superset-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From maximebeauche...@apache.org
Subject [incubator-superset] branch master updated: filter recently viewed to just have explore and dashboard types (#4808)
Date Wed, 11 Apr 2018 20:19:24 GMT
This is an automated email from the ASF dual-hosted git repository.

maximebeauchemin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git


The following commit(s) were added to refs/heads/master by this push:
     new 3c29ca7  filter recently viewed to just have explore and dashboard types (#4808)
3c29ca7 is described below

commit 3c29ca79ae87bd5e10ef0d60419ec73fbe8aa7e1
Author: Hugh A. Miles II <hughmil3s@gmail.com>
AuthorDate: Wed Apr 11 16:19:20 2018 -0400

    filter recently viewed to just have explore and dashboard types (#4808)
---
 .../javascripts/profile/components/RecentActivity.jsx      | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/superset/assets/javascripts/profile/components/RecentActivity.jsx b/superset/assets/javascripts/profile/components/RecentActivity.jsx
index 7099a08..14cf7a8 100644
--- a/superset/assets/javascripts/profile/components/RecentActivity.jsx
+++ b/superset/assets/javascripts/profile/components/RecentActivity.jsx
@@ -12,12 +12,14 @@ export default class RecentActivity extends React.PureComponent {
   render() {
     const rowLimit = 50;
     const mutator = function (data) {
-      return data.map(row => ({
-        name: <a href={row.item_url}>{row.item_title}</a>,
-        type: row.action,
-        time: moment.utc(row.time).fromNow(),
-        _time: row.time,
-      }));
+      return data
+        .filter(row => row.action === 'dashboard' || row.action === 'explore')
+        .map(row => ({
+          name: <a href={row.item_url}>{row.item_title}</a>,
+          type: row.action,
+          time: moment.utc(row.time).fromNow(),
+          _time: row.time,
+        }));
     };
     return (
       <div>

-- 
To stop receiving notification emails like this one, please contact
maximebeauchemin@apache.org.

Mime
View raw message