Main Master is a CRUD generator for Laravel projects. This project was created to make it easier for developers to create Laravel projects. This project is built with Laravel 10 and Bootstrap 5.
app:convert-menu command
.# From Packagist
$ composer create-project arwp/main-master {your-project-name}
# ---- OR -----
# Clone the repository
$ git clone https://github.com/arwahyu01/main-master.git {your-project-name}
$ cd main-master
$ composer install
$ cp .env.example .env
$ php artisan key:generate
$ php artisan migrate --seed
$ php artisan serve # or use valet
<script type="application/javascript">
fetch("{{ url('/js/'.$backend.'/'.$page->code.'/datatable.js') }}", {
method: 'POST',
headers: {
"X-CSRF-TOKEN": "{{ csrf_token() }}",
"Content-Type": "application/json"
},
body: JSON.stringify({id: "{{ $id }}"})
})
.then(e => e.text())
.then(r => {
Function('"use strict";\n' + r)();
}).catch(e => console.log(e));
</script>
JSON.stringify({'id': "{{ $id }}",'id2': "{{ $id2 }}"})
for multiple requestJSON.stringify({id: "{{ $id }}"})
for single request$id
, in datatable.blade.js file like this : $('#datatable').DataTable({
ajax: `{{ url(config('master.app.url.backend').'/'.$url.'/data?id='${id}') }}`,
});
Install this package to your laravel project
composer require arwp/mvc
php artisan make:mvc [name]
in your terminal to create a module
php artisan migrate
to create table
php artisan delete:mvc [name]
to delete a module (delete all file and table in database)