Hello folks. Thanks for your time.

I am looking for assistance with the shipping flat rate module to be able to assign flat rate services based on a custom product variable.

The shipping services would look like this:

For 1 to 12 "Shipping Items": $10 for domestic, $45 for international
For 12 to 24 "Shipping Items": $20 for domestic, international must contact for custom quote
For 24+ "Shipping Items": domestic must contact for custom quote, international must contact for custom quote

Because all of the products in the store had the same number of "shipping items" (1 item shipped per product) I was previously able to achieve this without any problems using a total number of products condition with rules. However, a new product has been added that has a different number of "shipping items" (8 items shipped) although it still counts as a single product for the commerce order.

What I would like to do is use the same sort of rule sets based on a total calculation of a new variable that I have added to the product called shipping_items. The problem is that I cannot figure out how to "call" this variable in the condition.

If anyone can provide any guidance I would greatly appreciate it. Also, I apologize if this issue has been addressed elsewhere (I checked but may have missed it). Please bear with me, as I am a novice Drupal user. Thanks again!

Comments

rszrama’s picture

Status: Active » Closed (won't fix)

I don't know how to configure this off the top of my head. I'd personally just right custom code to do it, as I tend to stay away from the Rules UI for complex logic. If you're still trying to get this done via Rules, I recommend https://drupal.stackexchange.com for support.