imagina / iforms-module
Iforms module for AsgardCMS
Installs: 2 970
Dependents: 2
Suggesters: 0
Security: 0
Stars: 1
Watchers: 3
Forks: 10
Type:asgard-module
pkg:composer/imagina/iforms-module
Requires
- php: ^8.1
- anhskohbo/no-captcha: ^3.5
- composer/installers: ~1.0
- imagina/core-module: ^10.0
- maatwebsite/excel: ^3.1
Requires (Dev)
- orchestra/testbench: ^8.5
- phpunit/phpunit: ^10
README
By Imagina Soluciones Web
Installation
composer require imagina/iforms-module
Configuration
This module require maatwebsite/excel
The Maatwebsite\Excel\ExcelServiceProvider is auto-discovered and registered by default.
If you want to register it yourself, add the ServiceProvider in config/app.php:
'providers' => [ /* * Package Service Providers... */ Maatwebsite\Excel\ExcelServiceProvider::class, ]
The Excel facade is also auto-discovered. If you want to add it manually, add the Facade in config/app.php:
'aliases' => [ ... 'Excel' => Maatwebsite\Excel\Facades\Excel::class, ]
To publish the config, run the vendor publish command:
php artisan vendor:publish --provider="Maatwebsite\Excel\ExcelServiceProvider"
This will create a new config file named config/excel.php.
data source maatwebsite/excel
Add NOCAPTCHA_SECRET and NOCAPTCHA_SITEKEY in .env file :
NOCAPTCHA_SECRET=secret-key
NOCAPTCHA_SITEKEY=site-key
(You can obtain them from here)
End Points
| PATH | METHODS |
|---|---|
| /iforms/v4/forms | [GET, POST, PUT, DELETE] |
| /iforms/v4/fields | [GET, POST, PUT, DELETE] |
| /iforms/v4/types | [GET] |
| /iforms/v4/leads | [GET, POST] |
Iforms blade component
<x-iforms::form :id="$formId" :layout="$layout" />
$formId the form id or system name ex: contact or 1
$layout the form layout
| LAYOUT | TYPE |
|---|---|
| form-layout-1 | horizontal |
| form-layout-2 | inline |
| form-layout-3 | no label |
Iforms newsletter subscription form component
<x-iforms::newsletter :title="$title" :description="$description" />
$title the form title
$description the form description