diff --git a/Admin/Install/db.json b/Admin/Install/db.json index a328605..4a6f64c 100755 --- a/Admin/Install/db.json +++ b/Admin/Install/db.json @@ -9,8 +9,23 @@ "primary": true, "autoincrement": true }, - "comments_list_status": { - "name": "comments_list_status", + "comments_list_active": { + "name": "comments_list_active", + "type": "TINYINT", + "null": false + }, + "comments_list_allow_comment": { + "name": "comments_list_allow_comment", + "type": "TINYINT", + "null": false + }, + "comments_list_allow_voting": { + "name": "comments_list_allow_voting", + "type": "TINYINT", + "null": false + }, + "comments_list_allow_edit": { + "name": "comments_list_allow_edit", "type": "TINYINT", "null": false } diff --git a/Models/CommentList.php b/Models/CommentList.php index 8413f3a..9e0ffe9 100755 --- a/Models/CommentList.php +++ b/Models/CommentList.php @@ -46,7 +46,31 @@ class CommentList * @var bool * @since 1.0.0 */ - protected bool $isActive = true; + public bool $isActive = true; + + /** + * Is active + * + * @var bool + * @since 1.0.0 + */ + public bool $allowComment = true; + + /** + * Is active + * + * @var bool + * @since 1.0.0 + */ + public bool $allowVoting = true; + + /** + * Is active + * + * @var bool + * @since 1.0.0 + */ + public bool $allowEdit = true; /** * Get id. diff --git a/Models/CommentListMapper.php b/Models/CommentListMapper.php index 482357d..c908c59 100755 --- a/Models/CommentListMapper.php +++ b/Models/CommentListMapper.php @@ -34,7 +34,10 @@ final class CommentListMapper extends DataMapperAbstract */ protected static array $columns = [ 'comments_list_id' => ['name' => 'comments_list_id', 'type' => 'int', 'internal' => 'id'], - 'comments_list_status' => ['name' => 'comments_list_status', 'type' => 'bool', 'internal' => 'isActive'], + 'comments_list_active' => ['name' => 'comments_list_active', 'type' => 'bool', 'internal' => 'isActive'], + 'comments_list_allow_comment' => ['name' => 'comments_list_allow_comment', 'type' => 'bool', 'internal' => 'allowComment'], + 'comments_list_allow_voting' => ['name' => 'comments_list_allow_voting', 'type' => 'bool', 'internal' => 'allowVoting'], + 'comments_list_allow_edit' => ['name' => 'comments_list_allow_edit', 'type' => 'bool', 'internal' => 'allowEdit'], ]; /**