From a57d779cafc739ece9176d7ff8db73bd349fc1ed Mon Sep 17 00:00:00 2001 From: themohooks <81331307+themohooks@users.noreply.github.com> Date: Tue, 11 Feb 2025 14:20:32 +0300 Subject: [PATCH] set comment & new reason for decline --- app/Controllers/Api/Admin/Images/SetVisibility.php | 3 +++ app/Models/Photo.php | 3 +++ views/pages/Admin/Photo.php | 10 ++++++++++ views/pages/Profile/LK/History.php | 3 +++ 4 files changed, 19 insertions(+) diff --git a/app/Controllers/Api/Admin/Images/SetVisibility.php b/app/Controllers/Api/Admin/Images/SetVisibility.php index 9797635..b442fde 100644 --- a/app/Controllers/Api/Admin/Images/SetVisibility.php +++ b/app/Controllers/Api/Admin/Images/SetVisibility.php @@ -18,6 +18,9 @@ class SetVisibility if (!array_key_exists('declineReason', $data)) { $data['declineReason'] = null; } + if ($_POST['comment'] != null) { + $data['declineComment'] = $_POST['comment']; + } $data['declineReason'] = $_GET['decline_reason']; $updatedJsonString = json_encode($data); diff --git a/app/Models/Photo.php b/app/Models/Photo.php index b04a31a..596a888 100644 --- a/app/Models/Photo.php +++ b/app/Models/Photo.php @@ -37,6 +37,9 @@ class Photo { case 5: return 'Расчленёнка'; break; + case 6: + return 'Файл сломан'; + break; default: return 'Не подходит для сайта'; break; diff --git a/views/pages/Admin/Photo.php b/views/pages/Admin/Photo.php index db0adf7..bd54f80 100644 --- a/views/pages/Admin/Photo.php +++ b/views/pages/Admin/Photo.php @@ -123,7 +123,17 @@ use \App\Models\User; Расчленёнка +
+ + +
+
+ + +