You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by zh...@apache.org on 2016/02/17 12:15:46 UTC
kylin git commit: KYLIN-1413 FIX Row key column's sequence is wrong
after saving the cube
Repository: kylin
Updated Branches:
refs/heads/2.x-staging c9e209aea -> 1ad86e1e6
KYLIN-1413 FIX Row key column's sequence is wrong after saving the cube
Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/1ad86e1e
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/1ad86e1e
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/1ad86e1e
Branch: refs/heads/2.x-staging
Commit: 1ad86e1e6bee6bc5b04c2534419b95d9a775e3c6
Parents: c9e209a
Author: janzhongi <ji...@ebay.com>
Authored: Wed Feb 17 19:15:20 2016 +0800
Committer: janzhongi <ji...@ebay.com>
Committed: Wed Feb 17 19:16:02 2016 +0800
----------------------------------------------------------------------
webapp/app/js/controllers/cubeAdvanceSetting.js | 8 +++++++-
webapp/app/partials/cubeDesigner/advanced_settings.html | 2 +-
2 files changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/kylin/blob/1ad86e1e/webapp/app/js/controllers/cubeAdvanceSetting.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeAdvanceSetting.js b/webapp/app/js/controllers/cubeAdvanceSetting.js
index 213b039..e0a8327 100644
--- a/webapp/app/js/controllers/cubeAdvanceSetting.js
+++ b/webapp/app/js/controllers/cubeAdvanceSetting.js
@@ -57,7 +57,7 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function ($scope, $modal,cubeConfi
var _isFixedLength = item.encoding.substring(0,12) === "fixed_length"?"true":"false";//fixed_length:12
var _fixedLength ;
if(_isFixedLength){
- _fixedLength = item.encoding.substring(12,item.encoding.length);
+ _fixedLength = item.encoding.substring(13,item.encoding.length);
}
var rowkeyObj = {
column:item.column,
@@ -116,6 +116,12 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function ($scope, $modal,cubeConfi
}
+ $scope.resortRowkey = function(){
+ for(var i=0;i<$scope.convertedRowkeys.length;i++){
+ $scope.refreshRowKey($scope.convertedRowkeys,i,$scope.convertedRowkeys[i]);
+ }
+ }
+
$scope.removeRowkey = function(arr,index,item){
if (index > -1) {
arr.splice(index, 1);
http://git-wip-us.apache.org/repos/asf/kylin/blob/1ad86e1e/webapp/app/partials/cubeDesigner/advanced_settings.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/advanced_settings.html b/webapp/app/partials/cubeDesigner/advanced_settings.html
index 09b98f9..c553763 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -225,7 +225,7 @@
</tr>
</thead>
- <tbody ui-sortable="state.mode=='edit'" ng-model="convertedRowkeys">
+ <tbody ui-sortable="{update:resortRowkey()}" ng-model="convertedRowkeys">
<tr ng-repeat="rowkey_column in convertedRowkeys track by $index"
ng-class="state.mode=='edit'?'sort-item':''">