How to calculate the freight of various products

Asked

Viewed 3,560 times

14

I am developing a virtual store and I need to implement the freight calculation for the purchase, I managed to make this implementation but the problem is that with a single product in the cart I get the correct return, but with several products in the cart the values do not match the simulator of the logistics company.

I wanted to know how I do to calculate the freight of various products together. If I do the calculation of the cubage of each one separately and then sum all, or if I do the calculation of the cubage with the sum of the dimensions of the products, or what is the correct way to do this.

I am lost in this calculation because not on the Internet there is only content explaining about the calculation of individual products and I cannot solve this issue.

  • Look, when I do with the post office I always add up the weight of everyone to do the calculation, I think the correct thing would be to calculate the tank with the sum of the dimensions.

2 answers

4

To make a calculation that matches the logistics company, you would have to do the same calculation that they do. Each company can be its own criterion:

  • weight-only

  • dimension: width + height + depth not exceeding an established value (airline type: the sum of width + height + depth shall not exceed 115 cm)

  • dimension: in the combination of product size it is possible to assemble a box with limits maximum width, height and depth, and having the problem of optimizing your products to fit in this box

  • a fixed value for the first package and then a smaller value for each extra package

  • a fixed value for the first kilo and a smaller value for each extra kilo

  • a combination of any rule above.

If the rules are on any site, use the rules they explain (e.g. , you use the Post Office of Brazil, you can see the rules on their website)

If they’re not, just asking and getting their answer.

And if they provide an interface that you can access, make your program inform the data for them and let them calculate for you, if your contract with them allows.

Unfortunately, any response without knowing what your logistics company or the criteria they use will only be general tips and speculation, making it difficult to help you.

1

The question goes beyond adding the dimensions and weights, the correct is to define standard boxes and with the sum of the products identify will fit in it...

Because if we just add up the values, it may occur to exceed the limit allowed by the Post Office.

What can be done: Example: Box 1 (20 x 20 x 20), Box 2 (30 x 30 x 40)....... by adding more than 1 product, should be added its dimensions and make the check, THE PRODUCTS FIT IN BOX 1?... THE PRODUCTS FIT IN BOX 2?? , if the dimensions exceed the registered boxes, dismember the quotation... will have to quote individually products.

It may seem a little complicated, but reduces the possibility of mistakes and always ends up earning a little in the value of freight.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.