---x新增功能
This commit is contained in:
parent
37e8e8fb29
commit
baa518014e
|
@ -26,6 +26,7 @@ declare module Configs {
|
|||
brick: Array<Brick>;
|
||||
status: boolean;
|
||||
editable: boolean;
|
||||
hot: boolean;
|
||||
}
|
||||
interface Brick {
|
||||
ip: Array<string>;
|
||||
|
|
|
@ -27,6 +27,7 @@ declare module Configs {
|
|||
status: boolean;
|
||||
path: string;
|
||||
editable?: boolean;
|
||||
hot?: number;
|
||||
}
|
||||
function formatVolumes(volumes: Array<volume>): void;
|
||||
/**
|
||||
|
|
|
@ -17,6 +17,26 @@
|
|||
/// <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/developer/ts/developerPlugin.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/dataManagerModel.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/developerEnrichers.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/environmentPanel.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/fileMigrationTask.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/home.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsJob.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsJobs.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/kubernetesModel.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsLog.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsMetrics.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/navbar.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipeline.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipelineDirective.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipelines.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/project.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/projectSelector.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/workspaces.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/build.d.ts"/>
|
||||
|
@ -29,7 +49,6 @@
|
|||
/// <reference path="d.ts/kubernetes/ts/deploymentConfig.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/deploymentConfigs.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/events.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/kubernetesModel.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/host.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/hosts.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/imageRepositories.d.ts"/>
|
||||
|
@ -58,25 +77,6 @@
|
|||
/// <reference path="d.ts/kubernetes/ts/sharedControllers.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/tabs.d.ts"/>
|
||||
/// <reference path="d.ts/kubernetes/ts/templates.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/developerPlugin.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/dataManagerModel.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/developerEnrichers.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/environmentPanel.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/fileMigrationTask.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/home.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsJob.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsJobs.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsLog.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/jenkinsMetrics.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/navbar.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipeline.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipelineDirective.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/pipelines.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/project.d.ts"/>
|
||||
/// <reference path="d.ts/developer/ts/projectSelector.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/workspaces.d.ts"/>
|
||||
/// <reference path="d.ts/navigation/ts/navigationPlugin.d.ts"/>
|
||||
/// <reference path="d.ts/system/ts/systemHelpers.d.ts"/>
|
||||
/// <reference path="d.ts/system/ts/systemPlugin.d.ts"/>
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -248,8 +248,8 @@ gulp.task('connect', ['watch'], function() {
|
|||
targetPath: '/hawtio/git'
|
||||
}, {
|
||||
proto: "http",
|
||||
port: "8088",
|
||||
hostname: "192.168.0.110",
|
||||
port: "8080",
|
||||
hostname: "192.168.0.181",
|
||||
path: '/java/console/api',
|
||||
targetPath: "/"
|
||||
}];
|
||||
|
|
|
@ -28,7 +28,9 @@
|
|||
<span class="">云路径:{{volume.path}}</span>
|
||||
</th>
|
||||
<th class="no-fade table-header sj_table_td02">
|
||||
<span class=""></span>
|
||||
<span class="">存储类型:</span>
|
||||
<span ng-show="{{volume.hot==0}}">热区</span>
|
||||
<span ng-show="{{volume.hot==1}}">冷区</span>
|
||||
</th>
|
||||
<th class="no-fade table-header">
|
||||
<span class="">已用 {{volume.formatUsedSize}} / 共 {{volume.formatTotalSize}}</span>
|
||||
|
|
|
@ -40,10 +40,6 @@
|
|||
<th>
|
||||
<input type="text" class="sj_txt_box02 mr5" name="volumePath" ng-model="ngDialogData.path" ng-disabled="!{{ngDialogData.editable}}" ng-pattern="/^(\/[a-z0-9A-Z _\-.%]+)+$/" required="required" />
|
||||
</th>
|
||||
<!--<th>
|
||||
<button ng-show="ngDialogData.status" class="sj_btn_red fl" ng-click="stopVolume(ngDialogData)">停止</button>
|
||||
<button ng-hide="ngDialogData.status" class="sj_btn_blue fl" ng-click="startVolume(ngDialogData)">启动</button>
|
||||
</th> -->
|
||||
</tr>
|
||||
<tr ng-repeat="row in ngDialogData.brick">
|
||||
<th class="new_left">
|
||||
|
@ -88,8 +84,11 @@
|
|||
</th>
|
||||
<!--<th>
|
||||
<button class="sj_btn_grey mr5" ng-click="cancel()">取消</button>
|
||||
</th>
|
||||
<!--<th colspan="5"> {{message}}</th>-->
|
||||
</th> -->
|
||||
<th colspan="5" ng-show="!ngDialogData.name">
|
||||
<span>是否为热区</span>
|
||||
<input type="checkbox" checked="checked" name="hot" ng-model="ngDialogData.hot"/>
|
||||
</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
@ -147,12 +147,14 @@ module Configs{
|
|||
editable: block.editable || false
|
||||
});
|
||||
});
|
||||
|
||||
return {
|
||||
name: volume.name,
|
||||
path: volume.path,
|
||||
brick: brick,
|
||||
status: volume.status,
|
||||
editable: volume.editable || false
|
||||
editable: volume.editable || false,
|
||||
hot: volume.hot == 0 ? true : false
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -169,7 +171,8 @@ module Configs{
|
|||
path: string
|
||||
brick: Array<Brick>;
|
||||
status: boolean;
|
||||
editable: boolean
|
||||
editable: boolean,
|
||||
hot: boolean
|
||||
}
|
||||
|
||||
export interface Brick{
|
||||
|
|
|
@ -29,7 +29,8 @@ module Configs{
|
|||
folder?: Array<any>; //volume的文件
|
||||
status: boolean;
|
||||
path: string;
|
||||
editable?: boolean
|
||||
editable?: boolean,
|
||||
hot?: number
|
||||
}
|
||||
|
||||
//字节大小转换成字符大小
|
||||
|
@ -103,7 +104,7 @@ module Configs{
|
|||
//this.updateCodeInfo();
|
||||
}
|
||||
public updateVolumeData(){
|
||||
var result=null;
|
||||
var result=null;
|
||||
$.ajax({
|
||||
async: false,
|
||||
type : "POST",
|
||||
|
|
|
@ -31,14 +31,15 @@ module Configs{
|
|||
status: false,
|
||||
editable: true
|
||||
}],
|
||||
editable: true
|
||||
editable: true,
|
||||
hot: true
|
||||
},
|
||||
className: 'ngdialog-theme-default'
|
||||
});
|
||||
}
|
||||
|
||||
$scope.editRow = (volume) => {
|
||||
var fVolume = formatVolume(volume);
|
||||
var fVolume = formatVolume(volume);
|
||||
ngDialog.open({
|
||||
template: 'newDialog.html',
|
||||
width: 1005,
|
||||
|
@ -126,7 +127,9 @@ module Configs{
|
|||
ip.push(brick["ip"][key]);
|
||||
brick["ip"] = ip.join("\.");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
data.hot = data.hot == true ? 0 : 1;
|
||||
|
||||
var spinner;
|
||||
|
||||
|
|
|
@ -67,7 +67,8 @@ module Configs{
|
|||
|
||||
}
|
||||
|
||||
$scope.onSubmit = (entity) => {
|
||||
$scope.onSubmit = (entity) => {
|
||||
console.log(entity);
|
||||
if($scope.volumeForm.$valid){
|
||||
$scope.$emit('update', entity);
|
||||
$scope.closeThisDialog();
|
||||
|
|
|
@ -68,6 +68,6 @@ module Developer {
|
|||
if(status === 200)
|
||||
console.log("删除成功");
|
||||
});
|
||||
});
|
||||
});
|
||||
}]);
|
||||
}
|
||||
|
|
|
@ -233,6 +233,7 @@ module Developer {
|
|||
向后台发生数据迁移请求,$http:发生http异步请求;第二个参数:请求url;第三个参数:请求操作类型;第四个参数:请求携带的数据;第五个参数:
|
||||
一个回调函数,请求响应后的回调函数。
|
||||
*/
|
||||
|
||||
if(Kubernetes.alreadyExitInFolder($scope.tableConfig.selectedItems, $scope.selectNode)){
|
||||
migrationClick.close();
|
||||
Configs.customAlert("提示", "操作失败:" + "数据已在当前目录!", '',null, 0, "error");
|
||||
|
@ -260,9 +261,15 @@ module Developer {
|
|||
},
|
||||
open: (selected) =>{
|
||||
var migrationClick = $scope.migrationClick;
|
||||
|
||||
ConfigsModel.updateVolumeData();
|
||||
if(ConfigsModel.cluster!=null)
|
||||
$scope.volumes = ConfigsModel.cluster;
|
||||
|
||||
/*
|
||||
判断数据是否已挂载使用和正在迁移。
|
||||
*/
|
||||
*/
|
||||
|
||||
var message = Kubernetes.checkForMigration($scope.replicasModel.replicationControllers, $scope.model.transferTasks , $scope.tableConfig.selectedItems, "manager");
|
||||
|
||||
if(message == ""){
|
||||
|
|
|
@ -211,9 +211,12 @@
|
|||
</script>
|
||||
<script type="text/ng-template" id="taskEdit.html">
|
||||
<div class="ngCellText" ng-init="entity=row.entity" ng-controller="Kubernetes.TaskEdit">
|
||||
<button class="btn sj_btn" ng-click="showDeleteOne.open(entity)">
|
||||
<button class="btn sj_btn" ng-click="showDeleteOne.open(entity)" ng-disabled="entity.status == 1">
|
||||
<span class="glyphicon glyphicon-trash"></span> 删除
|
||||
</button>
|
||||
<button class="btn sj_btn" ng-click="showCancelOne.open(entity)" ng-disabled="entity.process == 100">
|
||||
<span class="glyphicon glyphicon-remove"></span> 取消
|
||||
</button>
|
||||
<div hawtio-confirm-dialog="showDeleteOne.show" title="是否删除任务?" ok-button-text="确认" cancel-button-text="取消" on-cancel="showDeleteOne.onCancelled()" on-ok="showDeleteOne.onOk()">
|
||||
<div class="dialog-body">
|
||||
<p>
|
||||
|
@ -221,6 +224,13 @@
|
|||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div hawtio-confirm-dialog="showCancelOne.show" title="是否取消任务?" ok-button-text="确认" cancel-button-text="取消" on-cancel="showCancelOne.onCancelled()" on-ok="showCancelOne.onOk()">
|
||||
<div class="dialog-body">
|
||||
<p>
|
||||
是否取消:{{entity.name}}-{{entity.systemName}} 任务?
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
<!-- 迁移进度条 -->
|
||||
|
@ -280,21 +290,19 @@
|
|||
<script type="text/ng-template" id="strandColumn.html">
|
||||
<div class="ngCellText" ng-init="entity=row.entity">
|
||||
<div ng-show="true" title="是否是标准表汇总库">
|
||||
<span ng-show="entity.type == 0" > 否</span>
|
||||
<span ng-show="entity.type == 1" > 是</span>
|
||||
<span ng-show="entity.type == 0"> 否</span>
|
||||
<span ng-show="entity.type == 1"> 是</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
|
||||
<script type="text/ng-template" id="isExistHot.html">
|
||||
<div class="ngCellText" ng-init="entity=row.entity">
|
||||
<div ng-show="true" title="是否是标准表汇总库">
|
||||
<span ng-show="entity.existHotData == 0" > 否</span>
|
||||
<span ng-show="entity.existHotData == 1" > 是</span>
|
||||
<span ng-show="entity.existHotData == 0"> 否</span>
|
||||
<span ng-show="entity.existHotData == 1"> 是</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
|
||||
<div ng-controller="Kubernetes.TopLevel">
|
||||
<div class="wiki-icon-view" ng-controller="Kubernetes.FileDropController" nv-file-drop nv-file-over uploader="uploader" over-class="ready-drop">
|
||||
<div class="row kubernetes-view" ng-view></div>
|
||||
|
|
|
@ -135,9 +135,29 @@ module Kubernetes {
|
|||
showDeleteOne.item = null;
|
||||
}
|
||||
};
|
||||
/*$scope.deleteRow = (entity) =>{
|
||||
$scope.$emit('deleteRow', entity);
|
||||
}*/
|
||||
|
||||
$scope.showCancelOne = {
|
||||
show: false,
|
||||
item: null,
|
||||
open: (entity) => {
|
||||
/*if(entity.status == 1)
|
||||
Configs.customAlert("提示", "操作失败: 正在迁移的任务,不能删除!", '',null, 0, "error");
|
||||
else{*/
|
||||
var showCancelOne = $scope.showCancelOne;
|
||||
showCancelOne.show = true;
|
||||
showCancelOne.item = entity;
|
||||
//}
|
||||
},
|
||||
onOk: () => {
|
||||
var showCancelOne = $scope.showCancelOne;
|
||||
$scope.$emit('deleteRow', showCancelOne.item);
|
||||
},
|
||||
onCancel: ()=>{
|
||||
var showCancelOne = $scope.showCancelOne;
|
||||
showCancelOne.show = false;
|
||||
showCancelOne.item = null;
|
||||
}
|
||||
};
|
||||
}]);
|
||||
|
||||
export var LoadMask = controller('LoadMask', ['$scope', ($scope) => {
|
||||
|
|
|
@ -323,8 +323,7 @@ module Kubernetes {
|
|||
检查迁移文件是否正在迁移
|
||||
*/
|
||||
|
||||
for(i in transferTasks){
|
||||
console.log(transferTasks[i].id);
|
||||
for(i in transferTasks){
|
||||
/*if(transferTasks[i]["_key"] == item["_key"] && (transferTasks[i]["status"] == "1" || transferTasks[i]["status"] == "0") && item["year"] == transferTasks[i].labels.dataYear){
|
||||
message = "数据正在迁移"
|
||||
return message;
|
||||
|
|
|
@ -135,6 +135,7 @@ module System{
|
|||
});
|
||||
}
|
||||
|
||||
//审核
|
||||
$scope.verifySql = (selected, type) => {
|
||||
ngDialog.open({
|
||||
template: 'sqlVerification.html',
|
||||
|
@ -148,6 +149,7 @@ module System{
|
|||
});
|
||||
}
|
||||
|
||||
//替换
|
||||
$scope.moveSql = (selected, type) => {
|
||||
ngDialog.open({
|
||||
template: 'sqlMove.html',
|
||||
|
@ -195,7 +197,8 @@ module System{
|
|||
content: data.content
|
||||
})
|
||||
}).success((data,header,config,status) => {
|
||||
//shareUpdate(data);
|
||||
$scope.model = SystemModel.sqlInfo = data.data;
|
||||
shareUpdate($scope.model, $scope.optionsFilter);
|
||||
}).error((data,header,config,status) => {
|
||||
Configs.customAlert("提示", "脚本替换或归档失败!", '',null, 0, "error");
|
||||
});
|
||||
|
|
|
@ -102,7 +102,7 @@ module System{
|
|||
$scope.tableParams.settings({
|
||||
dataset: $scope.model
|
||||
});
|
||||
Configs.customAlert("提示", "操作成功: 本次excel文件录入成功!", '',null, 0, "success");
|
||||
Configs.customAlert("提示", "操作成功: 本次合计新增了" + data.area + "个行政区划、" + data.system + "个信息系统,更新了" + data.update + "个信息系统", '',null, 0, "success");
|
||||
},
|
||||
error: (XMLHttpRequest, textStatus, errorThrown) =>{
|
||||
$("#load").remove();
|
||||
|
|
|
@ -230,7 +230,7 @@ module System{
|
|||
检查数据是否在热区
|
||||
*/
|
||||
|
||||
if(item.mark == 1){
|
||||
if(item.mark == 1 && item.dataBaseType == 'ORACLE'){
|
||||
Configs.customAlert("提示", "操作失败:选择的系统的数据存储在冷区,请先将数据迁移到热区再检验!", '',null, 0, "error");
|
||||
return
|
||||
}
|
||||
|
@ -382,8 +382,7 @@ module System{
|
|||
});
|
||||
});
|
||||
|
||||
$scope.openLog = (entity) => {
|
||||
console.log(entity);
|
||||
$scope.openLog = (entity) => {
|
||||
var name = entity.areaCode + "_" + entity.sysCode + "_" + entity.dataVersion
|
||||
var containerName = entity.cityName + "-" + entity.districtName + "-" + entity.sysName + "-版本" + entity.dataVersion;
|
||||
entity["name"] = name;
|
||||
|
|
Loading…
Reference in New Issue