Forums / Customization from the Admin / Price not getting displayed correctly; with attributes

Price not getting displayed correctly; with attributes

Views: 4,847

Results 1 to 20 of 33
26 Jun 2014, 7:02 AM
#1
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Price not getting displayed correctly; with attributes

Hi,
I have used radio buttons to price a product, based on its sizes.
So in the pricing screen I have kept the price as 0. This is an exempted product, hence I have created a new tax class called "no vat" & mentioned the rate as 0%.
attaching the screen shot for the same:
Attachment 14208

Next in the attribute section I have done the following setting :
Attachment 14210

On this category I have put a discount of 10% thru salemaker.

But, if you see the website - the amount next to radio button has not taken the discount, whereas the amount next to the price is showing the discount.

Another funny thing is that despite mentioning "no vat", a vat of 5.5% is added on each of these products in the attribute window. I have highlighted that in the image above.
I have a vat category of 5.5%, but clearly I have not defined it here.
I have no clue what to change where. Please help !:no:

27 Jun 2014, 11:39 AM
#2
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Anyone ?

27 Jun 2014, 2:06 PM
#3
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

What price is displayed on the public side of things, not admin screen?

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

28 Jun 2014, 3:16 AM
#4
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

I am pretty sure that I have found the issue for that, I just need to test a little more ...

Is there anywhere else you see a problem on the Product Tax/No Tax issue besides the Attributes Controller?

I will try to finish testing this fix as soon as I can and get the fix for v1.5.1 as I have been working on fixes for v1.5.3 ...

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!

28 Jun 2014, 6:31 AM
#5
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

@ RixStix - by mistake I have attached wrong image. The last one was meant to be the site image. Here it is :
Attachment 14215

28 Jun 2014, 6:31 AM
#6
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

@ RixStix - by mistake I have attached wrong image. The last one was meant to be the site image. Here it is :
Attachment 14215

28 Jun 2014, 6:37 AM
#7
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

@ Ajeh, Thank you so much !
There are only two categories; on my site; where there is no tax. One of them is books and the other these. I do not have attributes on books, so can't see any issue there.
If you want me to do some testing at my end, would be happy to help :)

28 Jun 2014, 6:41 AM
#8
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

@ Ajeh, Thank you so much !
There are only two categories; on my site; where there is no tax. One of them is books and the other these. I do not have attributes on books, so can't see any issue there.
If you want me to do some testing at my end, would be happy to help :)

28 Jun 2014, 7:15 AM
#9
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

devyani ... pretty positive I will have your solution tomorrow after I wake up and have some coffee ... :)

Your issue is actually more of a "proper display" problem and not an error of bad or damaged code and does not affect you store, but is wrong and a pain in the admin ...

Please let me know if you have seen this anywhere else in your admin or your store, besides the attributes controller so that I can give you those fixes when I put the fix together for you on the Attributes Controller ...

NOTE: This will also be fixed in our next release and I am surprised as heck that no one has reported this until now ... thanks for the excellent catch! I will get you the solution quick as I can tomorrow but it is 3:14am here and I gotta snooze a bit first ... :sleep1:

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!

28 Jun 2014, 2:41 PM
#10
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

To fix the Attributes controller to display the Tax or No Tax on a Product, edit the file:
/your_secret_admin/attributes_controller.php

Change the code around line 1222 and add the code in RED:

<?php
  $current_options_name = '';
[B]  // get products tax id
  $product_check = $db->Execute("select products_tax_class_id from " . TABLE_PRODUCTS . " where products_id = '" . $products_filter . "'" . " limit 1");
//  echo '$products_filter: ' . $products_filter . ' tax id: ' . $product_check->fields['products_tax_class_id'] . '<br>';
[/B]  while (!$attributes_values->EOF) {
    $current_attributes_products_id = $attributes_values->fields['products_id'];

Change the code around line 1594 and add the code in RED:

$attributes_price_final = $currencies->display_price($attributes_price_final, [B]zen_get_tax_rate($product_check->fields['products_tax_class_id'])[/B], 1);

Change the code around line 1596 and add the code in RED:

$attributes_price_final_onetime = $currencies->display_price($attributes_price_final_onetime, [B]zen_get_tax_rate($product_check->fields['products_tax_class_id'])[/B], 1);

Change the code around line 1629 and add the code in RED:

      $new_attributes_price = '|' . $currencies->display_price($new_attributes_price, [B]zen_get_tax_rate($product_check->fields['products_tax_class_id'])[/B], 1);

Now check to see if the Product without tax displays in the Attributes Controller right and check it a Product with tax displays in the Attributes Controller right ...

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!

29 Jun 2014, 1:15 PM
#11
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Thanks Ajeh, I will try right away !
Also, another thing that I noticed is about the priority of the different taxation. So, If I have assigned a particular product to a particular tax type, the other tax should not be added. It is doing that. But the final invoice display shows all the three taxes.
Attaching an example : Attachment 14216

My website is : https://www.bambino.co.in

Thanks !

29 Jun 2014, 1:16 PM
#12
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Thanks Ajeh, I will try right away !
Also, another thing that I noticed is about the priority of the different taxation. So, If I have assigned a particular product to a particular tax type, the other tax should not be added. It is doing that. But the final invoice display shows all the three taxes.
Attaching an example : Attachment 14216

My website is : https://www.bambino.co.in

Thanks !

3 Jul 2014, 11:45 AM
#13
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Hi Ajeh,
Sorry for replying so late.
I had another ccAvenue error that was to be fixed. Hence could not try this earlier.
I tried this fix, but there is no change.
Please let me know if you need more information.:blink:

3 Jul 2014, 2:29 PM
#14
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

You are showing the Orders in the Admin, if I am not mistaken ...

The changes that I posted should fix the display in the Attributes Controller ... are those working in the Attributes Controller now?

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 Jul 2014, 5:12 PM
#15
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Oops ! I am such a nuthead.
Of course if you ask me to make changes in the admin folder, the effect would be on the admin side !
I will check it rightaway

3 Jul 2014, 5:21 PM
#16
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Ok. So the prices are displayed correctly now. But the main problem was that the attributed price is not taking the discounts on that category. I am attaching the screen shot of the web page for that product.
Attachment 14229

This is the updated admin setting
Attachment 14230

If you can see , next to product listing the "priced by attributes" is coming in red with correct price. But with the radio buttons, its not getting reflected on the site

Thank you for looking into this...

3 Jul 2014, 5:45 PM
#17
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

What are your settings in the Sale Maker that you are using?

If you edit the Product for Super Dry Sheets Plain Blue, what is the master_categories_id set to?

If you edit the Product for the Super Soft PRINTED SHEETS what is the master_categories_id set to?

NOTE: with SaleMaker, Sales are set to Products that use the Category that is set in SaleMaker that uses that Categories categories_id as the master_categories_id ...

This means if a Product is "Linked" to a SaleMaker category, the Product does not get the proper settings for the SaleMaker discount ...

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!

4 Jul 2014, 7:26 AM
#18
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

Ajeh:

What are your settings in the Sale Maker that you are using?

---- I am using the salemaker to have a sale of 10% off on category "Bed protectors"

If you edit the Product for Super Dry Sheets Plain Blue, what is the master_categories_id set to?

---- The product is set for master category - "Bed protectors"
If you edit the Product for the Super Soft PRINTED SHEETS what is the master_categories_id set to?

---- The product is set for master category - "Tinycare"

I am not sure but I think the salemaker is doing its job, otherwise I would not have got the display ( marked in circle) as in the image below.
Attachment 14234
I have done similar stuff for another sub-category - nappies. Its working fine here. Attaching the picture for your reference.
Attachment 14235

Not sure what I am missing !

4 Jul 2014, 1:23 PM
#19
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Price not getting displayed correctly; with attributes

The Muslin Triangle is showing the prices while the Plain Blue is not ...

What is the master_categories_id for the Muslin Triangle?

What is the master_categories_id for the Plain Blue?

What are the settings on the SaleMaker set to for the Muslin Triangle Category?

What are the settings on the SaleMaker set to for the Plain Blue Category?

Something is different between the two either on the Product settings or the SaleMaker settings ...

Do both the Muslin Triangle Category and the Plain Blue Category only have 1 SaleMaker set to them?

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!

4 Jul 2014, 1:33 PM
#20
devyani avatar

devyani

Zen Follower

Join Date:
Aug 2011
Posts:
199
Plugin Contributions:
0

Re: Price not getting displayed correctly; with attributes

That's what even I am trying to understand...
Can I send the screenshots of these settings ? Both the products have different master categories.
Bu the procedure I used is same.