diff --git a/src/views/Project.vue b/src/views/Project.vue index 186ec4e..98dc7ab 100644 --- a/src/views/Project.vue +++ b/src/views/Project.vue @@ -181,7 +181,11 @@ function getCellValue(userstory: Userstory, header: TableHeader): string | numbe return userstory.status_extra_info?.name || userstory.status?.toString() || ""; } const value = userstory[header.key as keyof Userstory]; - return value ?? ""; + + if (value === null) return null; + if (typeof value === "string" || typeof value === "number") return value; + if (value === undefined) return ""; + return String(value); } else { if (header.attributeId === undefined) return "N/A (no attr ID)"; @@ -189,8 +193,13 @@ function getCellValue(userstory: Userstory, header: TableHeader): string | numbe if (attributes) { // Ключи для кастомных полей приходят как строки const attrValue = attributes[header.attributeId.toString()]; - return attrValue ?? ""; + + if (attrValue === null) return null; + if (typeof attrValue === "string" || typeof attrValue === "number") return attrValue; + if (attrValue === undefined) return ""; + return String(attrValue); } + if (isLoadingAttributesForAnyStory.value && !dataStore.userstoryAttributesMap.has(userstory.id)) { return "..."; } @@ -213,7 +222,6 @@ function getCellValue(userstory: Userstory, header: TableHeader): string | numbe } table thead tr th { font-weight: bold; - /* cursor: pointer; is added inline for now */ } table thead tr th:hover { background-color: #f2f2f2;