Repository: kylin Updated Branches: refs/heads/master f3ae1c42d -> 577acc5a7
KYLIN-3029 The warning window of exist cube name is not work Project: http://git-wip-us.apache.org/repos/asf/kylin/repo Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/577acc5a Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/577acc5a Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/577acc5a Branch: refs/heads/master Commit: 577acc5a7c10291d4d5458d9afa620c823822061 Parents: f3ae1c4 Author: peng.jianhua <peng.jian...@zte.com.cn> Authored: Wed Nov 29 21:33:22 2017 +0800 Committer: chenzhx <c...@apache.org> Committed: Tue Dec 5 17:56:47 2017 +0800 ---------------------------------------------------------------------- webapp/app/js/controllers/cubeSchema.js | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/kylin/blob/577acc5a/webapp/app/js/controllers/cubeSchema.js ---------------------------------------------------------------------- diff --git a/webapp/app/js/controllers/cubeSchema.js b/webapp/app/js/controllers/cubeSchema.js index 590168b..0af7cc2 100755 --- a/webapp/app/js/controllers/cubeSchema.js +++ b/webapp/app/js/controllers/cubeSchema.js @@ -160,6 +160,18 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic }); + var queryParam = {offset: 0, limit: 65535}; + + CubeService.list(queryParam, function (all_cubes) { + if($scope.allCubes.length > 0){ + $scope.allCubes.splice(0,$scope.allCubes.length); + } + + for (var i = 0; i < all_cubes.length; i++) { + $scope.allCubes.push(all_cubes[i].name.toUpperCase()); + } + }); + // ~ public methods $scope.filterProj = function(project){ return $scope.userService.hasRole('ROLE_ADMIN') || $scope.hasPermission(project,$scope.permissions.ADMINISTRATION.mask); @@ -292,18 +304,6 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic $scope.check_cube_info = function(){ - var queryParam = {offset: 0, limit: 65535}; - - CubeService.list(queryParam, function (all_cubes) { - if($scope.allCubes.length > 0){ - $scope.allCubes.splice(0,$scope.allCubes.length); - } - - for (var i = 0; i < all_cubes.length; i++) { - $scope.allCubes.push(all_cubes[i].name.toUpperCase()); - } - }); - if(($scope.state.mode === "edit") &&$scope.cubeMode=="addNewCube"&&($scope.allCubes.indexOf($scope.cubeMetaFrame.name.toUpperCase()) >= 0)){ SweetAlert.swal('Oops...', "The cube named [" + $scope.cubeMetaFrame.name.toUpperCase() + "] already exists", 'warning'); return false;