Updated flows tree
Deploy Frontend / build-and-deploy (push) Successful in 1m4s Details

This commit is contained in:
romanskijdev 2026-08-04 13:28:07 +03:00
parent aa50168138
commit 69d1c11f7d
1 changed files with 3 additions and 4 deletions

View File

@ -36,14 +36,13 @@ export function groupHierarchiesIntoChains(
const scopeObjectId = scopeType === 'topic' ? h.topic_id :
scopeType === 'category' ? h.topic_category_id : null
// Формируем ключ группы
const key = `${h.subordinate_id}-${h.department_id}-${scopeType}-${scopeObjectId || 'null'}`
// Формируем ключ группы (добавляем target_system)
const targetSystemPart = h.target_system || 'all'
const key = `${h.subordinate_id}-${h.department_id}-${scopeType}-${scopeObjectId || 'null'}-${targetSystemPart}`
if (!groups.has(key)) {
// Определяем название объекта области действия
let scopeObjectName = 'Все темы'
if (scopeType === 'category' && h.subordinate) {
// Будет заполнено позже из categories
scopeObjectName = `Категория #${scopeObjectId}`
} else if (scopeType === 'topic') {
scopeObjectName = `Тема #${scopeObjectId}`