Fixed broken commit

Previous commit runs only in dev
This commit is contained in:
2025-06-01 17:16:35 +03:00
parent 60ac3fe4d1
commit 55248873c5

View File

@@ -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;