PHP Fatal Error: Class Not Found
Bug #262475 reported by
Anthony Bush
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
CoughPHP |
Fix Released
|
High
|
Anthony Bush |
Bug Description
Create two tables, one with a PK, one without. Add an FK (in DB or just by using the same column name) from 2nd table to 1st. For example:
table_one
key_id PK
name
table_two
table_one_id
blah
After generating, you'll only have classes for the first table. Try to create a new "TableOne" object save it. Fatal error occurs because generator generates links to it in NotifyChildrenO
Changed in coughphp: | |
assignee: | nobody → awbush |
importance: | Undecided → High |
milestone: | none → 1.3.1 |
status: | New → In Progress |
To post a comment you must log in.
This bug has existed since 1.1 (when the overhaul took place), maybe longer. It's extremely rare as it requires that you have a table without primary key AND that they be linked either by name or FK to a table that *does* have a primary key AND that you try to save a new object or change the key for an existing one (you could still update existing so long as you didn't change the primary key).