diff --git a/behaviors/CommentBehavior.php b/behaviors/CommentBehavior.php index 66641fd..63a8aa8 100755 --- a/behaviors/CommentBehavior.php +++ b/behaviors/CommentBehavior.php @@ -39,7 +39,7 @@ * @var bool */ private $cacheRating = false; - + /** * @inheritdoc */ diff --git a/models/CommentModel.php b/models/CommentModel.php index a639515..9a0b6ae 100755 --- a/models/CommentModel.php +++ b/models/CommentModel.php @@ -3,6 +3,7 @@ use artweb\artbox\comment\behaviors\ParentBehavior; use artweb\artbox\comment\models\interfaces\CommentInterface; + use yii\base\InvalidConfigException; use yii\behaviors\AttributeBehavior; use yii\behaviors\BlameableBehavior; use yii\behaviors\TimestampBehavior; @@ -43,6 +44,8 @@ public $entityId; + private $entityModel; + public function scenarios() { $scenarios = parent::scenarios(); @@ -63,7 +66,7 @@ ]; return $scenarios; } - + public static function tableName() { return '{{%artbox_comment}}'; diff --git a/models/CommentModelSearch.php b/models/CommentModelSearch.php index ece993b..094a721 100755 --- a/models/CommentModelSearch.php +++ b/models/CommentModelSearch.php @@ -120,6 +120,7 @@ 'status', 'entity', 'entity_id', + 'created_at', ], 'defaultOrder' => [ 'created_at' => SORT_DESC, diff --git a/widgets/CommentWidget.php b/widgets/CommentWidget.php index 01a43af..979d75c 100755 --- a/widgets/CommentWidget.php +++ b/widgets/CommentWidget.php @@ -6,6 +6,7 @@ use artweb\artbox\comment\models\interfaces\CommentInterface; use artweb\artbox\comment\models\RatingModel; use artweb\artbox\comment\Module; + use artweb\artbox\models\Customer; use Yii; use yii\base\InvalidConfigException; use yii\base\Model; -- libgit2 0.21.4