fix: валидация пустых parentRowIds в редакторе подсправочника

This commit is contained in:
2026-07-21 11:21:32 +03:00
parent e2f8a41029
commit b086ff4513

View File

@@ -288,6 +288,14 @@ export default function TableEditor() {
toast({ title: 'Выберите подсправочник', variant: 'destructive' });
return;
}
if (subdirectoryParentRowIds.size === 0) {
toast({
title: 'Не выбраны строки родителя',
description: 'Подсправочник не будет отображаться в форме. Отметьте хотя бы одну строку.',
variant: 'destructive',
});
return;
}
const payload = {
childTableId: childId,
parentColumnIndex: subdirectoryParentColumnIndex,