-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shipping infrastructure and generic implementation (OCC-60) #4
Comments
I don't know about other countries, in the USA the notion of a "Size" picklist is very handy as a lot of clients set up their generic shipping pricing matrix based on "Size" and "Destination" (where "Destination" is either a state and/or country. This works pretty good because of flat rate boxes. So for the generic one I would love to see a toggle between "Size" based approach and "Unit" based approach. |
Fixed rate and Rate by size/weight with excel spreadsheet import/export. |
Destination: I think the generic shipping method should not have "size" or properties like that. We should, however, provide an extension point for those. Meaning that a shipping method would have its own list of those conditions |
Please open a separate issue for territories. The reason for having size outside of providers is that they really are common. If I ship through FedEx and USPS, they will both require weight. I don't want to have to enter a USPS weight and a FedEx weight for the same product. Am I missing something? This being said, we could have a weight part, a volume part, and so on. |
Specifically the weight: A free or fixed price shipping would not need that. |
I think we're in violent agreement: if you don't use shipping methods that depend on dimensions, you don't have to have the part on your products. USPS and FedEx could still look for it though. |
Shipping providers usually returns prices with tax. So there is no need to tax again shipping rates. It's supposed to be added on top of the actual invoice total price + taxes : (Multiple Product Prices) = (Invoice Subtotal + Tax) |
you would still need to tax the other products in the cart, right? Or do shipping providers take care of that? |
The shipping price is a separate product which includes it's own tax. If you use USPS they will include tax depending on where the package departs from. Though, the shipping tax is not part of the Invoice tax because it is a service that is not given by you but by the shipping provider. So you don't need to manage these tax in your accounting. The shipping provider is a "subcontractor" Though the tax provider is a feature that we require too. |
I understand now. But taxes on the products in the cart also depend at least in part on the destination of shipping. That is the match I meant. |
Is implementation of shipping (costs) is already in progress? In O1 Nwazet.Commerce there was an IShippingMethodProvider interface. Implement a custom shipping method just needs to derive from that interface. For Orchard Commerce, I do not see any interfaces or preparations for handling shipping costs. Since my shipping costs calculations depend on the ZIP, I would ask user for ZIP and store it together with the calculated shipping cost. But where to store them? Should ShoppingCartViewModel be extended to keep the info about shipment? ShoppingCartViewModel Thanks, |
Hi Dieter, this issue is not in progress. It's up for grabs to the community if anyone is interested.
I don't think storing the price is the best approach. If your shipping cost only depends on the shipping address, then it's more efficient to store a table that correlates ZIP to shipping price as an OC site setting or in appsettings.json and just look that up when needed. You can already generate shipping cost as an additional cart item using current OrchardCore.Commerce like this: In OCC if the user has a saved address (in Hope this helps. |
Thanks Sára, I am actually trying this and looks great. Wenn adding an extra entry to viewModel.Lines it is necessary to also reference a Product content item, since otherwise code will not work in many places. Thanks |
Hi Sára, when adding the shipping cost only to the viewModel.Lines as described before, it is not part of the created order :( PaymentService.CreateOrUpdateOrderFromShoppingCartAsync calls but the implementation of CreateOrUpdateOrderFromShoppingCartAsync update the lines of the order part Any suggestions? |
This could be fixed in Payment/Services/PaymentService.cs in methods CreatePendingOrderFromShoppingCartAsync and CreateOrUpdateOrderFromShoppingCartAsync: Instead of _shoppingCartHelpers.CreateOrderLineItemsAsync(cart) call _shoppingCartHelpers.CreateOrderLineItemsAsyncEx(cartViewModel) See also #397 |
Shipping is a very complex feature set, that may not be necessary in the minimum feature set, but is vital to many if not most businesses.
Dimensions
part that can be added to products and that is not implementation-specific.A generic implementation would likely be mostly manually operated, and would be a place to store external tracking links, shipping provider name, and simple pricing determination based on weight and volume intervals. It should not attempt to be too sophisticated, as that would likely imply specialization that should really live in provider-specialized extensions.
Note: there exist Stripe-like shipping broker services that could also be good first implementations or extensions to build.
Jira issue
The text was updated successfully, but these errors were encountered: