How to Create a Restricted Administration Control in Laravel

Framework
Laravel
Web Programming

How to Create a Restricted Administration Control in Laravel 6

Steps: 1.Create a migration file for admin user. php artisan make:migration add_is_admin_to_user_table –table=users 2. Add is_admin field to user table public function up() { Schema::table(‘users’, function(Blueprint $table) { $table->boolean(‘is_admin’)->default(false); }); } public function down() { Schema::table(‘users’, function(Blueprint $table) { $table->dropColumn(‘is_admin’); }); } 3. Run the migrate command php artisan migrate 4. Create administration controller php […]

Read More