mirror of
https://github.com/Nikolay-Shirokov/cc-1c-skills.git
synced 2026-08-18 01:00:24 +03:00
refactor(mxl-compile,mxl-decompile): ключ ячейки control → controlType
Тег ячейки <control> и тег формата <controlType> в выгрузке — разные вещи: первый несёт сериализованные настройки элемента управления, второй GUID его вида. Ключ DSL описывал второй, а назывался как первый, и при поддержке настроек отображение стало бы перекрёстным. Свести их в один ключ нельзя: <controlType> живёт в палитре и разделяется ячейками с одинаковым оформлением, а настройки принадлежат конкретной ячейке. Синоним не заводим — он занял бы ровно то имя, которое освобождается. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
7f743b18a9
commit
aaeb752cf1
@@ -5,10 +5,10 @@
|
||||
"areas": [
|
||||
{
|
||||
"name": "Ввод",
|
||||
"rows": [{ "cells": [{ "col": 1, "valueType": "Boolean", "control": "кнопка" }] }]
|
||||
"rows": [{ "cells": [{ "col": 1, "valueType": "Boolean", "controlType": "кнопка" }] }]
|
||||
}
|
||||
]
|
||||
},
|
||||
"params": { "outputPath": "Template.xml" },
|
||||
"expectError": "Unknown 'control' value \"кнопка\" (area \"Ввод\"). Allowed: input, checkbox, none or a GUID"
|
||||
"expectError": "Unknown 'controlType' value \"кнопка\" (area \"Ввод\"). Allowed: input, checkbox, none or a GUID"
|
||||
}
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
{
|
||||
"name": "Ошибка: control без valueType",
|
||||
"name": "Ошибка: controlType без valueType",
|
||||
"input": {
|
||||
"columns": 1,
|
||||
"areas": [
|
||||
{
|
||||
"name": "Ввод",
|
||||
"rows": [{ "cells": [{ "col": 1, "control": "checkbox" }] }]
|
||||
"rows": [{ "cells": [{ "col": 1, "controlType": "checkbox" }] }]
|
||||
}
|
||||
]
|
||||
},
|
||||
"params": { "outputPath": "Template.xml" },
|
||||
"expectError": "Cell 'control' requires 'valueType' (area \"Ввод\")"
|
||||
"expectError": "Cell 'controlType' requires 'valueType' (area \"Ввод\")"
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
]},
|
||||
{ "cells": [
|
||||
{ "col": 1, "valueType": "Boolean" },
|
||||
{ "col": 2, "valueType": "Boolean", "control": "checkbox" }
|
||||
{ "col": 2, "valueType": "Boolean", "controlType": "checkbox" }
|
||||
]},
|
||||
{ "cells": [
|
||||
{ "col": 1, "valueType": "String(10)" },
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
{ "valueType": "Number(15,3,any)" },
|
||||
{ "valueType": "Строка(10)" },
|
||||
{ "valueType": "String(10,variable)" },
|
||||
{ "valueType": "Булево", "control": "Поле Флажка" }
|
||||
{ "valueType": "Булево", "controlType": "Поле Флажка" }
|
||||
]
|
||||
]
|
||||
}
|
||||
|
||||
@@ -9,8 +9,8 @@
|
||||
"rows": [
|
||||
{ "cells": [
|
||||
{ "col": 1, "valueType": "" },
|
||||
{ "col": 2, "valueType": "Number(15,3)", "control": "none" },
|
||||
{ "col": 3, "valueType": "Boolean", "control": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee" },
|
||||
{ "col": 2, "valueType": "Number(15,3)", "controlType": "none" },
|
||||
{ "col": 3, "valueType": "Boolean", "controlType": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee" },
|
||||
{ "col": 4, "valueType": "String(50)", "style": "bordered" }
|
||||
]},
|
||||
{ "rowStyle": "bordered", "cells": [
|
||||
|
||||
@@ -12,11 +12,11 @@
|
||||
{ "cells": [
|
||||
{ "col": 1, "valueType": "Number(15,3,nonneg)" },
|
||||
{ "col": 2, "valueType": "String(10,fixed)" },
|
||||
{ "col": 3, "valueType": "Boolean", "control": "checkbox" }
|
||||
{ "col": 3, "valueType": "Boolean", "controlType": "checkbox" }
|
||||
]},
|
||||
{ "cells": [
|
||||
{ "col": 1, "valueType": "" },
|
||||
{ "col": 2, "valueType": "Number(10,2)", "control": "none" },
|
||||
{ "col": 2, "valueType": "Number(10,2)", "controlType": "none" },
|
||||
{ "col": 3, "valueType": "Boolean + CatalogRef.Валюты + String + DateTime" }
|
||||
]},
|
||||
{ "cells": [
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"areas": [
|
||||
{
|
||||
"name": "Ввод",
|
||||
"rows": [[{ "valueType": "Number(15,3,nonneg)" }, { "valueType": "String(10,fixed)" }, { "valueType": "Boolean", "control": "checkbox" }], [{ "valueType": "" }, { "valueType": "Number(10,2)", "control": "none" }, { "valueType": "Boolean + CatalogRef.Валюты + String + DateTime" }], [{ "valueType": "AnyRef" }, { "valueType": "Number(10,2)", "param": "Сумма", "detail": "Расшифровка" }]]
|
||||
"rows": [[{ "valueType": "Number(15,3,nonneg)" }, { "valueType": "String(10,fixed)" }, { "valueType": "Boolean", "controlType": "checkbox" }], [{ "valueType": "" }, { "valueType": "Number(10,2)", "controlType": "none" }, { "valueType": "Boolean + CatalogRef.Валюты + String + DateTime" }], [{ "valueType": "AnyRef" }, { "valueType": "Number(10,2)", "param": "Сумма", "detail": "Расшифровка" }]]
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user