shop_system.php

Go to the documentation of this file.
00001 <?php
00002 
00008 class Shop_System extends Shop_Config
00009 {
00010 
00016     protected $_sThisTemplate = 'shop_system.tpl';
00017 
00024     public function render()
00025     {
00026         $myConfig = $this->getConfig();
00027         parent::render();
00028 
00029         $aConfArrs = array();
00030 
00031         $oLang = oxRegistry::getLang();
00032 
00033         $aLanguages = $oLang->getLanguageArray();
00034         $sLangAbbr = $aLanguages[$oLang->getObjectTplLanguage()]->abbr;
00035 
00036         // loading shop location countries list (defines in which country shop exists)
00037         include "shop_countries.php";
00038 
00039         $soxId = $this->getEditObjectId();
00040         if (!$soxId) {
00041             $soxId = $myConfig->getShopId();
00042         }
00043 
00044         $oDb = oxDb::getDb();
00045         $sShopCountry = $oDb->getOne("select DECODE( oxvarvalue, " . $oDb->quote($myConfig->getConfigParam('sConfigKey')) . ") as oxvarvalue from oxconfig where oxshopid = '$soxId' and oxvarname = 'sShopCountry'", false, false);
00046 
00047         $this->_aViewData["shop_countries"] = $aLocationCountries[$sLangAbbr];
00048         $this->_aViewData["confstrs"]["sShopCountry"] = $sShopCountry;
00049 
00050         return $this->_sThisTemplate;
00051     }
00052 }