Results 1 to 10 of 15

Hybrid View

  1. #1
    Join Date
    Jan 2013
    Location
    Utah
    Posts
    20
    Plugin Contributions
    0

    Default One time charge to be combined with total

    I've been looking for this coding for a while, but no answer yet. My products are yard signs, and I have attributes to auto calculate and update total at the bottom. My attribute prices are hidden because they are not relevent (such as double sided +0.80 etc.)
    Total price will update depending on what attributes they select, and quantity they pick. People will select single or double sided, size, wire sticks or none... all those are standard attribute prices that have quantity discounts coded, and reflect the total, but design proof is a "one time" charge. So after they select all the features they need, they get the total, but on the next screen, in the shpooing cart they see 2 prices. That will confuse them. The secont price is the one time charge, and it only shows up if they select the proof. Is there a way to combine that so that it's just one price? I'm attaching an image Click image for larger version. 

Name:	one time charge.jpg 
Views:	182 
Size:	20.8 KB 
ID:	12970

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: One time charge to be combined with total

    Are you wanting to combine the Unit Price? Total Price? Or both for each Product?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Jan 2013
    Location
    Utah
    Posts
    20
    Plugin Contributions
    0

    Default Re: One time charge to be combined with total

    I would hope for both if at all possible. I also wonder would invoices and emails show it separate or together? I'd need it to be together on all of it.

    If combining it is not an option, would there be a way to label the one time fee to show the attribute name next to it or something. Maybe have attribute name to the left of the $ amount

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: One time charge to be combined with total

    It might make more sense to show the two seperate under the Unit Price then the combination under the Total Price ...

    You can edit the file:
    /includes/modules/pages/shopping_cart/header_php.php

    with these changes or fool with them and see what you get changing from:

    Code:
      $productsPriceEach = $currencies->format($ppe) . ($products[$i]['onetime_charges'] != 0 ? '<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
      $productsPriceTotal = $currencies->format($ppt) . ($products[$i]['onetime_charges'] != 0 ? '<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
      $buttonUpdate = ((SHOW_SHOPPING_CART_UPDATE == 1 or SHOW_SHOPPING_CART_UPDATE == 3) ? zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT) : '') . zen_draw_hidden_field('products_id[]', $products[$i]['id']);
    to be:
    Code:
      $productsPriceEach = $currencies->format($ppe) . ($products[$i]['onetime_charges'] != 0 ? '<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
      $pp_onetime = zen_round(zen_add_tax($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id'])), $currencies->get_decimal_places($_SESSION['currency']));
      $pp_total_all = $pp_onetime + $ppt;
    //  $productsPriceTotal = $currencies->format($ppt) . ($products[$i]['onetime_charges'] != 0 ? '<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
      $productsPriceTotal = $currencies->format($pp_total_all);
      $buttonUpdate = ((SHOW_SHOPPING_CART_UPDATE == 1 or SHOW_SHOPPING_CART_UPDATE == 3) ? zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT) : '') . zen_draw_hidden_field('products_id[]', $products[$i]['id']);
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  5. #5
    Join Date
    Jan 2013
    Location
    Utah
    Posts
    20
    Plugin Contributions
    0

    Default Re: One time charge to be combined with total

    Thank so much. That works great. For future readers of this post, the code above combined the right hand column, total and one time charge into one.

    That still leaves 2 lines under the column on the left called unit, and I can live with that. However it would be ideal to possibly label it somehow so it shows what that bottom price is all about. For example, there are 2 instances that I have one time charge. One charge is if they request a proof, and other is if they request us to create the design. If possibly, is there a way to show on the left of the onetime charge what that charge is. (maybe insert an attributes name)

  6. #6
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: One time charge to be combined with total

    As a guess, what if you change:
    Code:
      $productsPriceEach = $currencies->format($ppe) . ($products[$i]['onetime_charges'] != 0 ? '<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
    to read:
    Code:
      $productsPriceEach = $currencies->format($ppe) . ($products[$i]['onetime_charges'] != 0 ? '<br />one time:<br />' . $currencies->display_price($products[$i]['onetime_charges'], zen_get_tax_rate($products[$i]['tax_class_id']), 1) : '');
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

 

 

Similar Threads

  1. Attributes with a discount and one-time charge
    By rbuswell in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 27 Oct 2011, 05:41 PM
  2. One time charge
    By Tool Pusher in forum Setting Up Categories, Products, Attributes
    Replies: 3
    Last Post: 9 Feb 2010, 03:32 AM
  3. Need one time charge with Product Attribute Grid
    By jalaco in forum Setting Up Categories, Products, Attributes
    Replies: 5
    Last Post: 30 Apr 2008, 04:33 AM
  4. Using "One time charge" with attributes
    By hiddink in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 16 May 2006, 09:06 AM

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