function display($tpl = null) { if (!class_exists('VmConfig')) { require JPATH_ADMINISTRATOR . DS . 'components' . DS . 'com_virtuemart' . DS . 'helpers' . DS . 'config.php'; } VmConfig::loadConfig(true); if (file_exists(JPATH_SITE . DS . 'components' . DS . 'com_onepage' . DS . 'config' . DS . 'onepage.cfg.php')) { include JPATH_SITE . DS . 'components' . DS . 'com_onepage' . DS . 'config' . DS . 'onepage.cfg.php'; } require_once JPATH_ADMINISTRATOR . DS . 'components' . DS . 'com_onepage' . DS . 'models' . DS . 'config.php'; $model = new JModelConfig(); //$limit = JRequest::getVar('limit', $mainframe->getCfg('list_limit')); //limitstart = JRequest::getVar('limitstart', 0); /* if (!file_exists(JPATH_ADMINISTRATOR.DS.'components'.DS.'com_virtuemart'.DS.'classes'.DS.'ps_onepage.php')) { $model->install(true); } */ $model->loadVmConfig('config'); require_once JPATH_COMPONENT . DS . 'assets' . DS . 'export_helper.php'; $this->ehelper = new OnepageTemplateHelper(); $this->opcexts = $model->getOPCExtensions(); $countries = $model->getShippingCountries(); $pms = $model->getPaymentMethods(); $sty = $model->getClassNames(); $default_country = $model->getDefaultC(); $dis = $model->getDisabledOPC(); $this->assignRef('disable_onepage', $dis); $model->checkLangFiles(); $trackingfiles = $model->getPhpTrackingThemes(); $this->assignRef('trackingfiles', $trackingfiles); $model->getExtLangVars(); $langs = $model->getLanguages(); $css = $model->retCss(); $php = $model->retPhp(); $sids = $model->getShippingRates(); if (empty($sids)) { $sids = array(); } $coref = array(); $ulist = $model->getUserFieldsLists($coref); $this->assignRef('clist', $coref); $this->assignRef('ulist', $ulist); $langse = array(); $exts = array(); $lext = $model->listExts($exts, $langse); $adminxts = array(); $langse2 = array(); $lext2 = $model->listExtsaAdmin($adminxts, $langse2); $this->assignRef('exts', $exts); $this->assignRef('adminxts', $adminxts); $this->assignRef('extlangs', $langse); $langerr = $model->getlangerr(); $this->assignRef('langerr', $langerr); //$lang_vars = $model->getLangVars(); $templates = $model->getTemplates(); $errors = $model->getErrMsgs(); $statuses = $model->getOrderStatuses(); $codes = $model->getJLanguages(); $exthtml = $model->getExtensions(); $groups = $model->listShopperGroups(); $vatgroups = $model->listShopperGroupsSelect(); $lfields = $model->listUserfields(); //function getArticleSelector($name, $value, $required=false) require_once JPATH_SITE . DS . 'components' . DS . 'com_onepage' . DS . 'helpers' . DS . 'config.php'; $this->lang_thank_youpage = OPCconfig::getValue('ty_page', 'ty_page', 0, array(0 => '')); $this->model =& $model; $this->assignRef('groups', $groups); $this->assignRef('vatgroups', $vatgroups); $this->assignRef('lfields', $lfields); $this->assignRef('exthtml', $exthtml); $this->assignRef('codes', $codes); $this->assignRef('statuses', $statuses); $this->assignRef('errors', $errors); $this->assignRef('templates', $templates); //$this->assignRef('lang_vars', $lang_vars); if (empty($pms)) { $pms = array(); } $this->assignRef('pms', $pms); $this->assignRef('sty', $sty); $this->assignRef('countries', $countries); $this->assignRef('default_country', $default_country); $this->assignRef('langs', $langs); // ok $this->assignRef('css', $css); $this->assignRef('php', $php); $this->assignRef('sids', $sids); $model2 = $this->getModel(); $model2->checkTable(); // $currencies = $model->getAllCurrency($limitstart, $limit); // $total = $model->countRows(); jimport('joomla.html.pagination'); //$pageNav = new JPagination($total, $limitstart, $limit); //$this->assignRef('currencies', $currencies); //$this->assignRef('pageNav', $pageNav); parent::display($tpl); }