0
如何将Mage_Core_Model_Store_Group对象的属性获取到数组中?我需要将_storeIds和_storeCodes分别放入数组中。从后端获取Magento Mage_Core_Model_Store_Group到前端数组
$theobjectthathasdataiwant = Mage::getSingleton('adminhtml/system_store')->getGroupCollection();
var_dump($theobjectthathasdataiwant);
结果:
object(Mage_Core_Model_Store_Group)[129]
protected '_cacheTag' => boolean true
protected '_eventPrefix' => string 'store_group' (length=11)
protected '_eventObject' => string 'store_group' (length=11)
protected '_stores' =>
array (size=3)
7 =>
.....
protected '_storeIds' =>
array (size=3)
7 => string '7' (length=1)
4 => string '4' (length=1)
5 => string '5' (length=1)
protected '_storeCodes' =>
array (size=3)
7 => string 'rg' (length=2)
4 => string 'xray' (length=4)
5 => string 'zoe' (length=3)
protected '_storesCount' => int 3
预先感谢您!