acl.global.php 2.14 KB
Newer Older
1
<?php
2 3
/**
 * gredu_labs
4
 *
5 6 7 8
 * @link https://github.com/eellak/gredu_labs for the canonical source repository
 * @copyright Copyright (c) 2008-2015 Greek Free/Open Source Software Society (https://gfoss.ellak.gr/)
 * @license GNU GPLv3 http://www.gnu.org/licenses/gpl-3.0-standalone.html
 */
9 10 11
return [
    'acl' => [
        'default_role' => 'guest',
12 13 14
        'roles' => [
            'guest' => [],
            'user' => [],
15
            'school' => ['user'],
16
            'admin' => ['user'],
17 18
        ],
        'resoures' => [],
19
        'guards' => [
20 21
            'resources' => [],
            'callables' => [],
22
            'routes' => [
23
                ['/', ['guest', 'user'], ['get']],
kanellov's avatar
kanellov committed
24
                ['/about', ['guest', 'user'], ['get']],
25
                ['/school', ['school'], ['get']],
26
                ['/school/labs', ['school'], ['get', 'post', 'delete']],
27 28 29
                ['/school/staff', ['school'], ['get', 'post', 'delete']],
                ['/school/assets', ['school'], ['get', 'post', 'delete']],
                ['/school/labs/attachment', ['school'], ['get', 'delete']],
30
                ['/school/software', ['school'], ['get', 'post', 'delete']],
31
                ['/application-form', ['school'], ['get', 'post']],
32
                ['/application-form/submit-success', ['school'], ['get']],
33
                ['/application-form/report', ['school'], ['get']],
34
                ['/receive-equip', ['school'], ['get', 'post'], GrEduLabs\ReceiveEquip\Acl\Assertion\CanSubmit::class],
35 36
                ['/receive-equip/submit-success', ['school'], ['get']],
                ['/receive-equip/report', ['school'], ['get']],
37
                ['/receive-equip/receive-doc/{fn}', ['school'], ['get']],
38
                ['/tpe_survey', ['school'], ['get', 'post']],
39
                ['/tpe_survey/total-teachers', ['school'], ['post']],
40
                ['/forum', ['guest', 'user'], ['get']],
41
                ['/sch_sync/sync', ['school'], ['get']],
42
                ['/in_numbers', ['guest', 'user'], ['get']],
43
                ['/export/csv/edulabs_{type}.csv', ['guest', 'user'], ['get']],
Vassilis Kanellopoulos's avatar
Vassilis Kanellopoulos committed
44
                ['/open-data', ['guest', 'user'], ['get']],
45 46 47 48
            ],
        ],
    ],
];