34 if ($soxId !=
"-1" && isset($soxId)) {
36 $oShop =
oxNew(
"oxshop");
38 if (!isset($isubjlang)) {
42 if ($isubjlang && $isubjlang > 0) {
43 $this->_aViewData[
"subjlang"] = $isubjlang;
46 $oShop->loadInLang($isubjlang, $soxId);
48 $this->_aViewData[
"edit"] = $oShop;
54 $this->_aViewData[
'IsOXDemoShop'] =
$myConfig->isDemoShop();
55 if (!isset($this->_aViewData[
'updatenav'])) {
59 return "shop_main.tpl";
79 $aParams[
'oxshops__oxactive'] = (isset($aParams[
'oxshops__oxactive']) && $aParams[
'oxshops__oxactive'] ==
true) ? 1 : 0;
80 $aParams[
'oxshops__oxproductive'] = (isset($aParams[
'oxshops__oxproductive']) && $aParams[
'oxshops__oxproductive'] ==
true) ? 1 : 0;
83 $iLang = ($isubjlang && $isubjlang > 0) ? $isubjlang : 0;
86 $oShop =
oxNew(
"oxshop");
88 $oShop->loadInLang($iLang, $soxId);
90 $aParams[
'oxshops__oxid'] = null;
93 if ($aParams[
'oxshops__oxsmtp']) {
94 $aParams[
'oxshops__oxsmtp'] = trim($aParams[
'oxshops__oxsmtp']);
97 $oShop->setLanguage(0);
98 $oShop->assign($aParams);
99 $oShop->setLanguage($iLang);
102 $oShop->oxshops__oxsmtppwd->setValue($sNewSMPTPass ==
'-' ?
"" : $sNewSMPTPass);
113 $this->_aViewData[
"updatelist"] =
"1";
126 $aNonCopyVars = array(
"aSerials",
"IMS",
"IMD",
"IMA",
"sBackTag",
"sUtilModule",
"aModulePaths",
"aModuleFiles",
"aModuleEvents",
"aModuleVersions",
"aModuleTemplates",
"aModules",
"aDisabledModules");
128 $aMultiShopTables = $this->
getConfig()->getConfigParam(
'aMultiShopTables');
129 foreach ($aMultiShopTables as $sMultishopTable) {
130 $aNonCopyVars[] =
'blMallInherit_' . strtolower($sMultishopTable);
133 return $aNonCopyVars;
149 $sSelect =
"select oxvarname, oxvartype, DECODE( oxvarvalue, " . $oDB->quote(
$myConfig->getConfigParam(
'sConfigKey')) .
") as oxvarvalue, oxmodule from oxconfig where oxshopid = '1'";
150 $rs = $oDB->execute($sSelect);
151 if ($rs !=
false && $rs->recordCount() > 0) {
153 $sVarName = $rs->fields[0];
154 if (!in_array($sVarName, $aNonCopyVars)) {
155 $sID = $myUtilsObject->generateUID();
156 $sInsert =
"insert into oxconfig (oxid, oxshopid, oxvarname, oxvartype, oxvarvalue, oxmodule) values ( '$sID', " . $oDB->quote($oShop->getId())
157 .
", " . $oDB->quote($rs->fields[0])
158 .
", " . $oDB->quote($rs->fields[1])
159 .
", ENCODE( " . $oDB->quote($rs->fields[2])
160 .
", '" .
$myConfig->getConfigParam(
'sConfigKey')
162 .
", " . $oDB->quote($rs->fields[3]) .
" )";
163 $oDB->execute($sInsert);
169 $sInheritAll = $oShop->oxshops__oxisinherited->value ?
"true" :
"false";
170 $aMultiShopTables =
$myConfig->getConfigParam(
'aMultiShopTables');
171 foreach ($aMultiShopTables as $sMultishopTable) {
172 $myConfig->saveShopConfVar(
"bool",
'blMallInherit_' . strtolower($sMultishopTable), $sInheritAll, $oShop->oxshops__oxid->value);