From 5e692733b726d7c8840ed06c9978e3b24bd28c64 Mon Sep 17 00:00:00 2001 From: neo <397763@gmail.com> Date: Tue, 23 Jun 2026 17:23:24 +0500 Subject: [PATCH] =?UTF-8?q?fix:=20correct=20DrakonWidget=20node=20types=20?= =?UTF-8?q?(branch=E2=86=92action=E2=86=92question=E2=86=92end)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 85 ++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 54 insertions(+), 31 deletions(-) diff --git a/index.html b/index.html index 82a1c60..689278d 100644 --- a/index.html +++ b/index.html @@ -1354,20 +1354,62 @@ document.querySelectorAll('a[href^="#"]').forEach((a) => { // ============================================ // DRAKON DIAGRAM — DrakonWidget (view mode) // ============================================ +// DrakonWidget node types: end, action, question, branch, insertion, address, +// select, case, loopbegin, loopend, parbegin, parend, duration +// Flow direction: entry branch (branchId:0) → ... → end (terminator) + function initDrakonDiagram() { - // Business process: Client → Audit → Drakon diagram → Done + // Business process diagram — client onboarding flow var diagram = { name: "Наш процесс", items: { - "1": { type: "begin", content: "Начало" }, - "2": { type: "action", one: "3", content: "Брифинг клиента" }, - "3": { type: "action", one: "4", content: "Аудит процессов" }, - "4": { type: "question", one: "5", no: "6", content: "Понятно?" }, - "5": { type: "action", one: "8", content: "Создание схем ДРАКОН" }, - "6": { type: "action", one: "7", content: "Уточняем процесс" }, - "7": { type: "address", one: "4", content: "Возврат к этапу" }, - "8": { type: "action", one: "9", content: "Согласование" }, - "9": { type: "end", content: "Готово" } + // Entry point (arrow icon) + "1": { + type: "branch", + branchId: 0, + one: "2" + }, + // Step 1 + "2": { + type: "action", + one: "3", + content: "Брифинг клиента" + }, + // Step 2 + "3": { + type: "action", + one: "4", + content: "Аудит процессов" + }, + // Decision + "4": { + type: "question", + one: "5", + no: "6", + content: "Понятно?" + }, + // Yes path — proceed + "5": { + type: "action", + one: "7", + content: "Создание схем ДРАКОН" + }, + // No path — clarify + "6": { + type: "action", + one: "7", + content: "Уточняем процесс" + }, + // Merge + "7": { + type: "action", + one: "8", + content: "Согласование" + }, + // End — terminator + "8": { + type: "end" + } } }; @@ -1380,7 +1422,7 @@ function initDrakonDiagram() { theme: { lineWidth: 2, borderWidth: 0, - background: "#fafbfc", + background: "#ffffff", iconBorder: "#d1d5db", iconBack: "#ffffff", iconRadius: 6, @@ -1392,26 +1434,7 @@ function initDrakonDiagram() { font: "14px Inter, sans-serif", headerFont: "bold 15px Inter, sans-serif", yes: "Да", - no: "Нет", - icons: { - question: { - iconBack: "#fef3c7", - iconBorder: "#f59e0b", - color: "#92400e", - borderWidth: 1 - }, - begin: { - iconBack: "#dcfce7", - iconBorder: "#16a34a", - color: "#15803d", - borderWidth: 1 - }, - end: { - iconBack: "#f3f4f6", - iconBorder: "#9ca3af", - borderWidth: 1 - } - } + no: "Нет" } };