Personalized checkout and custom promotions with Shopify Scripts
I need help editing this script
If shipping_rate.price is greater than 75 make it 75
because we have 3 different locations that have 3 different shipping rate = 75
but we are in a small country and we want to make our shipping rate flat 75 no matter if customer picked items from different locations
but what is happening now that if the customer picked items from 3 location
he will pay 75+75+75
We want him to pay only 75
I tried to use this code
input.shipping_rates.each do |shipping_rate|
next unless shipping_rate.source == "shopify"
if shipping_rate.price > 75
shipping_rate.price = 75
end
output.shipping_rates = input.shipping_rates
but it didn't work
User | RANK |
---|---|
2 | |
2 | |
2 | |
2 | |
2 |
Transform this holiday season into a shopping spree. Plus, learn how to effortlessly open ...
By Jasonh Dec 8, 2023Make the shift from discounts to donations, and witness your business not only thrive fina...
By Holly Dec 4, 2023On our Shopify Expert Marketplace, you can find many trusted third party developers and fr...
By Arno Nov 27, 2023