Closed
Description
Questions should go to https://forum.phalconphp.com
Documentation issues should go to https://github.com/phalcon/docs/issues
Expected and Actual Behavior
When generating models the dev tools builds it with the camelize option even if i didn't add the option, i got a field named ProducType and when i generate the model it outputs productType, making the findFirstBy and the get-set methods unable to work.
Provide output if related
/**
* field name is ProductType and it outputs like productType
* @var integer
* @Column(type="integer", length=11, nullable=false)
*/
protected $productType; // <---- here
/**
* Method to set the value of field productType
*
* @param integer $productType
* @return $this
*/
public function setProductType($productType)
{
$this->productType = $productType; // <---- here
return $this;
}
Provide minimal script to reproduce the issue
phalcon model --products --get-set --force --mapcolumn
Details
- System info and versions (if possible): (
phalcon info
) - Phalcon Framework version: 3.2.4
- PHP Version: 7.1
- Operating System: RHEL7
- Server: Apache
- Other related info (Database, table schema): MYSQL 5.x