-
Notifications
You must be signed in to change notification settings - Fork 462
Description
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.5000
Or, 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