PHP code example of mcrud / crud

1. Go to this page and download the library: Download mcrud/crud library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

mcrud / crud example snippets


// app/Providers/AppServiceProvider.php
Gate::define('manage-crud-generator', fn ($user) => $user->is_admin);
// config/crud.php
'ability' => 'manage-crud-generator',
bash
composer vendor:publish --provider="Spatie\Permission\PermissionServiceProvider" --tag="permission-migrations"
php artisan migrate
bash
php artisan crud:generate schema.json --dry-run
php artisan crud:generate schema.json --migrate
php artisan crud:generate schema.json --auth      # also generate login, profile and user management
bash
php artisan vendor:publish --tag=crud-stubs     # stubs/crud: every generated file is a stub
php artisan vendor:publish --tag=crud-config
php artisan vendor:publish --tag=crud-assets    # public/vendor/crud: studio.js and studio-i18n.js