From b7b5ad4d3e3cc332593cc078f4108a36dc38fb54 Mon Sep 17 00:00:00 2001
From: UladzislauKutarkin
<72550466+UladzislauKutarkin@users.noreply.github.com>
Date: Wed, 21 Feb 2024 20:48:30 +0400
Subject: [PATCH] UIPQB-73: Result Viewer shows current date if date column is
not present (#84)
---
CHANGELOG.md | 1 +
src/QueryBuilder/ResultViewer/helpers.js | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index fe9ffb34..28bc3078 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,7 @@
* [UIPQB-54](https://issues.folio.org/browse/UIPQB-54) Add support for array fields in query results.
* [UIPQB-70](https://issues.folio.org/browse/UIPQB-70) Array fields support verification.
* [UIPQB-80](https://issues.folio.org/browse/UIPQB-80) Add operators for NumberType and adjust operators for IntegerType.
+* [UIPQB-73](https://folio-org.atlassian.net/browse/UIPQB-73) Result Viewer shows current date if date column is not present.
## [1.0.0](https://github.com/folio-org/ui-plugin-query-builder/tree/v1.0.0) (2023-10-12)
diff --git a/src/QueryBuilder/ResultViewer/helpers.js b/src/QueryBuilder/ResultViewer/helpers.js
index fbd48af1..04f70c75 100644
--- a/src/QueryBuilder/ResultViewer/helpers.js
+++ b/src/QueryBuilder/ResultViewer/helpers.js
@@ -23,7 +23,7 @@ export const getTableMetadata = (entityType) => {
formatted[value] = (item) => {
if (dataType === DATA_TYPES.DateType) {
- return ;
+ return item[value] ? : '';
} else if (dataType === DATA_TYPES.ArrayType) {
return item[value]?.join(' | ');
} else {