Jump to content

Alegra

Members
  • Posts

    5
  • Joined

  • Last visited

Profile Information

  • First Name
    Alegra
  • Last Name
    Felica

Alegra's Achievements

Newbie

Newbie (1/14)

  • Week One Done Rare
  • One Month Later Rare
  • One Year In Rare

Recent Badges

2

Reputation

  1. To edit the position of the links in "My account" block (my Prestashop version is 1.7.5), open the modules/ps_customeraccountlinks/ps_customeraccountlinks.php Around line 100 you will find "my_account_urls = array". In this array is set position of links with numbers from 0-5. $my_account_urls = array( 2 => array( 'title' => $this->trans('Orders', array(), 'Admin.Global'), 'url' => $link->getPageLink('history', true), ), 3 => array( 'title' => $this->trans('Credit slips', array(), 'Modules.Customeraccountlinks.Admin'), 'url' => $link->getPageLink('order-slip', true), ), 1 => array( 'title' => $this->trans('Addresses', array(), 'Shop.Theme.Global'), 'url' => $link->getPageLink('addresses', true), ), 0 => array( 'title' => $this->trans('Personal info', array(), 'Modules.Customeraccountlinks.Admin'), 'url' => $link->getPageLink('identity', true), ), ); if ((int)Configuration::get('PS_ORDER_RETURN')) { $my_account_urls[4] = array( 'title' => $this->trans('Merchandise returns', array(), 'Modules.Customeraccountlinks.Admin'), 'url' => $link->getPageLink('order-follow', true), ); } if (CartRule::isFeatureActive()) { $my_account_urls[5] = array( 'title' => $this->trans('Vouchers', array(), 'Shop.Theme.Customeraccount'), 'url' => $link->getPageLink('discount', true), ); }
  2. I had as Bellini13 described the problem exactly with discount type # 2 on page "My Vouchers". My Presta version is 1.6.1.4 I create a voucher with the following parameters: Conditions - Custumer - Limit to a single customer - Minimum amount - 0 - Total available - 1 - Total available for each user - 1 - Restrictions - All groups Actions - Apply a discount - Percent - Value - 10% - Apply a discount to - Order (without shipping) In the shop I use two currencies: - BGN - EUR On the page "My Vouchers" discount is shown as follows for both currencies: - BGN - EUR To solve this problem, I did the following: In controllers/front/DiscountController.php found: public function initContent() { parent::initContent(); $cart_rules = CartRule::getCustomerCartRules($this->context->language->id, $this->context->customer->id, true, false); $nb_cart_rules = count($cart_rules); foreach ($cart_rules as &$discount) { $discount['value'] = Tools::convertPriceFull( $discount['value'], new Currency((int)$discount['reduction_currency']), new Currency((int)$this->context->cart->id_currency) ); } $this->context->smarty->assign(array( 'nb_cart_rules' => (int)$nb_cart_rules, 'cart_rules' => $cart_rules, 'discount' => $cart_rules, 'nbDiscounts' => (int)$nb_cart_rules) ); $this->setTemplate(_PS_THEME_DIR_.'discount.tpl'); } } And add: public function initContent() { parent::initContent(); $cart_rules = CartRule::getCustomerCartRules($this->context->language->id, $this->context->customer->id, true, false); $nb_cart_rules = count($cart_rules); foreach ($cart_rules as &$discount) { +++ if ($discount['id_discount_type'] == Discount::AMOUNT){ $discount['value'] = Tools::convertPriceFull( $discount['value'], new Currency((int)$discount['reduction_currency']), new Currency((int)$this->context->cart->id_currency) ); } $this->context->smarty->assign(array( 'nb_cart_rules' => (int)$nb_cart_rules, 'cart_rules' => $cart_rules, 'discount' => $cart_rules, 'nbDiscounts' => (int)$nb_cart_rules) ); $this->setTemplate(_PS_THEME_DIR_.'discount.tpl'); } +++ } } Now percent in both currencies are the same.
  3. Hello everyone, Please excuse me for my bad English. I have Prestashop 1.6.1.4 and most of the products in the store are zero stock but can be ordered. In this case I want customers who order products with zero stock (pre-order) to receive specific % discount. How can I add such a filter in the Catalog Price Rules? Please help
  4. Hi everyone! I have the same question - how to create a newsletter in Presta Shop? Please, people, don't be so "quiet" - help us. Thanks in advance Alegra
×
×
  • Create New...