From 0a7877ddbe7908d6a17089e1005308a945d3d21f Mon Sep 17 00:00:00 2001 From: Nikita Kiselev Date: Thu, 25 Dec 2025 20:43:12 +0300 Subject: [PATCH] feat: add customizable text for manager contact button - Add text_manager_button field to TextsDTO with getter method - Update SettingsSerializerService to validate and deserialize new field - Add text_manager_button field to admin settings store - Add input field in admin TextsView for configuring button text - Update SPA SettingsStore with default value including emoji - Replace hardcoded button text in Product.vue with configurable text - Remove SVG icon from manager button to allow emoji usage - Add default value with emoji to app.php configuration - Button text now customizable via admin panel Texts tab --- frontend/admin/src/stores/settings.js | 1 + frontend/admin/src/views/TextsView.vue | 4 ++++ frontend/spa/src/stores/SettingsStore.js | 1 + frontend/spa/src/views/Product.vue | 7 +------ .../upload/oc_telegram_shop/configs/app.php | 1 + .../oc_telegram_shop/src/DTO/Settings/TextsDTO.php | 11 ++++++++++- .../src/Services/SettingsSerializerService.php | 7 ++++++- 7 files changed, 24 insertions(+), 8 deletions(-) diff --git a/frontend/admin/src/stores/settings.js b/frontend/admin/src/stores/settings.js index 3fd30d0..79a58e1 100644 --- a/frontend/admin/src/stores/settings.js +++ b/frontend/admin/src/stores/settings.js @@ -57,6 +57,7 @@ export const useSettingsStore = defineStore('settings', { start_button: { text: '', }, + text_manager_button: '', }, sliders: { diff --git a/frontend/admin/src/views/TextsView.vue b/frontend/admin/src/views/TextsView.vue index c3d38e3..387d009 100644 --- a/frontend/admin/src/views/TextsView.vue +++ b/frontend/admin/src/views/TextsView.vue @@ -30,6 +30,10 @@ Текст на кнопке приветственного сообщения, которая открывает магазин. + + + Текст на кнопке для связи с менеджером на странице товара. Используется только при выборе режима "Кнопка связи с менеджером" в настройках витрины. +