Yoram Kornatzky

Start Laravel with the Admin

The Common Landscape of Laravel Projects

You construct a new web app with Laravel framework. It requires a user facing and an administrator facing web app. It is really just one web app, with separate views, probably, but a shared database.

How Do You Start?

Well, you have the Artisan command line tool, so you can generate controllers, views, models, and all sorts of things. But where do you start?

We say: start your Laravel project with the admin

Start with the Models

You have a clear idea of the conceptual structure of your data. Start with the models. Most often, your app is structured around models, so when generating the models, you generate the resource controllers for these, when appropriate.

Create the migrations.

Seed the Database

Fill it. So your views and controllers can be immediately tested. Use factories and seeders.

Construct the Admin Side

Administrators access a much larger part of the data than the ordinary classes of users, but often their views have a much simpler look and feel. So the admin side can be viewed as a prototype of user side.