fix(settings): code-managed keys in advanced panel only

Align can_edit lists with deploy SQL: runtime Montzar/price keys stay in
tenant advanced settings (read-only), not super admin catalog.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-19 19:55:41 +03:30
co-authored by Cursor
parent 1a8001fb75
commit 6da3f84a89
2 changed files with 35 additions and 10 deletions
@@ -214,6 +214,7 @@ import {
formatValueForSave,
helpText,
isSettingVisible,
isCodeManagedSettingKey,
isSettingLocked,
isSettingActive,
isSwitchOn,
@@ -308,6 +309,7 @@ const filteredRows = computed(() =>
(baseData.value || []).filter((row) => {
if (row.id == null || !matchesFilter(row)) return false
if (!isSettingVisible(row.key)) return false
if (isCodeManagedSettingKey(row.key) && !isSystemMode.value) return false
if (isSystemMode.value) return true
return isEditable(row)
})
@@ -427,6 +429,7 @@ function rowColSpan(row: Const): number {
}
function isReadonly(row: Const): boolean {
if (isCodeManagedSettingKey(row.key)) return true
if (isSystemMode.value) return false
return isSettingLocked(row.can_edit)
}