Enable check config for System topic

This commit is contained in:
walking98
2019-05-09 20:26:29 +08:00
parent daa1cb6638
commit 68e9a7b6ca
2 changed files with 7 additions and 7 deletions

View File

@@ -265,7 +265,7 @@ module.controller('topicController', ['$scope', 'ngDialog', '$http','Notificatio
});
};
$scope.openUpdateDialog = function (topic) {
$scope.openUpdateDialog = function (topic, sysFlag) {
$http({
method: "GET",
url: "topic/examineTopicConfig.query",
@@ -274,16 +274,15 @@ module.controller('topicController', ['$scope', 'ngDialog', '$http','Notificatio
}
}).success(function (resp) {
if(resp.status ==0){
$scope.openCreateOrUpdateDialog(resp.data);
$scope.openCreateOrUpdateDialog(resp.data, sysFlag);
}else {
Notification.error({message: resp.errMsg, delay: 2000});
}
});
};
$scope.openCreateOrUpdateDialog = function (request) {
$scope.openCreateOrUpdateDialog = function (request, sysFlag) {
var bIsUpdate = true;
if(request == null){
request = [{
writeQueueNums:16,
@@ -309,6 +308,7 @@ module.controller('topicController', ['$scope', 'ngDialog', '$http','Notificatio
template: 'topicModifyDialog',
controller: 'topicModifyDialogController',
data:{
sysFlag:sysFlag,
topicRequestList:request,
allClusterNameList:Object.keys(resp.data.clusterInfo.clusterAddrTable),
allBrokerNameList:Object.keys(resp.data.brokerServer),
@@ -320,7 +320,7 @@ module.controller('topicController', ['$scope', 'ngDialog', '$http','Notificatio
}
$scope.openAddDialog = function () {
$scope.openCreateOrUpdateDialog(null);
$scope.openCreateOrUpdateDialog(null, false);
}
}]);

View File

@@ -61,8 +61,7 @@
ng-click="consumerView(topic)">consumer {{'MANAGE' | translate}}
</button>
<button class="btn btn-raised btn-sm btn-primary" type="button"
ng-show="{{!sysFlag}}"
ng-click="openUpdateDialog(topic)">topic {{'CONFIG' |translate}}
ng-click="openUpdateDialog(topic, sysFlag)">topic {{'CONFIG' |translate}}
</button>
<button class="btn btn-raised btn-sm btn-primary" type="button"
ng-show="{{!sysFlag}}"
@@ -213,6 +212,7 @@
<div class="modal-footer">
<div class="ngdialog-buttons">
<button type="button" class="ngdialog-button ngdialog-button-primary"
ng-show="{{!ngDialogData.sysFlag}}"
ng-click="postTopicRequest(item)">{{ 'COMMIT' | translate }}
</button>
<button type="button" class="ngdialog-button ngdialog-button-secondary"