mirror of
https://github.com/Nikolay-Shirokov/cc-1c-skills.git
synced 2026-06-16 18:53:18 +03:00
7c765137db
Крупнейший левередж-кластер. Companion-панели элемента (AutoCommandBar/ContextMenu)
теперь несут контент как СВОЙСТВА:
- commandBar → <AutoCommandBar> (командная панель)
- contextMenu → <ContextMenu> (контекстное меню)
Значение: массив = shorthand для { children }; объект { autofill?, horizontalAlign?,
children[] }. children — обычная грамматика button/buttonGroup/popup.
Forgiving-синонимы (commandBar ← autoCommandBar/AutoCommandBar/autoCmdBar/cmdBar/
КоманднаяПанель; contextMenu ← ContextMenu/КонтекстноеМеню). Разведение «тип-элемент
vs панель-свойство» — по ТИПУ значения: строка = элемент-тип в дереве (cmdBar:"Имя"),
объект/массив = companion-панель этого элемента. Тип-синонимы применяются только к
строковому значению. Механизм общий (любой элемент), декомпилятор захватывает в
Decompile-Element, компилятор — Emit-CompanionPanel.
Новый ключ кнопки commandName — глобальная команда «как есть» (CommonCommand.X,
Catalog.X.Command.Y) без обёртки Form. (раньше попадала в command и ошибочно
оборачивалась в Form.Command.). stdCommand/command без изменений.
Декомпилятор: для дин-список-таблицы пустой AutoCommandBar(autofill=false) не пишет
commandBar (восстановит heuristic) — без шума. tableAutofill остаётся shorthand,
commandBar имеет приоритет.
TOTAL diff lines выборки 2.17: 7560 → 5293 (-2267), match 11 → 13,
cascade LOST 3414 → 1805. Table>ContextMenu/Table>AutoCommandBar ушли из топа impact.
Снапшот table сертифицирован в 1С (8.3.24); регресс form-compile 33/33 зелёный
на ps + python. decompile v0.29, compile v1.48.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
49 lines
2.0 KiB
JSON
49 lines
2.0 KiB
JSON
{
|
|
"name": "Форма с таблицей",
|
|
"preRun": [
|
|
{
|
|
"script": "meta-compile/scripts/meta-compile",
|
|
"input": { "type": "DataProcessor", "name": "Таблица" },
|
|
"args": { "-JsonPath": "{inputFile}", "-OutputDir": "{workDir}" }
|
|
},
|
|
{
|
|
"script": "form-add/scripts/form-add",
|
|
"args": { "-ObjectPath": "{workDir}/DataProcessors/Таблица.xml", "-FormName": "Форма" }
|
|
}
|
|
],
|
|
"params": { "outputPath": "DataProcessors/Таблица/Forms/Форма/Ext/Form.xml" },
|
|
"validatePath": "DataProcessors/Таблица/Forms/Форма/Ext/Form.xml",
|
|
"input": {
|
|
"title": "Просмотр данных",
|
|
"elements": [
|
|
{ "table": "Данные", "path": "Данные", "changeRowSet": true, "titleLocation": "top",
|
|
"viewStatusLocation": "None", "searchControlLocation": "None",
|
|
"excludedCommands": ["Add", "Delete", "MoveUp", "MoveDown"],
|
|
"commandBar": { "autofill": false, "children": [
|
|
{ "button": "ПанельОбновить", "command": "Обновить" }
|
|
]},
|
|
"contextMenu": { "children": [
|
|
{ "buttonGroup": "МенюГруппа", "children": [
|
|
{ "button": "МенюОбновить", "command": "Обновить" }
|
|
]}
|
|
]},
|
|
"columns": [
|
|
{ "input": "Дата", "path": "Данные.Дата" },
|
|
{ "input": "Сумма", "path": "Данные.Сумма" },
|
|
{ "input": "Комментарий", "path": "Данные.Комментарий" }
|
|
]}
|
|
],
|
|
"attributes": [
|
|
{ "name": "Объект", "type": "DataProcessorObject.Таблица", "main": true },
|
|
{ "name": "Данные", "type": "ValueTable", "columns": [
|
|
{ "name": "Дата", "type": "date" },
|
|
{ "name": "Сумма", "type": "decimal(15,2)" },
|
|
{ "name": "Комментарий", "type": "string(200)" }
|
|
]}
|
|
],
|
|
"commands": [
|
|
{ "name": "Обновить", "action": "ОбновитьОбработка" }
|
|
]
|
|
}
|
|
}
|