Download the PHP package tokarskimarcin/laravel-admin-ext-modal-form without Composer
On this page you can find all versions of the php package tokarskimarcin/laravel-admin-ext-modal-form. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download tokarskimarcin/laravel-admin-ext-modal-form
More information about tokarskimarcin/laravel-admin-ext-modal-form
Files in tokarskimarcin/laravel-admin-ext-modal-form
Package laravel-admin-ext-modal-form
Short Description Extension allows create modal form
License MIT
Homepage https://github.com/tokarskimarcin/laravel-admin-ext-modal-form
Informations about the package laravel-admin-ext-modal-form
Modal Form / laravel-admin-extensions
Requires
- "php": ">=7.2.0",
- "encore/laravel-admin": "~1.6"
Installation
Publishing
Execute command below to publish package. It will copy vendor resources to your application public directory.
php artisan vendor:publish --provider="Encore\ModalForm\ModalFormServiceProvider"
Update
To update assets of package add option to publishing command.
Documentation
1. Create modal button
Use Encore\ModalForm\Form\ModalButton class to create modal button. In constructor pass parameters (string $title, string $href)
Methods
2. Form
Use modal form as regular Admin form
Or by Modal facade like Admin facade
Modal size can be changed:
3. JS
Events are triggered on modal button.
Button selector:
Events:
1.
After modal form submit
2.
On ajax response error
3.
On response validation error
4.
On model creation success. While this events is triggered, model id can be found in button data. Id can be found there until new model is created