kylin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject [2/3] kylin git commit: KYLIN-3183 fix the bug of the 'Remove' button in 'Query HIstory'
Date Wed, 24 Jan 2018 06:45:01 GMT
KYLIN-3183 fix the bug of the 'Remove' button in 'Query HIstory'

Signed-off-by: chenzhx <chen@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/4f1f8a59
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/4f1f8a59
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/4f1f8a59

Branch: refs/heads/master
Commit: 4f1f8a595eade778bb2c2eb4fb88504a7af003d3
Parents: 6791327
Author: peng.jianhua <peng.jianhua@zte.com.cn>
Authored: Fri Jan 19 18:20:24 2018 +0800
Committer: chenzhx <chen@apache.org>
Committed: Wed Jan 24 14:44:53 2018 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/query.js | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/4f1f8a59/webapp/app/js/controllers/query.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/query.js b/webapp/app/js/controllers/query.js
index cac7ccb..e7190cc 100644
--- a/webapp/app/js/controllers/query.js
+++ b/webapp/app/js/controllers/query.js
@@ -322,6 +322,8 @@ KylinApp
             if (queryToRemove) {
                 var index = $scope.cachedQueries.indexOf(queryToRemove);
                 $scope.cachedQueries.splice(index, 1);
+                var indexFilter = $scope.cachedFilterQueries.indexOf(queryToRemove);
+                $scope.cachedFilterQueries.splice(indexFilter, 1);
                 storage.set("saved_queries", $scope.cachedQueries);
             }
         }
@@ -344,16 +346,16 @@ KylinApp
 
         $scope.listSavedQueries = function () {
             QueryService.list({project: $scope.projectModel.selectedProject}, function (queries)
{
-                $scope.savedQueries = queries
+                $scope.savedQueries = queries;
                 $scope.savedQueries.curPage = 1;
                 $scope.savedQueries.perPage = 3;
             });
         }
 
         $scope.listCachedQueries = function () {
-          $scope.cachedQueries = storage.get("saved_queries")
+          $scope.cachedQueries = storage.get("saved_queries");
           $scope.cachedFilterQueries = $scope.cachedQueries.filter(function (query) {
-            return query.project === $scope.projectModel.selectedProject
+            return query.project === $scope.projectModel.selectedProject;
           });
           if (!$scope.cachedFilterQueries) {
             $scope.cachedFilterQueries = [];


Mime
View raw message