View Issue Details

IDProjectCategoryView StatusLast Update
0004538OXID ERP InterfaceOXID ERP Interface - subpublic2012-12-10 14:19
Reportere.kuzminov Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2.9.0_35501 
Summary0004538: In ERP calls getShopConfVar always select config params from Supershop but not from Subshop
DescriptionIt looks like oxconfig::_loadVarsFromDb (in in config "init")
is being called before oxERPBase::loadSessionData

but actual shopid for ERP authorized user is stored in session, that's why in oxconfig::_loadVarsFromDb shopid is considedred as default "1" and config params for supershops are written to params cache variable $this->_aThemeConfigParams.

And then if you try to access shop params in ERP plugin for example
$paramsFromConfigArray = $myConfig->getShopConfVar('aMconfig', $shopID);

it will always give you pre-cached shop param nevertheless you set $shopID as "1" or "2".
Additional InformationAs understand it affects ERP module only as there is no any cookies to get shopid on first getShopID function call and session is initiated only when function execution is started.

The way to overcome this is to add "shp" param to SOAP request url
for example
http://SHOP.com/modules/erp/oxerpservice.php?wsdl=&version=2.9.0&shp=2

but then ShopID param in OXERPLogin is useless and it should be somehow specified in documentation.
TagsNo tags attached.

Relationships

related to 0004722 resolvedSvenBrunk OXID eShop (all versions) Shop config is not reloaded on shop id change 

Activities

e.kuzminov

2012-09-20 19:58

reporter   ~0007466

EDIT :
not to "$this->_aThemeConfigParams", but to "$this->__aConfigParams"

arturas.sevcenko

2012-11-29 10:42

reporter   ~0008025

now plugin selects configs from shop which is specified in OXERPLogin