Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

sector78

Newbie
  
  • Posts

    9
  • Joined

  • Last visited

sector78's Achievements

Rookie

Rookie (2/14)

  • First Post
  • Conversation Starter
  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

0

Reputation

  1. Задача: Сделать скидку в процентах для группы покупателей opencart 2.0 и вывести ее в карточке товара со стандартной ценой? 1. Был установлен модуль Total Customer Group Discount Скидка отображается только в корзине, а как вывести цену со скидкой в карточку товара для групп пользователе? На одном форуме подсказали: в файле \catalog\controller\product\product.phpнаходим $discounts = $this->model_catalog_product->getProductDiscounts($this->request->get['product_id']); и перед ним вставим // Скидка для групп if ($this->customer->getGroupId() == 2) { $perc_price = $product_info['price'] - ($product_info['price'] / 100) * 10; $data['special'] = $this->currency->format($this->tax->calculate($perc_price, $product_info['tax_class_id'], $this->config->get('config_tax'))); } else { $data['special'] = false; } соответственно цифра 2 это id нужной группы, а 10 это проценты Но поскольку групп будет несколько например - одна группа "id=2" - скидка 3%, а вторая группа "id=3" - скидка 5% и т.д.
  2. не работает модуль, как его правильно установить и второй вопрос , как сделать его по умолчанию вместо 15 товаров
Guest
×
  • Create New...

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.