1
0
mirror of https://github.com/freescout-helpdesk/freescout.git synced 2024-11-13 22:23:50 +01:00

Updated FreeScout Modules Dev (markdown)

FreeScout 2018-11-13 17:38:01 +03:00
parent dd222fd4a9
commit 1829744113

@ -124,7 +124,7 @@ Retrieving variables in JS:
alert(Vars.hello_world); alert(Vars.hello_world);
``` ```
### Routes ## Routes
Routes configuration is located in `/Modules/ModuleName/Http/routes.php` Routes configuration is located in `/Modules/ModuleName/Http/routes.php`
@ -158,6 +158,25 @@ Module's public files can be added to the application in the module's service pr
}, 20, 1); }, 20, 1);
``` ```
## Extra service providers:
`module.json`:
```
"providers": [
"Modules\\SampleModule\\Providers\\ExtraProvider"
],
```
Service provider from module's `vendor`:
```
"providers": [
"\\Service\\Provider\\PathProvider"
],
```
and add to the main service provier:
```
// It has to be included here to require vendor service providers in module.json
require_once __DIR__.'/../vendor/autoload.php';
```
## Module Composer Dependencies ## Module Composer Dependencies
Module may include composer packages in it's `composer.json`: Module may include composer packages in it's `composer.json`: