EAV商品表直接取某一字段值

来源:互联网 发布:软件测试基本过程 编辑:程序博客网 时间:2024/05/01 21:18

Magento备忘-EAV商品表直接取某一字段值

比通过模型LOAD商品模型后再用getData取值快

G::getResourceModel('catalog/product')->getAttributeRawValue($entityId, $attribute, $store)

getAttributeRawValue函数参考

    /**
* Retrieve attribute's raw value from DB.
*
* @param int $entityId
* @param int|string|array $attribute atrribute's ids or codes
* @param int|G_Core_Model_Store $store
* @return bool|string|array
*/

public function getAttributeRawValue($entityId, $attribute, $store)
原创粉丝点击