From commits-return-2011-archive-asf-public=cust-asf.ponee.io@superset.incubator.apache.org Wed Jan 9 19:45:56 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 2CC95180669 for ; Wed, 9 Jan 2019 19:45:56 +0100 (CET) Received: (qmail 29783 invoked by uid 500); 9 Jan 2019 18:45:55 -0000 Mailing-List: contact commits-help@superset.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@superset.incubator.apache.org Delivered-To: mailing list commits@superset.incubator.apache.org Received: (qmail 29774 invoked by uid 99); 9 Jan 2019 18:45:55 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Jan 2019 18:45:55 +0000 Received: by gitbox.apache.org (ASF Mail Server at gitbox.apache.org, from userid 33) id BD2DC85C07; Wed, 9 Jan 2019 18:45:54 +0000 (UTC) Date: Wed, 09 Jan 2019 18:45:55 +0000 To: "commits@superset.apache.org" Subject: [incubator-superset] 01/04: Fix deck.gl Polygon not show (#6545) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit From: michellet@apache.org In-Reply-To: <154705955430.31125.6508497396117105185@gitbox.apache.org> References: <154705955430.31125.6508497396117105185@gitbox.apache.org> X-Git-Host: gitbox.apache.org X-Git-Repo: incubator-superset X-Git-Refname: refs/heads/0.30 X-Git-Reftype: branch X-Git-Rev: 83929985d0e0228a347711d07501f5ff4c67f6ad X-Git-NotificationType: diff X-Git-Multimail-Version: 1.5.dev Auto-Submitted: auto-generated Message-Id: <20190109184554.BD2DC85C07@gitbox.apache.org> This is an automated email from the ASF dual-hosted git repository. michellet pushed a commit to branch 0.30 in repository https://gitbox.apache.org/repos/asf/incubator-superset.git commit 83929985d0e0228a347711d07501f5ff4c67f6ad Author: MukaJiTrue <45657828+MukaJiTrue@users.noreply.github.com> AuthorDate: Wed Dec 19 02:16:09 2018 +0700 Fix deck.gl Polygon not show (#6545) * Fix deck.gl Polygon not show * Replace "//" to "// " (cherry picked from commit 926f78c21d2ef513edcbc9af2e766bfe5c8e8b53) --- superset/assets/src/visualizations/deckgl/utils.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/superset/assets/src/visualizations/deckgl/utils.js b/superset/assets/src/visualizations/deckgl/utils.js index 10c9363..149ef2b 100644 --- a/superset/assets/src/visualizations/deckgl/utils.js +++ b/superset/assets/src/visualizations/deckgl/utils.js @@ -89,8 +89,10 @@ export function getBuckets(fd, features, accessor) { breakPoints.slice(1).forEach((value, i) => { const range = breakPoints[i] + ' - ' + breakPoints[i + 1]; const mid = 0.5 * (parseInt(breakPoints[i], 10) + parseInt(breakPoints[i + 1], 10)); + // fix polygon doesn't show + const metricLabel = fd.metric ? fd.metric.label || fd.metric : null; buckets[range] = { - color: colorScaler({ [fd.metric.label || fd.metric]: mid }), + color: colorScaler({ [metricLabel || fd.metric]: mid }), enabled: true, }; });