Ver Fonte

Ticket #285 - remove old code.

AntonLV há 10 anos atrás
pai
commit
08d4250716

+ 0 - 38
modules/boonex/membership_pricing/classes/BxDolStudioPermissionsPrices.php

@@ -1,38 +0,0 @@
-<?php
-/**
- * Copyright (c) BoonEx Pty Limited - http://www.boonex.com/
- * CC-BY License - http://creativecommons.org/licenses/by/3.0/
- *
- * @defgroup    TridentStudio Trident Studio
- * @{
- */
-defined('BX_DOL') or die('hack attempt');
-
-bx_import('BxTemplStudioGrid');
-bx_import('BxDolStudioTemplate');
-bx_import('BxDolStudioPermissionsQuery');
-
-class BxDolStudioPermissionsPrices extends BxTemplStudioGrid
-{
-    protected $iLevel = 0;
-
-    public function __construct ($aOptions, $oTemplate = false)
-    {
-        parent::__construct ($aOptions, $oTemplate);
-
-        $this->oDb = new BxDolStudioPermissionsQuery();
-
-        $iLevel = (int)bx_get('level');
-        if($iLevel > 0)
-            $this->iLevel = $iLevel;
-
-        $this->_aQueryAppend['level'] = $this->iLevel;
-    }
-
-    protected function _getDataSql($sFilter, $sOrderField, $sOrderDir, $iStart, $iPerPage)
-    {
-        $this->_aOptions['source'] .= $this->oDb->prepare("AND `IDLEvel`=? ", $this->iLevel);
-        return parent::_getDataSql($sFilter, $sOrderField, $sOrderDir, $iStart, $iPerPage);;
-    }
-}
-/** @} */

+ 0 - 90
modules/boonex/membership_pricing/classes/BxDolStudioPermissionsQuery.php

@@ -1,90 +0,0 @@
-<?php
-/**
- * Copyright (c) BoonEx Pty Limited - http://www.boonex.com/
- * CC-BY License - http://creativecommons.org/licenses/by/3.0/
- *
- * @defgroup    TridentStudio Trident Studio
- * @{
- */
-defined('BX_DOL') or die('hack attempt');
-
-bx_import('BxDolAclQuery');
-
-class BxDolStudioPermissionsQuery extends BxDolAclQuery
-{
-    function __construct()
-    {
-        parent::__construct();
-    }
-
-    function getPrices($aParams, &$aItems, $bReturnCount = true)
-    {
-        $aMethod = array('name' => 'getAll', 'params' => array(0 => 'query'));
-        $sSelectClause = $sJoinClause = $sWhereClause = $sOrderClause = $sLimitClause = "";
-
-        if(!isset($aParams['order']) || empty($aParams['order']))
-           $sOrderClause = "ORDER BY `tap`.`Order` ASC";
-
-        switch($aParams['type']) {
-            case 'by_id':
-                $aMethod['name'] = 'getRow';
-                $sWhereClause .= $this->prepare("AND `tap`.`id`=?", $aParams['value']);
-                break;
-            case 'by_level_id':
-                $sWhereClause .= $this->prepare("AND `tap`.`IDLevel`=?", $aParams['value']);
-                break;
-            case 'by_level_id_pair':
-                $aMethod['name'] = "getPairs";
-                $aMethod['params'][1] = 'days';
-                $aMethod['params'][2] = 'price';
-                $sWhereClause .= $this->prepare("AND `tap`.`IDLevel`=?", $aParams['value']);
-                break;
-            case 'by_level_id_duration':
-                $aMethod['name'] = 'getRow';
-                $sWhereClause .= $this->prepare("AND `tap`.`IDLevel`=? AND `tap`.`Days`=?", $aParams['level_id'], $aParams['days']);
-                break;
-            case 'counter_by_levels':
-                $aMethod['name'] = 'getPairs';
-                $aMethod['params'][1] = 'level_id';
-                $aMethod['params'][2] = 'counter';
-                $sSelectClause = ", COUNT(*) AS `counter`";
-                $sGroupClause = "GROUP BY `tap`.`IDLevel`";
-                break;
-        }
-
-        $aMethod['params'][0] = "SELECT " . ($bReturnCount ? "SQL_CALC_FOUND_ROWS" : "") . "
-                `tap`.`id` AS `id`,
-                `tap`.`IDLevel` AS `level_id`,
-                `tap`.`Days` AS `days`,
-                `tap`.`Price` AS `price`,
-                `tap`.`Order` AS `order`" . $sSelectClause . "
-            FROM `sys_acl_level_prices` AS `tap` " . $sJoinClause . "
-            WHERE 1 " . $sWhereClause . " " . $sOrderClause . " " . $sLimitClause;
-        $aItems = call_user_func_array(array($this, $aMethod['name']), $aMethod['params']);
-
-        if(!$bReturnCount)
-            return !empty($aItems);
-
-        return (int)$this->getOne("SELECT FOUND_ROWS()");
-    }
-
-    function getPriceOrderMax($iLevelId)
-    {
-        $sSql = $this->prepare("SELECT MAX(`Order`) FROM `sys_acl_level_prices` WHERE `IDLevel`=?", $iLevelId);
-        return (int)$this->getOne($sSql);
-    }
-
-    function deletePrices($aParams)
-    {
-        $sWhereClause = "";
-
-        switch($aParams['type']) {
-            case 'by_level_id':
-                $sWhereClause .= $this->prepare("AND `IDLevel`=?", $aParams['value']);
-                break;
-        }
-
-        return (int)$this->query("DELETE FROM `sys_acl_level_prices` WHERE 1 " . $sWhereClause) > 0;
-    }
-}
-/** @} */

+ 0 - 50
modules/boonex/membership_pricing/classes/cron.php

@@ -1,50 +0,0 @@
-<?php
-
-        //========================================================================================================================
-
-        // - Membership check -
-        echo "\n- Membership expiration letters -\n";
-
-        $iExpireNotificationDays = (int)getParam("expire_notification_days");
-        $bExpireNotifyOnce = getParam("expire_notify_once") == 'on';
-
-        $iExpireLetters = 0;
-
-        bx_import('BxDolDb');
-        $oDb = BxDolDb::getInstance();
-
-        bx_import('BxDolAcl');
-        $oAcl = BxDolAcl::getInstance();
-
-        $aRow = $oDb->getFirstRow( "SELECT `ID` FROM `Profiles`");
-        while(!empty($aRow)) {
-            $aCurrentMem = getMemberMembershipInfo( $aRow['ID'] );
-            // If expire_notification_days is -1 then notify after expiration
-            if ( $aCurrentMem['ID'] == MEMBERSHIP_ID_STANDARD && $iExpireNotificationDays == -1 ) {
-                // Calculate last UNIX Timestamp
-                $iLastTimestamp = time() - 24 * 3600;
-                $aLastMem = getMemberMembershipInfo( $aRow['ID'], $iLastTimestamp );
-                if($aCurrentMem['ID'] != $aLastMem['ID']) {
-                    $bMailResult = $oAcl->getExpirationLetter($aRow['ID'], $aLastMem['Name'], -1);
-                    if($bMailResult)
-                        $iExpireLetters++;
-                }
-            }
-            // If memberhip is not standard then check if it will change
-            else if($aCurrentMem['ID'] != MEMBERSHIP_ID_STANDARD) {
-                // Calculate further UNIX Timestamp
-                $iFurtherTimestamp = time() + $iExpireNotificationDays * 24 * 3600;
-                $aFurtherMem = getMemberMembershipInfo( $aRow['ID'], $iFurtherTimestamp );
-                if($aCurrentMem['ID'] != $aFurtherMem['ID'] && $aFurtherMem['ID'] == MEMBERSHIP_ID_STANDARD) {
-                    if(!$bExpireNotifyOnce || abs($iFurtherTimestamp - $aCurrentMem['DateExpires']) < 24 * 3600) {
-                        $bMailResult = $oAcl->getExpirationLetter( $aRow['ID'], $aCurrentMem['Name'], (int)(($aCurrentMem['DateExpires'] - time())/(24 * 3600)));
-                        if($bMailResult)
-                            $iExpireLetters++;
-                    }
-                }
-            }
-
-            $aRow = $oDb->getNextRow();
-        }
-
-        echo "Send membership expire letters: $iExpireLetters letters\n";

+ 0 - 37
modules/boonex/membership_pricing/install/sql/install.sql

@@ -1,37 +0,0 @@
-
---
--- CATEGORY: Memberships
---
-INSERT INTO `sys_options_categories`(`type_id`, `name`, `caption`, `hidden`, `order`) VALUES (@iTypeId, 'memberships', '_adm_stg_cpt_category_memberships', 0, 8);
-SET @iCategoryId = LAST_INSERT_ID();
-
-INSERT INTO `sys_options`(`category_id`, `name`, `caption`, `value`, `type`, `extra`, `check`, `check_error`, `order`) VALUES
-(@iCategoryId, 'expire_notification_days', '_adm_stg_cpt_option_expire_notification_days', '1', 'digit', '', '', '', 1),
-(@iCategoryId, 'expire_notify_once', '_adm_stg_cpt_option_expire_notify_once', 'on', 'checkbox', '', '', '', 2),
-(@iCategoryId, 'db_clean_mem_levels', '_adm_stg_cpt_option_db_clean_mem_levels', '30', 'digit', '', '', '', 3);
-
-
-CREATE TABLE `sys_acl_level_prices` (
-  `id` int(11) NOT NULL auto_increment,
-  `IDLevel` int(10) unsigned NOT NULL DEFAULT '0',
-  `Days` int(10) unsigned NOT NULL default '1',
-  `Price` float unsigned NOT NULL default '1',
-  `Order` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `type` (`IDLevel`,`Days`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8;
-
-INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `override_class_name`, `override_class_file`) VALUES
-('sys_studio_acl_prices', 'Sql', 'SELECT * FROM `sys_acl_level_prices` WHERE 1 ', 'sys_acl_level_prices', 'id', 'Order', '', '', 100, NULL, 'start', '', 'Days,Price', '', 'like', '', '', 'BxTemplStudioPermissionsPrices', '');
-
-INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
-('sys_studio_acl_prices', 'Order', '', '1%', 0, '', '', 1),
-('sys_studio_acl_prices', 'Days', '_adm_prm_txt_term', '40%', 0, '', '', 2),
-('sys_studio_acl_prices', 'Price', '_adm_prm_txt_price', '40%', 0, '', '', 3),
-('sys_studio_acl_prices', 'actions', '', '19%', 0, '', '', 4);
-
-INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `confirm`, `order`) VALUES
-('sys_studio_acl_prices', 'independent', 'add', '_adm_prm_btn_add_price', '', 0, 1),
-('sys_studio_acl_prices', 'single', 'edit', '', 'pencil', 0, 1),
-('sys_studio_acl_prices', 'single', 'delete', '', 'remove', 1, 2);
-

+ 0 - 13
modules/boonex/membership_pricing/install/sql/uninstall.sql

@@ -1,13 +0,0 @@
-
-
-SET @iCategoryId = (SELECT `id` FROM `sys_options_categories` WHERE `name` = 'memberships');
-DELETE FROM `sys_options_categories` WHERE `id` = @iCategoryId;
-DELETE FROM `sys_options` WHERE `category_id` = @iCategoryId;
-
-
-DROP TABLE IF EXISTS `sys_acl_level_prices`;
-
-DELETE FROM `sys_objects_grid` WHERE `object`='sys_studio_acl_prices';
-DELETE FROM `sys_grid_fields` WHERE `object`='sys_studio_acl_prices';
-DELETE FROM `sys_grid_actions` WHERE `object`='sys_studio_acl_prices';
-

+ 0 - 371
modules/boonex/membership_pricing/template/scripts/BxBaseStudioPermissionsPrices.php

@@ -1,371 +0,0 @@
-<?php
-/**
- * Copyright (c) BoonEx Pty Limited - http://www.boonex.com/
- * CC-BY License - http://creativecommons.org/licenses/by/3.0/
- *
- * @defgroup    TridentView Trident Studio Representation classes
- * @ingroup     TridentStudio
- * @{
- */
-defined('BX_DOL') or die('hack attempt');
-
-bx_import('BxDolStudioPermissionsPrices');
-bx_import('BxTemplStudioFormView');
-
-class BxBaseStudioPermissionsPrices extends BxDolStudioPermissionsPrices
-{
-    function __construct($aOptions, $oTemplate = false)
-    {
-        parent::__construct($aOptions, $oTemplate);
-
-        $this->_aOptions['actions_single']['edit']['attr']['title'] = _t('_adm_prm_btn_price_edit');
-        $this->_aOptions['actions_single']['delete']['attr']['title'] = _t('_adm_prm_btn_price_delete');
-    }
-
-    public function performActionAdd()
-    {
-        $sAction = 'add';
-
-        $sFilter = bx_get('filter');
-        if(strpos($sFilter, $this->sParamsDivider) !== false)
-            list($this->iLevel, $sFilter) = explode($this->sParamsDivider, $sFilter);
-
-        if((int)$this->iLevel == 0)
-            $this->iLevel = (int)bx_get('IDLevel');
-
-        $aForm = array(
-            'form_attrs' => array(
-                'id' => 'adm-prm-price-add',
-                'action' => BX_DOL_URL_ROOT . 'grid.php?o=' . $this->_sObject . '&a=' . $sAction,
-                'method' => BX_DOL_STUDIO_METHOD_DEFAULT
-            ),
-            'params' => array (
-                'db' => array(
-                    'table' => 'sys_acl_level_prices',
-                    'key' => 'id',
-                    'uri' => '',
-                    'uri_title' => '',
-                    'submit_name' => 'do_submit'
-                ),
-            ),
-            'inputs' => array (
-                'IDLevel' => array(
-                    'type' => 'hidden',
-                    'name' => 'IDLevel',
-                    'value' => $this->iLevel,
-                    'db' => array (
-                        'pass' => 'Int',
-                    ),
-                ),
-                'Days' => array(
-                    'type' => 'text',
-                    'name' => 'Days',
-                    'caption' => _t('_adm_prm_txt_price_add_days'),
-                    'info' => _t('_adm_prm_dsc_price_add_days'),
-                    'value' => '',
-                    'db' => array (
-                        'pass' => 'Int',
-                    ),
-                ),
-                'Price' => array(
-                    'type' => 'text',
-                    'name' => 'Price',
-                    'caption' => _t('_adm_prm_txt_price_add_price'),
-                    'info' => '',
-                    'value' => '',
-                    'db' => array (
-                        'pass' => 'Float',
-                    ),
-                ),
-                'controls' => array(
-                    'name' => 'controls',
-                    'type' => 'input_set',
-                    array(
-                        'type' => 'submit',
-                        'name' => 'do_submit',
-                        'value' => _t('_adm_prm_btn_price_add'),
-                    ),
-                    array (
-                        'type' => 'reset',
-                        'name' => 'close',
-                        'value' => _t('_adm_prm_btn_price_cancel'),
-                        'attrs' => array(
-                            'onclick' => "$('.bx-popup-applied:visible').dolPopupHide()",
-                            'class' => 'bx-def-margin-sec-left',
-                        ),
-                    )
-                )
-            )
-        );
-
-        $oForm = new BxTemplStudioFormView($aForm);
-        $oForm->initChecker();
-
-        if($oForm->isSubmittedAndValid()) {
-            $aPrice = array();
-            $iPrice = $this->oDb->getPrices(array('type' => 'by_level_id_duration', 'level_id' => $oForm->getCleanValue('IDLevel'), 'days' => $oForm->getCleanValue('Days')), $aPrice);
-            if($iPrice != 0) {
-                echoJson(array('msg' => _t('_adm_prm_err_price_duplicate')));
-                return;
-            }
-
-            $iId = (int)$oForm->insert(array('Order' => $this->oDb->getPriceOrderMax($this->iLevel) + 1));
-            if($iId != 0) {
-                $this->oDb->updateLevels($this->iLevel, array('Purchasable' => 'yes'));
-                $aRes = array('grid' => $this->getCode(false), 'blink' => $iId);
-            } else
-                $aRes = array('msg' => _t('_adm_prm_err_price_create'));
-
-            echoJson($aRes);
-        } else {
-            bx_import('BxTemplStudioFunctions');
-            $sContent = BxTemplStudioFunctions::getInstance()->popupBox('adm-prm-price-add-popup', _t('_adm_prm_txt_price_add_popup'), $this->_oTemplate->parseHtmlByName('prm_add_price.html', array(
-                'form_id' => $aForm['form_attrs']['id'],
-                'form' => $oForm->getCode(true),
-                'object' => $this->_sObject,
-                'action' => $sAction
-            )));
-
-            echoJson(array('popup' => array('html' => $sContent, 'options' => array('closeOnOuterClick' => false))));
-        }
-    }
-
-    public function performActionEdit()
-    {
-        $sAction = 'edit';
-
-        $aIds = bx_get('ids');
-        if(!$aIds || !is_array($aIds)) {
-            $iId = (int)bx_get('id');
-            if(!$iId) {
-                echoJson(array());
-                exit;
-            }
-
-            $aIds = array($iId);
-        }
-
-        $iId = $aIds[0];
-
-        $aPrice = array();
-        $iPrice = $this->oDb->getPrices(array('type' => 'by_id', 'value' => $iId), $aPrice);
-        if($iPrice != 1 || empty($aPrice)) {
-            echoJson(array());
-            exit;
-        }
-
-        if((int)$this->iLevel == 0)
-            $this->iLevel = (int)$aPrice['level_id'];
-
-        $aForm = array(
-            'form_attrs' => array(
-                'id' => 'adm-prm-price-edit',
-                'action' => BX_DOL_URL_ROOT . 'grid.php?o=' . $this->_sObject . '&a=' . $sAction,
-                'method' => BX_DOL_STUDIO_METHOD_DEFAULT
-            ),
-            'params' => array (
-                'db' => array(
-                    'table' => 'sys_acl_level_prices',
-                    'key' => 'id',
-                    'uri' => '',
-                    'uri_title' => '',
-                    'submit_name' => 'do_submit'
-                ),
-            ),
-            'inputs' => array (
-                'id' => array(
-                    'type' => 'hidden',
-                    'name' => 'id',
-                    'value' => $iId,
-                    'db' => array (
-                        'pass' => 'Int',
-                    ),
-                ),
-                'IDLevel' => array(
-                    'type' => 'hidden',
-                    'name' => 'IDLevel',
-                    'value' => $aPrice['level_id'],
-                    'db' => array (
-                        'pass' => 'Int',
-                    ),
-                ),
-                'Days' => array(
-                    'type' => 'text',
-                    'name' => 'Days',
-                    'caption' => _t('_adm_prm_txt_price_add_days'),
-                    'info' => _t('_adm_prm_dsc_price_add_days'),
-                    'value' => $aPrice['days'],
-                    'db' => array (
-                        'pass' => 'Int',
-                    ),
-                ),
-                'Price' => array(
-                    'type' => 'text',
-                    'name' => 'Price',
-                    'caption' => _t('_adm_prm_txt_price_add_price'),
-                    'info' => '',
-                    'value' => round($aPrice['price'], 2),
-                    'db' => array (
-                        'pass' => 'Float',
-                    ),
-                ),
-                'controls' => array(
-                    'name' => 'controls',
-                    'type' => 'input_set',
-                    array(
-                        'type' => 'submit',
-                        'name' => 'do_submit',
-                        'value' => _t('_adm_prm_btn_price_save'),
-                    ),
-                    array (
-                        'type' => 'reset',
-                        'name' => 'close',
-                        'value' => _t('_adm_prm_btn_price_cancel'),
-                        'attrs' => array(
-                            'onclick' => "$('.bx-popup-applied:visible').dolPopupHide()",
-                            'class' => 'bx-def-margin-sec-left',
-                        ),
-                    )
-                )
-            )
-        );
-
-        $oForm = new BxTemplStudioFormView($aForm);
-        $oForm->initChecker();
-
-        if($oForm->isSubmittedAndValid()) {
-            $iId = $oForm->getCleanValue('id');
-
-            $aPrice = array();
-            $iPrice = $this->oDb->getPrices(array('type' => 'by_level_id_duration', 'level_id' => $oForm->getCleanValue('IDLevel'), 'days' => $oForm->getCleanValue('Days')), $aPrice);
-            if($iPrice != 0 && !empty($aPrice) && $aPrice['id'] != $iId) {
-                echoJson(array('msg' => _t('_adm_prm_err_price_duplicate')));
-                return;
-            }
-
-            if((int)$oForm->update($iId) > 0)
-                $aRes = array('grid' => $this->getCode(false), 'blink' => $iId);
-            else
-                $aRes = array('msg' => _t('_adm_prm_err_price_update'));
-
-            echoJson($aRes);
-        } else {
-            bx_import('BxTemplStudioFunctions');
-            $sContent = BxTemplStudioFunctions::getInstance()->popupBox('adm-prm-price-edit-popup', _t('_adm_prm_txt_price_edit_popup', $aPrice['days']), $this->_oTemplate->parseHtmlByName('prm_add_price.html', array(
-                'form_id' => $aForm['form_attrs']['id'],
-                'form' => $oForm->getCode(true),
-                'object' => $this->_sObject,
-                'action' => $sAction
-            )));
-
-            echoJson(array('popup' => array('html' => $sContent, 'options' => array('closeOnOuterClick' => false))));
-        }
-    }
-
-    function performActionDelete()
-    {
-        $aIds = bx_get('ids');
-        if (!$aIds || !is_array($aIds)) {
-            echoJson(array());
-            exit;
-        }
-
-        $aPrice = array();
-        $this->oDb->getPrices(array('type' => 'by_id', 'value' => $aIds[0]), $aPrice, false);
-
-        parent::performActionDelete();
-
-        $aPrices = array();
-        $iPrices = $this->oDb->getPrices(array('type' => 'by_level_id', 'value' => $aPrice['level_id']), $aPrices);
-        if($iPrices == 0)
-            $this->oDb->updateLevels($this->iLevel, array('Purchasable' => 'no'));
-    }
-
-    function getJsObject()
-    {
-        return 'oBxDolStudioPermissionsPrices';
-    }
-
-    function getCode($isDisplayHeader = true)
-    {
-        return $this->_oTemplate->parseHtmlByName('prm_prices.html', array(
-            'content' => parent::getCode($isDisplayHeader),
-            'js_object' => $this->getJsObject(),
-            'grid_object' => $this->_sObject,
-            'params_divider' => $this->sParamsDivider
-        ));
-    }
-
-    protected function _addJsCss()
-    {
-        parent::_addJsCss();
-        $this->_oTemplate->addJs(array('jquery.form.min.js', 'permissions_prices.js'));
-
-        bx_import('BxTemplStudioFormView');
-        $oForm = new BxTemplStudioFormView(array());
-        $oForm->addCssJs();
-    }
-    protected function _getCellPrice ($mixedValue, $sKey, $aField, $aRow)
-    {
-        return parent::_getCellDefault (_t_format_currency($mixedValue), $sKey, $aField, $aRow);
-    }
-
-    protected function _getCellDays ($mixedValue, $sKey, $aField, $aRow)
-    {
-        return parent::_getCellDefault (_t('_sys_x_days', $mixedValue), $sKey, $aField, $aRow);
-    }
-
-    protected function _getActionAdd($sType, $sKey, $a, $isSmall = false, $isDisabled = false, $aRow = array())
-    {
-        if($this->iLevel == 0)
-            $isDisabled = true;
-
-        return parent::_getActionDefault($sType, $sKey, $a, $isSmall, $isDisabled, $aRow);
-    }
-
-    protected function _getFilterControls ()
-    {
-        parent::_getFilterControls();
-
-        $sContent = "";
-
-        bx_import('BxTemplStudioFormView');
-        $oForm = new BxTemplStudioFormView(array());
-
-        $aInputLevels = array(
-            'type' => 'select',
-            'name' => 'level',
-            'attrs' => array(
-                'id' => 'bx-grid-level-' . $this->_sObject,
-                'onChange' => 'javascript:' . $this->getJsObject() . '.onChangeLevel()'
-            ),
-            'value' => 'id-' . $this->iLevel,
-            'values' => array()
-        );
-
-        $aLevels = $aCounter = array();
-        $this->oDb->getLevels(array('type' => 'all'), $aLevels, false);
-        $this->oDb->getPrices(array('type' => 'counter_by_levels'), $aCounter, false);
-        foreach($aLevels as $aLevel)
-            $aInputLevels['values']['id-' . $aLevel['id']] = _t($aLevel['name']) . " (" . (isset($aCounter[$aLevel['id']]) ? $aCounter[$aLevel['id']] : "0") . ")";
-
-        asort($aInputLevels['values']);
-        $aInputLevels['values'] = array_merge(array('id-0' => _t('_adm_prm_txt_select_level')), $aInputLevels['values']);
-
-        $sContent .= $oForm->genRow($aInputLevels);
-        if($this->iLevel == 0)
-            return $sContent;
-
-        $aInputSearch = array(
-            'type' => 'text',
-            'name' => 'keyword',
-            'attrs' => array(
-                'id' => 'bx-grid-search-' . $this->_sObject
-            )
-        );
-        $sContent .= $oForm->genRow($aInputSearch);
-
-        return $sContent;
-    }
-}
-/** @} */