Do you have a well migration files and you want to make a Laravel Application on top of it?
By using this tool you can generate Models, Requests with Rules, Routes, Controllers, Forms, and Vue components like routers, store modules, and themes.
So lets start.
Simply clone the project.
- Copy
init.php
file to your server. - Open
result.html
and select your migration file 1. single file 2. select folder - You can choose the properties you want from the table.
- Click init code.
- if it is single file will preview it in page and be ready to send to server.
- if it is folder will be ready to send to server
- Click on create files which will start sending data to the server to create file.
Note : if you need to convert an HTML element or JS or PHP code,
fileToString.html
can do this task for you.
- After reading the migration file as a text. Push this text into
listOfFiles
array. - Then extract column name and type from the migration file via regular expressions.
- Create new Setting from the extracted data, push Setting into Settings array, and pass Setting element to componets to create template of file.
- Make the file ready to be sent to the server.
- The server processes the requests by creating the needed files.
create relationship don't work with single file because we don't know another tables until you add it.
## Scale Laravel App Link: https://medium.com/@munza/large-scale-laravel-application-9d52c3d38e51set a new function inside ==> function map() for example :
protected function mapCategoryRoutes()
{
Route::prefix('categories')
->middleware('web')
->namespace('TuringChallenge\Category\Http\Controllers')
->group(base_path('app/Category/route.php'));
}
- Import your secipt file into
result.html
- Go to
initObject
script and declare the new imported file. - Push it into
filesPHP
array which is used to send requests to the server.