Jump to content

Add a line in product.tpl with different price


hellykun

Recommended Posts

Hello Everyone,

 

I am trying to do something here. I am trying to add a line in every product that show our store price which is a little more expensive than web price. I have added the following code in product tpl file:

<p class="our_price_display">
				{if $priceDisplay >= 0 && $priceDisplay <= 2}
					<span id="our_price_display"><font color = "green"> Web Price:  </font> {convertPrice price=$productPrice}</span>
					<!--{if $tax_enabled  && ((isset($display_tax_label) && $display_tax_label == 1) OR !isset($display_tax_label))}
						{if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if}
					{/if}-->
				{/if}
				</p>
				
				<p class="our_price_display">
				{if $priceDisplay >= 0 && $priceDisplay <= 2}
					<span id="our_price_display"><font color = "black" size = "4">Store Price : {convertPrice price=($productPrice*1.05)} </font></span>
					<!--{if $tax_enabled  && ((isset($display_tax_label) && $display_tax_label == 1) OR !isset($display_tax_label))}
						{if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if}
					{/if}-->
				{/if}
				</p>

The problem is that when a product has different attributes and the user selects them the price of the second (Store Price) stays the same and the "Web Price" is not shown Which file handles the product price for products with different combinations (combination price)?

 

Thanks a lot in advance.

Link to comment
Share on other sites

From what I can understand there is a JS file that handles the change of price when the product has combinations with specific prices set.

 

The fields with the id=our_price_display are changed.

 

Could somebody point me to this js file?

Thanks a lot

I am using prestashop 1.5.4
 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...