Showing Total Order Weight in HikaMarket

  • Posts: 268
  • Thank you received: 7
  • Hikamarket Frontedition Hikamarket Multivendor Hikaserial Standard Hikashop Business
8 years 3 months ago #247615

-- HikaShop version -- : 2.6.3
-- HikaMarket version -- : 1.7.1
-- Joomla version -- : 3.6.2
-- PHP version -- : 5.4

How can I show the total order weight in the order details in the control panel? must be a way as it shows everything else.

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 3 months ago #247635

Hi,

It would require a view override to add the display of such information.
HikaShop order do not provide the order weight ; so you'll need to calculate it using the order's products.
To simplify the process, you can see to use the HikaShop cart class functions, like "calculateWeightAndVolume" ; but you'll need to give it a compatible object as parameter.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 268
  • Thank you received: 7
  • Hikamarket Frontedition Hikamarket Multivendor Hikaserial Standard Hikashop Business
8 years 3 months ago #247641

Not sure what you mean by "To simplify the process, you can see to use the HikaShop cart class functions, like "calculateWeightAndVolume" ; but you'll need to give it a compatible object as parameter."

Can you provide a little more information?

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 3 months ago #247649

Hi,

I'm just saying that the HikaShop cart class have a function which take a cart in parameter and will process the cart products in order to give you a cart weight (and cart volume).
A cart and an order are very similar in their structure, so it would be possible to provide an order object (with correct products) and call the function to get the order weight.
It would require some analyze and some PHP/Development skills ; but it is something possible and the "calculateWeightAndVolume" would avoid to recreate the wheel.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

Moderators: Obsidev
Time to create page: 0.060 seconds
Powered by Kunena Forum