From 99dd41be056c4f45bff2221505de349acf37566e Mon Sep 17 00:00:00 2001 From: Sasha Rybkin Date: Mon, 26 Apr 2021 17:46:44 +0300 Subject: [PATCH] fix --- models/MoleTask.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/models/MoleTask.php b/models/MoleTask.php index 7f07ace..891535e 100644 --- a/models/MoleTask.php +++ b/models/MoleTask.php @@ -143,7 +143,8 @@ class MoleTask extends \yii\db\ActiveRecord $model->dateAdd = $dateAdd ?: date('Y-m-d H:i:s'); $model->project = $project ?: Yii::$app->getModule('cron')->project; $model->module = $module; - $model->type = stripos($controller, '.') ? $controller : ($model->project . '.' . $model->controller); // для совместимости + $model->type = ((empty($model->module) ? $model->project : $model->module) . '.' . $model->controller); // для совместимости + $model->isReady = 1; return $model->save(); }