vodkoglot Опубликовано: августа 10, 2018 Жалоба Поделиться Опубликовано: августа 10, 2018 помогите как сделать что бы вывод товара начинался с определенного производителя? Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
WarStyle Опубликовано: августа 10, 2018 Жалоба Поделиться Опубликовано: августа 10, 2018 2 часа назад, vodkoglot сказал: помогите как сделать что бы вывод товара начинался с определенного производителя? Сделать чтобы выводился с определенного производителя, изи же. По сути, больше информации нужно, где выводился, как выводился, версия движка какая. Чем подробнее опишите, тем быстрее получите ответ. Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
vodkoglot Опубликовано: августа 13, 2018 Автор Жалоба Поделиться Опубликовано: августа 13, 2018 OpenCart © 2009-2018 Все права защищены.Version 2.2.0.0 вывод в категориях мне нужно что бы выводился первым производитель Panda Скрытый текст Картинки, код и логи убирайте под спойлер. Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Это популярное сообщение. WarStyle Опубликовано: августа 13, 2018 Это популярное сообщение. Жалоба Поделиться Опубликовано: августа 13, 2018 2 часа назад, vodkoglot сказал: OpenCart © 2009-2018 Все права защищены.Version 2.2.0.0 вывод в категориях мне нужно что бы выводился первым производитель Panda Показать содержимое Картинки, код и логи убирайте под спойлер. 1) Покупаете и устанавливаете модуль Batch Editor. 2) В этом модуле фильтруете товар по нужному производителю и задаете порядок сортировки 0 (он уже наверное так и задан). 3) Фильтруете все товары, кроме производителя Panda и ставите им порядок сортировки например 999. Вот так примерно будет выглядеть фильтр всех товаров, без панды: http://joxi.ru/5md7EW3UkN4z1r только вместо Apple должно быть Panda AWARO 1 Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
vodkoglot Опубликовано: августа 13, 2018 Автор Жалоба Поделиться Опубликовано: августа 13, 2018 а без плагина? Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Это популярное сообщение. RHCk Опубликовано: августа 13, 2018 Это популярное сообщение. Жалоба Поделиться Опубликовано: августа 13, 2018 3 часа назад, vodkoglot сказал: а без плагина? То же самое, только ручками каждый товар. AWARO 1 Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
BuslikDrev Опубликовано: августа 14, 2018 Жалоба Поделиться Опубликовано: августа 14, 2018 Сделать так в: catalog\controller\product\category.php Скрытый текст $product_total = $this->model_catalog_product->getTotalProducts($filter_data); $results = $this->model_catalog_product->getProducts($filter_data); foreach ($results as $result) { if ($result['manufacturer_id'] == 8) { if ($result['image']) { $image = $this->model_tool_image->resize($result['image'], $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } else { $image = $this->model_tool_image->resize('placeholder.png', $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) { $price = $this->currency->format($this->tax->calculate($result['price'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $price = false; } if ((float)$result['special']) { $special = $this->currency->format($this->tax->calculate($result['special'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $special = false; } if ($this->config->get('config_tax')) { $tax = $this->currency->format((float)$result['special'] ? $result['special'] : $result['price']); } else { $tax = false; } if ($this->config->get('config_review_status')) { $rating = (int)$result['rating']; } else { $rating = false; } $data['products'][] = array( 'product_id' => $result['product_id'], 'thumb' => $image, 'name' => $result['name'], 'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get('config_product_description_length')) . '..', 'price' => $price, 'special' => $special, 'tax' => $tax, 'minimum' => $result['minimum'] > 0 ? $result['minimum'] : 1, 'rating' => $result['rating'], 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url) ); } } foreach ($results as $result) { if ($result['manufacturer_id'] != 8) { if ($result['image']) { $image = $this->model_tool_image->resize($result['image'], $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } else { $image = $this->model_tool_image->resize('placeholder.png', $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) { $price = $this->currency->format($this->tax->calculate($result['price'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $price = false; } if ((float)$result['special']) { $special = $this->currency->format($this->tax->calculate($result['special'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $special = false; } if ($this->config->get('config_tax')) { $tax = $this->currency->format((float)$result['special'] ? $result['special'] : $result['price']); } else { $tax = false; } if ($this->config->get('config_review_status')) { $rating = (int)$result['rating']; } else { $rating = false; } $data['products'][] = array( 'product_id' => $result['product_id'], 'thumb' => $image, 'name' => $result['name'], 'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get('config_product_description_length')) . '..', 'price' => $price, 'special' => $special, 'tax' => $tax, 'minimum' => $result['minimum'] > 0 ? $result['minimum'] : 1, 'rating' => $result['rating'], 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url) ); } } Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Это популярное сообщение. WarStyle Опубликовано: августа 14, 2018 Это популярное сообщение. Жалоба Поделиться Опубликовано: августа 14, 2018 2 часа назад, BuslikDrev сказал: Сделать так в: catalog\controller\product\category.php Показать содержимое $product_total = $this->model_catalog_product->getTotalProducts($filter_data); $results = $this->model_catalog_product->getProducts($filter_data); foreach ($results as $result) { if ($result['manufacturer_id'] == 8) { if ($result['image']) { $image = $this->model_tool_image->resize($result['image'], $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } else { $image = $this->model_tool_image->resize('placeholder.png', $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) { $price = $this->currency->format($this->tax->calculate($result['price'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $price = false; } if ((float)$result['special']) { $special = $this->currency->format($this->tax->calculate($result['special'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $special = false; } if ($this->config->get('config_tax')) { $tax = $this->currency->format((float)$result['special'] ? $result['special'] : $result['price']); } else { $tax = false; } if ($this->config->get('config_review_status')) { $rating = (int)$result['rating']; } else { $rating = false; } $data['products'][] = array( 'product_id' => $result['product_id'], 'thumb' => $image, 'name' => $result['name'], 'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get('config_product_description_length')) . '..', 'price' => $price, 'special' => $special, 'tax' => $tax, 'minimum' => $result['minimum'] > 0 ? $result['minimum'] : 1, 'rating' => $result['rating'], 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url) ); } } foreach ($results as $result) { if ($result['manufacturer_id'] != 8) { if ($result['image']) { $image = $this->model_tool_image->resize($result['image'], $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } else { $image = $this->model_tool_image->resize('placeholder.png', $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')); } if (($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) { $price = $this->currency->format($this->tax->calculate($result['price'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $price = false; } if ((float)$result['special']) { $special = $this->currency->format($this->tax->calculate($result['special'], $result['tax_class_id'], $this->config->get('config_tax'))); } else { $special = false; } if ($this->config->get('config_tax')) { $tax = $this->currency->format((float)$result['special'] ? $result['special'] : $result['price']); } else { $tax = false; } if ($this->config->get('config_review_status')) { $rating = (int)$result['rating']; } else { $rating = false; } $data['products'][] = array( 'product_id' => $result['product_id'], 'thumb' => $image, 'name' => $result['name'], 'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get('config_product_description_length')) . '..', 'price' => $price, 'special' => $special, 'tax' => $tax, 'minimum' => $result['minimum'] > 0 ? $result['minimum'] : 1, 'rating' => $result['rating'], 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url) ); } } А завтра он передумает и снова придет ? BuslikDrev и RHCk 1 1 Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Рекомендуемые сообщения
Присоединяйтесь к обсуждению
Вы можете опубликовать сейчас и зарегистрироваться позже. Если у вас есть учётная запись, войдите, чтобы публиковать под своей учётной записью.