You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@atlas.apache.org by ni...@apache.org on 2020/01/22 12:08:58 UTC

[atlas] branch master updated: ATLAS-3592 : UI: Ignore any empty values for Date type attribute in Entity property table

This is an automated email from the ASF dual-hosted git repository.

nixon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/atlas.git


The following commit(s) were added to refs/heads/master by this push:
     new 4d44690  ATLAS-3592 : UI: Ignore any empty values for Date type attribute in Entity property table
4d44690 is described below

commit 4d44690a79478e6a0eb5793a815215c131e4f896
Author: kevalbhatt <kb...@apache.org>
AuthorDate: Wed Jan 22 16:58:04 2020 +0530

    ATLAS-3592 : UI: Ignore any empty values for Date type attribute in Entity property table
    
    Signed-off-by: nixonrodrigues <ni...@apache.org>
---
 dashboardv2/public/js/utils/CommonViewFunction.js | 2 +-
 dashboardv3/public/js/utils/CommonViewFunction.js | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dashboardv2/public/js/utils/CommonViewFunction.js b/dashboardv2/public/js/utils/CommonViewFunction.js
index ad97e0a..b9896a9 100644
--- a/dashboardv2/public/js/utils/CommonViewFunction.js
+++ b/dashboardv2/public/js/utils/CommonViewFunction.js
@@ -258,7 +258,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Enum
             if (defEntity && defEntity.typeName) {
                 var defEntityType = defEntity.typeName.toLocaleLowerCase();
                 if (defEntityType === 'date') {
-                    keyValue = new Date(keyValue);
+                    keyValue = keyValue > 0 ? new Date(keyValue) : "";
                 } else if (_.isObject(keyValue)) {
                     keyValue = extractObject({ "keyValue": keyValue, "key": key, 'defEntity': defEntity });
                 }
diff --git a/dashboardv3/public/js/utils/CommonViewFunction.js b/dashboardv3/public/js/utils/CommonViewFunction.js
index 225b6ee..f83aa0a 100644
--- a/dashboardv3/public/js/utils/CommonViewFunction.js
+++ b/dashboardv3/public/js/utils/CommonViewFunction.js
@@ -258,7 +258,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Enum
             if (defEntity && defEntity.typeName) {
                 var defEntityType = defEntity.typeName.toLocaleLowerCase();
                 if (defEntityType === 'date') {
-                    keyValue = new Date(keyValue);
+                    keyValue = keyValue > 0 ? new Date(keyValue) : "";
                 } else if (_.isObject(keyValue)) {
                     keyValue = extractObject({ "keyValue": keyValue, "key": key, 'defEntity': defEntity });
                 }