diff --git a/src/Controller/BackendController.php b/src/Controller/BackendController.php index 567c2e7..4b41351 100644 --- a/src/Controller/BackendController.php +++ b/src/Controller/BackendController.php @@ -127,7 +127,14 @@ public function unreadGet(Application $app, Request $request) { $status = FeedbackStatus::UNREAD; - $stmt = $app['db']->prepare("SELECT * FROM `bolt_is_useful_feedback` WHERE `status` = :status"); + $sql = "SELECT `bolt_is_useful_feedback`.*,"; + $sql .= " `bolt_is_useful`.`contenttype`,"; + $sql .= " `bolt_is_useful`.`contentid`"; + $sql .= " FROM `bolt_is_useful_feedback`"; + $sql .= " LEFT JOIN `bolt_is_useful` ON `bolt_is_useful_feedback`.`is_useful_id` = `bolt_is_useful`.`id`"; + $sql .= " WHERE `status` = :status"; + + $stmt = $app['db']->prepare($sql); $stmt->bindParam('status', $status); $stmt->execute(); $feedback = $stmt->fetchAll(); diff --git a/src/Extension.php b/src/Extension.php index 7e98138..ec2f1ab 100644 --- a/src/Extension.php +++ b/src/Extension.php @@ -177,7 +177,7 @@ protected function registerAssets() ->setLate(true) ->setZone(Zone::BACKEND) ; - + return $assets; } diff --git a/templates/backend/_navigation.twig b/templates/backend/_navigation.twig index fb62ec1..d00a035 100644 --- a/templates/backend/_navigation.twig +++ b/templates/backend/_navigation.twig @@ -11,7 +11,7 @@
Page | IP | Date | Message | @@ -25,6 +26,12 @@ {% set statusReadLink = path('is_useful.feedback.status', { id: item.id, status: 'read' }) %} {% set statusDoneLink = path('is_useful.feedback.status', { id: item.id, status: 'done' }) %}
---|---|---|
+ + {{ record.title }} + + | {{ ip }} | {{ datetime }} |