Commit 5564cb29 authored by Aster's avatar Aster Committed by waltermazza
Browse files

General Bug Fixes and Improvements

parent 1cc2ab4f
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
/* use bedezign\yii2\audit\assets\JSLoggingAsset; */
use yii\helpers\Html;
use elitedivision\amos\layout\assets\BaseAsset;
use arter\amos\layout\assets\BaseAsset;
BaseAsset::register($this);
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\helpers\Html;
use elitedivision\amos\core\icons\AmosIcons;
use elitedivision\amos\core\utilities\CurrentUser;
use elitedivision\amos\core\widget\WidgetAbstract;
use elitedivision\amos\dashboard\AmosDashboard;
use elitedivision\amos\layout\Module;
use elitedivision\amos\layout\toolbar\Nav;
use elitedivision\amos\layout\toolbar\NavBar;
use arter\amos\core\helpers\Html;
use arter\amos\core\icons\AmosIcons;
use arter\amos\core\utilities\CurrentUser;
use arter\amos\core\widget\WidgetAbstract;
use arter\amos\dashboard\AmosDashboard;
use arter\amos\layout\Module;
use arter\amos\layout\toolbar\Nav;
use arter\amos\layout\toolbar\NavBar;
use yii\helpers\ArrayHelper;
use yii\helpers\Url;
use yii\web\JsExpression;
......@@ -35,11 +31,11 @@ use yii\web\JsExpression;
<?php
/* Configuration of Slideshow - begin */
if (\Yii::$app->getModule('slideshow') && isset(\Yii::$app->params['slideshow']) && \Yii::$app->params['slideshow'] === TRUE) {
$slideshow = new \elitedivision\amos\slideshow\models\Slideshow;
$slideshow = new \arter\amos\slideshow\models\Slideshow;
$route = "/".\Yii::$app->request->getPathInfo();
$idSlideshow = $slideshow->hasSlideshow($route);
$slideshowLabel = ($idSlideshow) ? $slideshow->findOne($idSlideshow)->label : NULL;
echo \elitedivision\amos\slideshow\widgets\SlideshowWidget::widget([]);
echo \arter\amos\slideshow\widgets\SlideshowWidget::widget([]);
}
/** @var bool|false $disablePlatformLinks - if true all the links to dashboard, settings, etc are disabled */
$disablePlatformLinks = isset(\Yii::$app->params['disablePlatformLinks']) ? \Yii::$app->params['disablePlatformLinks']
......@@ -80,7 +76,7 @@ use yii\web\JsExpression;
/* Configuration of Slideshow - end */
/* Configuration header menu: field translation */
$headerMenu = new elitedivision\amos\core\views\common\HeaderMenu();
$headerMenu = new arter\amos\core\views\common\HeaderMenu();
$menuTranslation = $headerMenu->getTranslationField();
$menuCustom = $headerMenu->getCustomContent();
/* echo Translation button */
......@@ -188,7 +184,7 @@ use yii\web\JsExpression;
$btnsLogout = '';
$btnsEsci = '';
$btnLogoutUrl = ['/admin/security/logout'];
/** @var \elitedivision\amos\socialauth\Module $socialAuthModule */
/** @var \arter\amos\socialauth\Module $socialAuthModule */
$socialAuthModule = Yii::$app->getModule('socialauth');
if (YII_ENV_PROD && !is_null($socialAuthModule) && ($socialAuthModule->enableSpid === true)) {
$btnLogoutUrl['backTo'] = Url::to([
......@@ -258,7 +254,7 @@ use yii\web\JsExpression;
];
$settingsItemsElements = [];
$atLeastOneElement = false;
if (\Yii::$app->controller instanceof \elitedivision\amos\dashboard\controllers\base\DashboardController) {
if (\Yii::$app->controller instanceof \arter\amos\dashboard\controllers\base\DashboardController) {
$atLeastOneElement = true;
$settingsItemsElements[] = [
'label' => Yii::t('amoscore', 'Ordinamenti dashboard'),
......@@ -340,21 +336,21 @@ use yii\web\JsExpression;
if (\Yii::$app->getModule('chat')) {
$widget = new \elitedivision\amos\chat\widgets\icons\WidgetIconChat();
$widget = new \arter\amos\chat\widgets\icons\WidgetIconChat();
$bulletCount = $widget->getBulletCount();
$chatLink = Html::tag('li',
Html::a(
AmosIcons::show('comments-o', [], 'dash')."<span class='badge'>".(($bulletCount > 0 ) ? $bulletCount
: "" )."</span>"
, '/messages',
['title' => \elitedivision\amos\chat\AmosChat::t('amoschat', 'Messaggi privati')]
['title' => \arter\amos\chat\AmosChat::t('amoschat', 'Messaggi privati')]
), ['class' => 'header-plugin-icon']
);
$menuItems[] = $chatLink;
}
if (\Yii::$app->getModule('myactivities') && !\Yii::$app->user->isGuest && Yii::$app->user->can('MYACTIVITIES_READ')) {
$widget = new \elitedivision\amos\myactivities\widgets\icons\WidgetIconMyActivities();
$widget = new \arter\amos\myactivities\widgets\icons\WidgetIconMyActivities();
if (
(isset(\Yii::$app->params['disableBulletCounters']) && (\Yii::$app->params['disableBulletCounters'] === true)) &&
(!isset(\Yii::$app->params['enableMyActivitiesBulletCounters']) || (isset(\Yii::$app->params['enableMyActivitiesBulletCounters']) && (\Yii::$app->params['enableMyActivitiesBulletCounters'] === false)))
......@@ -368,7 +364,7 @@ use yii\web\JsExpression;
AmosIcons::show('bell', [], 'dash')."<span class='badge'>".(($bulletCount > 0 ) ? $bulletCount
: "" )."</span>"
, '/myactivities/my-activities/index',
['title' => \elitedivision\amos\myactivities\AmosMyActivities::t('amosmyactivities',
['title' => \arter\amos\myactivities\AmosMyActivities::t('amosmyactivities',
'My activities')]
), ['class' => 'header-plugin-icon']
);
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use yii\helpers\FileHelper;
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\layout\parts
* @package arter\amos\layout\parts
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\controllers\CrudController;
use elitedivision\amos\core\forms\CreateNewButtonWidget;
use elitedivision\amos\core\helpers\Html;
use elitedivision\amos\core\icons\AmosIcons;
use elitedivision\amos\core\views\ChangeView;
use elitedivision\amos\core\views\grid\ActionColumn;
use elitedivision\amos\slideshow\models\Slideshow;
use arter\amos\core\controllers\CrudController;
use arter\amos\core\forms\CreateNewButtonWidget;
use arter\amos\core\helpers\Html;
use arter\amos\core\icons\AmosIcons;
use arter\amos\core\views\ChangeView;
use arter\amos\core\views\grid\ActionColumn;
use arter\amos\slideshow\models\Slideshow;
use kartik\export\ExportMenu;
use yii\base\Event;
use yii\data\ActiveDataProvider;
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\module\BaseAmosModule;
use elitedivision\amos\core\widget\WidgetAbstract;
use arter\amos\core\module\BaseAmosModule;
use arter\amos\core\widget\WidgetAbstract;
use yii\helpers\Html;
/** @var bool|false $disablePlatformLinks - if true all the links to dashboard, settings, etc are disabled */
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\module\BaseAmosModule;
use arter\amos\core\module\BaseAmosModule;
use yii\helpers\Html;
/** @var bool|false $disablePlatformLinks - if true all the links to dashboard, settings, etc are disabled */
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use yii\bootstrap\Alert;
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\layout\views\layouts\parts
* @package arter\amos\layout\views\layouts\parts
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
$moduleCwh = Yii::$app->getModule('cwh');
$moduleCommunity = Yii::$app->getModule('community');
......@@ -18,19 +14,19 @@ $layoutModule = Yii::$app->getModule('layout');
$scope = null;
if (!empty($moduleCwh)) {
/** @var \elitedivision\amos\cwh\AmosCwh $moduleCwh */
/** @var \arter\amos\cwh\AmosCwh $moduleCwh */
$scope = $moduleCwh->getCwhScope();
}
if (!empty($scope)) {
if (isset($scope['community'])) {
$communityId = $scope['community'];
$community = \elitedivision\amos\community\models\Community::findOne($communityId);
$community = \arter\amos\community\models\Community::findOne($communityId);
}
}
$controller = Yii::$app->controller;
$isActionUpdate = ($controller->action->id == 'update');
$confirm = $isActionUpdate ? [
'confirm' => \elitedivision\amos\core\module\BaseAmosModule::t('amoscore', '#confirm_exit_without_saving')
'confirm' => \arter\amos\core\module\BaseAmosModule::t('amoscore', '#confirm_exit_without_saving')
] : null;
$model = null;
......@@ -42,7 +38,7 @@ $model = null;
// $model = $controller->model;
// if ($model->hasProperty('community_id')) {
// $communityId = $model->community_id;
// $community = \elitedivision\amos\community\models\Community::findOne($communityId);
// $community = \arter\amos\community\models\Community::findOne($communityId);
// }
//}
......@@ -59,7 +55,7 @@ if (isset($community)) {
if (!is_null($eventsModule) && ($community->context == $eventsModule->model('Event'))) {
echo $this->render('events_network_scope', $viewParams);
} else if ($community->context == \elitedivision\amos\community\models\Community::className()) {
} else if ($community->context == \arter\amos\community\models\Community::className()) {
$viewScope = 'community_network_scope';
echo $this->render($viewScope, $viewParams);
} else if (!is_null(Yii::$app->getModule('challenge')) && $community->context == \amos\challenge\models\ChallengeTeam::className()) {
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core\views\layouts\parts
* @package arter\amos\core\views\layouts\parts
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\helpers\Html;
use elitedivision\amos\core\icons\AmosIcons;
use arter\amos\core\helpers\Html;
use arter\amos\core\icons\AmosIcons;
/**
* @var yii\web\View $this
* @var \elitedivision\amos\core\record\Record $model
* @var \elitedivision\amos\core\components\PartQuestionarioAbstract $partsQuestionario
* @var \arter\amos\core\record\Record $model
* @var \arter\amos\core\components\PartQuestionarioAbstract $partsQuestionario
* @var bool $hidePartsLabel
* @var bool $hidePartsUrl
*/
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\layout
* @package arter\amos\layout
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\layout\assets\BaseAsset;
use arter\amos\layout\assets\BaseAsset;
$asset = BaseAsset::register($this);
?>
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use yii\helpers\FileHelper;
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core\views\layouts
* @package arter\amos\core\views\layouts
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
......@@ -19,7 +15,7 @@ use yii\helpers\Html;
use yii\helpers\Url;
/* @var $this \yii\web\View */
/* @var \elitedivision\amos\core\components\PartQuestionarioAbstract $partsQuestionario */
/* @var \arter\amos\core\components\PartQuestionarioAbstract $partsQuestionario */
/* @var $content string */
$urlCorrente = Url::current();
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\components\AmosView;
use arter\amos\core\components\AmosView;
use yii\helpers\Html;
use yii\helpers\Url;
////\bedezign\yii2\audit\web\JSLoggingAsset::register($this);
/** @var $this \elitedivision\amos\core\components\AmosView */
/** @var $this \arter\amos\core\components\AmosView */
/** @var $content string */
$urlCorrente = Url::current();
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\layout\assets\FormAsset;
use elitedivision\amos\layout\assets\IEAssets;
use arter\amos\layout\assets\FormAsset;
use arter\amos\layout\assets\IEAssets;
use yii\helpers\Html;
use yii\helpers\Url;
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use yii\helpers\Html;
use yii\helpers\Url;
use elitedivision\amos\dashboard\models\AmosWidgets;
use arter\amos\dashboard\models\AmosWidgets;
////\bedezign\yii2\audit\web\JSLoggingAsset::register($this);
/* @var $this \yii\web\View */
......@@ -111,7 +107,7 @@ if ($countArrayUrl) {
}
}
echo \elitedivision\amos\core\toolbar\Nav::widget([
echo \arter\amos\core\toolbar\Nav::widget([
'items' => $items,
'encodeLabels' => false,
'options' => ['class' => 'nav nav-tabs'],
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\components\AmosView;
use arter\amos\core\components\AmosView;
use yii\helpers\Html;
use yii\helpers\Url;
////\bedezign\yii2\audit\web\JSLoggingAsset::register($this);
/** @var $this \elitedivision\amos\core\components\AmosView */
/** @var $this \arter\amos\core\components\AmosView */
/** @var $content string */
$urlCorrente = Url::current();
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\core
* @package arter\amos\core
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\core\components\AmosView;
use elitedivision\amos\dashboard\models\AmosWidgets;
use arter\amos\core\components\AmosView;
use arter\amos\dashboard\models\AmosWidgets;
use yii\helpers\Url;
////\bedezign\yii2\audit\web\JSLoggingAsset::register($this);
......@@ -96,7 +92,7 @@ if ($countArrayUrl) {
</div>
<?php if ($this instanceof \elitedivision\amos\core\components\AmosView): ?>
<?php if ($this instanceof \arter\amos\core\components\AmosView): ?>
<?php $this->beginViewContent() ?>
<?php endif; ?>
<?= $content ?>
......
<?php
/**
* Lombardia Informatica S.p.A.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\layout
* @package arter\amos\layout
* @category CategoryName
* @author Lombardia Informatica S.p.A.
*/
use elitedivision\amos\layout\Module;
use arter\amos\layout\Module;
?>
<div class="intro">
......