Jump to content

Catalogo/prodotti backoffice non funziona la ricerca


Recommended Posts

Buongiorno

Da qualche tempo non funziona più la ricerca di prodotti all'interno del backoffice "catalogo/prodotti" anche la semplice opzione STATO "active/inactiv" non funziona nulla, ho notato che nella querri manca una riga o almeno non è completa, i teoria dovrebbe apparire la seguente query:

SELECT SQL_CALC_FOUND_ROWS p.`id_product`  AS `id_product`,
 p.`reference`  AS `reference`,
 sa.`price`  AS `price`,
 p.`id_shop_default`  AS `id_shop_default`,
 p.`is_virtual`  AS `is_virtual`,
 pl.`name`  AS `name`,
 pl.`link_rewrite`  AS `link_rewrite`,
 sa.`active`  AS `active`,
 shop.`name`  AS `shopname`,
 image_shop.`id_image`  AS `id_image`,
 cl.`name`  AS `name_category`,
 0 AS `price_final`,
 pd.`nb_downloadable`  AS `nb_downloadable`,
 sav.`quantity`  AS `sav_quantity`,
 IF(sav.`quantity`<=0, 1, 0) AS `badge_danger`,
 cp.`position`  AS `position`
FROM  `psip_product` p
 LEFT JOIN `psip_product_lang` pl ON (pl.`id_product` = p.`id_product` AND pl.`id_lang` = 2 AND pl.`id_shop` = 1)
 LEFT JOIN `psip_stock_available` sav ON (sav.`id_product` = p.`id_product` AND sav.`id_product_attribute` = 0 AND sav.id_shop = 1  AND sav.id_shop_group = 0 )
 JOIN `psip_product_shop` sa ON (p.`id_product` = sa.`id_product` AND sa.id_shop = 1)
 LEFT JOIN `psip_category_lang` cl ON (sa.`id_category_default` = cl.`id_category` AND cl.`id_lang` = 2 AND cl.id_shop = 1)
 LEFT JOIN `psip_category` c ON (c.`id_category` = cl.`id_category`)
 LEFT JOIN `psip_shop` shop ON (shop.id_shop = 1)
 LEFT JOIN `psip_image_shop` image_shop ON (image_shop.`id_product` = p.`id_product` AND image_shop.`cover` = 1 AND image_shop.id_shop = 1)
 LEFT JOIN `psip_image` i ON (i.`id_image` = image_shop.`id_image`)
 LEFT JOIN `psip_product_download` pd ON (pd.`id_product` = p.`id_product`)
 INNER JOIN `psip_category_product` cp ON (cp.`id_product` = p.`id_product` AND cp.`id_category` = 15)
WHERE (1 AND pl.`name` LIKE '%artigiano%' AND state = 1)
 
ORDER BY  `active` desc,  `id_product` asc
 
LIMIT 0, 50
;

Mentre la parte WHERE non appare completa come di seguito:

SELECT SQL_CALC_FOUND_ROWS p.`id_product`  AS `id_product`,
 p.`reference`  AS `reference`,
 sa.`price`  AS `price`,
 p.`id_shop_default`  AS `id_shop_default`,
 p.`is_virtual`  AS `is_virtual`,
 pl.`name`  AS `name`,
 pl.`link_rewrite`  AS `link_rewrite`,
 sa.`active`  AS `active`,
 shop.`name`  AS `shopname`,
 image_shop.`id_image`  AS `id_image`,
 cl.`name`  AS `name_category`,
 0 AS `price_final`,
 pd.`nb_downloadable`  AS `nb_downloadable`,
 sav.`quantity`  AS `sav_quantity`,
 IF(sav.`quantity`<=0, 1, 0) AS `badge_danger`,
 cp.`position`  AS `position`
FROM  `psue_product` p
 LEFT JOIN `psue_product_lang` pl ON (pl.`id_product` = p.`id_product` AND pl.`id_lang` = 2 AND pl.`id_shop` = 1)
 LEFT JOIN `psue_stock_available` sav ON (sav.`id_product` = p.`id_product` AND sav.`id_product_attribute` = 0 AND sav.id_shop = 1  AND sav.id_shop_group = 0 )
 JOIN `psue_product_shop` sa ON (p.`id_product` = sa.`id_product` AND sa.id_shop = 1)
 LEFT JOIN `psue_category_lang` cl ON (sa.`id_category_default` = cl.`id_category` AND cl.`id_lang` = 2 AND cl.id_shop = 1)
 LEFT JOIN `psue_category` c ON (c.`id_category` = cl.`id_category`)
 LEFT JOIN `psue_shop` shop ON (shop.id_shop = 1)
 LEFT JOIN `psue_image_shop` image_shop ON (image_shop.`id_product` = p.`id_product` AND image_shop.`cover` = 1 AND image_shop.id_shop = 1)
 LEFT JOIN `psue_image` i ON (i.`id_image` = image_shop.`id_image`)
 LEFT JOIN `psue_product_download` pd ON (pd.`id_product` = p.`id_product`)
 INNER JOIN `psue_category_product` cp ON (cp.`id_product` = p.`id_product` AND cp.`id_category` = 24)
WHERE 1
 
ORDER BY  `active` desc,  `id_product` asc
 
LIMIT 0, 100
;

Dove posso correggere questo problema?

 

saluti

Link to comment
Share on other sites

  • 2 weeks later...
  • 8 months later...
  • 1 month later...
  • 1 year later...

Purtroppo no a noi funziona senza problemi, 

su tutti i siti che gestisco non esiste questo problema la ricerca funziona senza problemi,

non capisco come vedi la query dall'ingranaggio?

nel tal caso io la vedo con 

Quote

WHERE (1 AND pl.`name` LIKE '%poster%' AND state = 1)

a me sembra più un problema di modulo che interferisce,

hai errori nella console javascript?

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...