yangruiyou85 / yiidoc

Automatically exported from code.google.com/p/yiidoc
0 stars 0 forks source link

Bad name of generated models #42

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
Generate model via shell by command "model table_name" in Yii 1.1

In the related model table_name2 to model "table_name" in the method
"relations" class name is generated as "TableName", but the real class was
generated in file table_name.php with name "table_name extends
CActiveRecord" so i can`t use this model.

Original issue reported on code.google.com by iakreve...@gmail.com on 15 Dec 2009 at 9:50

GoogleCodeExporter commented 9 years ago
this problem is rased if i call $tableName2->table_name->property_of_table_name

Original comment by iakreve...@gmail.com on 15 Dec 2009 at 9:57

GoogleCodeExporter commented 9 years ago
This is expected. You will need to manually fix the generated rules() method 
since
the "model" command may not have full knowledge to correctly generate it.

Original comment by qiang.xue on 27 Dec 2009 at 10:15