AAAAhome/academiac/www/administrator/components/com_csvi/models/templatetypes.php000060400000005573151453053520023763 0ustar00getDbo(); $query = $db->getQuery(true); // Select the required fields from the table. $query->select('*'); $query->from('#__csvi_template_types'); // Add the list ordering clause. $orderCol = $this->state->get('list.ordering'); $orderDirn = $this->state->get('list.direction'); $query->order($db->getEscaped($orderCol.' '.$orderDirn)); return $query; } /** * Load the template types for a given selection * * @copyright * @author RolandD * @todo * @see * @access public * @param $action the import or export option * @param $component the component * @return array of available template types * @since 3.5 */ public function loadTemplateTypes($action, $component) { $db = JFactory::getDbo(); $q = "SELECT t.template_type_name FROM `#__csvi_template_types` AS t WHERE t.template_type = ".$db->Quote($action)." AND t.component = ".$db->Quote($component); $db->setQuery($q); $types = $db->loadResultArray(); // Get translations $trans = array(); foreach ($types as $type) { $trans[$type] = JText::_('COM_CSVI_'.strtoupper($type)); } return $trans; } } ?>home/academiac/www/administrator/components/com_csvi/controllers/templatetypes.php000060400000001206151453150470025035 0ustar00