Trying to establish a simple multiple relation between two tables.
Unfortunately Codeigniter keeps saying:
"Unable to locate the model you have specified: eventtrigger".
Here comes the code:
class Task extends DataMapper
{
public $has_one = array('employee',
'eventtrigger' => array('class' => 'employee'));
[…]
}
I know, this is very few information.
But I hope there is a known problem concerning this construct.
regards:maak.
You need to also define the relation's
other_field
property, and you also need to define the reverse relation in theEmployee
model:And in the Employee model:
For more info on this: http://datamapper.wanwizard.eu/pages/advancedrelations.html
Unfortunately, as @bmorenate mentioned, DataMapper isn't actively supported anymore.