Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Not an Issue
-
Affects Version/s: 0.9.2
-
Fix Version/s: Next Major Release
-
Component/s: Zend_Db_Table
-
Labels:None
-
Fix Version Priority:Should Have
Description
Zend Framework changelog says:
ZF-1214Support a hook for column name transformations in Zend_Db_Table_Row
Thats right, it supports a hook for own transformations, but it does not function because there is still a todo in code.
public function __construct(array $config = array()) { if (isset($config['table']) && $config['table'] instanceof Zend_Db_Table_Abstract) { $this->_table = $config['table']; $this->_tableClass = get_class($this->_table); } if (isset($config['data'])) { if (!is_array($config['data'])) { require_once 'Zend/Db/Table/Row/Exception.php'; throw new Zend_Db_Table_Row_Exception('Data must be an array'); } // @todo: use setFromArray(), which employs _transformColumn(). <--- TODO $this->_data = $config['data']; $this->_cleanData = $this->_data; } // Retrieve primary keys from table schema if ($table = $this->_getTable()) { $info = $this->_getTable()->info(); $this->_primary = (array) $info['primary']; } }
Because of this todo I cannot use my own column name transformation.
Oh sorry I forgot something
This constructor is from Zend_Db_Table_Row_Abstract.