PHP code example of open20 / amos-organizzazioni

1. Go to this page and download the library: Download open20/amos-organizzazioni library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

open20 / amos-organizzazioni example snippets



'modules' => [
    'organizzazioni' => [
        'class' => 'open20\amos\organizzazioni\Module'
    ],
],

If do you want to enable community creation for every single organization set this
parameter to true in your modules-amos.php config file. If this is true organization
module manager is able to create a reserved community.
These reserved communities can be made/managed by legal representative and 
operative referee.
'modules' => [
    'organizzazioni' => [
        'class' => 'open20\amos\organizzazioni\Module',
        'enableCommunityCreation' => true
    ],
],



return [
    '@vendor/open20/amos-organizzazioni/src/migrations',
];



if (isset($modules['tag'])) {
    ...
    if (isset($modules['organizzazioni'])) {
        $modules['tag']['modelsEnabled'][] = 'open20\amos\organizzazioni\models\Profilo';
        $modules['tag']['modelsEnabled'][] = 'open20\amos\organizzazioni\models\ProfiloSedi';
    }
    ...
}
bash
php yii migrate/up --migrationPath=@vendor/open20/amos-organizzazioni/src/migrations