Hey guys. I'm having trouble getting a custom ship...
# general
d
Hey guys. I'm having trouble getting a custom shipping calculator to work. I've done this before in a previous version of Solidus but even though I can see the calculator in the admin interface and set it up there the compute_package method is just never called. I've got a couple of promotion rules and actions working so I'm familiar to an extent with how to do this. I followed the documentation here: https://legacy-guides.solidus.io/developers/shipments/custom-shipping-calculators. Based on that I tried to include the custom class like below:
Copy code
Rails.application.config.spree.calculators.shipping_methods << Spree::Calculator::Shipping::CustomPriceSackCalculator
That didn't work. Interestingly the above method of including the promotion rules and actions also didn't work. I had to include them like below:
Copy code
Rails.application.config.spree.calculators.shipping_methods << 'Spree::Calculator::Shipping::CustomPriceSackCalculator'
I did the same with the shipping calculator but without any luck. I'm on the following: rails (7.0.8) solidus (4.3.2)