Jump to content

dokorek

Members
  • Posts

    15
  • Joined

  • Last visited

Profile Information

  • Location
    Poland
  • Activity
    Agency

dokorek's Achievements

  1. Masakra z tym błędem. Pojawia się bardzo rzadko i nie wiadomo od czego jest zależny
  2. Witam Na stronie ceneo http://dlasklepow.ceneo.pl/oprogramowanie-dla-sklepow/ jest informacja że taka integracja jest dostępna. Niestety żadnego linka ani informacji gdzie pobrać nie ma.
  3. I have got the same error on different module :/ SOLUTION: In Dreamweaver do: Commands -> Apply source formating Save file and upload it on your ftp
  4. I have solution it is very simple You must add: $this->identifier = 'id_customer'; $this->addRowAction('edit'); and function: public function displayEditLink($token, $id, $name = null) { $tpl = $this->createTemplate('helpers/list/list_action_edit.tpl'); if (!array_key_exists('Test', self::$cache_lang)) self::$cache_lang['Test'] = $this->l('Test', 'Helper'); $tpl->assign(array( 'href' => 'index.php?controller=AdminCustomers&id_customer='.$id.'&updatecustomer&token='.Tools::getAdminTokenLite('AdminCustomers'), 'action' => self::$cache_lang['Test'], 'id' => $id )); return $tpl->fetch(); } my code from AdminGroupsController.php protected function renderCustomersList($group) { $genders = array(0 => '?'); $genders_icon = array('default' => 'unknown.gif'); foreach (Gender::getGenders() as $gender) { $genders_icon[$gender->id] = '../genders/'.(int)$gender->id.'.jpg'; $genders[$gender->id] = $gender->name; } $this->table = 'customer_group'; $this->lang = false; $this->list_id = 'customer_group'; $this->identifier = 'id_customer'; $this->actions = array(); $this->bulk_actions = false; $this->list_no_link = true; $this->fields_list = (array( 'id_customer' => array('title' => $this->l('ID'), 'width' => 15,'prefix' => '<b>', 'suffix' => '</b>', 'align' => 'center', 'filter_key' => 'c!id_customer'), 'firstname' => array('title' => $this->l('First name'), 'align' => 'left'), 'lastname' => array('title' => $this->l('Last name'), 'align' => 'left'), 'email' => array('title' => $this->l('Email address'), 'width' => 150, 'align' => 'left', 'filter_key' => 'c!email', 'orderby' => true), 'nb' => array('title' => $this->l('Orders'), 'width' => 100,), 'wartosc' => array('title' => $this->l('Wartość'), 'width' => 150,), 'date_add' => array('title' => $this->l('Register date'), 'width' => 150, 'align' => 'right', 'type' => 'date'), 'active' => array('title' => $this->l('Enabled'),'align' => 'center','width' => 20, 'active' => 'status','type' => 'bool') )); $this->_select = 'c.*, co.*, SUM( co.`total_paid_real`) AS wartosc, COUNT( co.`id_customer`) AS nb, co.`id_customer` AS id_customer '; $this->_join = ' LEFT JOIN `'._DB_PREFIX_.'customer` c ON (a.`id_customer` = c.`id_customer`) LEFT JOIN `'._DB_PREFIX_.'orders` co ON (co.`id_customer` = c.`id_customer`) '; $this->_where = 'AND a.`id_group` = '.(int)$group->id.' AND c.`deleted` != 1'; $this->_group = 'GROUP BY co.`id_customer`'; self::$currentIndex = self::$currentIndex.'&viewgroup'.'&id_group='.(int)$group->id; $this->addRowAction('edit'); $this->processFilter(); return parent::renderList(); } public function displayEditLink($token, $id, $name = null) { $tpl = $this->createTemplate('helpers/list/list_action_edit.tpl'); if (!array_key_exists('Test', self::$cache_lang)) self::$cache_lang['Test'] = $this->l('Test', 'Helper'); $tpl->assign(array( 'href' => 'index.php?controller=AdminCustomers&id_customer='.$id.'&updatecustomer&token='.Tools::getAdminTokenLite('AdminCustomers'), 'action' => self::$cache_lang['Test'], 'id' => $id )); return $tpl->fetch(); }
  5. Hi I need to add to detailed view of customers in selected group (controller=AdminGroups) availability to edit customer (action edit link to customer edit page)- see screenshot: I've edited AdminGroupsController.php to see how many orders customer have and how many they paid: protected function renderCustomersList($group) { $genders = array(0 => '?'); $genders_icon = array('default' => 'unknown.gif'); foreach (Gender::getGenders() as $gender) { $genders_icon[$gender->id] = '../genders/'.(int)$gender->id.'.jpg'; $genders[$gender->id] = $gender->name; } $this->table = 'customer_group'; $this->lang = false; $this->list_id = 'customer_group'; $this->actions = array(); $this->bulk_actions = false; $this->list_no_link = true; $this->fields_list = (array( 'id_customer' => array('title' => $this->l('ID'), 'width' => 15,'prefix' => '<b>', 'suffix' => '</b>', 'align' => 'center', 'filter_key' => 'c!id_customer'), //'id_gender' => array('title' => $this->l('Titles'), 'align' => 'center', 'width' => 50,'icon' => $genders_icon, 'list' => $genders), 'firstname' => array('title' => $this->l('First name'), 'align' => 'left'), 'lastname' => array('title' => $this->l('Last name'), 'align' => 'left'), 'email' => array('title' => $this->l('Email address'), 'width' => 150, 'align' => 'left', 'filter_key' => 'c!email', 'orderby' => true), //'birthday' => array('title' => $this->l('Birth date'), 'width' => 150, 'align' => 'right', 'type' => 'date'), 'nb' => array('title' => $this->l('Orders'), 'width' => 100,), 'wartosc' => array('title' => $this->l('Wartość'), 'width' => 150,), 'date_add' => array('title' => $this->l('Register date'), 'width' => 150, 'align' => 'right', 'type' => 'date'), 'active' => array('title' => $this->l('Enabled'),'align' => 'center','width' => 20, 'active' => 'status','type' => 'bool') )); $this->_select = 'c.*, co.*, SUM( co.`total_paid_real`) AS wartosc, COUNT( co.`id_customer`) AS nb '; $this->_join = ' LEFT JOIN `'._DB_PREFIX_.'customer` c ON (a.`id_customer` = c.`id_customer`) LEFT JOIN `'._DB_PREFIX_.'orders` co ON (co.`id_customer` = c.`id_customer`) '; $this->_where = 'AND a.`id_group` = '.(int)$group->id.' AND c.`deleted` != 1'; $this->_group = 'GROUP BY co.`id_customer`'; self::$currentIndex = self::$currentIndex.'&viewgroup'; $this->addRowAction('test'); $this->processFilter(); return parent::renderList(); } I have made function displayTestLink but i cant get $id_customer value to made it works public function displayTestLink($token = null, $id, $id_customer, $name = null) { $tpl = $this->createTemplate('helpers/list/list_action_edit.tpl'); if (!array_key_exists('Test', self::$cache_lang)) self::$cache_lang['Test'] = $this->l('Test', 'Helper'); $tpl->assign(array( 'href' => 'index.php?controller=AdminCustomers&id_customer='.$id_customer.'&updatecustomer&token='.($token != null ? $token : $this->token), 'action' => self::$cache_lang['Test'], 'id' => $id, 'idc' => $idc )); return $tpl->fetch(); } please help me
  6. Thank you very much !!! It helps me with my popcart error
  7. A ja mam 2 błędy: Notice: Undefined property: CashOnDeliveryplus::$_postErrors in C:\xampp\htdocs\modules\cashondeliveryplus\cashondeliveryplus.php on line 114 Notice: Use of undefined constant PS_LANG_DEFAULT - assumed 'PS_LANG_DEFAULT' in C:\xampp\htdocs\modules\cashondeliveryplus\cashondeliveryplus.php on line 858
×
×
  • Create New...