Нет вывода &where=`{"Data.favorite":"1"}`
Есть решение
Подскажите в чём может быть проблемы вывода товаров со статусом «Особый» из miniShop2. Товары с &where=`{«Data.popular»:«1»}`и &where=`{«Data.new»:«1»}` выводятся всё ок. А вот если &where=`{«Data.favorite»:«1»}` то результата нету. Вызов сниппета такой:
1
[[!msProducts? &tpl=`itemHome.hb` &parents=`5` &showHidden=`1` &where=`{"Data.favorite":"1"}` &limit=`6` &showLog=`1`]]Лог:0.0000730: xPDO query object created
0.0003119: leftJoined msProductData as Data
0.0002460: leftJoined msVendor as Vendor
0.0000050: Grouped by msProduct.id
0.0000892: Added selection of msProduct: SQL_CALC_FOUND_ROWS `id`, `type`, `contentType`, `pagetitle`, `longtitle`, `description`, `alias`, `link_attributes`, `published`, `pub_date`, `unpub_date`, `parent`, `isfolder`, `introtext`, `content`, `richtext`, `template`, `menuindex`, `searchable`, `cacheable`, `createdby`, `createdon`, `editedby`, `editedon`, `deleted`, `deletedon`, `deletedby`, `publishedon`, `publishedby`, `menutitle`, `donthit`, `privateweb`, `privatemgr`, `content_dispo`, `hidemenu`, `class_key`, `context_key`, `content_type`, `uri`, `uri_override`, `hide_children_in_tree`, `show_in_tree`, `properties`
0.0000379: Added selection of msProductData: `article`, `price`, `old_price`, `weight`, `image`, `thumb`, `vendor`, `made_in`, `new`, `popular`, `favorite`, `tags`, `color`, `size`, `source`
0.0000329: Added selection of msVendor: `name` AS `vendor.name`, `resource` AS `vendor.resource`, `country` AS `vendor.country`, `logo` AS `vendor.logo`, `address` AS `vendor.address`, `phone` AS `vendor.phone`, `fax` AS `vendor.fax`, `email` AS `vendor.email`, `description` AS `vendor.description`, `properties` AS `vendor.properties`
0.0011990: Processed additional conditions
0.0015931: Added where condition: class_key=msProduct, Data.favorite=1, msProduct.parent:IN(5,76,94,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,95,97,98,99,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116), msProduct.published=1, msProduct.deleted=0
0.0000620: Sorted by msProduct.id, ASC
0.0000062: Limited to 6, offset 0
0.0005288: SQL prepared "SELECT SQL_CALC_FOUND_ROWS `msProduct`.`id`, `msProduct`.`type`, `msProduct`.`contentType`, `msProduct`.`pagetitle`, `msProduct`.`longtitle`, `msProduct`.`description`, `msProduct`.`alias`, `msProduct`.`link_attributes`, `msProduct`.`published`, `msProduct`.`pub_date`, `msProduct`.`unpub_date`, `msProduct`.`parent`, `msProduct`.`isfolder`, `msProduct`.`introtext`, `msProduct`.`content`, `msProduct`.`richtext`, `msProduct`.`template`, `msProduct`.`menuindex`, `msProduct`.`searchable`, `msProduct`.`cacheable`, `msProduct`.`createdby`, `msProduct`.`createdon`, `msProduct`.`editedby`, `msProduct`.`editedon`, `msProduct`.`deleted`, `msProduct`.`deletedon`, `msProduct`.`deletedby`, `msProduct`.`publishedon`, `msProduct`.`publishedby`, `msProduct`.`menutitle`, `msProduct`.`donthit`, `msProduct`.`privateweb`, `msProduct`.`privatemgr`, `msProduct`.`content_dispo`, `msProduct`.`hidemenu`, `msProduct`.`class_key`, `msProduct`.`context_key`, `msProduct`.`content_type`, `msProduct`.`uri`, `msProduct`.`uri_override`, `msProduct`.`hide_children_in_tree`, `msProduct`.`show_in_tree`, `msProduct`.`properties`, `Data`.`article`, `Data`.`price`, `Data`.`old_price`, `Data`.`weight`, `Data`.`image`, `Data`.`thumb`, `Data`.`vendor`, `Data`.`made_in`, `Data`.`new`, `Data`.`popular`, `Data`.`favorite`, `Data`.`tags`, `Data`.`color`, `Data`.`size`, `Data`.`source`, `Vendor`.`name` AS `vendor.name`, `Vendor`.`resource` AS `vendor.resource`, `Vendor`.`country` AS `vendor.country`, `Vendor`.`logo` AS `vendor.logo`, `Vendor`.`address` AS `vendor.address`, `Vendor`.`phone` AS `vendor.phone`, `Vendor`.`fax` AS `vendor.fax`, `Vendor`.`email` AS `vendor.email`, `Vendor`.`description` AS `vendor.description`, `Vendor`.`properties` AS `vendor.properties` FROM `NH6i_site_content` AS `msProduct` LEFT JOIN `NH6i_ms2_products` `Data` ON `msProduct`.`id`=`Data`.`id` LEFT JOIN `NH6i_ms2_vendors` `Vendor` ON `Data`.`vendor`=`Vendor`.`id` WHERE ( `msProduct`.`class_key` = 'msProduct' AND `Data`.`favorite` = '1' AND `msProduct`.`parent` IN (5,76,94,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,95,97,98,99,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116) AND `msProduct`.`published` = 1 AND `msProduct`.`deleted` = 0 ) GROUP BY msProduct.id ORDER BY msProduct.id ASC LIMIT 6 "
0.0014141: SQL executed
0.0000961: Total rows: 0
0.0000119: Rows fetched
0.0000181: Returning raw data
0.0054879: Total time
23 068 672: Memory usageЗдесь уже посмотрел так и тут в том числе
Комментарии: 1