Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 54364200C4F for ; Sat, 18 Mar 2017 02:38:14 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 52BC7160B8C; Sat, 18 Mar 2017 01:38:14 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 52BF8160B80 for ; Sat, 18 Mar 2017 02:38:13 +0100 (CET) Received: (qmail 25199 invoked by uid 500); 18 Mar 2017 01:38:12 -0000 Mailing-List: contact commits-help@atlas.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@atlas.incubator.apache.org Delivered-To: mailing list commits@atlas.incubator.apache.org Received: (qmail 25190 invoked by uid 99); 18 Mar 2017 01:38:12 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 18 Mar 2017 01:38:12 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 16FDF18F174 for ; Sat, 18 Mar 2017 01:38:12 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -3.568 X-Spam-Level: X-Spam-Status: No, score=-3.568 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-0.001, SPF_NEUTRAL=0.652, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id Ma9UemINBDCY for ; Sat, 18 Mar 2017 01:38:09 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id C491A60CE2 for ; Sat, 18 Mar 2017 01:38:08 +0000 (UTC) Received: (qmail 17607 invoked by uid 99); 18 Mar 2017 01:31:27 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 18 Mar 2017 01:31:27 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 89589DFE1E; Sat, 18 Mar 2017 01:31:27 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: madhan@apache.org To: commits@atlas.incubator.apache.org Message-Id: <04f1768eba7c4843b1230186874e94ac@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: incubator-atlas git commit: ATLAS-1668: updated UI to exclude terms from tag UI elements Date: Sat, 18 Mar 2017 01:31:27 +0000 (UTC) archived-at: Sat, 18 Mar 2017 01:38:14 -0000 Repository: incubator-atlas Updated Branches: refs/heads/0.8-incubating 89b4c133a -> 46485ba13 ATLAS-1668: updated UI to exclude terms from tag UI elements Signed-off-by: Madhan Neethiraj (cherry picked from commit e0145ffd40c08054cea7073239541879447794b4) Project: http://git-wip-us.apache.org/repos/asf/incubator-atlas/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-atlas/commit/46485ba1 Tree: http://git-wip-us.apache.org/repos/asf/incubator-atlas/tree/46485ba1 Diff: http://git-wip-us.apache.org/repos/asf/incubator-atlas/diff/46485ba1 Branch: refs/heads/0.8-incubating Commit: 46485ba13cf8dce280389ba872d357b23ffcebd6 Parents: 89b4c13 Author: kevalbhatt Authored: Fri Mar 10 18:14:02 2017 +0530 Committer: Madhan Neethiraj Committed: Fri Mar 17 18:31:21 2017 -0700 ---------------------------------------------------------------------- .../AddTermToEntityLayoutView.js | 6 +++--- .../js/views/business_catalog/TreeLayoutView.js | 1 - .../public/js/views/search/SearchLayoutView.js | 8 ++++++-- .../js/views/search/SearchResultLayoutView.js | 2 +- .../public/js/views/tag/CreateTagLayoutView.js | 6 +++++- dashboardv2/public/js/views/tag/TagLayoutView.js | 19 +++++++++---------- .../public/js/views/tag/addTagModalView.js | 3 +++ 7 files changed, 27 insertions(+), 18 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/business_catalog/AddTermToEntityLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/business_catalog/AddTermToEntityLayoutView.js b/dashboardv2/public/js/views/business_catalog/AddTermToEntityLayoutView.js index dd45e48..0212efe 100644 --- a/dashboardv2/public/js/views/business_catalog/AddTermToEntityLayoutView.js +++ b/dashboardv2/public/js/views/business_catalog/AddTermToEntityLayoutView.js @@ -74,9 +74,9 @@ define(['require', } var obj = { termName: termName, - guid: that.multiple[i].id.id, - deletedEntity: Enums.entityStateReadOnly[that.multiple[i].id.state], - entityName: that.multiple[i].model.get('name') + guid: that.multiple[i].id, + deletedEntity: Enums.entityStateReadOnly[that.multiple[i].model.status], + entityName: Utils.getName(that.multiple[i].model) }; if (obj.deletedEntity) { Utils.notifyError({ http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js b/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js index 0bca0df..998c8f4 100644 --- a/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js +++ b/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js @@ -377,7 +377,6 @@ define(['require', } var name = Utils.checkTagOrTerm(model.get('name'), true); if (name.name) { - // data-name="''" Space is required for DSL search Input if (that.viewBased) { parentLi = '
' + name.name + ''; } else { http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/search/SearchLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/search/SearchLayoutView.js b/dashboardv2/public/js/views/search/SearchLayoutView.js index d3a9030..e68f8c0 100644 --- a/dashboardv2/public/js/views/search/SearchLayoutView.js +++ b/dashboardv2/public/js/views/search/SearchLayoutView.js @@ -172,11 +172,15 @@ define(['require', return Utils.getName(model.toJSON(), 'name').toLowerCase(); } this.typeHeaders.fullCollection.sort().each(function(model) { + var name = Utils.getName(model.toJSON(), 'name'); if (model.get('category') == 'ENTITY') { - typeStr += ''; + typeStr += ''; } if (model.get('category') == 'CLASSIFICATION') { - tagStr += ''; + var checkTagOrTerm = Utils.checkTagOrTerm(name); + if (checkTagOrTerm.tag) { + tagStr += ''; + } } }); that.ui.typeLov.html(typeStr); http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/search/SearchResultLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/search/SearchResultLayoutView.js b/dashboardv2/public/js/views/search/SearchResultLayoutView.js index d2a3b51..3446a67 100644 --- a/dashboardv2/public/js/views/search/SearchResultLayoutView.js +++ b/dashboardv2/public/js/views/search/SearchResultLayoutView.js @@ -294,7 +294,7 @@ define(['require', if (Globals.entityCreate && Globals.entityTypeConfList && Utils.getUrlState.isSearchTab()) { createEntityTag = "

If you do not find the entity in search result below then you can" + ' create new entity

'; } - that.$('.searchResult').html(resultData + multiAssignDataTag + multiAssignDataTerm + createEntityTag); + that.$('.searchResult').html(resultData + multiAssignDataTerm + multiAssignDataTag + createEntityTag); }, silent: true, reset: true http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/tag/CreateTagLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/tag/CreateTagLayoutView.js b/dashboardv2/public/js/views/tag/CreateTagLayoutView.js index 957a056..34fa114 100644 --- a/dashboardv2/public/js/views/tag/CreateTagLayoutView.js +++ b/dashboardv2/public/js/views/tag/CreateTagLayoutView.js @@ -98,7 +98,11 @@ define(['require', that = this; this.ui.parentTag.empty(); this.tagCollection.fullCollection.each(function(val) { - str += ''; + var name = Utils.getName(val.toJSON()), + checkTagOrTerm = Utils.checkTagOrTerm(name); + if (checkTagOrTerm.tag) { + str += ''; + } }); that.ui.parentTag.html(str); // IE9 support http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/tag/TagLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/tag/TagLayoutView.js b/dashboardv2/public/js/views/tag/TagLayoutView.js index e6b2065..5311ad1 100644 --- a/dashboardv2/public/js/views/tag/TagLayoutView.js +++ b/dashboardv2/public/js/views/tag/TagLayoutView.js @@ -144,18 +144,17 @@ define(['require', }; that.collection.fullCollection.sort().each(function(model) { var name = Utils.getName(model.toJSON(), 'name'); - if (name.indexOf(".") > -1) { - return; - } - if (searchString) { - if (name.search(new RegExp(searchString, "i")) != -1) { - // data-name="''" Space is required for DSL search Input - str += '
  • ' + name + '
  • '; + var checkTagOrTerm = Utils.checkTagOrTerm(name); + if (checkTagOrTerm.tag) { + if (searchString) { + if (name.search(new RegExp(searchString, "i")) != -1) { + str += '
  • ' + name + '
  • '; + } else { + return; + } } else { - return; + str += '
  • ' + name + '
  • '; } - } else { - str += '
  • ' + name + '
  • '; } }); this.ui.tagsParent.empty().html(str); http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/46485ba1/dashboardv2/public/js/views/tag/addTagModalView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/tag/addTagModalView.js b/dashboardv2/public/js/views/tag/addTagModalView.js index 559b2d5..cda5cf6 100644 --- a/dashboardv2/public/js/views/tag/addTagModalView.js +++ b/dashboardv2/public/js/views/tag/addTagModalView.js @@ -193,6 +193,9 @@ define(['require', var str = ''; this.collection.fullCollection.sort().each(function(obj, key) { var name = Utils.getName(obj.toJSON(), 'name'); + if (name === "TaxonomyTerm") { + return; + } // using obj.get('name') insted of name variable because if html is presen in name then escaped name will not found in tagList. if (_.indexOf(that.tagList, obj.get('name')) === -1) { str += '';