News:

Support the VirtueMart project and become a member

Main Menu

Crossed out price without discount ?!

Started by thebit, January 29, 2015, 11:10:01 AM

Previous topic - Next topic

thebit

Hello folks,
after an importation from a csv file (with csvi-free component) with two test products I have some issues with showed price.
I created manually a product test Test iva21 and it shows the correct price (without any cross)
So, I imported 2 test product from a csv file with this structure:

product_sku;product_name;product_in_stock;product_price;product_tax_id;category_id;published
907002998;2IN FIBRA SOLUBILE 20BUST;10;7,75;1;1;Y
901191092;2IN FIBRA+DOLCIF 13BUST BIPAR;20;7,49;2;1;Y

Both products (as you can see in the picture) have two equal prices and one of them is crossed out.
In the middle price I manually set a discount price = 9€ and it is correctly showed with the red icon (right-corner)
The problem is: in the third product I have not changed anything and also that product  is showed with a crossed out price equal to the other price.
Finally, if I go in the page of the third product (see the 2nd attached picture) is showed an image with 0% off
Why in my test product I have one price and no icon "% off" ?

I hope you can help me, thanks

(Joomla: 2.5.28 - VM: 2.6.14)

AH

find the product id for the sku and then look in the database price table, you might find your answer there

_virtuemart_product_prices

Here is the code (FROM VM 3.0.4)  that determines how to display a price, it is similar in your version



if (round($product->prices['basePriceWithTax'],$currency->_priceConfig['salesPrice'][1]) != $product->prices['salesPrice']) {
echo '<span class="price-crossed" >' . $currency->createPriceDiv ('basePriceWithTax', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_WITHTAX', $product->prices) . "</span>";
}
if (round($product->prices['salesPriceWithDiscount'],$currency->_priceConfig['salesPrice'][1]) != $product->prices['salesPrice']) {
echo $currency->createPriceDiv ('salesPriceWithDiscount', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITH_DISCOUNT', $product->prices);
}
Regards
A

Joomla 4.4.5
php 8.1

GJC Web Design

you need to also check your template display logic for discounted prices if your using a 3rd party template
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

thebit

Hi,
Quote from: GJC Web Design on January 29, 2015, 11:49:24 AM
you need to also check your template display logic for discounted prices if your using a 3rd party template
I also tried with a default joomla template (Beez_20) and the result is the same. Products imported from csv via csvi 2 equal prices and one of them is crossed.
Quote from: Hutson on January 29, 2015, 11:49:24 AM
find the product id for the sku and then look in the database price table, you might find your answer there

_virtuemart_product_prices
I selected a product which shows a crossed price and I replaced all fields (differents from the product I created manually) of this products with the fields of the product I created manually but the issue of crossed price and  of the icon (with "0% off") remains

AH

Regards
A

Joomla 4.4.5
php 8.1

thebit

Quote from: Hutson on January 29, 2015, 23:46:17 PM
check your database as I said above
I checked all my db table which starts with virtuemart_price_* or virtuemart_product_*
I read some forum topic and I realized thisi a bug still unresolved in VM 2 version

thebit

Exacly, I checked
  • _virtuemart_products
  • _virtuemart_products_it_it
  • _virtuemart_product_categories
  • _virtuemart_product_prices

    and the fields content are the same!

servlet

you have different number of columns for head roll and for product values
Check your CSV file
Он-лайн магазин за фототапети http://mishelfoster.com