CodeIgniter Forums
Content types CRUD: configuration OR own controllers & models - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Content types CRUD: configuration OR own controllers & models (/showthread.php?tid=45688)



Content types CRUD: configuration OR own controllers & models - El Forum - 10-01-2011

[eluser]iamzozo[/eluser]
I'm working on a project, a simple cms. There is an admin controller which handle all the CRUD operations for any content. There is a configuration file for each content type. Example news.php configuration file stores, which columns need for the list and which fields for the forms. Like news title for the form is: title => array('type' => 'input', 'field' => 'title', ...) When i call a content type, the admin controller read the config file and create the list or the form for it. It's working, but i would like to know what's the opinions for this method! Or who has got any experience with something similar Smile
The decision problem is:
- the base crud operations in one hand: not so flexible, special issues can mess it up
- own controllers & models for different content types: too much same task: news crud, events crud ( & time to create)
What do you suggest?