advanced modules and has many ($has_many) relationships
Hello,
I am new to fuel and enjoying what I have seen so far.
I am using it to create an admin for an image gallery application and in doing so have created an advanced module called gallery.
the module has 2 models: galleries and images where a user can create a gallery and then assign multiple images to it.
when I add the 'images' to the $has_many array, I get an error in gallery/galleries/create:
Unable to locate the file: images_model.php
I am wondering if I am understanding the advanced module concept properly as a wholly contained set of simple modules that could be moved between projects and who's modules have a relationship together?
Thank you for pointers in the right direction,
-NP
Comments
i had to specify that the model was in the gallery folder (where gallery is the name of my advanced module):
$has_many = array('images' => array('gallery/images_model'));
would like to make sure i am on the right track conceptualizing advanced modules however.
Thank you,
-NP
$has_many = array('images' => array('gallery' => 'images_model'));
-NP