Posts: 18
Threads: 5
Joined: Jun 2017
Reputation:
0
Hello
from which side do you start building and app?
I mean
given that you already know which the users areas and interactions are and also you already have structured the DB,
do you start with empty controllers and views setting up the navigation and routes?
Or what?
Thank you for sharing your approach
Robert
Posts: 26
Threads: 5
Joined: Mar 2015
Reputation:
3
Hi, usually I start with weak (simple) entities from the database, creating its models and domain classes.
Then I start creating controllers with empty methods (future implementation) to build like a skeleton, in other words, what will be the controller responsibilities, or "actions".
Then views... HTML markup
Oh, along with these activities I'll certainly create some core files like MY_Controller, MY_Model and MY_Log, because I have own stuff inside these files.
Posts: 3,233
Threads: 69
Joined: Oct 2014
Reputation:
132
Likewise similar to php_rocs I use a top down approach working from the screens
back down into the app step by step defining the problems to be solved.
The screens can tell you a lot about the app for declaring variables etc;
These will also map into your models and controllers.
keep in mind KISS and DRY (Keep it simple stupid and do not repeat yourself).
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
Posts: 920
Threads: 9
Joined: Jun 2016
Reputation:
54
@InsiteFX
EXCELLENT POINT ABOUT KISS and DRY!!!
Posts: 5
Threads: 2
Joined: Aug 2019
Reputation:
0
Very good thread!
I‘m not sure how to start the best way. As many people would say ... it depends ;-)
But I would say ... first I create the header file to implement bootstrap, jquery and custom webfonts.
Then I create the most important and nessecary model(s) and controller(s) < first model, then controller to load a first view and provide data to it. Mostly the view just displays a list of loaded items.
Then I build another view to show details of one item. Often this is a form so that I could build some edit functionallity extending to CRUD (create, read, update, delete).
After that i want to make it look nice. So I tweak the css (scss). Now ... display-filters for the list. So some jQuery scripting :-)
If there should be users I would build the login now, also with session-management. Just the login, not the whole registration and forgot-password-stuff.
Before the software grows, I also try to build repeating view-parts to be flexible.
Posts: 60
Threads: 5
Joined: Sep 2018
Reputation:
0
Before everything I create a new Word file to note down & follow the "to do list" of the project. When I complete a task, I strikethrough it, I also write down any link of any forum help or a link of a video etc. Then the work takes control of me and the work itself in a proper way.
And I continue by doing it one by one, seeing the result of each section, of course by copying some parts from the previous jobs. This might lead to getting stucked to a point until you solve it. (Because I spend a lot of time searching for a solution. I rarely ask for help)