forked from laravel/laravel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathboot.php
33 lines (30 loc) · 885 Bytes
/
boot.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
/** @var rex_addon $this */
/**
* register permissions
*/
if (rex::isBackend() && is_object(rex::getUser())) {
rex_perm::register($this->getName() . '[]', 'Use My Laravel AddOn');
}
/**
* load scripts and styles
*/
if (rex::isBackend()) {
try {
rex_view::addCssFile($this->getAssetsUrl('css/backend.css'));
rex_view::addJsFile($this->getAssetsUrl('js/backend.js'));
} catch (rex_exception $e) {
// well, then ...
}
}
/*
|--------------------------------------------------------------------------
| Enable Frontend Requests
|--------------------------------------------------------------------------
|
| MyLaravelAddOn is the facade between this add-on and other parts of
| Redaxo. In order to handle requests from other add-ons or modules it must
| know about the Redaxo add-on instance.
|
*/
MyLaravelAddOn::setRedaxoAddOn($this);