function _buildContentWhereArray() { $state = $this->getState(); $where = parent::_buildContentWhereArray(); if ($state->parent_id > 0) { $where[] = ' a.parent_id=' . $state->parent_id; } return $where; }
function _buildContentWhereArray() { $state = $this->getState(); $where = parent::_buildContentWhereArray(); if ($state->plugin_type != -1) { $where[] = ' a.plugin_type=' . $state->plugin_type; } return $where; }
function _buildContentWhereArray() { $state = $this->getState(); $where = parent::_buildContentWhereArray(); if ($state->category_id > 0) { $where[] = ' (a.category_id=-1 OR a.id IN (SELECT field_id FROM #__helpdeskpro_field_categories WHERE category_id=' . $state->category_id . '))'; } return $where; }
function _buildContentWhereArray() { $where = parent::_buildContentWhereArray(); $state = $this->getState(); if ($state->filter_country_id) { $where[] = ' a.country_id = ' . $state->filter_country_id; } return $where; }
function _buildContentWhereArray() { $where = parent::_buildContentWhereArray(); $where[] = 'a.is_profile = 1'; if ($this->getState('id')) { $where[] = ' a.plan_id = ' . (int) $this->state->get('id'); } $where[] = ' a.id IN (SELECT DISTINCT profile_id FROM #__osmembership_subscribers WHERE published = 1)'; return $where; }
function _buildContentWhereArray() { $state = $this->getState(); $where = parent::_buildContentWhereArray(); if ($state->from_plan_id) { $where[] = ' a.from_plan_id = ' . $state->from_plan_id; } if ($state->to_plan_id) { $where[] = ' a.to_plan_id = ' . $state->to_plan_id; } return $where; }
function getData() { if (empty($this->_data)) { $db = JFactory::getDbo(); $rows = parent::getData(); for ($i = 0, $n = count($rows); $i < $n; $i++) { $row = $rows[$i]; $row->plans = OSMembershipHelper::getSubscriptions($row->id); } $this->_data = $rows; } return $this->_data; }
function _buildContentWhereArray() { $state = $this->getState(); $where = parent::_buildContentWhereArray(); if ($state->plan_id > 0) { $where[] = ' a.plan_id=' . $state->plan_id; } if ($state->country) { $where[] = ' a.country=' . $this->getDbo()->quote($state->country); } if ($state->vies != -1) { $where[] = ' a.vies=' . $state->vies; } return $where; }
function _buildContentWhereArray() { $app = JFactory::getApplication(); $user = JFactory::getUser(); $config = HelpdeskProHelper::getConfig(); $managedCategoryIds = HelpdeskProHelper::getTicketCategoryIds($user->get('username')); $where = parent::_buildContentWhereArray(); $state = $this->getState(); if ($state->category_id) { $where[] = ' a.category_id = ' . $state->category_id; } if ($state->status_id) { if ($state->status_id == -1) { if (!$user->authorise('core.admin')) { if (count($managedCategoryIds)) { //Show open and pending tickets to managers by default $where[] = ' (a.status_id=' . $config->new_ticket_status_id . ' OR a.status_id=' . $config->ticket_status_when_customer_add_comment . ') '; } else { //Show open tickets and require feedback tickets to customers //$where[] = ' (a.status_id='.$config->new_ticket_status_id.' OR a.status_id='.$config->ticket_status_when_admin_add_comment.') '; $where[] = " a.status_id != {$config->closed_ticket_status} "; } } else { //Show open and pending tickets to managers by default $where[] = ' (a.status_id=' . $config->new_ticket_status_id . ' OR a.status_id=' . $config->ticket_status_when_customer_add_comment . ') '; } } else { $where[] = ' a.status_id = ' . $state->status_id; } } if ($state->priority_id) { $where[] = ' a.priority_id = ' . $state->priority_id; } if (!$user->authorise('core.admin')) { //Super administrator can view all tickets if ($managedCategoryIds) { //He is ticket managers, so all tickets belong to him $where[] = ' a.category_id IN (' . implode(',', $managedCategoryIds) . ')'; } else { //Registered user, only show tickets submitted by himself $userId = $user->get('id'); $email = $user->get('email'); // $where[] = "(a.user_id=$userId OR a.email='$email') " ; $where[] = ' a.status_id = 4'; } } return $where; }
function _buildContentWhereArray() { $where = parent::_buildContentWhereArray(); $state = $this->getState(); if ($state->plan_id) { $where[] = ' a.plan_id = ' . $state->plan_id; } if ($state->published != -1) { $where[] = ' a.published = ' . $state->published; } switch ($state->subscription_type) { case 1: $where[] = ' a.act = "subscribe"'; break; case 2: $where[] = ' a.act = "renew"'; break; case 3: $where[] = ' a.act = "upgrade"'; break; } return $where; }
function __construct($config) { $config['state_vars'] = array('filter_order' => array('a.name', 'string', 1)); $config['search_fields'] = array('a.name'); parent::__construct($config); }
function __construct($config) { $config['search_fields'] = array('a.name', 'a.title'); $config['state_vars'] = array('show_core_field' => array(0, 'int', true), 'plan_id' => array(0, 'int', true)); parent::__construct($config); }
function __construct($config) { $config['main_table'] = '#__osmembership_subscribers'; parent::__construct($config); }
function __construct($config) { $config['state_vars'] = array('filter_order' => array('a.title', 'string', 1)); parent::__construct($config); }
function __construct() { parent::__construct(); }