Skip to main content

Formatting discounts

More
8 years 11 months ago #281024 by palee3
Formatting discounts was created by palee3
-- HikaShop version -- : 3.2.1

Hi,

I would like to ask for help again, about formatting discount prices.

At the moment there is a little anomaly with displaying discounts. I attached a screen about what is the current settings, and what I would like to make (right side of the picture).


Thank you in advance.

Regars,
Pal

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

More
8 years 11 months ago #281027 by nicolas
Replied by nicolas on topic Formatting discounts
Hi,

You'll have to edit the file "listing_price" of the view "product" via the menu Display>Views in order to change the way the discount is displayed.
Here is a thread where we talk about that:
www.hikashop.com/forum/4-how-to/21930-ho...discounts.html#33909

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

More
8 years 10 months ago #281780 by palee3
Replied by palee3 on topic Formatting discounts
Hi,

That post was a good starting point, but I have one more question, I do not find the Discount price in the source code (what is the 10 000 Ft in the example). Please can yopu help me with the discount price line/code what I would like to modify.

Original was (product/ listing_price 87 line)
Code:
echo $this->currencyHelper->format(-1*$this->row->discount->discount_flat_amount,$price->price_currency_id);

Modified to:
Code:
echo $this->currencyHelper->format($price->price_value_without_discount_with_tax,$price->price_currency_id). '</br> '; echo $this->currencyHelper->format(-1*$this->row->discount->discount_flat_amount,$price->price_currency_id). '</br> ';

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

More
8 years 10 months ago #281803 by Jerome
Replied by Jerome on topic Formatting discounts
Hello,

Since that price is displayed in the view, you can find the corresponding line which contains the information want.
But please note that you can still use PHP in order to know more about what a variable contains.
Code:
var_dump($price);

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.

Time to create page: 0.208 seconds
Powered by Kunena Forum