diff --git a/Admin/Install/db.json b/Admin/Install/db.json index 28ea0e9..a328605 100755 --- a/Admin/Install/db.json +++ b/Admin/Install/db.json @@ -8,6 +8,11 @@ "null": false, "primary": true, "autoincrement": true + }, + "comments_list_status": { + "name": "comments_list_status", + "type": "TINYINT", + "null": false } } }, diff --git a/Models/CommentListMapper.php b/Models/CommentListMapper.php index 26ea0b1..f342a14 100755 --- a/Models/CommentListMapper.php +++ b/Models/CommentListMapper.php @@ -34,6 +34,7 @@ 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'], ]; /** diff --git a/Theme/Backend/Components/Comment/CreateView.php b/Theme/Backend/Components/Comment/CreateView.php new file mode 100644 index 0000000..6f84efd --- /dev/null +++ b/Theme/Backend/Components/Comment/CreateView.php @@ -0,0 +1,59 @@ +setTemplate('/Modules/Comments/Theme/Backend/Components/Comment/create'); + } + + /** + * {@inheritdoc} + */ + public function render(...$data) : string + { + $this->list = $data[0]; + + return parent::render(); + } +} diff --git a/Theme/Backend/Components/Comment/ListView.php b/Theme/Backend/Components/Comment/ListView.php new file mode 100644 index 0000000..125d90e --- /dev/null +++ b/Theme/Backend/Components/Comment/ListView.php @@ -0,0 +1,59 @@ +setTemplate('/Modules/Comments/Theme/Backend/Components/Comment/list'); + } + + /** + * {@inheritdoc} + */ + public function render(...$data) : string + { + $this->list = $data[0]; + + return parent::render(); + } +} diff --git a/Theme/Backend/Components/Comment/create.tpl.php b/Theme/Backend/Components/Comment/create.tpl.php new file mode 100644 index 0000000..29a1ec6 --- /dev/null +++ b/Theme/Backend/Components/Comment/create.tpl.php @@ -0,0 +1,17 @@ + +
+
+
+
+
Create Comment
+
+ +
+
+
+
+
+
\ No newline at end of file diff --git a/Theme/Backend/Components/Comment/list.tpl.php b/Theme/Backend/Components/Comment/list.tpl.php new file mode 100644 index 0000000..c9529da --- /dev/null +++ b/Theme/Backend/Components/Comment/list.tpl.php @@ -0,0 +1,14 @@ +commentList->getComments(); +foreach ($comments as $comment) : ?> +
+
+
+
+ getContent(); ?> +
+
+
+
+ \ No newline at end of file diff --git a/Theme/Backend/comment-create.tpl.php b/Theme/Backend/comment-create.tpl.php deleted file mode 100755 index 38ce70a..0000000 --- a/Theme/Backend/comment-create.tpl.php +++ /dev/null @@ -1,119 +0,0 @@ -getData('nav')->render(); ?> - -
-
-
- -
-
-
- -
-
- -
- -
-
    -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
-
- -
-
    -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
-
- -
-
-
-
-
- -
-
- -
- -
- -
- -
-
-
-
-
- -
-
-
- -
-
-
-
-
-
-
-
diff --git a/Theme/Backend/comment-list.tpl.php b/Theme/Backend/comment-list.tpl.php deleted file mode 100755 index 403ba93..0000000 --- a/Theme/Backend/comment-list.tpl.php +++ /dev/null @@ -1,43 +0,0 @@ -l11nManager, $this->request, $this->response); -$footerView->setTemplate('/Web/Templates/Lists/Footer/PaginationBig'); -$footerView->setPages(20); -$footerView->setPage(1); - -echo $this->getData('nav')->render(); ?> -
- - - - - - - - $value) : ++$count; ?> - - -
getHtml('Documents') ?>
getHtml('Name') ?> - getHtml('Creator') ?> - getHtml('Created') ?> -
-
getHtml('Empty', '0', '0'); ?> - -
-