Include source-only forms in IDE rendering
CI / python (push) Has been cancelled
CI / rust (push) Has been cancelled

This commit is contained in:
2026-05-21 17:14:22 +03:00
parent 9f1f1a8ee1
commit 9dc35bae20
2 changed files with 88 additions and 2 deletions
+12 -1
View File
@@ -825,6 +825,14 @@ function ownerQualifiedNameForForm(formQualifiedName: string) {
return parts.length > 1 ? parts.slice(0, -1).join(".") : formQualifiedName;
}
function looksLikeObjectFormQualifiedName(qualifiedName: string) {
const parts = qualifiedName.split(".");
if (parts[0] === "ОбщаяФорма") {
return parts.length === 2;
}
return parts.length >= 3;
}
export async function getProjectWorkspaceData(projectId: string, apiUrl = resolveApiUrl(), selectedRoutine?: string | null, activeMode?: string | null) {
const selectedRoutineName = selectedRoutine?.trim() ?? null;
const workspaceMode = activeMode?.trim() || "overview";
@@ -862,7 +870,10 @@ export async function getProjectWorkspaceData(projectId: string, apiUrl = resolv
const selectedFormQualifiedName =
selectedTreeNode?.kind === "FORM"
? selectedTreeNode.qualified_name
: selectedRoutineName && selectedRoutineName.split(".").at(-1)?.toLocaleLowerCase("ru-RU").includes("форма")
: selectedRoutineName && (
selectedRoutineName.split(".").at(-1)?.toLocaleLowerCase("ru-RU").includes("форма") ||
looksLikeObjectFormQualifiedName(selectedRoutineName)
)
? selectedRoutineName
: null;
const selectedObjectName = selectedFormQualifiedName