Magento在保存时因缺少存储\u id而引发异常

Magento在保存时因缺少存储\u id而引发异常,magento,Magento,我遇到一个问题,在信用卡交易过程中,交易的保存操作导致抛出错误,抱怨未在保存的对象上设置store_id。有问题的代码位于Mage\u Eav\u Model\u Entity\u Abstract:\u collectSaveData$newObject中 if (array_key_exists($k, $origData)) { if ($this->_isAttributeValueEmpty($attribute, $v)) {

我遇到一个问题,在信用卡交易过程中,交易的保存操作导致抛出错误,抱怨未在保存的对象上设置store_id。有问题的代码位于Mage\u Eav\u Model\u Entity\u Abstract:\u collectSaveData$newObject中

 if (array_key_exists($k, $origData)) {
            if ($this->_isAttributeValueEmpty($attribute, $v)) {
                $delete[$attribute->getBackend()->getTable()][] = array(
                    'attribute_id'  => $attrId,
                    'value_id'      => $attribute->getBackend()->getValueId()
                );
            } else if ($v !== $origData[$k]) {
                $update[$attrId] = array(
                    'value_id' => $attribute->getBackend()->getValueId(),
                    'value'    => $v,
                );
            } else if ($v == $origData[$k] && $origData['store_id'] != $this->getDefaultStoreId()) {  <--- the exception origin
                $insert[$attrId] = $v;
            }
        } else if (!$this->_isAttributeValueEmpty($attribute, $v)) {
            $insert[$attrId] = $v;
        }
存储的对象类型为Mage\u Customer\u Model\u Address。问题很清楚,;地址模型没有定义存储区id。我的问题是a为什么不?或者b应该定义它?或者c这是一个bug


我用的是Magento ver。1.5.x-devel-90295

如果您使用的是alpha或beta版本,那么最好将其报告为bug。这也是我的问题的一部分。我不知道这是否是一个错误或是我在某种程度上搞砸了的预期行为。一个地址应该有一个store_id字段吗?为什么不在v1.4.2 stable上试用它,它会告诉你问题出在你的代码还是版本上不要使用测试版进行实时交易。。。更重要的是,永远不要开始创建基于测试版的网站,你不能依赖这些功能。