From 848b491a90a2cd66b6a2167eb7098e4787895a61 Mon Sep 17 00:00:00 2001
From: Ruslan Bakiev <572431+veikab@users.noreply.github.com>
Date: Thu, 9 Apr 2026 18:39:16 +0700
Subject: [PATCH] Collapse catalog settings list
---
app/pages/catalog-settings.vue | 40 +++++++++++++++++++++++++++++-----
1 file changed, 34 insertions(+), 6 deletions(-)
diff --git a/app/pages/catalog-settings.vue b/app/pages/catalog-settings.vue
index 2662f69..932762a 100644
--- a/app/pages/catalog-settings.vue
+++ b/app/pages/catalog-settings.vue
@@ -165,6 +165,18 @@ function parseTextOptionList(values: string[]) {
return normalizeOptionList(values, 'text');
}
+function enabledCustomizationCount(form: CatalogSettingForm) {
+ return [
+ form.allowCustomLength,
+ form.allowCustomSleeveBrand,
+ form.allowCustomLabel,
+ ].filter(Boolean).length;
+}
+
+function filledParameterGroupCount(form: CatalogSettingForm) {
+ return OPTION_GROUPS.filter((group) => form[group.key].length > 0).length;
+}
+
watch(
settings,
(items) => {
@@ -235,15 +247,31 @@ async function saveAllSettings() {
Типы товаров пока не появились в каталоге.
-
-
+
-
-
{{ item.productType }}
+
+
+
{{ item.productType }}
+
+ {{ filledParameterGroupCount(formFor(item)) }} параметров, {{ enabledCustomizationCount(formFor(item)) }} кастомные возможности
+
+
+
+
+
+
-
+