Commit 03762be8 authored by waltermazza's avatar waltermazza
Browse files

Arter namespace

parent b9913ac0
......@@ -6,7 +6,7 @@
"notifiche",
"yii2"
],
"homepage": "http://www.elitedivision.it/",
"homepage": "http://www.arter.it/",
"type": "component",
"license": "BSD-3-Clause",
"support": {
......@@ -29,10 +29,10 @@
},
"autoload": {
"psr-4": {
"elitedivision\\amos\\notificationmanager\\": "src"
"arter\\amos\\notificationmanager\\": "src"
}
},
"scripts": {
"post-install-cmd": "php yii migrate --migrationPath=@vendor/elitedivision/amos-notify/migrations --interactive=0"
"post-install-cmd": "php yii migrate --migrationPath=@vendor/arter/amos-notify/migrations --interactive=0"
}
}
\ No newline at end of file
......@@ -5,12 +5,12 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notify
* @package arter\amos\notify
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager;
namespace arter\amos\notificationmanager;
/**
*
......@@ -48,14 +48,14 @@ namespace elitedivision\amos\notificationmanager;
* CHANNEL_ALL -- Tutti i Canali
*/
use elitedivision\amos\core\module\AmosModule;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\notificationmanager\base\NotifierRepository;
use elitedivision\amos\notificationmanager\base\NotifyWidget;
use elitedivision\amos\notificationmanager\listeners\NotifyWorkflowListener;
use elitedivision\amos\notificationmanager\models\NotificationChannels;
use elitedivision\amos\notificationmanager\models\NotificationsConfOpt;
use elitedivision\amos\notificationmanager\utility\NotifyUtility;
use arter\amos\core\module\AmosModule;
use arter\amos\core\record\Record;
use arter\amos\notificationmanager\base\NotifierRepository;
use arter\amos\notificationmanager\base\NotifyWidget;
use arter\amos\notificationmanager\listeners\NotifyWorkflowListener;
use arter\amos\notificationmanager\models\NotificationChannels;
use arter\amos\notificationmanager\models\NotificationsConfOpt;
use arter\amos\notificationmanager\utility\NotifyUtility;
use raoul2000\workflow\base\SimpleWorkflowBehavior;
use Yii;
use yii\base\Event;
......@@ -64,7 +64,7 @@ use yii\log\Logger;
/**
* Class AmosNotify
* @package elitedivision\amos\notificationmanager
* @package arter\amos\notificationmanager
*/
class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, NotifyWidget
{
......@@ -79,8 +79,8 @@ class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, Not
/**
* @var null |string
* [
* 'elitedivision\amos\admin\models\UserProfile' => '@common/mail/notify_validation/validator_user_profile',
* 'elitedivision\amos\news\models\News' => '@common/mail/notify_validation/validator_news',
* 'arter\amos\admin\models\UserProfile' => '@common/mail/notify_validation/validator_user_profile',
* 'arter\amos\news\models\News' => '@common/mail/notify_validation/validator_news',
* ]
*
*/
......@@ -89,8 +89,8 @@ class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, Not
/**
* @var null |string
* [
* 'elitedivision\amos\admin\models\UserProfile' => '@common/mail/notify_validation/validated_user_profile',
* 'elitedivision\amos\news\models\News' => '@common/mail/notify_validation/validated_news',
* 'arter\amos\admin\models\UserProfile' => '@common/mail/notify_validation/validated_user_profile',
* 'arter\amos\news\models\News' => '@common/mail/notify_validation/validated_news',
* ]
*/
public $viewPathEmailNotifyValidated = [];
......@@ -98,7 +98,7 @@ class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, Not
/**
* @inheritdoc
*/
public $controllerNamespace = 'elitedivision\amos\notificationmanager\controllers';
public $controllerNamespace = 'arter\amos\notificationmanager\controllers';
/**
* @inheritdoc
......@@ -123,7 +123,7 @@ class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, Not
public function init()
{
parent::init();
\Yii::setAlias('@elitedivision/amos/notificationmanager/commands', __DIR__ . '/commands/');
\Yii::setAlias('@arter/amos/notificationmanager/commands', __DIR__ . '/commands/');
// initialize the module with the configuration loaded from config.php
\Yii::configure($this, require(__DIR__ . DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . 'config.php'));
}
......@@ -134,7 +134,7 @@ class AmosNotify extends AmosModule implements \yii\base\BootstrapInterface, Not
public function bootstrap($app)
{
if ($app instanceof \yii\console\Application) {
$this->controllerNamespace = 'elitedivision\amos\notificationmanager\commands';
$this->controllerNamespace = 'arter\amos\notificationmanager\commands';
} else {
Event::on(
Record::className(),
......
......@@ -5,18 +5,18 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base
* @package arter\amos\notificationmanager\base
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base;
namespace arter\amos\notificationmanager\base;
use elitedivision\amos\core\user\User;
use arter\amos\core\user\User;
/**
* Interface Builder
* @package elitedivision\amos\notificationmanager\base
* @package arter\amos\notificationmanager\base
*/
interface Builder
{
......
......@@ -5,19 +5,19 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notify
* @package arter\amos\notify
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base;
namespace arter\amos\notificationmanager\base;
use elitedivision\amos\notificationmanager\base\builder\ContentImmediateMailBuilder;
use elitedivision\amos\notificationmanager\base\builder\ContentMailBuilder;
use elitedivision\amos\notificationmanager\base\builder\CustomMailBuilder;
use elitedivision\amos\notificationmanager\base\builder\ValidatedMailBuilder;
use elitedivision\amos\notificationmanager\base\builder\ValidatorsMailBuilder;
use elitedivision\amos\notificationmanager\models\ChangeStatusEmail;
use arter\amos\notificationmanager\base\builder\ContentImmediateMailBuilder;
use arter\amos\notificationmanager\base\builder\ContentMailBuilder;
use arter\amos\notificationmanager\base\builder\CustomMailBuilder;
use arter\amos\notificationmanager\base\builder\ValidatedMailBuilder;
use arter\amos\notificationmanager\base\builder\ValidatorsMailBuilder;
use arter\amos\notificationmanager\models\ChangeStatusEmail;
use yii\base\BaseObject;
class BuilderFactory extends BaseObject {
......
......@@ -5,19 +5,19 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notify
* @package arter\amos\notify
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base;
namespace arter\amos\notificationmanager\base;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\core\user\AmosUser;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\models\Notification;
use elitedivision\amos\notificationmanager\models\NotificationChannels;
use elitedivision\amos\notificationmanager\models\NotificationsRead;
use arter\amos\core\record\Record;
use arter\amos\core\user\AmosUser;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\models\Notification;
use arter\amos\notificationmanager\models\NotificationChannels;
use arter\amos\notificationmanager\models\NotificationsRead;
use Yii;
use yii\db\ActiveQuery;
......@@ -28,7 +28,7 @@ use yii\log\Logger;
/**
* Class NotifierRepository
* @package elitedivision\amos\notificationmanager\base
* @package arter\amos\notificationmanager\base
*/
class NotifierRepository
{
......
......@@ -9,7 +9,7 @@
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base;
namespace arter\amos\notificationmanager\base;
interface NotifyWidget
......
......@@ -9,7 +9,7 @@
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base;
namespace arter\amos\notificationmanager\base;
class NotifyWidgetDoNothing implements NotifyWidget
......
......@@ -5,24 +5,24 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\core\user\User;
use elitedivision\amos\core\utilities\Email;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\base\Builder;
use elitedivision\amos\notificationmanager\models\NotificationConf;
use arter\amos\core\user\User;
use arter\amos\core\utilities\Email;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\base\Builder;
use arter\amos\notificationmanager\models\NotificationConf;
use Yii;
use yii\base\BaseObject;
/**
* Class AMailBuilder
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
*/
abstract class AMailBuilder extends BaseObject implements Builder
{
......@@ -92,7 +92,7 @@ abstract class AMailBuilder extends BaseObject implements Builder
{
$module = \Yii::$app->getModule('translation');
if ($module && !empty($module->enableUserLanguage) && $module->enableUserLanguage == true) {
/** @var \elitedivision\amos\translation\AmosTranslation $module */
/** @var \arter\amos\translation\AmosTranslation $module */
$lang = $module->getUserLanguage($userId);
$module->setAppLanguage($lang);
}
......
......@@ -4,14 +4,14 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\AmosNotify;
class ContentImmediateMailBuilder extends ContentMailBuilder
{
......@@ -24,7 +24,7 @@ class ContentImmediateMailBuilder extends ContentMailBuilder
{
$controller = \Yii::$app->controller;
$contents_number = count($resultset);
$ris = $controller->renderPartial("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_immediate_email_header", [
$ris = $controller->renderPartial("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_immediate_email_header", [
'contents_number' => $contents_number
]);
return $ris;
......
......@@ -5,26 +5,26 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\core\interfaces\ModelLabelsInterface;
use elitedivision\amos\core\models\ModelsClassname;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\core\user\User;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\models\Notification;
use elitedivision\amos\notificationmanager\record\NotifyRecord;
use arter\amos\core\interfaces\ModelLabelsInterface;
use arter\amos\core\models\ModelsClassname;
use arter\amos\core\record\Record;
use arter\amos\core\user\User;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\models\Notification;
use arter\amos\notificationmanager\record\NotifyRecord;
use Yii;
use yii\helpers\Console;
/**
* Class ContentMailBuilder
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
*/
class ContentMailBuilder extends AMailBuilder
{
......@@ -84,7 +84,7 @@ class ContentMailBuilder extends AMailBuilder
protected function renderContent(Record $model, $user)
{
$controller = \Yii::$app->controller;
$ris = $controller->renderPartial("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/content", [
$ris = $controller->renderPartial("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/content", [
'model' => $model,
'profile' => $user->userProfile
]);
......@@ -98,7 +98,7 @@ class ContentMailBuilder extends AMailBuilder
protected function renderContentTitle(ModelLabelsInterface $model)
{
$controller = \Yii::$app->controller;
$ris = $controller->renderPartial("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_title", [
$ris = $controller->renderPartial("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_title", [
'title' => $model->getGrammar()->getModelLabel(),
]);
return $ris;
......@@ -112,7 +112,7 @@ class ContentMailBuilder extends AMailBuilder
{
$controller = \Yii::$app->controller;
$contents_number = count($resultset);
$ris = $controller->renderPartial("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_header", [
$ris = $controller->renderPartial("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_header", [
'contents_number' => $contents_number
]);
return $ris;
......@@ -125,7 +125,7 @@ class ContentMailBuilder extends AMailBuilder
protected function renderContentFooter(array $resultset, User $user)
{
$controller = \Yii::$app->controller;
$ris = $controller->renderPartial("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_footer", ['user' => $user]);
$ris = $controller->renderPartial("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/content_footer", ['user' => $user]);
return $ris;
}
......
......@@ -5,23 +5,23 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\core\interfaces\ModelGrammarInterface;
use elitedivision\amos\core\interfaces\ModelLabelsInterface;
use elitedivision\amos\core\user\User;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\models\ChangeStatusEmail;
use arter\amos\core\interfaces\ModelGrammarInterface;
use arter\amos\core\interfaces\ModelLabelsInterface;
use arter\amos\core\user\User;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\models\ChangeStatusEmail;
use Yii;
/**
* Class CustomMailBuilder
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
*/
class CustomMailBuilder extends AMailBuilder
{
......@@ -89,9 +89,9 @@ class CustomMailBuilder extends AMailBuilder
if ($email->template) {
$this->setTemplate($email->template);
} elseif ($email->toCreator) {
$this->setTemplate("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/validated");
$this->setTemplate("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/validated");
} else {
$this->setTemplate("@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/validator");
$this->setTemplate("@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/validator");
}
if (count($email->params)) {
$this->setParams($email->params);
......
......@@ -5,22 +5,22 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\core\interfaces\ModelGrammarInterface;
use elitedivision\amos\core\interfaces\ModelLabelsInterface;
use elitedivision\amos\core\user\User;
use elitedivision\amos\notificationmanager\AmosNotify;
use arter\amos\core\interfaces\ModelGrammarInterface;
use arter\amos\core\interfaces\ModelLabelsInterface;
use arter\amos\core\user\User;
use arter\amos\notificationmanager\AmosNotify;
use Yii;
/**
* Class ValidatedMailBuilder
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
*/
class ValidatedMailBuilder extends AMailBuilder
{
......@@ -50,7 +50,7 @@ class ValidatedMailBuilder extends AMailBuilder
$moduleNotify = Yii::$app->getModule('notify');
try {
$viewValidatorPath = "@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/validated";
$viewValidatorPath = "@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/validated";
if($moduleNotify && !empty($moduleNotify->viewPathEmailNotifyValidated) && !empty($moduleNotify->viewPathEmailNotifyValidated[get_class($model)])){
$viewValidatorPath = $moduleNotify->viewPathEmailNotifyValidated[get_class($model)];
}
......
......@@ -5,23 +5,23 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\base\builder;
namespace arter\amos\notificationmanager\base\builder;
use elitedivision\amos\core\interfaces\ModelGrammarInterface;
use elitedivision\amos\core\interfaces\ModelLabelsInterface;
use elitedivision\amos\core\user\User;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\utility\NotifyUtility;
use arter\amos\core\interfaces\ModelGrammarInterface;
use arter\amos\core\interfaces\ModelLabelsInterface;
use arter\amos\core\user\User;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\utility\NotifyUtility;
use Yii;
/**
* Class ValidatorsMailBuilder
* @package elitedivision\amos\notificationmanager\base\builder
* @package arter\amos\notificationmanager\base\builder
*/
class ValidatorsMailBuilder extends AMailBuilder
{
......@@ -54,7 +54,7 @@ class ValidatorsMailBuilder extends AMailBuilder
try {
$viewValidatorPath = "@vendor/elitedivision/amos-" . AmosNotify::getModuleName() . "/src/views/email/validator";
$viewValidatorPath = "@vendor/arter/amos-" . AmosNotify::getModuleName() . "/src/views/email/validator";
if($moduleNotify && !empty($moduleNotify->viewPathEmailNotifyValidator) && !empty($moduleNotify->viewPathEmailNotifyValidator[get_class($model)])){
$viewValidatorPath = $moduleNotify->viewPathEmailNotifyValidator[get_class($model)];
}
......
......@@ -5,19 +5,19 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\behaviors
* @package arter\amos\notificationmanager\behaviors
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\behaviors;
namespace arter\amos\notificationmanager\behaviors;
use elitedivision\amos\core\models\ModelsClassname;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\models\NotificationChannels;
use \elitedivision\amos\core\controllers\CrudController;
use elitedivision\amos\notificationmanager\models\NotificationSendEmail;
use elitedivision\amos\notificationmanager\models\NotificationsRead;
use arter\amos\core\models\ModelsClassname;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\models\NotificationChannels;
use \arter\amos\core\controllers\CrudController;
use arter\amos\notificationmanager\models\NotificationSendEmail;
use arter\amos\notificationmanager\models\NotificationsRead;
use Yii;
use yii\base\Behavior;
use yii\base\Exception;
......@@ -27,7 +27,7 @@ use yii\web\Application;
/**
* Class NotifyBehavior
* @package elitedivision\amos\core\behaviors
* @package arter\amos\core\behaviors
*/
class NotifyBehavior extends Behavior {
......@@ -264,7 +264,7 @@ class NotifyBehavior extends Behavior {
$notify->updated_at = null;
}
$canSave = true;
if($model instanceof \elitedivision\amos\core\interfaces\NotificationPersonalizedQueryInterface){
if($model instanceof \arter\amos\core\interfaces\NotificationPersonalizedQueryInterface){
$canSave = $model->canSaveNotification();
}
if($canSave) {
......
......@@ -4,28 +4,28 @@
* OPEN 2.0
*
*
* @package elitedivision\amos\notificationmanager\commands
* @package arter\amos\notificationmanager\commands
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\notificationmanager\commands;
use elitedivision\amos\admin\AmosAdmin;
use elitedivision\amos\admin\base\ConfigurationManager;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\user\User;
use elitedivision\amos\cwh\AmosCwh;
use elitedivision\amos\notificationmanager\AmosNotify;
use elitedivision\amos\notificationmanager\base\builder\AMailBuilder;
use elitedivision\amos\notificationmanager\base\BuilderFactory;
use elitedivision\amos\notificationmanager\models\base\NotificationSendEmail;
use elitedivision\amos\notificationmanager\models\Notification;
use elitedivision\amos\notificationmanager\models\NotificationChannels;
use elitedivision\amos\notificationmanager\models\NotificationConf;
use elitedivision\amos\notificationmanager\models\NotificationsConfOpt;
use elitedivision\amos\notificationmanager\models\NotificationsRead;
use elitedivision\amos\notificationmanager\utility\NotifyUtility;
namespace arter\amos\notificationmanager\commands;
use arter\amos\admin\AmosAdmin;
use arter\amos\admin\base\ConfigurationManager;
use arter\amos\admin\models\UserProfile;
use arter\amos\community\models\Community;
use arter\amos\core\user\User;
use arter\amos\cwh\AmosCwh;
use arter\amos\notificationmanager\AmosNotify;
use arter\amos\notificationmanager\base\builder\AMailBuilder;
use arter\amos\notificationmanager\base\BuilderFactory;
use arter\amos\notificationmanager\models\base\NotificationSendEmail;
use arter\amos\notificationmanager\models\Notification;
use arter\amos\notificationmanager\models\NotificationChannels;
use arter\amos\notificationmanager\models\NotificationConf;
use arter\amos\notificationmanager\models\NotificationsConfOpt;
use arter\amos\notificationmanager\models\NotificationsRead;
use arter\amos\notificationmanager\utility\NotifyUtility;
use Exception;
use Yii;
use yii\console\Controller;
......@@ -35,7 +35,7 @@ use yii\log\Logger;
/**
* Class NotifierController
* @package elitedivision\amos\notificationmanager\commands
* @package arter\amos\notificationmanager\commands
*/
class NotifierController extends Controller
{
......@@ -295,11 +295,11 @@ class NotifierController extends Controller
}
if (isset($cwhModule)) {
$modelsEnabled = \elitedivision\amos\cwh\models\CwhConfigContents::find()->addSelect('classname')->column();
$modelsEnabled = \arter\amos\cwh\models\CwhConfigContents::find()->addSelect('classname')->column();
$andWhere = "";
$i = 0;
foreach ($modelsEnabled as $classname) {
$cwhActiveQuery = new \elitedivision\amos\cwh\query\CwhActiveQuery($classname, [
$cwhActiveQuery = new \arter\amos\cwh\query\CwhActiveQuery($classname, [
'queryBase' => $classname::find(),
'userId' => $uid
]);
......@@ -309,7 +309,7 @@ class NotifierController extends Controller
$tableNews = Yii::$app->db->schema->getTableSchema('news');
$tableCategoryNews = Yii::$app->db->schema->getTableSchema('news_categorie');
if (class_exists($classname) && $tableNews && $tableCategoryNews && isset($tableCategoryNews->columns['notify_category'])) {
if ($classname == \elitedivision\amos\news\models\News::className()) {
if ($classname == \arter\amos\news\models\News::className()) {
/** @var Notification $notificationModel */
$notificationModel = $this->notifyModule->createModel('Notification');
$newsNotNotificationNotToSend = $notificationModel::find()
......@@ -322,7 +322,7 @@ class NotifierController extends Controller
}
$model = new $classname;
if($model instanceof \elitedivision\amos\core\interfaces\NotificationPersonalizedQueryInterface){
if($model instanceof \arter\amos\core\interfaces\NotificationPersonalizedQueryInterface){