Total Shipping Weight For Order #1049
kylekanderson
started this conversation in
Feature Requests
Replies: 1 comment
-
|
Sure it's doable. It does raise the question of whether the weight values etc should be in the order snapshot information, as product information could change. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
No
Describe the solution you'd like
It would be great to have the ability to get the total shipping weight for an Order. Ideally, we could pass a weight_unit to this function and the function would return a result similar to the weight_value that's returned for ProductVariants.
Example:
$order->totalShippingWeight('lbs'); // returns something like 0.5000Or, if no weight unit is provided:
$order->totalShippingWeight(); // returns something like ['weight_value' => 0.5000, 'weight_unit' => 'lbs']Describe alternatives you've considered
This could of course be accomplished outside of Lunar. However, with the possibility of mixed weight_units on ProductVariants, it could become difficult to implement. I'm not sure if Lunar already possesses the necessary information/logic to handle these sorts of conversions or not.
Additional context
None
Beta Was this translation helpful? Give feedback.
All reactions