diff --git a/Module.php b/Module.php index c35c6bd..6f29560 100755 --- a/Module.php +++ b/Module.php @@ -14,21 +14,19 @@ class Module extends \yii\base\Module { - - /** * @var string module name */ public static $name = 'artbox-comment'; /** - * User identity class, default to common\models\User + * User identity class, default to artweb\artbox\comment\models\User * @var string|null */ public $userIdentityClass = NULL; /** - * Comment model class, default to common\modules\models\CommentModel + * Comment model class, default to artweb\artbox\comment\modules\models\CommentModel * @var string comment model class */ public $commentModelClass = NULL; diff --git a/assets/CommentAsset.php b/assets/CommentAsset.php index dff12ca..c0e0ea7 100755 --- a/assets/CommentAsset.php +++ b/assets/CommentAsset.php @@ -39,4 +39,5 @@ 'yii\web\JqueryAsset', 'yii\web\YiiAsset', ]; - } \ No newline at end of file + } + \ No newline at end of file diff --git a/behaviors/ParentBehavior.php b/behaviors/ParentBehavior.php index 840c624..eab7c88 100755 --- a/behaviors/ParentBehavior.php +++ b/behaviors/ParentBehavior.php @@ -38,4 +38,5 @@ } } } - } \ No newline at end of file + } + \ No newline at end of file diff --git a/composer.json b/composer.json index b8aa6ad..cf3cbf7 100644 --- a/composer.json +++ b/composer.json @@ -5,7 +5,7 @@ "require": { "php": ">=7.0", "yiisoft/yii2": "*", - "developeruz/yii2-db-rbac": "*" + "artweb/artbox": "dev-master" }, "autoload": { "psr-4": { diff --git a/models/CommentModel.php b/models/CommentModel.php index e93533f..a639515 100755 --- a/models/CommentModel.php +++ b/models/CommentModel.php @@ -1,7 +1,6 @@ ParentBehavior::className(), ], - [ - 'class' => RatingBehavior::className(), - ], - /* Notification: uncomment to enable notifications. - [ - 'class' => NotifyBehavior::className(), - ], - */ ]; } @@ -271,4 +262,5 @@ ] ); } - } \ No newline at end of file + } + \ No newline at end of file diff --git a/models/RatingModel.php b/models/RatingModel.php index 152a4e3..6542ca9 100755 --- a/models/RatingModel.php +++ b/models/RatingModel.php @@ -2,7 +2,6 @@ namespace artweb\artbox\comment\models; - use common\models\User; use Yii; use yii\behaviors\BlameableBehavior; use yii\behaviors\TimestampBehavior; @@ -11,6 +10,8 @@ /** * This is the model class for table "artbox_comment_rating". * + * @todo Refactor User to Identity + * * @property integer $artbox_comment_rating_id * @property string $created_at * @property string $updated_at @@ -18,7 +19,6 @@ * @property integer $value * @property string $model * @property integer $model_id - * @property User $user */ class RatingModel extends ActiveRecord { @@ -79,14 +79,6 @@ ]; } - /** - * @return \yii\db\ActiveQuery - */ - public function getUser() - { - return $this->hasOne(User::className(), [ 'id' => 'user_id' ]); - } - public function getModel() { $model = $this->model; -- libgit2 0.21.4