---脚本审核增加保留你能

This commit is contained in:
wu ming 2016-11-25 10:21:14 +08:00
parent c1bda9fbc1
commit c8ae9e8c59
10 changed files with 1438 additions and 1391 deletions

12
defs.d.ts vendored
View File

@ -31,6 +31,12 @@
/// <reference path="d.ts/developer/ts/projects.d.ts"/> /// <reference path="d.ts/developer/ts/projects.d.ts"/>
/// <reference path="d.ts/developer/ts/workspace.d.ts"/> /// <reference path="d.ts/developer/ts/workspace.d.ts"/>
/// <reference path="d.ts/developer/ts/workspaces.d.ts"/> /// <reference path="d.ts/developer/ts/workspaces.d.ts"/>
/// <reference path="d.ts/configs/ts/configsUtils.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/watcher.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/term.d.ts"/>
/// <reference path="d.ts/configs/ts/shareController.d.ts"/>
/// <reference path="d.ts/configs/ts/glusterfsSetting.d.ts"/>
/// <reference path="d.ts/configs/ts/kubeClusterSetting.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/apps.d.ts"/> /// <reference path="d.ts/kubernetes/ts/apps.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/breadcrumbs.d.ts"/> /// <reference path="d.ts/kubernetes/ts/breadcrumbs.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/build.d.ts"/> /// <reference path="d.ts/kubernetes/ts/build.d.ts"/>
@ -56,8 +62,6 @@
/// <reference path="d.ts/kubernetes/ts/pipelines.d.ts"/> /// <reference path="d.ts/kubernetes/ts/pipelines.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/pod.d.ts"/> /// <reference path="d.ts/kubernetes/ts/pod.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/podEdit.d.ts"/> /// <reference path="d.ts/kubernetes/ts/podEdit.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/watcher.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/term.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/podLogs.d.ts"/> /// <reference path="d.ts/kubernetes/ts/podLogs.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/pods.d.ts"/> /// <reference path="d.ts/kubernetes/ts/pods.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/replicationController.d.ts"/> /// <reference path="d.ts/kubernetes/ts/replicationController.d.ts"/>
@ -74,10 +78,6 @@
/// <reference path="d.ts/kubernetes/ts/tabs.d.ts"/> /// <reference path="d.ts/kubernetes/ts/tabs.d.ts"/>
/// <reference path="d.ts/kubernetes/ts/templates.d.ts"/> /// <reference path="d.ts/kubernetes/ts/templates.d.ts"/>
/// <reference path="d.ts/navigation/ts/navigationPlugin.d.ts"/> /// <reference path="d.ts/navigation/ts/navigationPlugin.d.ts"/>
/// <reference path="d.ts/configs/ts/configsUtils.d.ts"/>
/// <reference path="d.ts/configs/ts/shareController.d.ts"/>
/// <reference path="d.ts/configs/ts/glusterfsSetting.d.ts"/>
/// <reference path="d.ts/configs/ts/kubeClusterSetting.d.ts"/>
/// <reference path="d.ts/system/ts/systemHelpers.d.ts"/> /// <reference path="d.ts/system/ts/systemHelpers.d.ts"/>
/// <reference path="d.ts/system/ts/systemPlugin.d.ts"/> /// <reference path="d.ts/system/ts/systemPlugin.d.ts"/>
/// <reference path="d.ts/system/ts/regionalismCodeSearch.d.ts"/> /// <reference path="d.ts/system/ts/regionalismCodeSearch.d.ts"/>

File diff suppressed because one or more lines are too long

View File

@ -248,8 +248,8 @@ gulp.task('connect', ['watch'], function() {
targetPath: '/hawtio/git' targetPath: '/hawtio/git'
}, { }, {
proto: "http", proto: "http",
port: "8080", port: "8088",
hostname: "192.168.0.181", hostname: "192.168.0.110",
path: '/java/console/api', path: '/java/console/api',
targetPath: "/" targetPath: "/"
}]; }];

View File

@ -239,7 +239,7 @@
<button class="btn pull-right sj_btn_blue " ng-click="replace()"> <button class="btn pull-right sj_btn_blue " ng-click="replace()">
替换 替换
</button> </button>
<button class="sj_btn_grey mr5 fr" ng-click="cancel()">取消</button> <button class="sj_btn_grey mr5 fr" ng-click="cancel()">保留</button>
</div> </div>
</div> </div>
</script> </script>

View File

@ -230,7 +230,15 @@ module Configs{
} }
$scope.cancel = () => { $scope.cancel = () => {
$scope.closeThisDialog(); //$scope.closeThisDialog();
$scope.$emit("replace", {
url: "/java/console/api/filePackage/handleSqlFile",
item: $scope.ngDialogData.item,
content: $scope.content,
opt: "delete",
type: $scope.ngDialogData.type
});
$scope.closeThisDialog();
} }
}]); }]);

View File

@ -37,7 +37,7 @@
<ul class="fr sj_table_bottom"> <ul class="fr sj_table_bottom">
<li class="mr5 ">当前显示{{(options.currentPageNum-1)*20 + 1}}~{{(options.currentPageNum-1)*20 + model.data.length}}行,共{{model.paramOptions.totalSize}}行,</li> <li class="mr5 ">当前显示{{(options.currentPageNum-1)*20 + 1}}~{{(options.currentPageNum-1)*20 + model.data.length}}行,共{{model.paramOptions.totalSize}}行,</li>
<!--<li class="mr5 ">每页显示 <!--<li class="mr5 ">每页显示
<select ng-options="value for value in pageSizeChoses" ng-change="selectAction()" ng-model="options.currentTableSize"></select> <select ng-options="value for value in pageSizeChoses" ng-cha=nge="selectAction()" ng-model="options.currentTableSize"></select>
</li>--> </li>-->
<li class="mr5 ">当前页码</li> <li class="mr5 ">当前页码</li>
<li> <li>

View File

@ -14,6 +14,7 @@ module Developer {
($scope, KubernetesModel: Kubernetes.KubernetesModelService, DataModel:Developer.DataModelService, ConfigsModel:Configs.ConfigsModelService, KubernetesState, $templateCache:ng.ITemplateCacheService, $location:ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL, $element, ngDialog) => { ($scope, KubernetesModel: Kubernetes.KubernetesModelService, DataModel:Developer.DataModelService, ConfigsModel:Configs.ConfigsModelService, KubernetesState, $templateCache:ng.ITemplateCacheService, $location:ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL, $element, ngDialog) => {
$scope.model=DataModel; $scope.model=DataModel;
$scope.replicasModel = KubernetesModel; $scope.replicasModel = KubernetesModel;
console.log("==============================");
init($scope, $location, $routeParams); init($scope, $location, $routeParams);
$scope.options = DataModel.paramOptions; $scope.options = DataModel.paramOptions;
$scope.pageSizeChoses = DataModel.paramOptions.pagerSizeOption; $scope.pageSizeChoses = DataModel.paramOptions.pagerSizeOption;
@ -103,6 +104,7 @@ module Developer {
nav.class=""; nav.class="";
}); });
item.class="active"; item.class="active";
$scope.model.updateParamOption("currentPageNum", 1);
$scope.model.updateParamOption("keyQuery", $scope.keyQuery); $scope.model.updateParamOption("keyQuery", $scope.keyQuery);
$scope.model.updateParamOption("dataBatch", item.alias); $scope.model.updateParamOption("dataBatch", item.alias);
} }
@ -327,6 +329,8 @@ module Developer {
function init($scope,$location,$routeParams){ function init($scope,$location,$routeParams){
//$scope.model.updateModel(); //$scope.model.updateModel();
//console.log($scope.options.currentPageNum);
console.log("==============================");
$scope.keyQuery = ""; $scope.keyQuery = "";
$scope.model.initParamOptions(); $scope.model.initParamOptions();
$scope.model.updateParamOption("keyQuery", $scope.keyQuery); $scope.model.updateParamOption("keyQuery", $scope.keyQuery);

View File

@ -213,7 +213,7 @@ module Kubernetes {
/** /**
**/ **/
$scope.extractOracle = (selected) =>{ $scope.extractOracle = (selected) =>{
var answer = false; var answer = false;
for (var i = 0; i < ConfigsModel.oracleParam.length; ++i) { for (var i = 0; i < ConfigsModel.oracleParam.length; ++i) {
if(ConfigsModel.oracleParam[i].type == 1){ if(ConfigsModel.oracleParam[i].type == 1){

View File

@ -11,7 +11,9 @@ module System{
shareInit($scope); shareInit($scope);
$scope.cities = classifyCity(SystemModel.regionalismInfo); $scope.cities = classifyCity(SystemModel.regionalismInfo);
$scope.status = [{id: 0, label: "有缺失"}, {id: 1, label: "正常"}, {id: 2, label:"待归档"}, {id: 3, label: "待审核"}]; $scope.status = [{id: 0, label: "有缺失"}, {id: 1, label: "正常"}, {id: 2, label:"待归档"}, {id: 3, label: "待审核"}];
SystemModel.updateSqlInfo();
$scope.cityFilter = $scope.model = SystemModel.sqlInfo; $scope.cityFilter = $scope.model = SystemModel.sqlInfo;
@ -100,8 +102,8 @@ module System{
$scope.help = () => { $scope.help = () => {
ngDialog.open({ ngDialog.open({
template: 'statusHelp.html', template: 'statusHelp.html',
width: 900, width: 600,
height: 600, height: 370,
closeByDocument: false, closeByDocument: false,
className: 'ngdialog-theme-default' className: 'ngdialog-theme-default'
}); });
@ -197,9 +199,9 @@ module System{
$scope.$on('onOk', (event, data) => { $scope.$on('onOk', (event, data) => {
Configs.create_mask(); //创建遮罩层 Configs.create_mask(); //创建遮罩层
Kubernetes.create_locadEffect("正在更新文件,请稍等!"); //创建数据加载效果层 Kubernetes.create_locadEffect("正在更新文件,请稍等!"); //创建数据加载效果层
var target = document.getElementById('loading') var target = document.getElementById('loading')
var spinner = new Spinner(Kubernetes.loadConfigs()).spin(target); var spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
$http({ $http({
url: "/java/console/api/filePackage/handleSqlFile", url: "/java/console/api/filePackage/handleSqlFile",
method: "POST", method: "POST",
@ -209,10 +211,12 @@ module System{
content: data.content content: data.content
}) })
}).success((data,header,config,status) => { }).success((data,header,config,status) => {
$("#load").remove(); $("#load").remove();
Kubernetes.removeMask(); Kubernetes.removeMask();
shareUpdate(data); shareUpdate(data);
}).error((data,header,config,status) => { }).error((data,header,config,status) => {
$("#load").remove();
Kubernetes.removeMask();
}); });
}); });
@ -270,6 +274,9 @@ module System{
if(items.length <= 0) if(items.length <= 0)
return; return;
Configs.create_mask(); //创建遮罩层
Kubernetes.create_locadEffect("正在更新文件,请稍等!"); //创建数据加载效果层
$http({ $http({
url: url, url: url,
method: 'POST', method: 'POST',
@ -303,12 +310,18 @@ module System{
}); });
} }
} }
$("#load").remove();
Kubernetes.removeMask();
$scope.tableParams.settings({ $scope.tableParams.settings({
dataset: filter dataset: filter
}); });
//响应成功 //响应成功
}).error(function(data,header,config,status){ }).error(function(data,header,config,status){
//处理响应失败 //处理响应失败
$("#load").remove();
Kubernetes.removeMask();
Configs.customAlert("提示", "一键审核或归档失败!", '',null, 0, "error");
}); });
} }

View File

@ -11,7 +11,7 @@ module System{
shareInit($scope); shareInit($scope);
$scope.modelServices = SystemModel; $scope.modelServices = SystemModel;
//$scope.modelServices.updateExcelInfo(); $scope.modelServices.updateExcelInfo();
$scope.model = SystemModel.systemInfoList; $scope.model = SystemModel.systemInfoList;
// 表头显示的信息 // 表头显示的信息