filipefurtad0
328aee6a03
Update all locales with the latest Transifex translations
2024-11-17 20:47:52 -06:00
Rachel Arnould
db79af45fb
Merge pull request #12879 from chahmedejaz/task/12776-pay-suppliers-report
...
[Flower Farms] - Pay Suppliers Report
2024-11-15 11:36:29 +01:00
Ahmed Ejaz
ed7685222e
12776: fix included tax on fees
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
4965e2bb9a
Update lib/reporting/reports/suppliers/helpers/line_items_access_helper.rb
...
Co-authored-by: David Cook <david@redcliffs.net >
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
6b3b29ac39
12776: refactor spec
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
9bcdac8f30
12776: rename vat to tax
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
e2d999da8d
12776: use EnterpriseFeeCalculator in specs
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
bc57447d54
12776: refactor supplier_adjustments method
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
f3e086ad59
12776: remove unnecessary include
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
298c0e8d7f
fix reported issues:
...
- wrong enterprise fees
- always 0 tax on fees
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
ed559b5257
update specs to have more line items
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
1fbdf25296
12776: fix missing order numbers
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
ec0d2d346b
use to_date for locale based formating
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
68c0d98736
add slash for abn acn
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
458c8f7608
Update lib/reporting/reports/suppliers/helpers/columns_helper.rb
...
Co-authored-by: David Cook <david@redcliffs.net >
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
654263a823
add systems spec
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
77f9c6587c
fix specs
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
13a614a5aa
fix rubocop lines issue
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
add973f1ff
12776: add new line
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
4349e42a84
12776: add specs
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
7cb28fd064
12776: add supplier report
2024-11-15 11:09:56 +01:00
Ahmed Ejaz
122a64e488
12776: add new report option
2024-11-15 11:09:56 +01:00
Maikel
8c6c1e28ff
Merge pull request #12967 from rioug/fix-bugsnag-notify
...
Fix Bugsnag call to notify
2024-11-14 13:42:23 +11:00
David Cook
889bec7404
Merge pull request #12961 from mkllnk/total-on-hand
...
Remove unused stock aggregation
2024-11-13 16:35:55 +11:00
David Cook
3f91027c51
Merge pull request #12953 from mkllnk/test-secret-collision
...
Avoid collision of test secrets
2024-11-13 15:58:41 +11:00
Gaetan Craig-Riou
2f9200b68b
Per review, use a better name
2024-11-11 14:03:10 +11:00
filipefurtad0
5d9bb9a8d5
Update all locales with the latest Transifex translations
2024-11-10 18:03:57 -06:00
Filipe
7b677796c1
Merge pull request #12797 from rioug/report-fix-supplier
...
Fix supplier loading on Product & inventory report
2024-11-10 18:03:20 -06:00
Gaetan Craig-Riou
eb66244b74
Fix Bugsnag call to notify
...
Make sure we add metadata as expected:
https://docs.bugsnag.com/platforms/ruby/rails/reporting-handled-errors/#add_metadata
2024-11-06 14:01:48 +11:00
Gaetan Craig-Riou
9afd545897
Merge pull request #12959 from openfoodfoundation/dependabot/npm_and_yarn/jquery-ui-1.14.1
...
Bump jquery-ui from 1.14.0 to 1.14.1
2024-11-04 10:25:26 +11:00
Gaetan Craig-Riou
36f7063897
Merge pull request #12958 from openfoodfoundation/dependabot/npm_and_yarn/elliptic-6.6.0
...
Bump elliptic from 6.5.7 to 6.6.0
2024-11-04 10:00:23 +11:00
Gaetan Craig-Riou
a53a697e66
Merge pull request #12956 from openfoodfoundation/dependabot/npm_and_yarn/trix-2.1.8
...
Bump trix from 2.1.7 to 2.1.8
2024-11-04 09:58:42 +11:00
Gaetan Craig-Riou
e9349ce79d
Merge pull request #12955 from openfoodfoundation/dependabot/npm_and_yarn/floating-ui/dom-1.6.12
...
Bump @floating-ui/dom from 1.6.11 to 1.6.12
2024-11-04 09:57:39 +11:00
Maikel Linke
271475893d
Remove unused stock aggregation
2024-11-01 16:46:35 +11:00
filipefurtad0
49a24ebd33
Update all locales with the latest Transifex translations
2024-10-31 19:05:25 -06:00
Filipe
a08b0a8b32
Merge pull request #12917 from nicogaldamez/ignore-name-column-for-customers
...
Ignores name column on customer model
2024-10-31 17:35:47 -06:00
Filipe
0d97f992b9
Merge pull request #12943 from mkllnk/sanitise
...
Sanitise HTML attributes in the database
2024-10-31 17:32:56 -06:00
Filipe
996d2f0d46
Merge pull request #12947 from mkllnk/staging-baseline
...
Add scripts to save and restore baseline data
2024-10-31 16:47:23 -06:00
dependabot[bot]
f01a33c545
Bump jquery-ui from 1.14.0 to 1.14.1
...
Bumps [jquery-ui](https://github.com/jquery/jquery-ui ) from 1.14.0 to 1.14.1.
- [Release notes](https://github.com/jquery/jquery-ui/releases )
- [Commits](https://github.com/jquery/jquery-ui/compare/1.14.0...1.14.1 )
---
updated-dependencies:
- dependency-name: jquery-ui
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-31 09:58:26 +00:00
dependabot[bot]
48c88d426e
Bump elliptic from 6.5.7 to 6.6.0
...
Bumps [elliptic](https://github.com/indutny/elliptic ) from 6.5.7 to 6.6.0.
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.7...v6.6.0 )
---
updated-dependencies:
- dependency-name: elliptic
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-31 02:16:59 +00:00
dependabot[bot]
f646a30dca
Bump trix from 2.1.7 to 2.1.8
...
Bumps [trix](https://github.com/basecamp/trix ) from 2.1.7 to 2.1.8.
- [Release notes](https://github.com/basecamp/trix/releases )
- [Commits](https://github.com/basecamp/trix/compare/v2.1.7...v2.1.8 )
---
updated-dependencies:
- dependency-name: trix
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-30 09:47:49 +00:00
dependabot[bot]
1e21939963
Bump @floating-ui/dom from 1.6.11 to 1.6.12
...
Bumps [@floating-ui/dom](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/dom ) from 1.6.11 to 1.6.12.
- [Release notes](https://github.com/floating-ui/floating-ui/releases )
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/dom/CHANGELOG.md )
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/dom@1.6.12/packages/dom )
---
updated-dependencies:
- dependency-name: "@floating-ui/dom"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-30 09:47:37 +00:00
Maikel Linke
337113000f
Avoid collision of test secrets
...
A test was failing locally because I have the OpenID client secret set
in my environment. And the dummy value was the same as another test key.
So it got replaced with the wrong value.
2024-10-30 16:03:29 +11:00
David Cook
3756e368c8
Merge pull request #12921 from rioug/12908-error-when-tax-refund
...
Add Bugsnag notification if we reach tax rate refund code
2024-10-30 14:51:40 +11:00
Gaetan Craig-Riou
54acc97fa1
Merge pull request #12951 from MichaelDimmitt/fix-typo
...
fix typo
2024-10-30 11:08:12 +11:00
michael
0f6f7b332c
fix typo
2024-10-29 08:18:14 -04:00
Maikel
946471923a
Merge pull request #12895 from dacook/update-release-template
...
Update release template
2024-10-29 16:11:18 +11:00
Maikel Linke
3f353690c7
Load staging baseline even if db in use
2024-10-29 12:44:46 +11:00
Maikel
b8822ee179
Merge pull request #12945 from mkllnk/dfc-amend-after-cancel
...
Amend backorder after cancellations
2024-10-29 11:26:18 +11:00
Gaetan Craig-Riou
701504fbb3
Merge pull request #12938 from mkllnk/restock
...
Spec restock after order cancellation
2024-10-28 09:56:01 +11:00
filipefurtad0
e9900ec1c7
Update all locales with the latest Transifex translations
2024-10-25 09:35:51 -06:00
Maikel Linke
8a0d9d99e5
Add scripts to save and restore baseline data
2024-10-25 15:07:39 +11:00
Maikel Linke
decf1e6f03
Move old Buildkite scripts to archive folder
...
We could delete them all but I want use some of their wisdom for new CI
scripts.
2024-10-25 14:23:33 +11:00
Maikel Linke
e0638b1765
Amend backorder after cancellations
...
The new job class blends code from the BackorderJob and the
CompleteBackorderJob for the specific case of adjusting quantities after
an order has been cancelled.
I would like to write a more general class which can be used for any
order amendmends but this was the quickest solution to cater for
currently running pilots.
2024-10-24 17:08:50 +11:00
Maikel Linke
a5f677f748
Create OidcAccount factory for simpler specs
2024-10-24 17:08:45 +11:00
Maikel Linke
63c83a19d6
Fix backorder spec with incomplete test data
2024-10-24 16:21:39 +11:00
Maikel
762e6ec568
Merge pull request #12940 from dacook/bug-12939
...
Bug 12939
2024-10-24 10:30:37 +11:00
Maikel Linke
d2e5087668
Remove redundant HTML sanitisation
...
We don't need to run the sanitiser each time we read an attribute. It's
a waste of time.
2024-10-24 08:47:11 +11:00
Maikel Linke
169e1cf288
Sanitise HTML attributes in the database
2024-10-24 08:47:11 +11:00
David Cook
45ca2961ec
Avoid crash
2024-10-23 22:06:53 +11:00
David Cook
1d75aa45ef
spec
2024-10-23 21:55:49 +11:00
David Cook
a123369f8d
Merge pull request #12935 from mkllnk/dfc-doc-deterministic
...
Make DFC API docs deterministic
2024-10-23 16:59:55 +11:00
Maikel Linke
90589ae868
Spec restock after order cancellation
2024-10-23 16:35:59 +11:00
Maikel Linke
167a69d2ef
Spec change in order state more precisely
2024-10-23 14:46:12 +11:00
Maikel Linke
09524e266f
Fix method name description
2024-10-23 14:42:02 +11:00
Maikel
1c58b061b4
Merge pull request #12934 from rioug/fix-unit-price-spec
...
Use the correct spanish translation
2024-10-22 10:21:26 +11:00
Gaetan Craig-Riou
24df29ddf5
Use the correct spanish translation
...
Translation has been updated so we need to use the correct spanish
word
2024-10-22 10:10:00 +11:00
drummer83
9f084057a1
Update all locales with the latest Transifex translations
2024-10-21 11:11:39 +02:00
Gaetan Craig-Riou
3f22e8cca7
Fix Bugsnag payload data
2024-10-21 11:13:42 +11:00
Konrad
c3b5456433
Merge pull request #12912 from chahmedejaz/task/12911-remove-admin-v3-toggle
...
Remove the admin_style_v3 toggle from Production and Staging environments
2024-10-19 13:41:14 +02:00
Konrad
7b0519dab9
Merge pull request #12927 from mkllnk/report-dates
...
Filter reports by last 3 months by default
2024-10-19 13:12:20 +02:00
Maikel
2609298d88
Merge pull request #12929 from mkllnk/dfc-backorder-fix
...
Handle case of BackorderJob having no work
2024-10-18 10:04:36 +11:00
Maikel
783de09987
Merge pull request #12932 from mkllnk/dfc-offline-token
...
Request offline access when connecting OIDC account
2024-10-18 10:03:25 +11:00
Maikel Linke
7b8aeb7ef8
Request offline access when connecting OIDC account
2024-10-18 09:39:49 +11:00
Maikel Linke
9c7105e764
Handle case of BackorderJob having no work
2024-10-17 15:39:32 +11:00
Maikel
afff200680
Merge pull request #12923 from openfoodfoundation/dependabot/npm_and_yarn/trix-2.1.7
...
Bump trix from 2.1.6 to 2.1.7
2024-10-17 15:26:18 +11:00
Maikel Linke
6c431d4052
Fixup specs to use the new datepicker tools
2024-10-17 15:08:02 +11:00
Maikel Linke
2b8487cc6d
Parse given datetime for reports properly
2024-10-17 15:08:02 +11:00
Maikel Linke
b9a72381fc
Fix datepicker infinite loop
...
The new default dates were not aligned with the assumption that the
datepicker would open on the current date. The datepicker helper would
try to navigate to the previous month or next month in relation to the
reference date. Now with the wrong reference date, it would infinitely
go into the past or future, not finding the right year and month.
I chose a more robust approach of setting the year and month directly
which the user can do as well. Then we don't need a reference date.
2024-10-17 15:06:56 +11:00
Maikel Linke
ea8e925077
Show default date range to user in date picker
2024-10-17 13:16:12 +11:00
Maikel Linke
a13e5ced3d
Select default dates for Packing report, too
2024-10-17 13:16:12 +11:00
Maikel Linke
aa7fffa5a2
Filter reports by last 3 months by default
...
The values are not shown on the screen and the user doesn't know which
default dates are applied but the filtering works.
2024-10-17 13:16:12 +11:00
Maikel Linke
3227922c76
Use reports helper to DRY
2024-10-17 13:16:12 +11:00
Maikel Linke
aa2a5757ec
Move Customers report spec to own file
2024-10-17 13:16:12 +11:00
David Cook
197363b199
Merge pull request #12924 from openfoodfoundation/dependabot/npm_and_yarn/hotwired/turbo-8.0.12
...
Bump @hotwired/turbo from 8.0.11 to 8.0.12
2024-10-17 09:49:22 +11:00
Konrad
a023443c75
Merge pull request #12880 from rioug/5574-fix-checkout-order-total-calc
...
Fix checkout order total and payment fees calculation
2024-10-16 21:16:34 +02:00
Nicolás Galdámez
2e29426834
Deletes failing test
...
It was a test associated with the migration from name to first_name +
last_name
2024-10-16 08:32:18 -03:00
Nicolás Galdámez
8e4d306901
Ignores name column on customer model
...
It's not being used because now there are columns for first name and
last name
2024-10-16 08:32:18 -03:00
dependabot[bot]
38196e8ff3
Bump @hotwired/turbo from 8.0.11 to 8.0.12
...
Bumps [@hotwired/turbo](https://github.com/hotwired/turbo ) from 8.0.11 to 8.0.12.
- [Release notes](https://github.com/hotwired/turbo/releases )
- [Commits](https://github.com/hotwired/turbo/commits )
---
updated-dependencies:
- dependency-name: "@hotwired/turbo"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-16 09:12:53 +00:00
dependabot[bot]
475c9fb4ab
Bump trix from 2.1.6 to 2.1.7
...
Bumps [trix](https://github.com/basecamp/trix ) from 2.1.6 to 2.1.7.
- [Release notes](https://github.com/basecamp/trix/releases )
- [Commits](https://github.com/basecamp/trix/compare/v2.1.6...v2.1.7 )
---
updated-dependencies:
- dependency-name: trix
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-16 09:12:41 +00:00
Ahmed Ejaz
c48162388c
12911: remove admin_style_v3 toggle for prod and staging
2024-10-16 13:14:42 +05:00
Gaetan Craig-Riou
f024aff45d
Add Bugsnag notification if we reach tax rate refund code
...
The original Spree code allow for a tax adjustment to be considered a
refund in a specific scenario:
- instance is using inclusive tax
- instance that applies different tax rate in different tax zones
This scenario should not happen with how our instances are configured
More info: https://github.com/openfoodfoundation/openfoodnetwork/pull/6565#discussion_r566535431
2024-10-16 11:37:21 +11:00
Maikel
ed668ded0a
Merge pull request #12913 from mkllnk/dfc-import-items
...
Import product's invalid weight as 1 item
2024-10-16 10:47:12 +11:00
Gaetan Craig-Riou
b461d499ad
Merge pull request #12914 from mkllnk/remove-stock-location-from-return-authorization
...
Remove StockLocation from ReturnAuthorization
2024-10-16 10:26:09 +11:00
Gaetan Craig-Riou
c1c281122f
Merge pull request #12898 from dacook/buu-producer-specs
...
[BUU] Add missing specs
2024-10-16 10:05:20 +11:00
David Cook
8c4cc051a4
Merge pull request #12916 from openfoodfoundation/dependabot/npm_and_yarn/hotwired/turbo-8.0.11
...
Bump @hotwired/turbo from 8.0.10 to 8.0.11
2024-10-16 10:01:50 +11:00
David Cook
d5b2408947
Reveal un-implemented tests
2024-10-16 09:51:04 +11:00
Maikel Linke
1eb70370c7
Import product's invalid weight as 1 item
...
We previously stored a scale which made the product screen believe that
we are dealing with weight.
2024-10-16 09:27:49 +11:00
Filipe
97b6289263
Merge pull request #12787 from rioug/move-variant-unit-attributes-to-variant
...
[Product Refactor] Move variant unit sizes to variant
2024-10-15 19:58:45 +01:00
dependabot[bot]
bda28dfaf7
Bump @hotwired/turbo from 8.0.10 to 8.0.11
...
Bumps [@hotwired/turbo](https://github.com/hotwired/turbo ) from 8.0.10 to 8.0.11.
- [Release notes](https://github.com/hotwired/turbo/releases )
- [Commits](https://github.com/hotwired/turbo/compare/v8.0.10...v8.0.11 )
---
updated-dependencies:
- dependency-name: "@hotwired/turbo"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-15 09:13:53 +00:00
Maikel Linke
d1ebe4e1d1
Make DFC API docs deterministic
2024-10-15 15:47:31 +11:00
Maikel Linke
a64aea4b9c
Remove StockLocation from ReturnAuthorization
...
We have only one default location and don't need it associated to
anything.
2024-10-15 13:36:57 +11:00
David Cook
cc9b764f0f
Fix rubocop
2024-10-15 10:37:20 +11:00
David Cook
ac5fa21ff2
Clean up
2024-10-15 10:33:20 +11:00
Gaetan Craig-Riou
781fcf21b9
Merge pull request #12910 from openfoodfoundation/dependabot/npm_and_yarn/jasmine-core-5.4.0
...
Bump jasmine-core from 5.3.0 to 5.4.0
2024-10-15 10:22:30 +11:00
Gaetan Craig-Riou
56d2642191
Merge pull request #12889 from openfoodfoundation/dependabot/npm_and_yarn/trix-2.1.6
...
Bump trix from 2.1.5 to 2.1.6
2024-10-15 10:20:43 +11:00
Rachel Arnould
f54552f939
Merge pull request #12886 from rioug/12855-VINE-connected-app
...
[Citi OFN Voucher] Add VINE connected app
2024-10-14 15:32:09 +02:00
dependabot[bot]
fb5740b38b
Bump trix from 2.1.5 to 2.1.6
...
Bumps [trix](https://github.com/basecamp/trix ) from 2.1.5 to 2.1.6.
- [Release notes](https://github.com/basecamp/trix/releases )
- [Commits](https://github.com/basecamp/trix/compare/v2.1.5...v2.1.6 )
---
updated-dependencies:
- dependency-name: trix
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-14 09:40:36 +00:00
dependabot[bot]
db14080a7f
Bump jasmine-core from 5.3.0 to 5.4.0
...
Bumps [jasmine-core](https://github.com/jasmine/jasmine ) from 5.3.0 to 5.4.0.
- [Release notes](https://github.com/jasmine/jasmine/releases )
- [Changelog](https://github.com/jasmine/jasmine/blob/main/RELEASE.md )
- [Commits](https://github.com/jasmine/jasmine/compare/v5.3.0...v5.4.0 )
---
updated-dependencies:
- dependency-name: jasmine-core
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-10-14 09:27:08 +00:00
Gaetan Craig-Riou
01337c12f0
Post rebase, fix product cloning spec
2024-10-14 15:02:35 +11:00
Gaetan Craig-Riou
f8eeca856e
Fix invoice print specs
2024-10-14 15:02:35 +11:00
Gaetan Craig-Riou
67c11333f3
Use AdminTooltipComponent, instead of partial
2024-10-14 15:02:35 +11:00
Gaetan Craig-Riou
40afe7e0ab
Fix rebase issue
2024-10-14 15:02:34 +11:00
Gaetan Craig-Riou
ef1f3207f7
Update spec/system/admin/products_v3/update_spec.rb
...
Co-authored-by: Maikel <maikel@email.org.au >
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
b0433bd8f5
Re add test for invalid cloned products
...
There is no easy way to make the original product invalid, but we can
make sure the cloned product will be invalid. The cloned product add
"COPe OF " in front of the product's name, so by starting with a name
that's long enough, the cloned product will have a name longer that 255
char and will then be invalid.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
755a394704
Fix spec to remove reliance on browser's message
...
Client side validation messages depend on the browser's locale, which
we have no controll over. Now we just check a message is set.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
04e14bf38b
Per review, check value are saved in the database
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
ce0c7929a7
Per review, remove the use of raw
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
2a671d491d
Remove commented out code
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
7c2c614f90
Update spec/models/spree/variant_spec.rb
...
Co-authored-by: David Cook <david@redcliffs.net >
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
3bb2232bc1
Remove non updatable check when updating a product
...
After the product redactor it only checked for the "description" on
product, which is actually skipped when doing an update.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
377f035ea8
Fix bulk coop report
...
The current spec is useless, but it has been addressed on master
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
dbca2e2b56
Add all columns moved to variant to ignored_columns
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
0695b434a2
Fix rebase issue
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
9db417319d
Improve variant related validation when creating product
...
I disabled Metrics/AbcSize for ensure_standard_variant as I don't think
that's hard to understand the code. And utimately it will be removed
once product actually becomes optional.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
a500c75ee9
Add stying for the unit pop out
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
630c398b12
Move unit popout css to a partial
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
64f60d1c8c
Fix small bug on edit variant page
...
- make sure the weight is only cleared when needed
- make sure the displayed unit is up to date
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
218d07c90d
Fix product import controller
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
83a619b097
Fix bulk order management page
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
fa986f3fc2
Fix orders and fulfillment report
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
977b6e6c2a
Fix minor differences in local env and CI
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
f7446749ff
Fix Unit price system spec
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
844cab458e
Post rebase fix product import system spec
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
8ec1f61cd7
Fix legacy bulk edit product system spec
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
893b541dca
Fix product system spec
...
The pending spec are to be fix after a rebase, master currently as
some changes which will make this easier
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
4ae392490b
Fix variant system spec
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
cda57fdb44
Add toggleOnHand action
...
It replicate the behavior of setOnDemand angular directive
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
25171413ef
Update Spree::Price parsing to match LocalizedNumber.parse
...
Spree::Price parsing was returning 0.0 when given a an empty string as
price, resulting in a variant being valid even if no price was given. It
only happened if `Spree::LocalizedNumber` wasn't used.
Spree::LocalizedNumber` return nil if given a blank number.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
4ad6971121
Fix Bulk product edit system spec after rebase
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
8f38762393
Add missing translations for variant form
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
d55950a3c5
Fix rebase issue
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
45075a0ccd
Fix rebase typo
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
144a09916c
Use instance_double instead of double
...
Instance double, amongst other thing, verifies that any methods being
stubbed would be present on an instance of the class
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
00dfe6810f
Fix ProductDuplicator
...
There isn't away I could think of to create an invalid product, so I
removed those test
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
058d7eeb69
Use unit_value_with_description
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
324a4ff591
Backport fix for hungarian instance
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
7f16b6acde
Update variant form and rip out angular
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
ce268ec175
Add systemOfMeasurement to VariantUnitManager
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
cc85fed7cc
Add localizeCurrency and specs
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
45b0686130
Add PriceParser and UnitPrices and specs
...
This is in preparation for removing angular from the variant update
page.
Converted using https://www.codeconvert.ai/coffeescript-to-javascript-converter
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
4cd83d3fd4
Prettify javascript
...
Also update .prettierignore so that spec files get prettified as well
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
768825d689
Fix Bulk Edit product part 2
...
Note, the empty entry for unit scale need a css fix , currently showing
at half height
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
e8234ee4a0
Fix Bulk products edit page , part 1
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
94030527a4
Update jest configuration to include webpacker dir
...
This allows the test environment to correctly resolve import of
services in controller ie: `import OptionValueNamer from
"js/services/option_value_namer";`
The added benefit is we can now import package to be tested directly
without having to specify the whole relative path ie in test file you
can do : `import variant_controller from "controllers/variant_controller";`
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
6ff9650eaf
Fix legacy bulk edit products UI
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
b1b534aa1b
Fix product and variant api serializer
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
cd74a73680
Consolidate angular option value namer spec
...
Merge the two spec files into the correct one.
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
36c4d24c93
Fix angular option value namer
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
9b4cd014bf
Fix DFC supplied product builder
2024-10-14 15:01:18 +11:00
Gaetan Craig-Riou
c8bf23bdc2
Fix UnitPrice spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
df82dd0759
Fix API v0 variants controller spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
5ec39f994a
Fix spree admin products controller spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
8a31153d6d
Fix API v0 products controller spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
4109fbde70
Fix variant controller spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
37ae217afc
Fix product set spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
4fd115897a
Refactor ProductImport::EntryValidator
...
Move comparaison function to ProductImport::SpreadsheetEntry
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
e22804712e
Fix product importer
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
d7d253e58d
Fix Unit Price service
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
e2c762f06b
Refactor, use instance_double in variant spec
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
1ad7123a9d
Fix Spree::LineItem
2024-10-14 14:56:47 +11:00
Gaetan Craig-Riou
1793aa3532
Migrate unit sizes to variant
2024-10-14 14:56:46 +11:00
Gaetan Craig-Riou
d0fe1585d7
Move variant unit attributes to variant 2
...
Update Spree::Product and spec
2024-10-14 14:56:46 +11:00
Gaetan Craig-Riou
f58a3a859f
Move variant unit attributes to variant 1
...
Update Spree::Variant model and spec
2024-10-14 14:56:46 +11:00
Gaetan Craig-Riou
3b89cd5957
Fix option value namer
...
Uses the variant variant_unit, variant_unit_name, variant_unit_scale
2024-10-14 14:56:46 +11:00
Gaetan Craig-Riou
e33ed5141b
Fix weigths and measures
...
Use variant_unit, variant_unit_scale from the variant
2024-10-14 14:56:46 +11:00
Gaetan Craig-Riou
4d81b145ca
Add variant_unit_scale, variant_unit_name to variant
2024-10-14 14:56:46 +11:00
Konrad
7211b0d64a
Merge pull request #12897 from rioug/12891-product-preview-fix-price
...
[Product Preview] Fix price currency display
2024-10-12 18:14:01 +02:00
Maikel
52c1491b15
Merge pull request #12906 from mkllnk/dfc-stock-import
...
Fail gracefully on DFC product import errors
2024-10-11 13:50:09 +11:00
Maikel Linke
95ff0d8d4a
Fail gracefully on DFC product import errors
2024-10-11 12:10:23 +11:00
Maikel Linke
7d2d14320f
Spec that connector update fixed bug
2024-10-11 09:54:29 +11:00
Maikel
7d1551ed04
Merge pull request #12904 from mkllnk/dfc-connector
...
Bump DFC connector from 1.0.0.pre.alpha.12 to 1.0.0.pre.alpha.13
2024-10-11 09:52:45 +11:00
Maikel Linke
3e71459346
Update API doc
2024-10-11 09:15:42 +11:00
Maikel Linke
ce2c80283c
Bump datafoodconsortium-connector from 1.0.0.pre.alpha.12 to 1.0.0.pre.alpha.13
...
Changed
- Use nil as default value for all types except arrays.
2024-10-11 09:12:40 +11:00
Maikel Linke
2be3f7b86d
Update all locales with the latest Transifex translations
2024-10-10 17:08:38 +11:00
Maikel
2d975c5534
Merge pull request #12899 from mkllnk/dfc-stock-check
...
DFC Orders update for pilot 1 and 2
2024-10-10 17:06:18 +11:00
Maikel Linke
86c91143b7
Update more variant data on import
2024-10-10 16:59:04 +11:00
Maikel Linke
cde757efbd
Split growing class
2024-10-10 16:58:01 +11:00
Maikel Linke
260e7ba817
Update products when importing them multiple times
...
Instead of creating a new variant every time.
2024-10-10 16:57:58 +11:00
Maikel Linke
bda506528f
Fix import of zero-weight products
...
We don't allow variants to have zero weight or volume. But a DFC import
in production showed that some catalogs list products with zero weight.
Despite the products having a weight, it's simpler to treat these as
items.
2024-10-10 14:08:02 +11:00
Maikel Linke
e429cb7198
Style growing class
2024-10-10 14:06:42 +11:00
Maikel Linke
a838ef4a21
DRY DFC product import
2024-10-10 14:04:54 +11:00
Maikel Linke
f0b6403c1d
Fix locally flaky spec around date filters
...
This spec would fail on Australian systems early in the morning or in
other timezones accordingly.
2024-10-10 09:58:01 +11:00
Maikel Linke
71ca292c92
Synchronise stock with DFC catalog during checkout
...
This will delay the checkout request by a few seconds if there's stock
to sync. But we minimise the chance of missing reduced stock from orders
on another platform.
We still have a gap between the checkout and placing a backorder. In
that time we can't guarantee enough stock. But let's tackle that after
the pilot.
2024-10-09 14:47:07 +11:00
David Cook
bc87c98e92
Add some specs for the producer dropdowns
2024-10-09 13:02:39 +11:00
Gaetan Craig-Riou
5b8e0d734f
Use Spree::Money to display prices
...
This is to ensure the correct currency and currency configuration is
applied.
2024-10-09 11:02:24 +11:00
David Cook
216883101e
Update release template
...
[skip ci]
2024-10-08 21:02:02 +11:00
Maikel Linke
adf0340153
Remove duplicate method
...
The method `CheckoutCallbacks#valid_order_line_items?` was a duplicate
of `OrderStockCheck#valid_order_line_items?`.
Apparently, it had been extracted twice:
* 1d074c2151
* 06eb98bdf4
But the first commit duplicated the method while the second moved the
original declaration.
2024-10-08 16:57:36 +11:00
Maikel Linke
664f324db6
Sync stock of multiple linked catalogs
...
And the logic becomes a bit simpler.
2024-10-08 16:37:35 +11:00
Gaetan Craig-Riou
08308ba08e
Fix spec checking if VINE api is set up
...
The condition for checking the error now match a real scenario
2024-10-08 16:15:35 +11:00
Maikel Linke
c609107379
Avoid race condition between checkout and stock sync
2024-10-08 16:03:10 +11:00
Gaetan Craig-Riou
df67b53971
Re add VINE_API_URL env variable
...
And add error handling if the variable is not set
2024-10-08 13:26:57 +11:00
Maikel
6f2c5b5f7f
Merge pull request #12888 from mkllnk/dfc-stock
...
[DFC Orders] Backorder stock controlled products
2024-10-08 10:57:59 +11:00
Gaetan Craig-Riou
a3d8ae693d
Add encryption for ConnectedApps::Vine#data
...
Added layer of security, we encrypt the API key and related secret.
It requires setting up some encryption keys that can be generated wiht
`bin/rails db:encryption:init`
2024-10-07 15:09:58 +11:00
Gaetan Craig-Riou
b14a1e72f3
Handle api secret
...
The VINE Api require a secret and an API key to be used. The secret is
used to sign the request. The secret is linked to the API key so we need
to store it along side the key.
2024-10-07 15:09:58 +11:00
Gaetan Craig-Riou
224738e0a1
Per review, clean up code
2024-10-07 15:09:51 +11:00
Gaetan Craig-Riou
10c3c53aad
Fix translation per review.
2024-10-07 11:23:22 +11:00
Gaetan Craig-Riou
e5b7f89b32
Merge pull request #12887 from mkllnk/stock-cleanup2
...
Remove unneeded StockLocation code
2024-10-07 09:40:46 +11:00
filipefurtad0
b7c34ced26
Update all locales with the latest Transifex translations
2024-10-05 22:35:38 +01:00
Rachel Arnould
f5baa42bfc
Merge pull request #12860 from chahmedejaz/bugfix/12852-fix-select2-choices-fixed-height
...
[BUU] Fix Display ordering in shopfront field to allow re-ordering of the sequence
2024-10-04 16:59:54 +02:00
Maikel Linke
86238cc0ee
Update all locales with the latest Transifex translations
2024-10-04 17:10:58 +10:00
Maikel Linke
61aa02b3c3
Sync stock with DFC catalog after cart update
2024-10-04 16:25:17 +10:00
Maikel Linke
4b2099625c
Clarify method action with name
...
Thanks, David.
2024-10-04 14:34:17 +10:00
Maikel Linke
f8bd0a1cc7
Adjust backorder for stock controlled items
...
We aggregate quantities over the whole order cycle to account for
cancelations and order adjustments by admins.
2024-10-03 15:58:53 +10:00
Maikel Linke
09de223c93
Backorder stock controlled products
2024-10-03 13:30:16 +10:00
Maikel Linke
74c80c9fff
Prepare BackorderJob for stock controlled items
...
We want to trigger the backordering for any linked product now. So let's
do that check early and then select the variants in the background.
It means less data passed to the job and less space for race conditions.
2024-10-03 13:28:20 +10:00
Maikel Linke
11f3bbc566
Remove leftover recording
2024-10-03 13:28:17 +10:00
Maikel Linke
e5ee398f26
Re-use default stock location in specs
2024-10-03 08:24:16 +10:00
Maikel Linke
99c098f567
Ignore StockLocation#active, it's always active
2024-10-03 08:24:16 +10:00
Maikel Linke
4b1d7d8a41
Remove dead permission to access StockLocation
...
We don't have any UI to edit stock locations. So this ability is unused.
2024-10-03 08:24:15 +10:00
Maikel Linke
1e3c18f3f6
Remove unneeded method StockLocation#propagate_variant
2024-10-03 08:24:15 +10:00
Gaetan Craig-Riou
22428fc78d
ConnectedApps controller, handle ConnectedApps::Vine
...
Add logiv to connect and disconnect VINE API plus spec
2024-10-02 16:44:27 +10:00
Gaetan Craig-Riou
f980cb45f6
Add logic for ConnectedApps::Vine#connect and disconnect
2024-10-02 16:44:27 +10:00
Gaetan Craig-Riou
097c6dee2f
Add VineApiService and specs
...
It handles connection to the VINE API
2024-10-02 16:44:21 +10:00
Gaetan Craig-Riou
63a1b390e2
Merge pull request #12885 from mkllnk/stock-cleanup
...
Remove use of unnecessary backorderable default column
2024-10-02 16:24:08 +10:00
Gaetan Craig-Riou
1a30cf6495
Hide VINE token
2024-10-02 16:19:03 +10:00
Gaetan Craig-Riou
f7708d69a7
Add VineJwtService
...
Generate a JWT token to be used to connect to the VINE api
2024-10-02 16:16:28 +10:00
Gaetan Craig-Riou
6eb5986c68
Merge pull request #12884 from mkllnk/oc-index
...
Add database index to order cycle dates
2024-10-02 16:01:50 +10:00
Maikel Linke
4d9f396f40
Ignore unused column spree_stock_locations.backorderable_default
2024-10-02 15:16:05 +10:00
Maikel Linke
ac3730096f
Update specs to assume backorderable default
2024-10-02 15:13:00 +10:00
Maikel Linke
662467a1a4
Use database default value for stock_items.backorderable
2024-10-02 15:09:44 +10:00
Maikel Linke
af07358914
Assume on-demand is false by default
...
We have only one stock location and that has the default set to false.
Now we can simplify code.
The mentioned Bugsnag notification has not been found. The stock item is
always present in this case but it doesn't hurt to guard against it with
`&.`.
2024-10-02 15:06:48 +10:00
Maikel Linke
8e7e5fc20f
Add database index to order cycle dates
2024-10-02 12:05:13 +10:00
Gaetan Craig-Riou
aa5feb6605
Remove system spec
...
It's covered by unit test of order updater
2024-10-02 09:33:02 +10:00
Maikel
3c613f80a3
Merge pull request #12875 from macanudo527/docker/upgrade_to_dockerv2
...
Use Dockerv2
2024-10-02 08:53:24 +10:00
Gaetan Craig-Riou
83b6f58100
Merge pull request #12881 from mkllnk/card-payment-spec
...
Fix date dependent spec
2024-10-01 13:30:49 +10:00
Maikel Linke
17c32ae09a
Spec change more clearly
2024-10-01 13:16:16 +10:00
Maikel Linke
0474c591de
Fix date-dependent spec
2024-10-01 13:14:09 +10:00
Maikel
196956140e
Merge pull request #12856 from mkllnk/dfc-order
...
Place backorders for linked products via DFC integration
2024-10-01 10:51:00 +10:00
Gaetan Craig-Riou
b2b6847882
Fix test data
...
The future is now ! :D
2024-10-01 10:38:33 +10:00
Gaetan Craig-Riou
d01d312b4f
Fix updating pending payment
...
Check if payment actually have an adjustment before trying to update it
2024-10-01 10:22:47 +10:00
Gaetan Craig-Riou
a74cf97083
Fix spec when adding a product with transaction fee
...
Previous iteration did not actually check the payment fee had been
updated. It also checks the order total get correctly updated.
Spec is passing, so fixing the order updater also fix this bug
: https://github.com/openfoodfoundation/openfoodnetwork/issues/12512
2024-10-01 09:49:44 +10:00
Gaetan Craig-Riou
03dbd54b25
Fix order updater to update payment fees
...
The order updater did not take into account payment fees on pending
payment.
2024-09-30 16:15:59 +10:00
Gaetan Craig-Riou
fafd86a2db
Revert change made in https://github.com/openfoodfoundation/openfoodnetwork/pull/12538
...
Although the change fix the issue in the back office scenario, it has
the side effect of getting the order total out of sync. Updating a
payment adjustment need to be followed by udpating the order total and
payment amount to keep everything in sync.
2024-09-30 16:04:44 +10:00
Gaetan Craig-Riou
91f2ca9286
Merge pull request #12734 from cillian/replace-text-angular-with-trix
...
Replace text angular editor with trix editor in About Us and Shopfront message fields
2024-09-30 09:40:48 +10:00
filipefurtad0
3015beab99
Update all locales with the latest Transifex translations
2024-09-27 18:02:50 -06:00
Filipe
da0660c119
Merge pull request #12857 from chahmedejaz/task/12626-add-clone-failure-explaination
...
[BUU] Fix No explanation why cloning failed
2024-09-27 17:58:31 -06:00
Filipe
852dd41f89
Merge pull request #12836 from wandji20/wb-OFN-11600
...
Add browser unsaved changes modal when navigating from order summary page [OFN-11600]
2024-09-27 17:41:04 -06:00
Filipe
48993232d1
Merge pull request #12833 from dacook/page-titles
...
[admin] Update page titles
2024-09-27 16:59:43 -06:00
wandji20
0002b2e019
Clean up hardcoded values and improve readability
2024-09-27 16:52:55 -06:00
wandji20
84a2e6c24d
Add browser unsaved changes modal when navigation form order sumary page [OFN-11600]
2024-09-27 16:52:55 -06:00
David Cook
be4e0a259e
Specify alternate html_title
...
Because the page title has extra content.
2024-09-27 15:48:28 -06:00
David Cook
c362e8dd0d
Use page titles in HTML head
...
This is much more meaningful than the controller name, and is helpful for browser tab history.
2024-09-27 15:48:28 -06:00
Ahmed Ejaz
1550ca5da0
fix the choice drag issue
...
- disabled width on select2-search-choice-close so that it doesn't cover whole option
2024-09-27 16:57:35 +05:00
Cillian O'Ruanaidh
f474afaceb
Merge in latest :master and resolve conflict in app/models/enterprise.rb
2024-09-27 10:11:26 +01:00
Sigmund Petersen
8c71760556
Merge pull request #12784 from wandji20/wb-OFN-12774
...
Make OC edit warning modal cancel button redirect user to OC list [OFN-12774]
2024-09-27 10:42:54 +02:00
wandji20
37ab832b86
Remove window unload event listener from edit order cycle cancel link
2024-09-27 10:02:49 +02:00
wandji20
a11873559b
Make OC edit warning modal cancel button redirect user to OC list [OFN-12774]
2024-09-27 10:02:49 +02:00
Maikel Linke
51b3770188
Keep failed backorder job in dead set
...
From Sidekiq's view, the job is successful when we rescue an error and
it will discard it. But we want the option to inspect the job and retry
it. Failing jobs are also reported to Bugsnag automatically.
I didn't specify `retry: false` because that discards the job as well.
But `retry: 0` should sent it straight to the dead set. No automatic
retries but it's treated like a failed job.
2024-09-26 14:32:55 +10:00
Maikel Linke
989a6d57e0
Notify user of failed backorder completion
2024-09-26 14:32:55 +10:00
Maikel Linke
495634b60c
Send error notification to owner
2024-09-26 14:32:55 +10:00
Maikel Linke
49fd1dc4a6
Report backorder errors instead of failing checkout
2024-09-26 14:32:55 +10:00
Maikel Linke
e31e45b875
Place backorders in the background
2024-09-26 14:32:55 +10:00
Maikel Linke
61fec653cf
Abstract OrderLocker for re-use
2024-09-26 14:32:55 +10:00
Maikel Linke
eece738865
Restore concurrency spec for the checkout
...
This was abandoned when the checkout was re-designed. But I want to
refactor the order locking mechanism and it would be good to know that I
don't break anything.
2024-09-26 14:32:55 +10:00
Maikel Linke
2465780c1c
Import prices and stock levels from DFC catalog
...
We were already importing stock levels from offers but now we are
looking at catalog items as well.
2024-09-26 14:32:01 +10:00
Neal Chambers
21b7e6e567
Use Dockerv2
2024-09-26 09:21:00 +09:00
Gaetan Craig-Riou
eb8050d61d
Add spec reproducing the bug
2024-09-25 15:58:28 +10:00
Maikel Linke
9f43244312
Import on-demand stock setting in DFC import
2024-09-25 10:55:41 +10:00
Maikel Linke
66f080232f
Import DFC product images
2024-09-25 10:55:41 +10:00
Maikel Linke
7f62b49da5
Move catalog loading to where it's needed
2024-09-25 10:55:41 +10:00
Maikel Linke
070b93c531
Fall back to givin product id w/o retail variant
2024-09-25 10:55:40 +10:00
Maikel Linke
fb96f8f936
Fall back to given product w/o wholesale variant
...
The class is moving to providing all data with several methods instead
of a data class containing the information. That should be more
flexible. Still some work to do.
2024-09-25 10:55:40 +10:00
Maikel Linke
4303f0e974
Build API URLs to work with any FDC Shopify shop
...
We can extend this service class when there are other APIs. And
hopefully the DFC will provide a standard for this discovery at some
point.
2024-09-25 10:55:40 +10:00
Maikel Linke
2eec4c73bf
Apply 4 hour completion delay only to one enterprise
2024-09-25 10:55:40 +10:00
Maikel Linke
5ef85aef3e
Handle backorder cancellations
2024-09-25 10:55:40 +10:00
Maikel Linke
283db8f9d0
Adjust quantities of backorder before completion
2024-09-25 10:55:40 +10:00
Maikel Linke
95e620a78b
Add lookup of variants by semantic id
2024-09-25 10:55:40 +10:00
Maikel Linke
c948efd9ce
Add structure to adjust final quantities
2024-09-25 10:55:40 +10:00
Maikel Linke
95bc0cc679
Reduce complexity of BackorderJob
2024-09-25 10:55:40 +10:00
Maikel Linke
efe2b724e6
Find wholesale offer for retail variant
2024-09-25 10:55:40 +10:00
Maikel Linke
14c32c0d2e
Reduce complexity
2024-09-25 10:55:40 +10:00
Maikel Linke
8f4f873ba0
Move offer finding into separate class
...
It's going to be more complicated.
2024-09-25 10:55:40 +10:00
Maikel Linke
c0ae2ede2c
Complete order 4 hours after order cycle closed
2024-09-25 10:55:40 +10:00
Maikel Linke
3ec53a7d71
Parse updated order result
2024-09-25 10:55:40 +10:00
Maikel Linke
3849db7c48
Simplify order update call
2024-09-25 10:55:39 +10:00
Maikel Linke
7b286ea31d
Complete test for FDC Orders API
...
Previous specs testing the live API assumed an order to be present or
not present. You needed to provide the right state before recording. I
condensed more into one test that completes the cycle and is repeatable,
assuming no order to start with.
2024-09-25 10:55:39 +10:00
Maikel Linke
3e0eb8708e
Simplify service with ivar
2024-09-25 10:55:39 +10:00
Maikel Linke
c7fa3ff819
Simplify order update logic
2024-09-25 10:55:39 +10:00
Maikel Linke
f839452df9
Complete an open order
2024-09-25 10:55:39 +10:00
Maikel Linke
a7a38890f4
Add needed quantities to existing line items
2024-09-25 10:55:39 +10:00
Maikel Linke
caa6d284f0
Find and update existing open order
2024-09-25 10:55:39 +10:00
Maikel Linke
827e37cada
Start moving backorder logic to service
...
The job class is getting too big.
2024-09-25 10:55:39 +10:00
Maikel Linke
6c6927af84
Add SaleSession with correct OrderCycle times
...
Apparently, the FDC implementation uses those dates to finalise orders.
2024-09-25 10:55:39 +10:00
Maikel Linke
439f0cac64
Raise errors on DFC requests
...
The simplified API was only returning the response body, not allowing us
to inspect if an error occurred. Since an error should be an exception
when communicating with a standardised protocol, we raise an error and
keep our simple API.
2024-09-25 10:55:39 +10:00
Maikel Linke
98966f6b89
Place backorders for DFC products
2024-09-25 10:55:39 +10:00
Maikel Linke
260e4f7b00
Create BackorderJob to place wholesale orders
2024-09-25 10:55:39 +10:00
Gaetan Craig-Riou
0824430da5
Add Vine connected app
...
The connection/disconnection logic is yet to be implemented
2024-09-24 10:43:55 +10:00
Gaetan Craig-Riou
099da3fc6c
Merge pull request #12872 from mkllnk/enterprise-serialiser
...
Clean up enterprise serialiser for shop page speed
2024-09-23 10:14:44 +10:00
Gaetan Craig-Riou
7078c4ef03
Merge pull request #12871 from openfoodfoundation/dependabot/npm_and_yarn/body-parser-1.20.3
...
Bump body-parser from 1.20.2 to 1.20.3
2024-09-23 10:09:49 +10:00
Maikel Linke
318790d207
Remove unused join table
...
Enterprises used to have products and products have variants. But now
enterprises have variants directly.
2024-09-20 16:44:25 +10:00
Maikel Linke
2be8ef96be
Remove unreachable code
...
These two methods return early if `active` is falsey. So for the rest of
the method we can assume `active` to be truthy.
2024-09-20 16:35:41 +10:00
Maikel Linke
f6e4b107b0
Update all locales with the latest Transifex translations
2024-09-20 09:46:02 +10:00
Filipe
a5d17b4da9
Merge pull request #12459 from mkllnk/description-html
...
Sanitise HTML in long description of enterprise
2024-09-19 16:12:45 -06:00
Filipe
83ab9594f6
Merge pull request #12854 from chahmedejaz/task/11200-conditionally-hide-producer-column
...
[BUU2] Hide producer column when there's only one producer in the admin account
2024-09-19 15:42:15 -06:00
Filipe
562a24524b
Merge pull request #12848 from rioug/12770-product-preview
...
Product preview
2024-09-19 15:20:18 -06:00
Filipe
2809194b42
Merge pull request #12847 from dacook/fix-bug-12835
...
Fix bug #12835 for producer reports
2024-09-19 14:31:04 -06:00
Maikel
7d3eff2abb
Merge pull request #12845 from wandji20/wb-OFN-12281
...
Fix- chore(deps): bump debounced from 0.0.5 to 1.0.2
2024-09-19 11:22:30 +10:00
dependabot[bot]
c0a49df150
Bump body-parser from 1.20.2 to 1.20.3
...
Bumps [body-parser](https://github.com/expressjs/body-parser ) from 1.20.2 to 1.20.3.
- [Release notes](https://github.com/expressjs/body-parser/releases )
- [Changelog](https://github.com/expressjs/body-parser/blob/master/HISTORY.md )
- [Commits](https://github.com/expressjs/body-parser/compare/1.20.2...1.20.3 )
---
updated-dependencies:
- dependency-name: body-parser
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-18 23:20:33 +00:00
David Cook
f8bb33a9e8
Merge pull request #12869 from openfoodfoundation/dependabot/npm_and_yarn/hotwired/turbo-8.0.10
...
Bump @hotwired/turbo from 8.0.6 to 8.0.10
2024-09-19 09:19:24 +10:00
dependabot[bot]
24a25d31a0
Bump @hotwired/turbo from 8.0.6 to 8.0.10
...
Bumps [@hotwired/turbo](https://github.com/hotwired/turbo ) from 8.0.6 to 8.0.10.
- [Release notes](https://github.com/hotwired/turbo/releases )
- [Commits](https://github.com/hotwired/turbo/compare/8.0.6...v8.0.10 )
---
updated-dependencies:
- dependency-name: "@hotwired/turbo"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-18 09:50:44 +00:00
David Cook
4822a9ebcd
Merge pull request #12868 from rioug/fix-buu-permission
...
[BUU] Add missing permission check on product actions
2024-09-18 17:25:24 +10:00
Gaetan Craig-Riou
68fa903d61
Add missing permission check on buu action
...
Plus request spec
2024-09-18 10:24:09 +10:00
wandji20
c2e0c94f2e
Remove unused debounced plugin
2024-09-17 11:56:07 +01:00
David Cook
296997d558
Test to ensure report abilities
2024-09-17 13:23:14 +10:00
David Cook
a9ad6a2851
Grant product managers ability to create reports
...
We missed this in c31416c , oops.
2024-09-17 13:08:49 +10:00
David Cook
1078e7cd36
Update specs
...
The key here is the enterprise_relationship. This is required for the supplier to have permission to see the orders.
Curiously, the unit test still passes. All will be revealed in the next commit..
2024-09-17 12:55:22 +10:00
Gaetan Craig-Riou
40c4d38e45
Add permission check
2024-09-17 12:01:53 +10:00
Gaetan Craig-Riou
a25937321a
Remove ability of any admin user to see all product
...
And fix related spec
2024-09-17 11:46:55 +10:00
wandji20
a8db288425
Improve debounced initialised events
2024-09-17 01:56:44 +01:00
dependabot[bot]
a106eb10b6
Bump debounced from 0.0.5 to 1.0.2
...
Bumps [debounced](https://github.com/hopsoft/debounced ) from 0.0.5 to 1.0.2.
- [Release notes](https://github.com/hopsoft/debounced/releases )
- [Commits](https://github.com/hopsoft/debounced/commits/v1.0.2 )
---
updated-dependencies:
- dependency-name: debounced
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-17 01:36:37 +01:00
David Cook
a6d71f8dd1
Merge pull request #12861 from openfoodfoundation/dependabot/npm_and_yarn/express-4.21.0
...
Bump express from 4.19.2 to 4.21.0
2024-09-17 09:26:41 +10:00
David Cook
5c300d6d41
Merge pull request #12864 from openfoodfoundation/dependabot/npm_and_yarn/floating-ui/dom-1.6.11
...
Bump @floating-ui/dom from 1.6.10 to 1.6.11
2024-09-17 09:26:24 +10:00
dependabot[bot]
bb4ff5adc2
Bump @floating-ui/dom from 1.6.10 to 1.6.11
...
Bumps [@floating-ui/dom](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/dom ) from 1.6.10 to 1.6.11.
- [Release notes](https://github.com/floating-ui/floating-ui/releases )
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/dom/CHANGELOG.md )
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/dom@1.6.11/packages/dom )
---
updated-dependencies:
- dependency-name: "@floating-ui/dom"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-16 09:29:53 +00:00
dependabot[bot]
be548c506d
Bump express from 4.19.2 to 4.21.0
...
Bumps [express](https://github.com/expressjs/express ) from 4.19.2 to 4.21.0.
- [Release notes](https://github.com/expressjs/express/releases )
- [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md )
- [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0 )
---
updated-dependencies:
- dependency-name: express
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-15 23:49:21 +00:00
Gaetan Craig-Riou
955f8ba5ae
Merge pull request #12858 from openfoodfoundation/dependabot/npm_and_yarn/hotwired/turbo-8.0.6
...
Bump @hotwired/turbo from 8.0.5 to 8.0.6
2024-09-16 09:48:22 +10:00
Konrad
ad94da975a
Add hint about the required Transifex Client
2024-09-14 21:30:54 +02:00
drummer83
f33eb23909
Update all locales with the latest Transifex translations
2024-09-14 20:50:45 +02:00
Ahmed Ejaz
9d5806b858
12626: remove invalid_fields_error locale
2024-09-14 18:10:58 +05:00
Ahmed Ejaz
35f9c420fd
12852: remove unnecessary !important
2024-09-14 18:04:52 +05:00
Ahmed Ejaz
052e3b6380
12852: add remove choice icon for select2
2024-09-14 17:42:10 +05:00
Ahmed Ejaz
1545708d4e
12852: remove fix height for the select2-choices
2024-09-14 17:18:09 +05:00
Ahmed Ejaz
2a4d275f4b
12626: use rails default error messages
2024-09-14 02:44:43 +05:00
dependabot[bot]
9ead14b8a0
Bump @hotwired/turbo from 8.0.5 to 8.0.6
...
Bumps [@hotwired/turbo](https://github.com/hotwired/turbo ) from 8.0.5 to 8.0.6.
- [Release notes](https://github.com/hotwired/turbo/releases )
- [Commits](https://github.com/hotwired/turbo/compare/v8.0.5...8.0.6 )
---
updated-dependencies:
- dependency-name: "@hotwired/turbo"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-13 09:26:22 +00:00
Gaetan Craig-Riou
38721d9f36
Per review, fix the tab spec
...
Both tabs have the product name, so add check got the image on the
product details tab.
2024-09-13 14:33:46 +10:00
Gaetan Craig-Riou
3f6aaa74cc
Remove duplicated styling for tabs
...
It uses the same styling as #admin now share via mixins
2024-09-13 14:14:30 +10:00
Ahmed Ejaz
c08683412c
12626: add a fallback message
2024-09-13 01:43:37 +05:00
Ahmed Ejaz
4a38d7ef57
12626: add explaination for clone failure
2024-09-12 03:47:53 +05:00
Ahmed Ejaz
243a4a55b4
11200: add spec for display producer column
2024-09-11 12:03:49 +05:00
Ahmed Ejaz
5be53a40a9
11200: rename products scope
2024-09-11 11:54:38 +05:00
Ahmed Ejaz
76fdf3725a
11200: add explanations
2024-09-11 11:41:01 +05:00
Gaetan Craig-Riou
67f037280a
Add comment in shop view file
...
It wasn't possible to directly reuse the shopfront views because they
are still using angular.
2024-09-11 14:50:37 +10:00
Gaetan Craig-Riou
776b9fcdab
Re enable images partial import
2024-09-11 14:24:24 +10:00
Gaetan Craig-Riou
7e84d41e8c
Simplify modal opening by just rendering the modal in turbo stream
2024-09-11 14:20:41 +10:00
Gaetan Craig-Riou
68491559f3
Merge pull request #12790 from filipefurtad0/revisit_Orders_and_Distributors_report
...
Improves test coverage on Orders and Distributors report
2024-09-11 10:28:55 +10:00
Ahmed Ejaz
f8d3467d46
11200: add specs
2024-09-11 01:59:43 +05:00
Ahmed Ejaz
1580d539df
11200: coniditonally hide producer column
2024-09-11 00:56:52 +05:00
Maikel
e2aac8ca1d
Merge pull request #12851 from openfoodfoundation/dependabot/npm_and_yarn/jasmine-core-5.3.0
...
Bump jasmine-core from 5.2.0 to 5.3.0
2024-09-10 13:50:11 +10:00
Maikel
15a2513815
Merge pull request #12849 from openfoodfoundation/dependabot/npm_and_yarn/turbo_power-0.7.0
...
Bump turbo_power from 0.6.2 to 0.7.0
2024-09-10 13:49:26 +10:00
Gaetan Craig-Riou
00768f6ba0
Add sytem spec for product preview on product edit page
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
908caa984b
Add system spec for product preview
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
6993750757
Fix product v3 action system spec
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
379e5acfe5
Fix product preview modal opening
...
The previous solution failed to take into account that it would have been
trigger on any turbo steam rendering action, not just the product preview
one. Now the open event is dispatched when the product preview
controller is connected, which happens when the modal html is rendered.
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
5bf6bdf7f0
Fix some display issue with long description
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
8de7c304fe
Add AdminTooltipComponent
...
I left the stimulus controller separated as it is generic enough
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
b6695ba9a2
Add product preview on product edit page
...
Plus translation
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
e8de76dc46
Add style for Shop
...
As before, move imported css to partials to avoid duplication. And use
mixin and variable to handle tooltip styling
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
55733555bf
Add style for Product details
...
Only import relevant css, which has been move to their own partial to
avoid duplication
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
f59ee96011
Copy foundation-sites css relevant to the modal
...
The frontend is based on fondation-sites to provide responsive design,
we can't just import in the backend. So opted for copying the part we
needed
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
2b74bbd45d
Add styling for tabs
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
d56ab9257b
Add tab switch and shop tab
2024-09-10 13:29:40 +10:00
Gaetan Craig-Riou
f24a4edc68
Add product detail to the modal
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
27dd5def57
Open modal before rendering the received html
...
This way we don't see a blank modal waiting for the content to load
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
561f4648d2
Improve tooltip partial
...
Set up default value optiona locals variable
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
64d3091db9
Add product preview modal
...
Plus open modal when clicking on "preview" link.
It's using event to communicate between stimulus controller :
https://stimulus.hotwired.dev/reference/controllers#cross-controller-coordination-with-events
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
0a9b858f2a
Add the ability to pass options ModalComponent
...
Now you can add another stimulus controller or action to the modal
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
4756ab47c2
Wire preview link via turbo-stream
2024-09-10 13:29:39 +10:00
Gaetan Craig-Riou
0a04342712
Remove event listener on disconnect
...
It prevents memory leak
2024-09-10 13:29:39 +10:00
filipefurtad0
556539d1b1
Removes pending from fixed issue
...
The pending was not signalling the bug fix as ordering needed to be corrected
2024-09-09 18:07:57 -06:00
filipefurtad0
b7aaab204c
Adds timer restriction with Timecop
...
The datet-time-picker test case was failing for me locally, but passing on GH-Actions. Controlling the time should prevent this type of flakyness
2024-09-09 18:07:57 -06:00
filipefurtad0
632184b0a8
Addresses Davids review
2024-09-09 18:07:57 -06:00
filipefurtad0
8500f6c198
Addresses reviews. The biggest change is moving the table CSS
...
into its helper, which touches other system specs (namely orders_and_fulfillment_spec.rb).
Rubocop fixup
2024-09-09 18:07:57 -06:00
filipefurtad0
ec4dba71c2
Adds flatpickr test
2024-09-09 18:07:57 -06:00
filipefurtad0
6117d70fae
Replaces code with shared examples
...
This spec was appearently flaky, let's see if this change stabilizes it. It came up here: https://github.com/openfoodfoundation/openfoodnetwork/actions/runs/10639846576/job/29498582671?pr=12790
Removes CSV tests based on permissions
Not sure we need these tests, proposing to remove them and use shared examples to test file download
2024-09-09 18:07:57 -06:00
filipefurtad0
2e5c526170
Adds basic coverage on report file download
...
Moves file download into report helper
Removes pdf file assertation
Removes test on PDF file on sales tax report
Removes PDF testing from helper
2024-09-09 18:07:57 -06:00
filipefurtad0
32e32117e3
Adds test case around hub filters
2024-09-09 18:07:57 -06:00
filipefurtad0
2a1d494301
Adds coverage for table contents
2024-09-09 18:07:57 -06:00
filipefurtad0
fd45dea9f7
Moves report test case into dedicated file
...
Sets up an enterprise user instead of an admin user
2024-09-09 18:07:57 -06:00
filipefurtad0
9073f0e5a8
Update all locales with the latest Transifex translations
2024-09-09 10:13:11 -06:00
dependabot[bot]
c4f2c1c3ca
Bump jasmine-core from 5.2.0 to 5.3.0
...
Bumps [jasmine-core](https://github.com/jasmine/jasmine ) from 5.2.0 to 5.3.0.
- [Release notes](https://github.com/jasmine/jasmine/releases )
- [Changelog](https://github.com/jasmine/jasmine/blob/main/RELEASE.md )
- [Commits](https://github.com/jasmine/jasmine/compare/v5.2.0...v5.3.0 )
---
updated-dependencies:
- dependency-name: jasmine-core
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-09 09:12:18 +00:00
dependabot[bot]
a23bbf8537
Bump turbo_power from 0.6.2 to 0.7.0
...
Bumps [turbo_power](https://github.com/marcoroth/turbo_power ) from 0.6.2 to 0.7.0.
- [Release notes](https://github.com/marcoroth/turbo_power/releases )
- [Commits](https://github.com/marcoroth/turbo_power/compare/v0.6.2...v0.7.0 )
---
updated-dependencies:
- dependency-name: turbo_power
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-09 09:11:49 +00:00
Konrad
6fac32b446
Merge pull request #12799 from chahmedejaz/bugfix/12777-incorrect-invoice-unit-display
...
Fix Display Unit As field is not Displaying on Invoice and Report
2024-09-06 12:55:03 +02:00
Konrad
cf21c03619
Merge pull request #12827 from johansenja/only-fetch-active-open-shops
...
Optimise shops page: Only inject distributors with active order cycles
2024-09-05 13:04:17 +02:00
David Cook
0f7f1130f1
Update spec/system/admin/invoice_print_spec.rb
2024-09-05 10:49:45 +02:00
Ahmed Ejaz
009d033e4c
12777: add specs
2024-09-05 10:49:45 +02:00
Ahmed Ejaz
983addff0d
12777: use unit_to_display method for variant unit
...
- This method prioritize display_as and after that considers options_text
2024-09-05 10:49:45 +02:00
Maikel Linke
d061fe8ad9
Remove unnecessary sanitising
...
Existing descriptions have been sanitised in a migration. New
descriptions are sanitised when assigned. That should cover everything.
2024-09-05 12:38:33 +10:00
Maikel Linke
53286c22ba
Sanitise existing long descriptions of enterprises
2024-09-05 12:07:05 +10:00
Maikel
0cf8f079e4
Merge pull request #12840 from openfoodfoundation/dependabot/github_actions/dot-github/workflows/actions/download-artifact-4.1.7
...
Bump actions/download-artifact from 3 to 4.1.7 in /.github/workflows
2024-09-05 10:26:20 +10:00
Maikel
f2163a42c4
Merge pull request #12841 from filipefurtad0/reproduce_#12835
...
Reproduces bug #12835
2024-09-05 10:04:34 +10:00
Maikel Linke
05b25c78bb
Bump all artifact actions to v4
2024-09-05 09:57:05 +10:00
filipefurtad0
cc3181c820
Adds unit spec regression test
2024-09-04 16:51:33 -06:00
Joseph Johansen
9cd39d5c91
Improve specificity of closed_shops API test data
2024-09-04 11:46:44 +01:00
Joseph Johansen
7d2f3bfa2f
Ensure excluded shops are captured by #closed_shops
2024-09-04 11:46:44 +01:00
Joseph Johansen
6df0b24bcf
Add implementation
2024-09-04 11:46:44 +01:00
Joseph Johansen
cf5e182cf7
Add specs for ShopsListService
2024-09-04 11:46:44 +01:00
dependabot[bot]
74bbc7c3c0
Bump actions/download-artifact from 3 to 4.1.7 in /.github/workflows
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 3 to 4.1.7.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v3...v4.1.7 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-09-04 07:13:07 +00:00
filipefurtad0
4773d1c82e
Reproduces bug #12835
2024-09-03 20:15:29 -06:00
Maikel
fde18ebf24
Merge pull request #12839 from johansenja/include-hidden-files-code-cov-chunk-upload
...
Enable include-hidden-files for uploading code coverage chunks
2024-09-04 10:19:47 +10:00
Joseph Johansen
fd2cbb67db
Enable include-hidden-files for upload code coverage chunks
2024-09-03 18:50:34 +01:00
Maikel
3f1d99d77c
Merge pull request #12831 from mkllnk/anonymous-orders
...
Share anonymised sales data on DFC API with authorised users
2024-09-03 10:59:30 +10:00
David Cook
9cfcab4f02
Merge pull request #12834 from rioug/12832-Fix-karma-test
...
Fix karma test
2024-09-02 14:08:23 +10:00
Gaetan Craig-Riou
703ad26773
Fix spec to make the test usefull
2024-09-02 12:23:27 +10:00
Gaetan Craig-Riou
627c9eede2
Fix spec using confirm pop up
...
For some reason, karma hang and fails with a timeout error if javascrpit
`confirm` pop up isn't mocked.
Plus fix spec to actually check the pop up has been displayed
2024-09-02 12:18:44 +10:00
David Cook
f9a76342f8
Merge pull request #12830 from filipefurtad0/remove_pdf_file_test_from_reports
...
Removes test on PDF file on sales tax report
2024-09-02 11:15:13 +10:00
Maikel Linke
d52134dad8
Filter sales data by dates
2024-08-30 15:00:06 +10:00
Maikel Linke
1016656781
Publish data only of participating distributors
2024-08-30 14:34:39 +10:00
Maikel Linke
bd1611630f
Build DFC data for sales
2024-08-30 14:34:32 +10:00
Maikel Linke
ce28c10c7e
Move sales data generation to a service object
...
There will be lots and lots. The sales data root object is also the
authenticated person. The data has its own URL (semantic id) which
doens't need to contain the user id.
The service object can also be tested more easily. I'm setting up the
test data here.
2024-08-30 14:30:46 +10:00
Maikel Linke
4342d3b912
Add DFC API endpoint for sales data
2024-08-30 14:30:46 +10:00
Maikel Linke
af3aed827a
Update all locales with the latest Transifex translations
2024-08-30 09:59:49 +10:00
Maikel
f73be6447e
Merge pull request #12824 from chahmedejaz/task/12823-fully-enable-admin-style-v3
...
[BUU] Fully enable admin_style_v3
2024-08-30 09:56:23 +10:00
Filipe
98eabc9d0f
Merge pull request #12826 from chahmedejaz/bugfix/12815-fix-inconsistent-unit-values
...
Fix Inconsistent Behavior When Editing Products to mg Units in Hungarian Locale
2024-08-29 17:47:44 -06:00
Filipe
169cbbe1a1
Merge pull request #12793 from rioug/12768_fix_bulk_coop_report
...
Fix bulk coop report
2024-08-29 15:20:48 -06:00
filipefurtad0
72a503c3c1
Removes test on PDF file on sales tax report
2024-08-29 11:46:22 -06:00
Konrad
afc4c1e967
Merge pull request #12760 from wandji20/wb-OFN-12744
...
UX improvements for creation of new products [OFN-12744]
2024-08-29 17:22:36 +02:00
Rachel Arnould
d76c4bddb0
Merge pull request #12806 from drummer83/typo
...
Fix typos in "category" and unify capitals on "Back To Xyz List" buttons
2024-08-29 16:40:35 +02:00
Konrad
ae993784d8
Merge pull request #12813 from chahmedejaz/task/12810-increase-price-column-width
...
[BUU] Fix the too Narrow Price field
2024-08-29 15:22:27 +02:00
Filipe
d1abe22c32
Merge pull request #12805 from mkllnk/update-wicked-pdf-config-syntax
...
Update deprecated WickedPdf config syntax
2024-08-28 21:35:40 -06:00
Filipe
2817b8891e
Merge pull request #12814 from dacook/buu/cell-padding
...
Increase column space in bulk products table
2024-08-28 21:30:03 -06:00
Filipe
ab87610d91
Merge pull request #12807 from kernal053/fix-broken-column-after-cloning
...
Fix broken column after cloning product
2024-08-28 21:03:53 -06:00
David Cook
54252f5444
Add comment
2024-08-29 09:42:59 +10:00
Ahmed Ejaz
7b6b0dbb78
12815: use en formatting for unit value conversion
2024-08-29 03:36:46 +05:00
Maikel
b2e15f52cf
Merge pull request #12822 from johansenja/include-coverage-assets
...
Fix artifact path for simplecov report upload
2024-08-29 08:10:38 +10:00
Ahmed Ejaz
5d18c48b6c
12823: fully enable admin_style_v3 flag
2024-08-29 02:09:29 +05:00
Konrad
0c2dcbc50d
Merge pull request #12812 from chahmedejaz/bugfix/12809-irresponsive-products-column-widths
...
[BUU] Fix Table width not responsive to the amount of selected columns
2024-08-28 16:45:07 +02:00
Joseph Johansen
4a028b2238
Fix artifact path for simplecov report upload
2024-08-28 11:09:01 +01:00
Maikel
43a366005c
Merge pull request #12798 from johansenja/enable-simplecov
...
Set up code coverage metrics with simplecov
2024-08-28 12:07:53 +10:00
Maikel Linke
64470e977a
Avoid name clash in simplecov task
...
A variable and a method were called the same.
Also made method calls more obvious with parenthesis.
2024-08-28 11:31:01 +10:00
Maikel Linke
a696c66857
Clean up tmp dir after test and avoid collisions
...
Best viewed ignoring whitespace changes.
2024-08-28 11:27:42 +10:00
Maikel Linke
cfeb0afbd4
Update all locales with the latest Transifex translations
2024-08-28 09:45:24 +10:00
Maikel Linke
4968e3dc8d
Update all locales with the latest Transifex translations
2024-08-28 09:12:52 +10:00
David Cook
5324747f89
Reduce cell padding
...
This is closer to the original design:
* 6px between inputs
* 6px vertical padding on condensed rows
* 12px vertical padding on relaxed rows
Note that 'relaxed' rows are now smaller than the regular rows, which was not the original intention. But we haven't got spare time to do a broader review of table styles right now.
2024-08-26 16:53:19 +10:00
Gaetan Craig-Riou
ef2856d169
Remove added eventListener on disconnect
...
It's good practise to remove added event listener to avoid memory leak
2024-08-26 11:15:26 +10:00
Ahmed Ejaz
d9c79ee49c
12810: increase price width
...
- make it to 10% which makes sure that any price value acceptable by the system is displayed fully
- Reduce On Hand to 8% to make up for some space for the above
2024-08-24 17:37:59 +05:00
Ahmed Ejaz
d1f9b0855d
12809: fix the class name for the producer column in product
2024-08-24 02:05:04 +05:00
drummer83
b82726e7ba
Unify the capital letters of the "Back To Xyz List" buttons and update specs
...
I decided to use the most frequently used version as the default, which is every word beginning with a capital letter
2024-08-23 13:23:57 +02:00
drummer83
7e7ab2e36d
Fix typo in "categeory" (additional e) and update specs
2024-08-23 13:20:46 +02:00
kernal053
e35a5179bb
Fix broken column after cloning product
2024-08-23 16:01:56 +05:30
Joseph Johansen
85385a1989
Rename uploads so combined report is listed first alphabetically
2024-08-23 11:26:45 +01:00
Joseph Johansen
a816814819
Update CI workflow to upload results and call rake task
2024-08-23 11:26:41 +01:00
Cillian O'Ruanaidh
60afa4d465
Revert whitespace changes in config/locales/en.yml
2024-08-23 10:07:32 +01:00
Cillian O'Ruanaidh
dd5175558e
Don't make any changes to non :en locales.
2024-08-23 10:03:34 +01:00
wandji20
94b98867d8
Revert use of searchableDropdownComponent for product unit
2024-08-23 09:57:37 +01:00
wandji20
35ef1b9c7f
Refactor new product dropdown to use SeachableDropdown component [OFN-12744]
2024-08-23 09:57:37 +01:00
wandji20
8badfb2505
Allow extra attributes to be passed to searchable dropdown component [OFN-12744]
2024-08-23 09:57:37 +01:00
wandji20
d61acd2cc1
Unify error messages and display on new product form [OFN-12744]
2024-08-23 09:57:37 +01:00
wandji20
7417cee20a
Fix leaked trix editor event listener [OFN-12744]
2024-08-23 09:57:37 +01:00
Cillian O'Ruanaidh
98951161b1
Revert "Add Trix translations for all the different English locale regions"
...
This reverts commit 70ca03173c .
2024-08-23 09:54:23 +01:00
Cillian O'Ruanaidh
a745249f3b
Revert "Reuse 'Please insert a URL' translation from text angular editor in the Trix editor" for all locales except :en
...
This reverts commit 2d6ffc0ca1 .
2024-08-23 09:52:57 +01:00
Cillian O'Ruanaidh
63c62cae08
Simplify setting of Trix editor translations
...
Co-authored-by: David Cook <david@redcliffs.net >
2024-08-23 09:47:48 +01:00
Maikel Linke
d489c77efe
Update deprecated WickedPdf config syntax
...
Avoids warning:
> WickedPdf.config= is deprecated and will be removed in future versions. Use WickedPdf.configure instead.
2024-08-23 15:57:59 +10:00
Maikel
e2423ad612
Merge pull request #12800 from filipefurtad0/adds_retry_option_on_edit_spec
...
Adds retry option to flaky edit_spec.rb
2024-08-23 12:02:59 +10:00
filipefurtad0
8b036113d9
Update all locales with the latest Transifex translations
2024-08-22 17:33:21 -06:00
Maikel
7f09044ae1
Merge pull request #12755 from johansenja/optimise-shops-page6
...
Optimise shops page: Enable injected enterprise data to be scoped to specific enterprise ids
2024-08-23 09:26:22 +10:00
Maikel
e9c7e1778c
Merge pull request #12782 from mkllnk/reports
...
Add fallback report loading in case websockets fail
2024-08-23 09:23:42 +10:00
filipefurtad0
32cd14ef54
Adds slep(2)
2024-08-22 15:55:31 -06:00
filipefurtad0
ad585f1eab
Adds retry option to flaky test case
...
...does so on another flaky test case
2024-08-22 15:55:31 -06:00
Filipe
d9368c1bfc
Merge pull request #12781 from wandji20/wb-OFN-12775
...
Add warning popup to order cycle list [OFN-12775]
2024-08-22 15:39:27 -06:00
wandji20
b6bfb4e866
Refactor order cycle same_dates method
2024-08-22 22:21:17 +01:00
wandji20
4d222c61c6
Improve readability of order_cycle_set process method
2024-08-22 22:17:12 +01:00
wandji20
d599cf77a2
Fix failing specs
2024-08-22 22:17:12 +01:00
wandji20
8f7505d53d
Refactor oc datetime content partial and include warning modal in oc list [OFN-12775]
2024-08-22 22:17:12 +01:00
wandji20
867e17301f
Support passing oc confirmation params for oc list [OFN-12775]
2024-08-22 22:17:12 +01:00
wandji20
95135ca526
Move order_cycle datetime verification logic to service files [OFN-12775]
2024-08-22 22:17:12 +01:00
wandji20
de063fecb1
Move same_datetime_value method to OrderCycle model [OFN-12775]
2024-08-22 22:17:12 +01:00
Filipe
ef9ca33913
Merge pull request #12772 from drummer83/E500_sub
...
Display admin order page instead of shopfront order page to avoid error 500
2024-08-22 13:26:20 -06:00
Konrad
2710eafc33
Merge pull request #12779 from EdwardLi-coder/clearer_error_message_and_clean_up
...
Clearer error message and clean up for Product Categories
2024-08-22 18:15:50 +02:00
Joseph Johansen
4718fdb0be
Optimise Spree::Taxon.supplied_taxons
2024-08-22 17:41:00 +02:00
Joseph Johansen
ce6ae04147
Add spec for confirming correct values when scoped
2024-08-22 17:41:00 +02:00
johansenja
1621f97fdb
Use subject method in spec
...
Co-authored-by: Gaetan Craig-Riou <40413322+rioug@users.noreply.github.com >
2024-08-22 17:41:00 +02:00
Joseph Johansen
96f9894f41
Add enterprise_ids to cache key
2024-08-22 17:41:00 +02:00
Joseph Johansen
66b519bd1c
Undo minor unneeded changes
2024-08-22 17:41:00 +02:00
Joseph Johansen
1b8e256e8a
Add unit tests
2024-08-22 17:41:00 +02:00
Joseph Johansen
b73e529bfc
Scope injected enterprise properties to specific enterprises
2024-08-22 17:41:00 +02:00
Konrad
25b1620707
Merge pull request #12743 from wandji20/wb-OFN-12214
...
(Fix) chore(deps): bump wicked_pdf from 2.6.3 to 2.8.0 [OFN-12214]
2024-08-22 17:34:20 +02:00
Joseph Johansen
5f9b14df9f
Implement rake task to combine results
2024-08-21 13:02:31 +01:00
Joseph Johansen
922b853e3a
Define specs for rake task to combine results
2024-08-21 13:02:31 +01:00
Joseph Johansen
8d747a2508
Enable coverage in base_spec_helper
2024-08-21 13:02:31 +01:00
Gaetan Craig-Riou
ef6e37e7ca
Fix suppliers_of_products_distributed_by
...
Plus spec
Left over from product refactor, it was missed because it's not covered
by unit or integration test
2024-08-21 13:05:34 +10:00
Gaetan Craig-Riou
a50be52cde
Merge pull request #12792 from openfoodfoundation/dependabot/npm_and_yarn/elliptic-6.5.7
...
Bump elliptic from 6.5.4 to 6.5.7
2024-08-21 09:56:19 +10:00
Gaetan Craig-Riou
d62d002bc5
Merge pull request #12780 from dacook/optimise-12714
...
Optimise subscriptions admin
2024-08-21 09:50:27 +10:00
Gaetan Craig-Riou
ffc2fed9b5
Remove unused code
2024-08-20 16:43:22 +10:00
Maikel
0c7448ba43
Merge pull request #12726 from mkllnk/order-stock-spec
...
Track (negative) stock for on-demand products and overrides
2024-08-20 15:05:16 +10:00
Gaetan Craig-Riou
24afd40414
Fix bulk coop supplier report
2024-08-20 14:32:35 +10:00
Maikel
524aec7868
Merge pull request #12788 from openfoodfoundation/dependabot/npm_and_yarn/mrujs-1.0.2
...
Bump mrujs from 1.0.1 to 1.0.2
2024-08-20 14:30:47 +10:00
David Cook
f2eb4b05f4
Avoid copying gigantic array
2024-08-20 14:00:13 +10:00
David Cook
ffaf1b4ea0
Cache distributor
2024-08-20 14:00:13 +10:00
David Cook
eb547f4861
Add test on number of db queries
...
Hmm, I think I seen an opportunity to clean up already.
2024-08-20 14:00:13 +10:00
David Cook
c9daca22d5
Rename spec to match class name
2024-08-20 14:00:13 +10:00
dependabot[bot]
7b22740289
Bump elliptic from 6.5.4 to 6.5.7
...
Bumps [elliptic](https://github.com/indutny/elliptic ) from 6.5.4 to 6.5.7.
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.4...v6.5.7 )
---
updated-dependencies:
- dependency-name: elliptic
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-08-20 03:52:13 +00:00
Maikel
66c8a5c424
Merge pull request #12789 from chahmedejaz/bugfix/12783-fix-artifact-upload-names-conflict
...
Fix Artifact Upload Conflicts with Unique Node-Based Names
2024-08-20 13:51:13 +10:00
David Cook
cfeac651b6
Merge pull request #12785 from filipefurtad0/spec_for_#12768
...
Reproduces S2 bug #12768
2024-08-20 13:45:07 +10:00
EdwardLi-coder
05315ff8e0
delete spree.new_taxon
2024-08-20 08:11:49 +08:00
EdwardLi-coder
c4ee6b14ff
clear error message and clean up
2024-08-20 08:11:49 +08:00
filipefurtad0
a78f46259c
Asserts on the flash warning first
...
The warning first displays "Saving..." before confirming changes are saved.
I'm not entirelly sure, but it seems that asserting on this first, before asserting on other page elements stabilizes the spec.
2024-08-19 13:58:03 -06:00
filipefurtad0
1e79fde236
Reproduces S2 bug #12768
2024-08-19 13:58:03 -06:00
Ahmed Ejaz
a9fe52a4ff
Revert "12783 - validate artifact upload"
...
This reverts commit 075f5499f8 .
2024-08-19 23:29:12 +05:00
Ahmed Ejaz
075f5499f8
12783 - validate artifact upload
2024-08-19 23:16:39 +05:00
Ahmed Ejaz
ed61f7e7bc
12783: use unique artifact name based on node index
2024-08-19 22:57:04 +05:00
dependabot[bot]
bd6019036e
Bump mrujs from 1.0.1 to 1.0.2
...
Bumps [mrujs](https://github.com/KonnorRogers/mrujs ) from 1.0.1 to 1.0.2.
- [Changelog](https://github.com/KonnorRogers/mrujs/blob/main/CHANGELOG.md )
- [Commits](https://github.com/KonnorRogers/mrujs/compare/v1.0.1...v1.0.2 )
---
updated-dependencies:
- dependency-name: mrujs
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-08-19 09:31:52 +00:00
Konrad
0bbc3d2758
Merge pull request #12766 from mkllnk/magick-dep
...
Remove direct dependency on MiniMagick
2024-08-18 18:39:48 +02:00
Konrad
ae6182579b
Merge pull request #12762 from EdwardLi-coder/change_colour_of_complete_order
...
change colour of "complete order"
2024-08-18 15:08:46 +02:00
Konrad
1e05811917
Merge pull request #12745 from johansenja/optimise-shops-page5
...
Improve effiency of OrderCycle.earliest_closing_times
2024-08-18 14:40:49 +02:00
Konrad
5f86a26f42
Merge pull request #12733 from wandji20/wb-OFN-6567
...
Update product variant unit display name, price, and total price width on different screen sizes [OFN-6567]
2024-08-18 13:25:24 +02:00
Konrad
3f1b907ef2
Merge pull request #12740 from wandji20/wb-OFN-12532-v1
...
Pluralize admin products search result [OFN-12532-v1]
2024-08-18 12:18:18 +02:00
Cillian O'Ruanaidh
08ab405893
Rename method for looking up trix attribute or action by translation key
2024-08-16 17:02:03 +01:00
Cillian O'Ruanaidh
ae2e92f09d
Don't need to set value on hidden fields for Trix editors, it will be set automatically
2024-08-16 16:20:53 +01:00
Cillian O'Ruanaidh
b174080e29
Fix Layout/LineLength Rubocop violation in spec/system/admin/enterprises_spec.rb
2024-08-16 16:08:41 +01:00
Cillian O'Ruanaidh
a2c3ac2f60
Fix expected placeholder in test after updating translation
2024-08-16 16:00:08 +01:00
Cillian O'Ruanaidh
429e2b0a86
Fix issue where Trix editor translations were not being set correctly in Chrome
2024-08-16 15:44:09 +01:00
Cillian O'Ruanaidh
70ca03173c
Add Trix translations for all the different English locale regions
2024-08-16 15:43:09 +01:00
Cillian O'Ruanaidh
7961ff7976
Don't add translations for Trix buttons and functions we are not using
2024-08-16 15:33:49 +01:00
Cillian O'Ruanaidh
2d6ffc0ca1
Reuse 'Please insert a URL' translation from text angular editor in the Trix editor
2024-08-16 15:31:59 +01:00
Maikel Linke
d9c296cdb3
Stabilise flaky report specs
...
It looks like we have a new race condition that may only be a problem in
specs. If you trigger one report, it displays via websockets and then
you trigger the next report, there may still be some Javascript active
that displays the first report while the second one is loading. I'm not
sure if users would navigate that fast though.
To minimise the problem, I adjusted the polling to leave more room for
the default websockets response.
2024-08-16 17:08:57 +10:00
Maikel Linke
23aa762be2
Add fallback report loading in case websockets fail
...
This also resolves a race condition scenario. Even if the report gets
rendered via websockets before the controller response is rendered then
the fallback script loads the report again. It's not the most beautiful
but probably okay until we replace websockts altogether.
I'm leaving websockets in at the moment because it can render the report
much quicker than polling can.
2024-08-16 15:24:34 +10:00
Maikel Linke
61f2954973
Add TurboPower Rails gem for nice helpers
...
The helpers are more convenient but also allow us to add options like
smooth scrolling. I thought that looked nicer and is less confusing.
Please note that the `scroll_into_view` helper uses the `targets`
attribute instead of `target`. That attribute needs CSS selectors with a
leading `#` for ids.
2024-08-16 14:37:57 +10:00
Maikel Linke
d354317c73
Replace cable_ready report loading w/ Turbo stream
...
I'm adding TurboPower for the scroll_into_view action. It adds all the
nice CableReady actions to Turbo Streams.
Note that I omitted `block: "start"` because that option is the default
in Javascript. And the generic `action` method doesn't support
parameters like this anyway. I'll work on that in the next commit.
I also re-introduced a race condition by rendering the "loading"
indicator after triggering the report rendering job. I'm planning to
resolve that later.
2024-08-16 14:37:57 +10:00
Maikel Linke
19ef047193
Create observable reports blob early
...
This will allow us to check for completion of the report later in case
websockets fail.
2024-08-16 14:37:57 +10:00
Maikel Linke
037eb456c0
Remove unused controller ivar
2024-08-16 14:37:57 +10:00
Maikel Linke
aed78f3138
Simplify reports controller code branching
2024-08-16 14:37:57 +10:00
Maikel Linke
c31416c536
Separate showing and rendering report
2024-08-16 14:37:57 +10:00
drummer83
f154de66f9
Display admin order page instead of shopfront order page to avoid error 500
2024-08-14 14:44:59 +02:00
wandji20
4a30493716
Improve code style [OFN-12214]
2024-08-13 18:29:27 +01:00
wandji20
f325857e1f
Strip end of long invoice table header names due to names not properly parsed when converting pdf to text [OFN-12214]
2024-08-13 18:23:27 +01:00
wandji20
58872a7017
Include mail stylsheet tag in invoice pdf files and mailer layout [OFN-12214]
2024-08-13 18:23:18 +01:00
wandji20
7392079d4d
Move mail related styles to asset pipeline [OFN-12214]
2024-08-13 17:11:29 +01:00
wandji20
506126c1d3
Bump wicked_pdf to version 2.8.1
2024-08-13 17:11:29 +01:00
wandji20
fa004d0897
Remove wicked pdf stylsheet include tag in order report pdf [OFN-12214]
2024-08-13 17:11:29 +01:00
dependabot[bot]
db7add88fe
chore(deps): bump wicked_pdf from 2.6.3 to 2.8.0
...
Bumps [wicked_pdf](https://github.com/mileszs/wicked_pdf ) from 2.6.3 to 2.8.0.
- [Release notes](https://github.com/mileszs/wicked_pdf/releases )
- [Changelog](https://github.com/mileszs/wicked_pdf/blob/master/CHANGELOG.md )
- [Commits](https://github.com/mileszs/wicked_pdf/commits )
---
updated-dependencies:
- dependency-name: wicked_pdf
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-08-13 17:11:29 +01:00
Maikel Linke
f21aca234c
Remove direct dependency on MiniMagick
...
We still depend on it as long as we set it as image processor but now we
can switch to another image processor without changing the code around
error handling.
We now rescue from unknown errors during image processing which should
make the app more robust.
2024-08-13 15:25:58 +10:00
EdwardLi-coder
93a6ff4b50
remove background-color
2024-08-13 09:38:20 +08:00
EdwardLi-coder
97a72dfde7
change colour of "complete order"
2024-08-12 12:01:02 +08:00
Cillian O'Ruanaidh
a6d3909e95
Replace text-angular editor with trix editor in fields for shop messages and about fields for enterprises and enterprise groups
2024-08-09 10:37:23 +01:00
Joseph Johansen
5ca7f40a4e
Add unit test
2024-08-06 16:12:13 +01:00
Joseph Johansen
a2f4df191a
Improve effiency of OrderCycle.earliest_closing_times
2024-08-06 16:12:13 +01:00
wandji20
b49da46842
Pluralize admin products search result [OFN-12532-v1]
2024-08-06 08:52:51 +01:00
wandji20
2d24593403
Update product variant unit display name, price, and total price widths on different screen sizes [OFN-6567]
2024-08-02 13:03:42 +01:00
Maikel Linke
2201d2e8c2
VariantOverride with on_demand now overriding stock
...
Otherwise we would try to take stock from the producer stock level
without respecting their on-demand settings. So from now on:
If stock level or on_demand are set on the override then it's not using
producer stock levels.
2024-08-02 14:40:17 +10:00
Maikel Linke
b6c407971d
Allow on-demand VariantOverride to track stock
...
We allowed this for producer stock and need to do the same for inventory
stock. This will allow us to create backorders for missing, but promised
stock.
2024-08-02 14:40:17 +10:00
Maikel Linke
cd8dc41b15
Update stock specs and add pending cases
2024-08-02 14:40:17 +10:00
Maikel Linke
a1887bdc76
Update stock levels of on-demand items
...
We weren't bothering with stock when items were on demand anyway. But we
want to track stock now so that we can backorder more when local stock
levels become negative.
2024-08-02 14:40:17 +10:00
Maikel Linke
e9f89362f4
Remove validation of positive stock when on demand
...
We weren't allowing negative stock to stop any bug from accidentally
drawing too much stock. But now we want to implement a backordering
logic that depends on negative stock levels to know how much is needed
to replenish stock levels.
2024-08-02 14:40:17 +10:00
Maikel Linke
675b7febdf
Test stock logic on variant level
...
VariantOverrides are bolted onto variants to change their logic.
2024-08-02 14:40:17 +10:00
Maikel Linke
90fdf59415
Test current stock logic on shipment level
...
During checkout, stock is adjusted when a shipment is finalised. The
chain is:
* Order state change to complete.
* Trigger Order#finalize! which updates shipments.
* Trigger Shipment#finalize! which adjusts stock on the variant.
* A variant holds stock in stock items or in a variant override.
2024-08-02 14:40:17 +10:00