Results 1 to 7 of 7
  1. #1

    help question Total weight on orders.php

    Hi

    I've been seeking answers and can't find any...

    How can i display the total weight of customers products ordered on orders.php for the admin, the page where i edit the orders.

    There are all others infos BUT the total weight....

    Many thanks!

    L.

  2. #2
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Total weight on orders.php

    The weight of the order is actually not saved once the order is complete. You could modify the checkout process to save it, but once the order has been placed and it's visible in admin, you'd have to go through all the products and their attributes to figure out the weight.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  3. #3

    Default Re: Total weight on orders.php

    Hi

    Thanks for your answer but I don't get it...

    If I select admin>configuration>shipping packaging>Display Number of Boxes and Weight Status=2

    the total weight shows everywhere when the order is complete, orders.php included, it is also on the invoice.php...

    what i want is to show it only on orders.php, so as it does show there must be a way to able it on orders.php only but i can't find the code used to display the total weight probably because it is something set up in the configuration...

    Any idea where i can find this code?

    Thanks

    Quote Originally Posted by swguy View Post
    The weight of the order is actually not saved once the order is complete. You could modify the checkout process to save it, but once the order has been placed and it's visible in admin, you'd have to go through all the products and their attributes to figure out the weight.

  4. #4
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Total weight on orders.php

    Quote Originally Posted by wirefram View Post
    Any idea where i can find this code?
    Is the global $shipping_weight variable of any use?

    Cheers
    Rod

  5. #5
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Total weight on orders.php

    $shipping_weight is a catalog side variable.
    This information is not available on the admin side. You will have to write code to figure it out.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  6. #6

    Default Re: Total weight on orders.php

    But invoice.php and orders.php ARE on the admin side, the total weight shows up on both with the configuration i described previously therefore there must be a variable available on the admin side to display this total weight....

    otherwise, where does this total weight come from on those 2 files available only from the admin?

    there is something used by the script to display this total weight on invoice.php and orders.php but i can't figure out what/where this is....




    Quote Originally Posted by swguy View Post
    $shipping_weight is a catalog side variable.
    This information is not available on the admin side. You will have to write code to figure it out.

  7. #7

    Default Re: Total weight on orders.php

    Looks like total weight is defined in the class order.php:

    $shipping_method_query = "select title, value
    from " . TABLE_ORDERS_TOTAL . "
    where orders_id = '" . (int)$order_id . "'
    and class = 'ot_shipping'";


    $shipping_method = $db->Execute($shipping_method_query);

    the variable must be $shipping_method I guess i have to stick the query somewhere on orders.php to use this variable... any idea about this?

 

 

Similar Threads

  1. Display Total weight in Admin/orders
    By rhodesengr in forum Basic Configuration
    Replies: 23
    Last Post: 25 Jan 2018, 05:01 PM
  2. v151 Not receiving total weight for orders
    By stompbox in forum Managing Customers and Orders
    Replies: 1
    Last Post: 3 Oct 2014, 01:53 PM
  3. Total Weight on Admin - Orders not showing
    By mydanilo in forum Customization from the Admin
    Replies: 20
    Last Post: 30 Sep 2011, 08:14 AM
  4. Replies: 1
    Last Post: 9 Sep 2009, 12:11 PM
  5. Replies: 1
    Last Post: 24 Aug 2009, 07:53 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR