Luis Ramos
0eab1b2339
Merge Spree::BaseController with ApplicationController
2021-01-15 21:59:16 +00:00
Matt-Yorkley
c0c7c6ec78
Update checkout helper summing and add test coverage
2021-01-15 17:29:21 +00:00
Matt-Yorkley
5593da2928
Delete dead code #update_hooks
...
These hooks allow Spree core to be modified by other gems and apps without changing Spree code. We don't use it. #YAGNI
2021-01-15 16:49:45 +00:00
Matt-Yorkley
8cc4c6a63f
Introduce soft-deprecation strategy when modifying tax rates
...
If an admin changes the amount on a tax rate, and that rate has been used by adjustments in the past, we need to soft-delete and clone it to preserve the data integrity of previous adjustments that were created using that rate.
2021-01-15 13:38:03 +00:00
Pau Pérez Fabregat
f240402c43
Merge pull request #6654 from Matt-Yorkley/update-without-callbacks
...
Remove #update_attributes_without_callbacks
2021-01-15 12:24:42 +01:00
Cillian O'Ruanaidh
79668e06a7
Remove ability to create new product from products page, use /admin/products/new instead.
...
It's simpler if there is just one place to add a new product. Closes #6650
This removes the 'creating directly from the new product path' test scenario because we have another 'assigning important attributes' scenario above which provides enough coverage.
2021-01-15 10:24:50 +00:00
Cillian O'Ruanaidh
110d692ffa
Include the 'Ready for' time for the order cycle in the Notify Producers Email
...
This is so people can distinguish which order cycle the email is referring to. Fixes #6371
2021-01-15 09:24:05 +00:00
Andy Brett
7ca81f45d0
Merge pull request #6641 from Matt-Yorkley/shipping-method-soft-deletion
...
Ensure ShippingMethod is correctly using soft-deletion
2021-01-14 11:53:19 -08:00
Andy Brett
18dcbbd892
Merge pull request #6613 from Matt-Yorkley/variant-override-serialization
...
Don't serialize all variant override objects where they are not needed
2021-01-14 10:59:11 -08:00
Andy Brett
81ea71af94
Merge pull request #6652 from jibees/6651-remove-trailing-asterisk-on-non-mandatory-field
...
remove asterisk on 'display as' field unit value for a product
2021-01-14 10:09:15 -08:00
Pau Pérez Fabregat
929ae82e00
Merge pull request #6574 from Matt-Yorkley/bye-bye-spree-paypal
...
Bye Bye Spree Paypal
2021-01-14 18:16:44 +01:00
Pau Pérez Fabregat
9689fe2edf
Merge pull request #6384 from andrewpbrett/fix-product-descriptions
...
correctly display '&' and ' ' in product descriptions
2021-01-14 17:00:16 +01:00
Luis Ramos
fd0bba19a7
Adapt enterprises code and specs to new namespace Sets::EnterpriseSet
2021-01-14 09:41:07 +00:00
Luis Ramos
ed0441dc41
Fix a few more rubocop issues
2021-01-14 09:41:07 +00:00
Luis Ramos
19b12092a0
Fix rubocop issues and adapt exceptions file
2021-01-14 09:41:07 +00:00
Luis Ramos
5d6d7f7ad0
Adapt enterprise fees code and specs to new namespace of Sets::EnterpriseFeeSet
2021-01-14 09:41:07 +00:00
Luis Ramos
96a351ad0e
Adapt usage of Sets to their new location
2021-01-14 09:41:07 +00:00
Luis Ramos
187b4a1fc2
Add Sets namespace to each set file
2021-01-14 09:41:07 +00:00
Luis Ramos
8e65d29b02
Move sets to specific services namespace
2021-01-14 09:41:07 +00:00
Pau Pérez Fabregat
9db4f9be15
Merge pull request #6634 from Matt-Yorkley/jobs-cleanup
...
Jobs cleanup
2021-01-14 10:08:15 +01:00
Maikel
168958311a
Merge pull request #6656 from Matt-Yorkley/payment-identifier
...
Fix payment identifier generation
2021-01-14 17:34:38 +11:00
Maikel
fbda1fffd7
Merge pull request #6653 from Matt-Yorkley/dead-code-available-payment
...
Dead code: #has_available_payment
2021-01-14 17:33:07 +11:00
Maikel
50472d18e0
Merge pull request #6642 from coopdevs/doc-customer-serializer
...
Doc customer serializer
2021-01-14 17:28:34 +11:00
Maikel
14842f52fc
Merge pull request #6633 from Matt-Yorkley/inverse-of
...
Adding inverse_of
2021-01-14 17:25:51 +11:00
Andy Brett
bbd7fd0350
handle nil product descriptions
2021-01-13 20:57:27 -08:00
Maikel Linke
be229c9002
Simplify email config by removing unused option
...
Spree used to give you more options to configure ActionMailer but our
setup is much simpler. We can remove unused code.
The removed option was never used by OFN and defaulted to true. We don't
need a database migration because the value isn't set in the database.
2021-01-14 12:05:41 +11:00
Andy Brett
8c4d12a501
limit item counter to max quantity available even if amount is manually filled in
2021-01-13 16:23:41 -08:00
Matt-Yorkley
5f2dc38241
Merge pull request #6098 from brymut/item-counter-fix
...
Fix #5989 Item counter accepts higher amount than available stock
2021-01-13 22:33:08 +01:00
Andy Brett
c29d57b54e
Merge pull request #6369 from Matt-Yorkley/broken-variants
...
Fix variant data inconsistencies
2021-01-13 11:10:44 -08:00
Pau Pérez Fabregat
6e48607760
Merge pull request #6629 from jibees/6199-alignment-readyfor-ipad
...
6199 adjust alignment on the Order Cycle component on ipad
2021-01-13 19:20:14 +01:00
Matt-Yorkley
18c9e16303
Fix payment identifier generation
...
Upstream fix from Spree 2.2.
See: 4e747187d7
2021-01-13 17:37:22 +00:00
Matt-Yorkley
7d0ec48bcf
Improve performance on summing adjustments and payment
...
:amount is a database field in these cases, as opposed to a method that returns a computed result. Calling `.sum(:amount)` is much more efficient here as it computes the sum at database level, as opposed to `.map(&:amount).sum`, which would fetch and instanciate all the objects first, and then sum the amounts after.
2021-01-13 16:16:49 +00:00
Matt-Yorkley
561cf23dc1
Remove #update_attributes_without_callbacks
...
This is a hacky Spree method that's removed in Spree 2.2
See: 7deba6a152
2021-01-13 16:02:21 +00:00
Matt-Yorkley
8d338a06f3
Delete dead code #has_available_payment
...
This is removed in Spree 2.2, as it serves no purpose.
See: 0617bdce30
2021-01-13 15:48:02 +00:00
Pau Perez
acd4dddf1b
Doc how balance_value works
...
[skip ci]
2021-01-13 12:50:41 +01:00
Jean-Baptiste Bellet
dcbf02bc47
remove asterisk on 'display as' field unit value for a product
...
as it's not a mandatory field
2021-01-13 11:30:08 +01:00
Andy Brett
5723a79409
check for content.present?
2021-01-11 21:21:24 -08:00
Matt-Yorkley
ca4de40fa2
Associate all adjustments with an order
...
This change is introduced in the adjustments updates from Spree 2.2 and used heavily in new scopes and methods (not included here).
2021-01-11 17:35:35 +00:00
Jean-Baptiste Bellet
8399b82bfd
rename component to spinner
...
A name for a "thing" rather a state
2021-01-11 16:49:56 +01:00
Matt-Yorkley
46ff247bc9
Ensure ShippingMethod#destroy is using soft-deletion
...
25f5c2daf8
We've already applied some of the changes in this commit during previous Spree upgrade work, but there were a couple of bits missing.
2021-01-11 15:46:38 +00:00
Jean-Baptiste Bellet
26edd83a54
do not include inside a javascript asset
...
I made a mistake by using it inside a javascript asset
revert part of commit e34050f7c
2021-01-11 16:33:44 +01:00
Jean-Baptiste Bellet
71dc5a8ff0
remove trailing space
2021-01-11 16:29:13 +01:00
Jean-Baptiste Bellet
e34050f7cb
add wrapper to show/hide loading spinner
2021-01-11 16:23:22 +01:00
Jean-Baptiste Bellet
544a7407e3
specify max-width to not overflow parent element
2021-01-11 16:22:47 +01:00
Jean-Baptiste Bellet
1b4254a5cf
Revert "replace code by reusable component"
...
This reverts commit 4d953abbe9 .
2021-01-11 16:12:17 +01:00
Pau Perez
dfed20d634
Consider awaiting_return, returned in balance
...
These states are reached when the order is complete and shipped. An
admin can create a new return authorization, which will set the order in
`awaiting_return` state. It's only after, when we call
`return_authorization#receive` that the return authorization moves to
`received` state and the order to `returned`.
You can do so from the UI by editing the return authorization and
clicking on Receive. However, we didn't find any order in such state in
UK, FR and AU. The UX is quite obfuscated. That must be why no users
clicked on it.
The `returned` state cannot count for the balance as is, since some of
the products are returned to the shop. That's enough for now.
2021-01-11 15:50:19 +01:00
Pau Perez
aa3fc71626
Consider resumed & payment orders in balance
...
These order states are already taken care of because they fall in the
`WHEN state IS NOT NULL` case.
2021-01-11 15:50:19 +01:00
Pau Perez
5018e88a34
Consider all states prior to checkout in balance
2021-01-11 15:50:19 +01:00
Pau Perez
398467e7ed
Hide new balance impl. under feature toggle
...
This makes it possible to deploy it without releasing it to users since
the toggle is not enabled for anyone.
It aims to make the balance calculation consistent across pages.
2021-01-11 15:50:19 +01:00
Pau Perez
2e9bae0ea5
Move relation includes out of query object
...
This query object is meant to be reusable but those includes are
context-specific and will likely not be needed when reusing the query
elsewhere. If we keep them there, chances are next dev might not notice
it and will introduce a performance regression.
2021-01-11 15:50:19 +01:00