Timeline for Is it possible to define the SKU only to be unique on website level (not globally)
Current License: CC BY-SA 3.0
5 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Aug 27, 2013 at 13:00 | comment | added | Alex | A comment: Having the "real SKU" in two places (as part of SKU and also in the custom_SKU field, would need us to keep both in sync - if the SKU changes - which it might never do) | |
Aug 27, 2013 at 11:06 | comment | added | Sander Mangel | Forgot about that last one. Thanks for the code snippet! | |
Aug 27, 2013 at 11:05 | comment | added | Andreas von Studnitz |
You don't need to load the product object. You can either add the attribute to the loaded attributes via config.xml (not sure about that) or via observer, or you can quick load just the attribute value with $attributeValue = Mage::getModel('catalog/product')->getResource()->getAttributeRawValue($productId, $attributeCode, Mage::app()->getStoreId()); .
|
|
Aug 27, 2013 at 10:51 | comment | added | Sander Mangel | Nice solution, the only downside as far as I can see is that this custom attribute isn't available by default in the shoppingcart or the orders, invoices and shipments. This would require you to load the original product object every time you need it | |
Aug 27, 2013 at 10:47 | history | answered | Andreas von Studnitz | CC BY-SA 3.0 |