Open filipefurtad0 opened 4 years ago
Adding the payment info and creating a new payment seems to trigger this error on Bugsnag: https://openfoodnetwork.slack.com/archives/CEF14NU3V/p1629799584026700
After seeing the error, refreshing the page shows that the payment was created, but the order is still on state = "payment":
Description
Observed while testing #6039
PR #5392 introduced the possibility to set shipping methods as "backoffice only", removing them from the /checkout page.
Currently, the most common workflow for creating backoffice orders is (following a top-down order): 1) choosing distributor and OC 2) adding products (can't set shipping methods before adding customer info) 3) adding customer details 4) changing/adding/updating info on shipping methods, tracking info and updating fees 5) adding payment info
If the hub has set all hipping methods as backofice only, and follows this workflow/order, then no shipping methods are available to choose from - which is the bug reported in this issue.
Expected Behavior
Shipping methods - as seen on /admin/shipping_methods - should always be available in the backoffice (lets forget tags for now - as there is an ongoing discussion on this matter)
Actual Behaviour
If all shipping methods are set as "backoffice only" then no available shipping method appears when placing backoffice orders (this happens for the workflow described above)
Steps to Reproduce
Log in as admin
choosing distributor and OC > adding products > adding customer details
Animated Gif/Screenshot
Workaround
If one sets the customer details in forehand, then the backoffice-only set shipping methods appear as expected. That means following this workflow:
1) choosing distributor and OC 2) adding customer details 3) adding products 4) changing/adding/updating info on shipping methods, tracking info and updating fees 5) adding payment info
Severity
Not sure on severity. Maybe an edge case - bug-s4?
Your Environment
Possible Fix