Compare commits
13 Commits
Author | SHA1 | Date |
---|---|---|
lili | f5d6b60ed8 | |
lili | 4e26bc1f8e | |
lili | d2f880064b | |
lili | 56edb8ea7b | |
lili | acae8c92df | |
lili | 9750e1467d | |
lili | 30c70fba37 | |
lili | 3ac9da8ad2 | |
lili | 4218595a3a | |
ladventure | 1ae916723d | |
ladventure | 93ad9c5304 | |
ladventure | b0fbb27903 | |
pengfei | 57d45a80f7 |
|
@ -9,6 +9,7 @@ declare module Configs {
|
||||||
static UPDATE: string;
|
static UPDATE: string;
|
||||||
static PUT: string;
|
static PUT: string;
|
||||||
static MOVE: string;
|
static MOVE: string;
|
||||||
|
static CREATE_DATABASE: string;
|
||||||
static EXTRACT: string;
|
static EXTRACT: string;
|
||||||
}
|
}
|
||||||
function createOracleInfo(array: Array<any>, id: number): {
|
function createOracleInfo(array: Array<any>, id: number): {
|
||||||
|
|
|
@ -7,6 +7,6 @@ declare module Configs {
|
||||||
对象的深拷贝
|
对象的深拷贝
|
||||||
*/
|
*/
|
||||||
function deepCopy(object: any): any;
|
function deepCopy(object: any): any;
|
||||||
function downloadFile($scope: any, $http: any, url: any, fn?: any): void;
|
function downloadFile($scope: any, $http: any, url: any, fileName: any, fn?: any): void;
|
||||||
function FileInputPlugin(fn: Function, isMultiple?: boolean): void;
|
function FileInputPlugin(fn: Function, isMultiple?: boolean): void;
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,4 +13,5 @@ declare module Configs {
|
||||||
var sqlVerificationController: ng.IModule;
|
var sqlVerificationController: ng.IModule;
|
||||||
var sqlMoveController: ng.IModule;
|
var sqlMoveController: ng.IModule;
|
||||||
var sysVerUpdateController: ng.IModule;
|
var sysVerUpdateController: ng.IModule;
|
||||||
|
var dataExportController: ng.IModule;
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,4 +70,5 @@ declare module Kubernetes {
|
||||||
function checkForMigration(replicationControllers: Array<KubePod>, transferTasks: Array<any>, selectItem: Array<any>, type: string): string;
|
function checkForMigration(replicationControllers: Array<KubePod>, transferTasks: Array<any>, selectItem: Array<any>, type: string): string;
|
||||||
function eliminateChechBoxClick(): void;
|
function eliminateChechBoxClick(): void;
|
||||||
function alreadyExitInFolder(selectedItems: Array<any>, selectNode: any): boolean;
|
function alreadyExitInFolder(selectedItems: Array<any>, selectNode: any): boolean;
|
||||||
|
function alreadyExitInCluster(selectedItems: Array<any>, volumePath: any): boolean;
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -249,7 +249,7 @@ gulp.task('connect', ['watch'], function() {
|
||||||
}, {
|
}, {
|
||||||
proto: "http",
|
proto: "http",
|
||||||
port: "9001",
|
port: "9001",
|
||||||
hostname: "192.168.191.100", //hostname:"127.0.0.1"
|
hostname: "192.168.191.102", //hostname:"127.0.0.1"
|
||||||
path: '/java/console/api',
|
path: '/java/console/api',
|
||||||
targetPath: "/"
|
targetPath: "/"
|
||||||
}];
|
}];
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
|
@ -16,10 +16,15 @@ a:hover,a:active{color:#333;}
|
||||||
.cl{ clear:both; overflow:hidden;}
|
.cl{ clear:both; overflow:hidden;}
|
||||||
/* public*/
|
/* public*/
|
||||||
.mt2{margin-top: 3px;}
|
.mt2{margin-top: 3px;}
|
||||||
.mt5{ margin-top: 5px;}.mt10{ margin-top: 10px;}.mt15{ margin-top: 15px;}
|
.mt5{ margin-top: 5px;}.mt10{ margin-top: 10px;}.mt15{ margin-top: 15px;}.mt20{ margin-top: 20px;}.mt30{ margin-top: 30px;}
|
||||||
.ml5{ margin-left:5px;}.ml10{ margin-left:10px;}.ml15{ margin-left:15px;}
|
.ml5{ margin-left:5px;}.ml10{ margin-left:10px;}.ml15{ margin-left:15px;}.ml20{ margin-left: 20px;}
|
||||||
.mr5{ margin-right:5px;}.mr10{ margin-right:10px;}.mr15{ margin-right:15px;}.mr17{ margin-right:17px;}.mr20{ margin-right:20px;}
|
.mr5{ margin-right:5px;}.mr10{ margin-right:10px;}.mr15{ margin-right:15px;}.mr17{ margin-right:17px;}.mr20{ margin-right:20px;}
|
||||||
.mb10{ margin-bottom: 10px;}
|
.mb5{ margin-bottom: 5px;}.mb10{ margin-bottom: 10px;}
|
||||||
|
.margin20{ margin:20px;}
|
||||||
|
.pt5{ padding-top:5px;}
|
||||||
|
.pb5{ padding-bottom:5px;}
|
||||||
|
.padding20{ padding: 20px;}
|
||||||
|
.height20{ height:20px;}
|
||||||
a.sj_btn_grey{ display:inline-block; padding:0px 15px; height:30px; line-height:30px; -webkit-border-radius:3px;-moz-border-radius:3px;-o-border-radius:3px;border-radius:3px; background-image:-webkit-linear-gradient(top, #fdfdfd,#e8e8e8);background-image:linear-gradient(top,#fdfdfd,#e8e8e8); border:1px solid #cecece; color:#505050;}
|
a.sj_btn_grey{ display:inline-block; padding:0px 15px; height:30px; line-height:30px; -webkit-border-radius:3px;-moz-border-radius:3px;-o-border-radius:3px;border-radius:3px; background-image:-webkit-linear-gradient(top, #fdfdfd,#e8e8e8);background-image:linear-gradient(top,#fdfdfd,#e8e8e8); border:1px solid #cecece; color:#505050;}
|
||||||
a:hover.sj_btn_grey{ background-image:-webkit-linear-gradient(top, #eeeeee,#d3d3d3);background-image:linear-gradient(top,#eeeeee,#d3d3d3);}
|
a:hover.sj_btn_grey{ background-image:-webkit-linear-gradient(top, #eeeeee,#d3d3d3);background-image:linear-gradient(top,#eeeeee,#d3d3d3);}
|
||||||
.sj_btn_grey{ display:inline-block; padding:0px 15px; height:30px; line-height:30px; -webkit-border-radius:3px;-moz-border-radius:3px;-o-border-radius:3px;border-radius:3px; background-image:-webkit-linear-gradient(top, #fdfdfd,#e8e8e8);background-image:linear-gradient(top,#fdfdfd,#e8e8e8); border:1px solid #cecece; color:#505050;}
|
.sj_btn_grey{ display:inline-block; padding:0px 15px; height:30px; line-height:30px; -webkit-border-radius:3px;-moz-border-radius:3px;-o-border-radius:3px;border-radius:3px; background-image:-webkit-linear-gradient(top, #fdfdfd,#e8e8e8);background-image:linear-gradient(top,#fdfdfd,#e8e8e8); border:1px solid #cecece; color:#505050;}
|
||||||
|
@ -77,6 +82,7 @@ a:hover.sj_btn_grey{ background-image:-webkit-linear-gradient(top, #eeeeee,#d3d3
|
||||||
.sj_table_td00{ width:5%;}
|
.sj_table_td00{ width:5%;}
|
||||||
.sj_table_td06{ width:15%;}
|
.sj_table_td06{ width:15%;}
|
||||||
.sj_over_hid{ display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
|
.sj_over_hid{ display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
|
||||||
|
.sj_over_hid2{ overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
|
||||||
.sj_content_table table tr td input{ margin-top:15px;}
|
.sj_content_table table tr td input{ margin-top:15px;}
|
||||||
.sj_content_table .sj_table_top td{ border-bottom:1px solid #a6a6a6; font-weight:bold; border-right:1px solid #ccc;}
|
.sj_content_table .sj_table_top td{ border-bottom:1px solid #a6a6a6; font-weight:bold; border-right:1px solid #ccc;}
|
||||||
.sj_table_bottom{ height:30px; line-height:30px; }
|
.sj_table_bottom{ height:30px; line-height:30px; }
|
||||||
|
@ -206,3 +212,11 @@ table tr.sj_popup_toptxt th{ font-weight: bold; text-align: center; color: #333
|
||||||
.sj_fluid{ margin-left:20px; margin-right: 20px;}
|
.sj_fluid{ margin-left:20px; margin-right: 20px;}
|
||||||
.custom-alert {width: 330px; border: none;background-color: #fff;font-weight: bold;font-size: 12px;-webkit-border-radius:5px; -moz-border-radius:5px;-o-border-radius:5px; border-radius:5px; box-shadow: 0px 2px 8px rgba(146, 153, 169, 0.5);}
|
.custom-alert {width: 330px; border: none;background-color: #fff;font-weight: bold;font-size: 12px;-webkit-border-radius:5px; -moz-border-radius:5px;-o-border-radius:5px; border-radius:5px; box-shadow: 0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||||
.custom-alert-title { line-height: 30px;padding: 0px 10px;background-color: #3b94d6;}
|
.custom-alert-title { line-height: 30px;padding: 0px 10px;background-color: #3b94d6;}
|
||||||
|
|
||||||
|
.sj-border-black{ border:1px solid #000;}
|
||||||
|
.export-li{ width:446px; height:30px;}
|
||||||
|
.export-label { height:30px;}
|
||||||
|
.export-li input{ width: 18px; height:18px;}
|
||||||
|
.export-li span{width:400px; height:18px;}
|
||||||
|
.box-sizing{ -moz-box-sizing: border-box; -webkit-box-sizing: border-box; -o-box-sizing: border-box; -ms-box-sizing: border-box; box-sizing: border-box; }
|
||||||
|
.border-left-none{ boder-left:none;}
|
|
@ -20,6 +20,7 @@
|
||||||
"gulp-watch": "^3.0.0",
|
"gulp-watch": "^3.0.0",
|
||||||
"hawtio-node-backend": "^2.0.5",
|
"hawtio-node-backend": "^2.0.5",
|
||||||
"stringify-object": "^2.0.0",
|
"stringify-object": "^2.0.0",
|
||||||
|
"tern": "^0.21.0",
|
||||||
"through2": "^0.6.3",
|
"through2": "^0.6.3",
|
||||||
"underscore.string": "^2.4.0",
|
"underscore.string": "^2.4.0",
|
||||||
"urijs": "^1.17.0",
|
"urijs": "^1.17.0",
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
<button class="btn sj_btn_green mb10" style="color:#fff;" ng-click="create()">
|
<button class="btn sj_btn_green mb10" style="color:#fff;" ng-click="create()">
|
||||||
<span class="glyphicon glyphicon-plus"></span> 添加
|
<span class="glyphicon glyphicon-plus"></span> 添加
|
||||||
</button>
|
</button>
|
||||||
|
<button class="btn sj_btn_green mb10" style="color:#fff;" ng-click="createGatherDababase()">
|
||||||
|
<span class="glyphicon glyphicon-plus"></span> 创建汇总库
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
@ -27,19 +30,28 @@
|
||||||
<div class="col-md-6 col-md-offset-1 ">
|
<div class="col-md-6 col-md-offset-1 ">
|
||||||
<form class="form-horizontal" novalidate="novalidate" name="validForm" ng-submit="onSubmit(tableForm)">
|
<form class="form-horizontal" novalidate="novalidate" name="validForm" ng-submit="onSubmit(tableForm)">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">名称</label>
|
<label class="col-sm-3 control-label">名称</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control " type="text" ng-model="tableForm.name" name="orcName" ng-minlength="2" ng-maxlength="20" required="required" ng-focus="tableForm.name=''"/>
|
<input class="system-info-danger-input form-control " type="text" ng-model="tableForm.name" name="orcName" ng-minlength="2" ng-maxlength="20" required="required" ng-focus="tableForm.name" placeholder="请输入2-20个字符的数据名称" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcName.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcName.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcName.$error.required">名称不能为空</span>
|
<span role="alert" ng-show="validForm.orcName.$error.required">名称不能为空</span>
|
||||||
<span role="alert" ng-show="!validForm.orcName.$error.required && validForm.orcName.$invalid">请输入2-20个字符的数据名称</span>
|
<span role="alert" ng-show="!validForm.orcName.$error.required && validForm.orcName.$invalid">请输入2-20个字符的数据名称</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- <div class="form-group" ng-show="add">
|
||||||
|
<label class="col-sm-3 control-label">是否创建汇总库</label>
|
||||||
|
<div class="col-sm-9 sj_form_input ">
|
||||||
|
<select class="form-control " ng-model="tableForm.isCreateGatherOracle">
|
||||||
|
<option value=1 ng-selected="tableForm.isCreateGatherOracle==1">是</option>
|
||||||
|
<option value=0 ng-selected="tableForm.isCreateGatherOracle==0" selected>否</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div> -->
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">IP</label>
|
<label class="col-sm-3 control-label">IP</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.ip" name="orcIP" ng-pattern="/((?:(?:25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(?:25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))))/" required="required" ng-focus="tableForm.ip=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.ip" name="orcIP" ng-pattern="/((?:(?:25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(?:25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))))/" required="required" ng-focus="tableForm.ip" placeholder="oracle的IP,例如:0.0.0.0" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcIP.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcIP.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcIP.$error.required">IP不能为空</span>
|
<span role="alert" ng-show="validForm.orcIP.$error.required">IP不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcIP.$error.pattern">请输入正确的IP地址</span>
|
<span role="alert" ng-show="validForm.orcIP.$error.pattern">请输入正确的IP地址</span>
|
||||||
|
@ -47,19 +59,82 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">端口号</label>
|
<label class="col-sm-3 control-label">端口号</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.port" name="orcPort" ng-pattern="/^([1-9]|[1-9]\d|[1-9]\d{2}|[1-9]\d{3}|[1-5]\d{4}|6[0-4]\d{3}|65[0-4]\d{2}|655[0-2]\d|6553[0-5])$/" required="required" ng-focus="tableForm.port=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.port" name="orcPort" ng-pattern="/^([1-9]|[1-9]\d|[1-9]\d{2}|[1-9]\d{3}|[1-5]\d{4}|6[0-4]\d{3}|65[0-4]\d{2}|655[0-2]\d|6553[0-5])$/" required="required" ng-focus="tableForm.port" placeholder="oracle的的端口,1~65535" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcPort.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcPort.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcPort.$error.required">端口号不能为空</span>
|
<span role="alert" ng-show="validForm.orcPort.$error.required">端口号不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcPort.$error.pattern">端口号必须为1~65535的数字</span>
|
<span role="alert" ng-show="validForm.orcPort.$error.pattern">端口号必须为1~65535的数字</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- <div ng-switch="tableForm.isCreateGatherOracle">
|
||||||
|
<div ng-switch-when="1">
|
||||||
<div class="form-group ">
|
<div class="form-group ">
|
||||||
<label class="col-sm-2 control-label">用戶名</label>
|
<label class="col-sm-3 control-label">开始时间</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.user" name="orcUser" ng-pattern="/^\w{2,15}$/" required="required" ng-focus="tableForm.user=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.startTime" name="startTime" ng-pattern="/^([0-9]{4})-(0?[1-9]|1[0-2])$/" required="required" ng-focus="tableForm.startTime" placeholder="开始时间,格式为yyyy-MM 例如:2018-02" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.startTime.$invalid && submitted">
|
||||||
|
<span role="alert" ng-show="validForm.startTime.$error.required">开始时间不能为空</span>
|
||||||
|
<span role="alert" ng-show="validForm.startTime.$error.pattern">格式为yyyy-MM 例如:2018-02</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">结束时间</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.endTime" name="orcEndTime" ng-pattern="/^([0-9]{4})-(0?[1-9]|1[0-2])$/" required="required" ng-focus="tableForm.endTime" placeholder="结束时间,格式为yyyy-MM 例如:2018-02" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcEndTime.$invalid && submitted">
|
||||||
|
<span role="alert" ng-show="validForm.orcEndTime.$error.required">结束时间不能为空</span>
|
||||||
|
<span role="alert" ng-show="validForm.orcEndTime.$error.pattern">格式为yyyy-MM 例如:2018-02</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系人</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.contact" name="contact" ng-pattern="" required="required" ng-focus="tableForm.contact" placeholder="联系人" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.contact.$invalid && submitted">
|
||||||
|
<span role="alert" ng-show="validForm.contact.$error.required">联系人不能为空</span>
|
||||||
|
<span role="alert" ng-show="validForm.contact.$error.pattern">联系人为有效联系人</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系方式</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.phone" name="phone" ng-pattern="/^[1][3,4,5,7,8][0-9]{9}$/" required="required" ng-focus="tableForm.phone" placeholder="联系方式" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.phone.$invalid && submitted">
|
||||||
|
<span role="alert" ng-show="validForm.phone.$error.required">联系方式不能为空</span>
|
||||||
|
<span role="alert" ng-show="validForm.phone.$error.pattern">手机号必须为有效的手机号码</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">数据版本号</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.dataVersion" name="dataVersion" ng-pattern="/^[1-9]\d*$/" required="required" ng-focus="tableForm.phone" placeholder="数据版本号" ng-init="tableForm.dataVersion=1" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.phone.$invalid && submitted">
|
||||||
|
<span role="alert" ng-show="validForm.phone.$error.required">版本号不能为空</span>
|
||||||
|
<span role="alert" ng-show="validForm.dataVersion.$error.pattern">数据版本号必须为正整数</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">编码方式</label>
|
||||||
|
<div class="col-sm-9 sj_form_input ">
|
||||||
|
<select class="form-control " ng-model="tableForm.encoding">
|
||||||
|
<option value=0 ng-selected="tableForm.encoding==GBK" selected>GBK</option>
|
||||||
|
<option value=1 ng-selected="tableForm.encoding==UTF8">UTF8</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div> -->
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">用戶名</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.user" name="orcUser" ng-pattern="/^\w{2,15}$/" required="required" ng-focus="tableForm.user" placeholder="oracle的用户名,2-15个字母、数字或下划线" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcUser.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcUser.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcUser.$error.required">用户名不能为空</span>
|
<span role="alert" ng-show="validForm.orcUser.$error.required">用户名不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcUser.$error.pattern">用户名必须为2-15个字母、数字或下划线</span>
|
<span role="alert" ng-show="validForm.orcUser.$error.pattern">用户名必须为2-15个字母、数字或下划线</span>
|
||||||
|
@ -67,9 +142,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">密码</label>
|
<label class="col-sm-3 control-label">密码</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.password" name="orcPassword" ng-pattern="/^\w{2,15}$/" required="required" ng-focus="tableForm.password=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.password" name="orcPassword" ng-pattern="/^\w{2,15}$/" required="required" ng-focus="tableForm.password" placeholder="oracle的密码,2-15个字母、数字或下划线" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcPassword.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcPassword.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcPassword.$error.required">密码不能为空</span>
|
<span role="alert" ng-show="validForm.orcPassword.$error.required">密码不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcPassword.$error.pattern">密码必须为2-15个字母、数字或下划线</span>
|
<span role="alert" ng-show="validForm.orcPassword.$error.pattern">密码必须为2-15个字母、数字或下划线</span>
|
||||||
|
@ -77,9 +152,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">服务名</label>
|
<label class="col-sm-3 control-label">服务名</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.databaseName" name="orcService" ng-pattern="/^[a-zA-Z]{1,10}$/" required="required" ng-focus="tableForm.databaseName=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.databaseName" name="orcService" ng-pattern="/^[a-zA-Z]{1,10}$/" required="required" ng-focus="tableForm.databaseName" placeholder="oracle的实例名,1-10个字母,例如ORCL" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcService.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcService.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcService.$error.required">服务名不能为空</span>
|
<span role="alert" ng-show="validForm.orcService.$error.required">服务名不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcService.$error.pattern">服务名必须为1-10个字母</span>
|
<span role="alert" ng-show="validForm.orcService.$error.pattern">服务名必须为1-10个字母</span>
|
||||||
|
@ -87,9 +162,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">表空间名</label>
|
<label class="col-sm-3 control-label">表空间名</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.tableName" name="orcTable" ng-pattern="/^\w{1,15}$/" required="required" ng-focus="tableForm.tableName=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.tableName" name="orcTable" ng-pattern="/^\w{1,15}$/" required="required" ng-focus="tableForm.tableName" placeholder="oracle的表空间名,1-15个字母、数字或下划线" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcTable.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcTable.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcTable.$error.required">表空间名不能为空</span>
|
<span role="alert" ng-show="validForm.orcTable.$error.required">表空间名不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcTable.$error.pattern">表空间名必须为1-15个字母、数字或下划线</span>
|
<span role="alert" ng-show="validForm.orcTable.$error.pattern">表空间名必须为1-15个字母、数字或下划线</span>
|
||||||
|
@ -97,26 +172,26 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">表后缀名</label>
|
<label class="col-sm-3 control-label">用户名后缀</label>
|
||||||
<div class="col-sm-10 sj_form_input">
|
<div class="col-sm-9 sj_form_input">
|
||||||
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.suffix" name="orcSuffix" ng-pattern="/^\w{1,10}$/" required="required" ng-focus="tableForm.suffix=''"/>
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.suffix" name="orcSuffix" ng-pattern="/^\w{1,10}$/" required="required" ng-focus="tableForm.suffix" placeholder="汇总生成新表的后缀名,1-10个字母、数字或下划线" />
|
||||||
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcSuffix.$invalid && submitted">
|
<div class="system-info-danger-red-char form-error" ng-show="validForm.orcSuffix.$invalid && submitted">
|
||||||
<span role="alert" ng-show="validForm.orcSuffix.$error.required">表后缀名不能为空</span>
|
<span role="alert" ng-show="validForm.orcSuffix.$error.required">用户名后缀不能为空</span>
|
||||||
<span role="alert" ng-show="validForm.orcSuffix.$error.pattern">表后缀名必须为1-10个字母、数字或下划线</span>
|
<span role="alert" ng-show="validForm.orcSuffix.$error.pattern">用户名后缀名必须为1-10个字母、数字或下划线</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-2 control-label">标准表汇总库</label>
|
<label class="col-sm-3 control-label">标准表汇总库</label>
|
||||||
<div class="col-sm-10 sj_form_input ">
|
<div class="col-sm-9 sj_form_input ">
|
||||||
<select class="form-control " ng-model="tableForm.type">
|
<select class="form-control " ng-model="tableForm.type">
|
||||||
<option value=0 ng-selected="tableForm.type==0" selected>否</option>
|
<option value=0 ng-selected="tableForm.type==0" ng-init="tableForm.type==0">否</option>
|
||||||
<option value=1 ng-selected="tableForm.type==1">是</option>
|
<option value=1 ng-selected="tableForm.type==1">是</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group" style="margin-left:145px;">
|
<div class="form-group" style="margin-left:145px;">
|
||||||
<button class="btn sj_btn_blue" type='submit' style="color:#fff;" >
|
<button class="btn sj_btn_blue" type='submit' style="color:#fff; margin-right:30px;">
|
||||||
<span class="glyphicon glyphicon-save "></span> 保存
|
<span class="glyphicon glyphicon-save "></span> 保存
|
||||||
</button>
|
</button>
|
||||||
<button class="btn sj_btn_grey" ng-click='cancel()'>
|
<button class="btn sj_btn_grey" ng-click='cancel()'>
|
||||||
|
@ -127,6 +202,121 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
<hr>
|
||||||
|
<div class="row " style="padding-top:10px;" ng-show="tableForm && createDatabase">
|
||||||
|
<h3 class="mb10" ng-show="createDatabase">填写创建汇总库信息:</h3>
|
||||||
|
<div class="col-md-6 col-md-offset-1 ">
|
||||||
|
<form class="form-horizontal" novalidate="novalidate" name="createDatabaseForm" ng-submit="onSubmitCreateDatabase(tableForm)">
|
||||||
|
<div class="form-group" ng-show="0">
|
||||||
|
<label class="col-sm-3 control-label">汇总库系统名称</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control " type="text" ng-model="tableForm.systemName" name="systemName" ng-minlength="2" ng-maxlength="20" required="required" ng-focus="tableForm.systemName" ng-init="tableForm.systemName='汇总库'" placeholder="请输入2-20个字符的汇总库系统名称" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.systemName.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.systemName.$error.required">汇总库系统名称不能为空</span>
|
||||||
|
<span role="alert" ng-show="!createDatabaseForm.systemName.$error.required && createDatabaseForm.systemName.$invalid">请输入2-20个字符的汇总库系统名称</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="form-group ">
|
||||||
|
<label class="col-sm-3 control-label">开始时间</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.startTime" name="startTime" ng-pattern="/^([0-9]{4})-(0?[1-9]|1[0-2])$/" required="required" ng-focus="tableForm.startTime" placeholder="开始时间,格式为yyyy-MM 例如:2018-02" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.startTime.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.startTime.$error.required">开始时间不能为空</span>
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.startTime.$error.pattern">格式为yyyy-MM 例如:2018-02</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">结束时间</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.endTime" name="endTime" ng-pattern="/^([0-9]{4})-(0?[1-9]|1[0-2])$/" required="required" ng-focus="tableForm.endTime" placeholder="结束时间,格式为yyyy-MM 例如:2018-02" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.endTime.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.endTime.$error.required">结束时间不能为空</span>
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.endTime.$error.pattern">格式为yyyy-MM 例如:2018-02</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系人</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.contact" name="contact" ng-pattern="" required="required" ng-focus="tableForm.contact" placeholder="联系人" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.contact.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.contact.$error.required">联系人不能为空</span>
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.contact.$error.pattern">联系人为有效联系人</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系方式</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.phone" name="phone" ng-pattern="/^[1][3,4,5,7,8][0-9]{9}$/" required="required" ng-focus="tableForm.phone" placeholder="联系方式" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.phone.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.phone.$error.required">联系方式不能为空</span>
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.phone.$error.pattern">手机号必须为有效的手机号码</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">数据版本号</label>
|
||||||
|
<div class="col-sm-9 sj_form_input">
|
||||||
|
<input class="system-info-danger-input form-control" type="text" ng-model="tableForm.dataVersion" name="dataVersion" ng-pattern="/^[1-9]\d*$/" required="required" ng-focus="tableForm.dataVersion" placeholder="数据版本号" ng-init="tableForm.dataVersion=1" />
|
||||||
|
<div class="system-info-danger-red-char form-error" ng-show="createDatabaseForm.dataVersion.$invalid && submittedCreateDatabase">
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.dataVersion.$error.required">版本号不能为空</span>
|
||||||
|
<span role="alert" ng-show="createDatabaseForm.dataVersion.$error.pattern">数据版本号必须为正整数</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">编码方式</label>
|
||||||
|
<div class="col-sm-9 sj_form_input ">
|
||||||
|
<select class="form-control " ng-model="createDatabaseForm.encoding">
|
||||||
|
<option value="GBK" ng-selected="createDatabaseForm.encoding==GBK" selected>GBK</option>
|
||||||
|
<option value="UTF8" ng-selected="createDatabaseForm.encoding==UTF8">UTF8</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group" style="margin-left:145px;">
|
||||||
|
<button class="btn sj_btn_blue" type='submit' style="color:#fff; margin-right:30px;">
|
||||||
|
<span class="glyphicon glyphicon-save "></span> 保存
|
||||||
|
</button>
|
||||||
|
<button class="btn sj_btn_grey" ng-click='cancelCreateDatabase()'>
|
||||||
|
<span class="glyphicon glyphicon-remove "></span> 取消
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<hr>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<style>
|
||||||
|
.form-horizontal input::-webkit-input-placeholder {
|
||||||
|
font-family: "微软雅黑";
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 28px;
|
||||||
|
font-style: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-horizontal input::-moz-placeholder {
|
||||||
|
font-family: "微软雅黑";
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 28px;
|
||||||
|
font-style: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-horizontal input:-moz-placeholder {
|
||||||
|
font-family: "微软雅黑";
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 28px;
|
||||||
|
font-style: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-horizontal input:-ms-input-placeholder {
|
||||||
|
font-family: "微软雅黑";
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 28px;
|
||||||
|
font-style: normal;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -411,7 +411,6 @@
|
||||||
<p>一键审核:待审核状态的所有脚本文件,后台一次性全部替换</p>
|
<p>一键审核:待审核状态的所有脚本文件,后台一次性全部替换</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<script type="text/ng-template" id="uploadErrorInfo.html">
|
<script type="text/ng-template" id="uploadErrorInfo.html">
|
||||||
<div class="container-fluid ">
|
<div class="container-fluid ">
|
||||||
|
@ -434,6 +433,44 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</script>
|
</script>
|
||||||
|
<script type="text/ng-template" id="dataExport.html">
|
||||||
|
<div class="container-fluid cl padding20 box-sizing">
|
||||||
|
<div class="sj_table_td05 sj-border-black mt10 padding20 fl">
|
||||||
|
<h3 class="mb10">选择需要导出的数据</h3>
|
||||||
|
<ul class="mb10" style="height:400px;overflow-y:auto;">
|
||||||
|
<li class="cl export-li">
|
||||||
|
<label class="export-label">
|
||||||
|
<input type="checkbox" ng-model="flag" class="fl" ng-click="selectAll(flag)" />
|
||||||
|
<span class="ml5 mt5 fl sj_over_hid">全选</span>
|
||||||
|
</label>
|
||||||
|
</li>
|
||||||
|
<li class="cl export-li" ng-repeat="item in uniqueData">
|
||||||
|
<label class="export-label">
|
||||||
|
<input type="checkbox" id={{item.id}} ng-checked="ischeckedId(item.id) " ng-click="selectId(item.id,$event) " class="fl " />
|
||||||
|
<span class="ml5 mt5 fl sj_over_hid ">{{item.cityName}}_{{item.districtName}}_{{item.systemName}}_{{item.endYear}}_{{item.submittedBatch}}_{{item.dataVersion}}</span>
|
||||||
|
</label>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="sj_table_td05 sj-border-black mt10 padding20 border-left-none fl ">
|
||||||
|
<h3 class="mb10 ">选择导出数据类型</h3>
|
||||||
|
<ul class="mb10 " style="height:400px;overflow-y:auto; ">
|
||||||
|
<li class="cl export-li " ng-repeat="item in export ">
|
||||||
|
<label class="export-label">
|
||||||
|
<input type="checkbox" id={{item.type}} ng-checked="ischeckedType(item.type) " ng-click="selectType(item.type,$event) " class="fl " />
|
||||||
|
<span class="ml5 mt5 fl sj_over_hid " style="width: 100px;">{{item.exportName}}</span>
|
||||||
|
<span class="ml5 mt5 fl sj_over_hid " style="width:100px;" ng-show="item.exportName=='汇总库' && gatherOracleSelected">请选择汇总库</span>
|
||||||
|
<select class="ml5 mt5 fl sj_over_hid" style="width: 150px;" ng-show="item.exportName=='汇总库' && gatherOracleSelected" ng-model="$parent.selectGatherOracleName">
|
||||||
|
<option ng-repeat="one in gatherOracles " value="{{one.id}} ">{{one.name}}</option>
|
||||||
|
</select>
|
||||||
|
</label>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<button class="sj_btn_blue mt20 fr " ng-click="onsubmit(idList,typeList,selectGatherOracleName) ">保存</button>
|
||||||
|
<button class="sj_btn_grey mt20 mr5 fr " ng-click="cancel() ">取消</button>
|
||||||
|
</div>
|
||||||
|
</script>
|
||||||
<div ng-controller="Kubernetes.TopLevel ">
|
<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="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>
|
<div class="row kubernetes-view " ng-view></div>
|
||||||
|
|
|
@ -0,0 +1,215 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="configPlugin.ts"/>
|
||||||
|
/// <reference path="configsDataService.ts"/>
|
||||||
|
/// <reference path="../../developer/ts/developerNavigation.ts"/>
|
||||||
|
/// <reference path="../../developer/ts/dataManagerHelper.ts"/>
|
||||||
|
var Configs;
|
||||||
|
(function (Configs) {
|
||||||
|
var OperateType = (function () {
|
||||||
|
function OperateType() {
|
||||||
|
}
|
||||||
|
Object.defineProperty(OperateType, "DELETE", {
|
||||||
|
get: function () { return "delete"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(OperateType, "UPDATE", {
|
||||||
|
get: function () { return "update"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(OperateType, "PUT", {
|
||||||
|
get: function () { return "put"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(OperateType, "MOVE", {
|
||||||
|
get: function () { return "move"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(OperateType, "EXTRACT", {
|
||||||
|
get: function () { return "extract"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
return OperateType;
|
||||||
|
})();
|
||||||
|
Configs.OperateType = OperateType;
|
||||||
|
Configs._module.controller('Configs.MenuItemController', ['$scope', '$location', function ($scope, $location) {
|
||||||
|
$scope.menuItem = [{
|
||||||
|
icon: "glyphicon glyphicon-cloud-upload",
|
||||||
|
label: "数据管理配置",
|
||||||
|
title: "配置数据存储信息",
|
||||||
|
href: UrlHelpers.join(Configs.context, "/gluster-fs/setting")
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon: "glyphicon glyphicon-th-list",
|
||||||
|
label: "服务集群配置",
|
||||||
|
title: "配置服务集群信息",
|
||||||
|
href: UrlHelpers.join(Configs.context, "/kube-cluster/setting")
|
||||||
|
}];
|
||||||
|
}]);
|
||||||
|
function createConfigBreadcrumbs($scope, $location, $routeParams) {
|
||||||
|
var url = $location.url();
|
||||||
|
var label, title;
|
||||||
|
switch (url) {
|
||||||
|
case "/config/gluster-fs/setting":
|
||||||
|
label = "数据管理配置";
|
||||||
|
title = "配置数据存储信息";
|
||||||
|
break;
|
||||||
|
case "/config/kube-cluster/setting":
|
||||||
|
label = "服务集群配置";
|
||||||
|
title = "配置服务集群信息";
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return Developer.activateCurrent([{
|
||||||
|
href: url,
|
||||||
|
label: label,
|
||||||
|
title: title //item.title
|
||||||
|
}]);
|
||||||
|
}
|
||||||
|
function createOracleInfo(array, id) {
|
||||||
|
var result = { "id": id };
|
||||||
|
angular.forEach(array, function (arr) {
|
||||||
|
result[arr.field] = arr.value;
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Configs.createOracleInfo = createOracleInfo;
|
||||||
|
function shareInit($scope, $location, $routeParams) {
|
||||||
|
$scope.subTabConfig = Developer.createCurrentSubNavBar($scope, $location, $routeParams);
|
||||||
|
$scope.mask = true;
|
||||||
|
/**
|
||||||
|
创建全屏遮挡
|
||||||
|
*/
|
||||||
|
$("#mask").css("position", "absolute");
|
||||||
|
$("#mask").css("background", "black");
|
||||||
|
$("#mask").css("opacity", 0.4);
|
||||||
|
$("#mask").css("filter", "progid:DXImageTransform.Microsoft.Alpha(style=4,opacity=25)");
|
||||||
|
$("#mask").css("top", "0px");
|
||||||
|
$("#mask").css("left", "0px");
|
||||||
|
$("#mask").css("width", document.body.clientWidth + document.body.scrollLeft);
|
||||||
|
$("#mask").css("height", document.body.clientHeight + document.body.scrollTop);
|
||||||
|
$("#mask").css("zIndex", 1000);
|
||||||
|
}
|
||||||
|
Configs.shareInit = shareInit;
|
||||||
|
function createNewObejct(array, obj) {
|
||||||
|
var result = [];
|
||||||
|
if (obj) {
|
||||||
|
angular.forEach(array, function (arr) {
|
||||||
|
result.push({
|
||||||
|
field: arr.field,
|
||||||
|
name: arr.displayName,
|
||||||
|
value: obj[arr.field]
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
angular.forEach(array, function (arr) {
|
||||||
|
result.push({
|
||||||
|
field: arr.field,
|
||||||
|
name: arr.displayName,
|
||||||
|
value: null
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Configs.createNewObejct = createNewObejct;
|
||||||
|
function oracleInfoOperate($http, url, operate, resource, fn) {
|
||||||
|
if (resource === null)
|
||||||
|
throw "不能操作空资源对象";
|
||||||
|
if (angular.isArray(resource)) {
|
||||||
|
var ids = [];
|
||||||
|
angular.forEach(resource, function (item) {
|
||||||
|
var id = item["id"] || item["name"] || item["_id"] || item["_key"];
|
||||||
|
ids.push(id);
|
||||||
|
});
|
||||||
|
$http({
|
||||||
|
method: "POST",
|
||||||
|
dataType: 'json',
|
||||||
|
url: UrlHelpers.join(url, operate + "s"),
|
||||||
|
data: ids,
|
||||||
|
}).success(function (data, header, config, status) {
|
||||||
|
if (angular.isFunction(fn))
|
||||||
|
fn(data, header);
|
||||||
|
}).error(function (data, header, config, status) {
|
||||||
|
if (angular.isFunction(fn))
|
||||||
|
fn(data, header);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var id = resource["id"] || resource["name"] || resource["_id"] || resource["_key"];
|
||||||
|
var RESTfulUrl = url;
|
||||||
|
if (id == "undefined") {
|
||||||
|
RESTfulUrl = UrlHelpers.join(url, operate);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
RESTfulUrl = UrlHelpers.join(url, id + "", operate);
|
||||||
|
}
|
||||||
|
$http({
|
||||||
|
method: "POST",
|
||||||
|
dataType: 'json',
|
||||||
|
url: RESTfulUrl,
|
||||||
|
data: JSON.stringify(resource),
|
||||||
|
}).success(function (data, header, config, status) {
|
||||||
|
if (angular.isFunction(fn))
|
||||||
|
fn(data, header);
|
||||||
|
// console.log("success");
|
||||||
|
// console.log(data + "_." + header + "_.." + config + "_..." + status);
|
||||||
|
// console.log("success");
|
||||||
|
}).error(function (data, header, config, status) {
|
||||||
|
if (angular.isFunction(fn))
|
||||||
|
fn(data, header);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Configs.oracleInfoOperate = oracleInfoOperate;
|
||||||
|
function createConfigHelperNavBar($scope, $location, $routeParams) {
|
||||||
|
return Developer.activateCurrent([
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Configs.context, "regionalism-code/searching"),
|
||||||
|
label: "行政区划检索",
|
||||||
|
title: "检索行政区划代码"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Configs.context, "system-code/searching"),
|
||||||
|
label: "系统编码检索",
|
||||||
|
title: "检索系统编码"
|
||||||
|
}
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
Configs.createConfigHelperNavBar = createConfigHelperNavBar;
|
||||||
|
function formatVolume(volume) {
|
||||||
|
var brick = [];
|
||||||
|
angular.forEach(volume.brick, function (block) {
|
||||||
|
brick.push({
|
||||||
|
ip: block.ip.split("."),
|
||||||
|
status: block.status,
|
||||||
|
path: block.path,
|
||||||
|
editable: block.editable || false
|
||||||
|
});
|
||||||
|
});
|
||||||
|
return {
|
||||||
|
name: volume.name,
|
||||||
|
path: volume.path,
|
||||||
|
brick: brick,
|
||||||
|
status: volume.status,
|
||||||
|
editable: volume.editable || false,
|
||||||
|
hot: volume.hot == 0 ? true : false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
Configs.formatVolume = formatVolume;
|
||||||
|
function volumesFormat(volumes) {
|
||||||
|
var result = [];
|
||||||
|
angular.forEach(volumes, function (volume) {
|
||||||
|
result.push(formatVolume(volume));
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Configs.volumesFormat = volumesFormat;
|
||||||
|
})(Configs || (Configs = {}));
|
||||||
|
//# sourceMappingURL=ConfigsHelper.js.map
|
File diff suppressed because one or more lines are too long
|
@ -9,6 +9,7 @@ module Configs{
|
||||||
public static get UPDATE(): string { return "update" }
|
public static get UPDATE(): string { return "update" }
|
||||||
public static get PUT(): string { return "put" }
|
public static get PUT(): string { return "put" }
|
||||||
public static get MOVE(): string { return "move" }
|
public static get MOVE(): string { return "move" }
|
||||||
|
public static get CREATE_DATABASE(): string { return "createDatabase" }
|
||||||
public static get EXTRACT(): string { return "extract" }
|
public static get EXTRACT(): string { return "extract" }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +25,8 @@ module Configs{
|
||||||
label: "服务集群配置",
|
label: "服务集群配置",
|
||||||
title: "配置服务集群信息",
|
title: "配置服务集群信息",
|
||||||
href: UrlHelpers.join(context, "/kube-cluster/setting")
|
href: UrlHelpers.join(context, "/kube-cluster/setting")
|
||||||
}]
|
}
|
||||||
|
]
|
||||||
}]);
|
}]);
|
||||||
|
|
||||||
function createConfigBreadcrumbs($scope, $location, $routeParams) {
|
function createConfigBreadcrumbs($scope, $location, $routeParams) {
|
||||||
|
@ -111,17 +113,16 @@ module Configs{
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
url: UrlHelpers.join(url, operate + "s"),
|
url: UrlHelpers.join(url, operate + "s"),
|
||||||
data: ids,
|
data: ids,
|
||||||
}).success((data,header,config,status) => {
|
}).then(function successCallback(response) {
|
||||||
if (angular.isFunction(fn))
|
if (angular.isFunction(fn))
|
||||||
fn(data, header);
|
fn(response.data, response.header);
|
||||||
}).error((data,header,config,status) => {
|
}, function errorCallback(response) {
|
||||||
if(angular.isFunction(fn))
|
fn(response.data, response.header);
|
||||||
fn(data, header);
|
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
var id = resource["id"] || resource["name"] || resource["_id"] || resource["_key"];
|
var id = resource["id"] || resource["name"] || resource["_id"] || resource["_key"];
|
||||||
var RESTfulUrl = url;
|
var RESTfulUrl = url;
|
||||||
if(id == "undefined"){
|
if (typeof(id) == "undefined") {
|
||||||
RESTfulUrl = UrlHelpers.join(url, operate);
|
RESTfulUrl = UrlHelpers.join(url, operate);
|
||||||
} else {
|
} else {
|
||||||
RESTfulUrl = UrlHelpers.join(url, id + "", operate);
|
RESTfulUrl = UrlHelpers.join(url, id + "", operate);
|
||||||
|
@ -132,19 +133,27 @@ module Configs{
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
url: RESTfulUrl,
|
url: RESTfulUrl,
|
||||||
data: JSON.stringify(resource),
|
data: JSON.stringify(resource),
|
||||||
}).success((data,header,config,status) => {
|
}).then(function successCallback(response) {
|
||||||
if (angular.isFunction(fn))
|
if (angular.isFunction(fn))
|
||||||
fn(data, header);
|
fn(response.data, response.status);
|
||||||
}).error((data,header,config,status) => {
|
}, function errorCallback(response) {
|
||||||
if(angular.isFunction(fn))
|
fn(response.data, response.status);
|
||||||
fn(data, header);
|
|
||||||
});
|
});
|
||||||
|
// success((data,header,config,status) => {
|
||||||
|
// if(angular.isFunction(fn))
|
||||||
|
// fn(data, header);
|
||||||
|
// // console.log("success");
|
||||||
|
// // console.log(data + "_." + header + "_.." + config + "_..." + status);
|
||||||
|
// // console.log("success");
|
||||||
|
// }).error((data,header,config,status) => {
|
||||||
|
// if(angular.isFunction(fn))
|
||||||
|
// fn(data, header);
|
||||||
|
// });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export function createConfigHelperNavBar($scope, $location, $routeParams) {
|
export function createConfigHelperNavBar($scope, $location, $routeParams) {
|
||||||
return Developer.activateCurrent([
|
return Developer.activateCurrent([{
|
||||||
{
|
|
||||||
href: UrlHelpers.join(context, "regionalism-code/searching"),
|
href: UrlHelpers.join(context, "regionalism-code/searching"),
|
||||||
label: "行政区划检索",
|
label: "行政区划检索",
|
||||||
title: "检索行政区划代码"
|
title: "检索行政区划代码"
|
||||||
|
|
|
@ -0,0 +1,38 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
var Configs;
|
||||||
|
(function (Configs) {
|
||||||
|
Configs.pluginName = "Configs";
|
||||||
|
Configs.context = "/config";
|
||||||
|
Configs.pluginPath = 'plugins/configs/';
|
||||||
|
Configs.templatePath = Configs.pluginPath + 'html/';
|
||||||
|
Configs._module = angular.module(Configs.pluginName, ['hawtio-core', 'hawtio-ui', 'ui.codemirror', 'nvd3', 'ngTable', 'ngDialog']);
|
||||||
|
Configs.route = PluginHelpers.createRoutingFunction(Configs.templatePath);
|
||||||
|
Configs.controller = PluginHelpers.createControllerFunction(Configs._module, Configs.pluginName);
|
||||||
|
Configs._module.config(['$provide', '$routeProvider', function ($provide, $routeProvider) {
|
||||||
|
$routeProvider.when(UrlHelpers.join(Configs.context, 'gluster-fs/setting'), Configs.route('glusterfsSetting.html', false))
|
||||||
|
.when(UrlHelpers.join(Configs.context, 'kube-cluster/setting'), Configs.route('kubeClusterSetting.html', false))
|
||||||
|
.when(Configs.context, { redirectTo: UrlHelpers.join(Configs.context, '/kube-cluster/setting') });
|
||||||
|
}]);
|
||||||
|
Configs._module.run(['viewRegistry', '$templateCache', 'HawtioExtension', '$compile', function (viewRegistry, $templateCache, ext, $compile) {
|
||||||
|
ext.add('config-setting', function ($scope) {
|
||||||
|
var template = $templateCache.get(UrlHelpers.join(Configs.templatePath, "configMenuItem.html"));
|
||||||
|
return $compile(template)($scope);
|
||||||
|
});
|
||||||
|
viewRegistry['config'] = Configs.templatePath + "shareLayout.html";
|
||||||
|
}]);
|
||||||
|
Configs._module.directive('gfsConfigTable', [function () {
|
||||||
|
return {
|
||||||
|
restrict: 'AE',
|
||||||
|
replace: true,
|
||||||
|
scope: {
|
||||||
|
tableTitle: '=',
|
||||||
|
tableContent: '='
|
||||||
|
},
|
||||||
|
template: "<table class=\"table table-hover\">\n <tr>\n <th ng-repeat=\"column in tableTitle.column\" class=\"no-fade table-header\">\n \t<span class=\"{{column.class}}\">{{column.title}}</span>\n </th> \n </tr>\n <tr ng-repeat = \"row in tableContent\" class=\"row.class\">\n \t<td ng-repeat=\"col in row\" class=\"col.class\">\n \t\t<span class=\"col.class\">{{col.title}}</span>\n \t</td>\n </tr> \n </table> \n ",
|
||||||
|
link: function (scope, element, attr) {
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}]);
|
||||||
|
hawtioPluginLoader.addModule(Configs.pluginName);
|
||||||
|
})(Configs || (Configs = {}));
|
||||||
|
//# sourceMappingURL=configPlugin.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"configPlugin.js","sourceRoot":"","sources":["configPlugin.ts"],"names":["Configs"],"mappings":"AAAA,yCAAyC;AAEzC,IAAO,OAAO,CAoDb;AApDD,WAAO,OAAO,EAAC,CAAC;IAEJA,kBAAUA,GAAGA,SAASA,CAACA;IACvBA,eAAOA,GAAGA,SAASA,CAACA;IACpBA,kBAAUA,GAAGA,kBAAkBA,CAACA;IAC7BA,oBAAYA,GAAGA,kBAAUA,GAAGA,OAAOA,CAACA;IACvCA,eAAOA,GAAGA,OAAOA,CAACA,MAAMA,CAACA,kBAAUA,EAAEA,CAACA,aAAaA,EAAEA,WAAWA,EAAEA,eAAeA,EAAEA,MAAMA,EAAEA,SAASA,EAAEA,UAAUA,CAACA,CAACA,CAACA;IACnHA,aAAKA,GAAGA,aAAaA,CAACA,qBAAqBA,CAACA,oBAAYA,CAACA,CAACA;IAC1DA,kBAAUA,GAAGA,aAAaA,CAACA,wBAAwBA,CAACA,eAAOA,EAAEA,kBAAUA,CAACA,CAACA;IAEpFA,eAAOA,CAACA,MAAMA,CAACA,CAACA,UAAUA,EAAEA,gBAAgBA,EAAEA,UAACA,QAAQA,EAAEA,cAAcA;YACtEA,cAAcA,CAACA,IAAIA,CAACA,UAAUA,CAACA,IAAIA,CAACA,eAAOA,EAAEA,oBAAoBA,CAACA,EAAEA,aAAKA,CAACA,uBAAuBA,EAAEA,KAAKA,CAACA,CAACA;iBACpGA,IAAIA,CAACA,UAAUA,CAACA,IAAIA,CAACA,eAAOA,EAAEA,sBAAsBA,CAACA,EAAEA,aAAKA,CAACA,yBAAyBA,EAAEA,KAAKA,CAACA,CAACA;iBAC/FA,IAAIA,CAACA,eAAOA,EAAEA,EAACA,UAAUA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,eAAOA,EAAEA,uBAAuBA,CAACA,EAACA,CAACA,CAACA;QACtFA,CAACA,CAACA,CAACA,CAACA;IAEHA,eAAOA,CAACA,GAAGA,CAACA,CAACA,cAAcA,EAAEA,gBAAgBA,EAAEA,iBAAiBA,EAAEA,UAAUA,EAAEA,UAACA,YAAYA,EAAEA,cAAuCA,EAAEA,GAAGA,EAAGA,QAA2BA;YACjKA,GAAGA,CAACA,GAAGA,CAACA,gBAAgBA,EAAEA,UAACA,MAAMA;gBAChCA,IAAIA,QAAQA,GAAIA,cAAcA,CAACA,GAAGA,CAASA,UAAUA,CAACA,IAAIA,CAACA,oBAAYA,EAAEA,qBAAqBA,CAACA,CAACA,CAACA;gBACjGA,MAAMA,CAACA,QAAQA,CAACA,QAAQA,CAACA,CAACA,MAAMA,CAACA,CAACA;YACnCA,CAACA,CAACA,CAACA;YAEHA,YAAYA,CAACA,QAAQA,CAACA,GAAGA,oBAAYA,GAAGA,kBAAkBA,CAACA;QAC/DA,CAACA,CAACA,CAACA,CAACA;IAENA,eAAOA,CAACA,SAASA,CAACA,gBAAgBA,EAAEA,CAACA;YACpCA,MAAMA,CAAAA;gBACLA,QAAQA,EAAEA,IAAIA;gBACdA,OAAOA,EAAGA,IAAIA;gBACdA,KAAKA,EAAEA;oBACNA,UAAUA,EAAEA,GAAGA;oBACfA,YAAYA,EAAEA,GAAGA;iBACjBA;gBACDA,QAAQA,EAAEA,woBAYDA;gBACDA,IAAIA,EAAEA,UAACA,KAAKA,EAAEA,OAAOA,EAAEA,IAAIA;gBAC3BA,CAACA;aACTA,CAAAA;QACFA,CAACA,CAACA,CAACA,CAACA;IAELA,kBAAkBA,CAACA,SAASA,CAACA,kBAAUA,CAACA,CAACA;AAC1CA,CAACA,EApDM,OAAO,KAAP,OAAO,QAoDb"}
|
|
@ -0,0 +1,129 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="configPlugin.ts"/>
|
||||||
|
var Configs;
|
||||||
|
(function (Configs) {
|
||||||
|
//字节大小转换成字符大小
|
||||||
|
function getStringSize(size) {
|
||||||
|
var result = size;
|
||||||
|
var suffix = ["B", "KB", "MB", "GB", "TB", "PB"];
|
||||||
|
var count = 1;
|
||||||
|
while (result >= 1024) {
|
||||||
|
result = result / 1024;
|
||||||
|
count++;
|
||||||
|
}
|
||||||
|
return result.toFixed(2) + suffix[count];
|
||||||
|
}
|
||||||
|
function formatVolume(volume) {
|
||||||
|
volume["formatTotalSize"] = getStringSize(volume.allSize);
|
||||||
|
volume["formatUsedSize"] = getStringSize(volume.usedSize);
|
||||||
|
volume["editable"] = false;
|
||||||
|
angular.forEach(volume.brick, function (brock) {
|
||||||
|
brock["formatUsedSize"] = getStringSize(brock.usedSize);
|
||||||
|
brock["formatAllSize"] = getStringSize(brock.availableSize);
|
||||||
|
brock["editable"] = false;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function formatVolumes(volumes) {
|
||||||
|
angular.forEach(volumes, function (volume) {
|
||||||
|
formatVolume(volume);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
Configs.formatVolumes = formatVolumes;
|
||||||
|
function IsBrockEquals(brock1, brock2) {
|
||||||
|
return brock1.ip == brock2.ip && brock1.path == brock2.path;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
刪除volume中指定的brock
|
||||||
|
*/
|
||||||
|
function deleteBrock(volume, brock) {
|
||||||
|
for (var i = 0; i < volume.brick.length; i++) {
|
||||||
|
var brick = volume.brick[i];
|
||||||
|
if (IsBrockEquals(brick, brock)) {
|
||||||
|
volume.brick.splice(i, 1);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Configs.deleteBrock = deleteBrock;
|
||||||
|
/**
|
||||||
|
volume添加brock
|
||||||
|
*/
|
||||||
|
function addBrock(volume, brock) {
|
||||||
|
if (brock != null && brock != undefined)
|
||||||
|
volume.brick.push(brock);
|
||||||
|
}
|
||||||
|
Configs.addBrock = addBrock;
|
||||||
|
var ConfigsModelService = (function () {
|
||||||
|
function ConfigsModelService() {
|
||||||
|
this.cluster = [];
|
||||||
|
this.oracleParam = [];
|
||||||
|
this.systemInfo = [];
|
||||||
|
this.regionalismInfo = [];
|
||||||
|
this.updateAllData();
|
||||||
|
}
|
||||||
|
ConfigsModelService.prototype.updateAllData = function () {
|
||||||
|
this.updateVolumeData();
|
||||||
|
this.updateOracleParam();
|
||||||
|
//this.updateCodeInfo();
|
||||||
|
};
|
||||||
|
ConfigsModelService.prototype.updateVolumeData = function () {
|
||||||
|
var result = null;
|
||||||
|
$.ajax({
|
||||||
|
async: false,
|
||||||
|
type: "POST",
|
||||||
|
url: "/java/console/api/volume/list",
|
||||||
|
success: function (data) {
|
||||||
|
if (data) {
|
||||||
|
result = data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.cluster = JSON.parse(result);
|
||||||
|
formatVolumes(this.cluster);
|
||||||
|
};
|
||||||
|
/*public updateCodeInfo(){
|
||||||
|
var result=null;
|
||||||
|
$.ajax({
|
||||||
|
async: false,
|
||||||
|
type : "POST",
|
||||||
|
url : "/java/console/api/code/list",
|
||||||
|
success : function(data) {
|
||||||
|
if(data){
|
||||||
|
result = data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.regionalismInfo = result.regionalism;
|
||||||
|
this.systemInfo = result.system;
|
||||||
|
}*/
|
||||||
|
ConfigsModelService.prototype.updateOracleParam = function () {
|
||||||
|
var result = null;
|
||||||
|
$.ajax({
|
||||||
|
async: false,
|
||||||
|
type: "POST",
|
||||||
|
url: "/java/console/api/oracle/list",
|
||||||
|
success: function (data) {
|
||||||
|
if (data) {
|
||||||
|
result = data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.oracleParam = result;
|
||||||
|
};
|
||||||
|
ConfigsModelService.prototype.getFolderByVolumeName = function (name) {
|
||||||
|
if (this.cluster === null)
|
||||||
|
return null;
|
||||||
|
for (var i = 0; i < this.cluster.length; i++) {
|
||||||
|
if (this.cluster[i].name === name)
|
||||||
|
return this.cluster[i].folder;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return ConfigsModelService;
|
||||||
|
})();
|
||||||
|
Configs.ConfigsModelService = ConfigsModelService;
|
||||||
|
Configs._module.factory('ConfigsModel', ['$rootScope', '$http', '$location', '$resource', function ($rootScope, $http, $location, $resource) {
|
||||||
|
var $scope = new ConfigsModelService();
|
||||||
|
return $scope;
|
||||||
|
}]);
|
||||||
|
})(Configs || (Configs = {}));
|
||||||
|
//# sourceMappingURL=configsDataService.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"configsDataService.js","sourceRoot":"","sources":["configsDataService.ts"],"names":["Configs","Configs.getStringSize","Configs.formatVolume","Configs.formatVolumes","Configs.IsBrockEquals","Configs.deleteBrock","Configs.addBrock","Configs.ConfigsModelService","Configs.ConfigsModelService.constructor","Configs.ConfigsModelService.updateAllData","Configs.ConfigsModelService.updateVolumeData","Configs.ConfigsModelService.updateOracleParam","Configs.ConfigsModelService.getFolderByVolumeName"],"mappings":"AAAA,yCAAyC;AACzC,uCAAuC;AACvC,IAAO,OAAO,CAoKb;AApKD,WAAO,OAAO,EAAA,CAAC;IAiCXA,aAAaA;IAChBA,uBAAuBA,IAAYA;QAClCC,IAAIA,MAAMA,GAAGA,IAAIA,CAACA;QAClBA,IAAIA,MAAMA,GAAEA,CAACA,GAAGA,EAAEA,IAAIA,EAAEA,IAAIA,EAAEA,IAAIA,EAAEA,IAAIA,EAAEA,IAAIA,CAACA,CAACA;QAChDA,IAAIA,KAAKA,GAACA,CAACA,CAACA;QACZA,OAAMA,MAAMA,IAAIA,IAAIA,EAACA,CAACA;YACrBA,MAAMA,GAAGA,MAAMA,GAACA,IAAIA,CAACA;YACrBA,KAAKA,EAAGA,CAACA;QACVA,CAACA;QACDA,MAAMA,CAACA,MAAMA,CAACA,OAAOA,CAACA,CAACA,CAACA,GAAGA,MAAMA,CAACA,KAAKA,CAACA,CAACA;IAC1CA,CAACA;IAEDD,sBAAsBA,MAAaA;QAClCE,MAAMA,CAACA,iBAAiBA,CAACA,GAAGA,aAAaA,CAACA,MAAMA,CAACA,OAAOA,CAACA,CAACA;QAC1DA,MAAMA,CAACA,gBAAgBA,CAACA,GAAGA,aAAaA,CAACA,MAAMA,CAACA,QAAQA,CAACA,CAACA;QAC1DA,MAAMA,CAACA,UAAUA,CAACA,GAAGA,KAAKA,CAACA;QAE3BA,OAAOA,CAACA,OAAOA,CAACA,MAAMA,CAACA,KAAKA,EAAEA,UAACA,KAAKA;YACnCA,KAAKA,CAACA,gBAAgBA,CAACA,GAAGA,aAAaA,CAACA,KAAKA,CAACA,QAAQA,CAACA,CAACA;YACxDA,KAAKA,CAACA,eAAeA,CAACA,GAAGA,aAAaA,CAACA,KAAKA,CAACA,aAAaA,CAACA,CAACA;YAC5DA,KAAKA,CAACA,UAAUA,CAACA,GAAGA,KAAKA,CAACA;QAC3BA,CAACA,CAACA,CAAAA;IACHA,CAACA;IAEDF,uBAA8BA,OAAqBA;QAClDG,OAAOA,CAACA,OAAOA,CAACA,OAAOA,EAAEA,UAACA,MAAMA;YAC/BA,YAAYA,CAACA,MAAMA,CAACA,CAACA;QACtBA,CAACA,CAACA,CAAAA;IACHA,CAACA;IAJeH,qBAAaA,gBAI5BA,CAAAA;IAEDA,uBAAuBA,MAAaA,EAAEA,MAAaA;QAClDI,MAAMA,CAACA,MAAMA,CAACA,EAAEA,IAAIA,MAAMA,CAACA,EAAEA,IAAIA,MAAMA,CAACA,IAAIA,IAAIA,MAAMA,CAACA,IAAIA,CAACA;IAC7DA,CAACA;IAEDJ;;MAEEA;IACFA,qBAA4BA,MAAaA,EAAEA,KAAWA;QACrDK,GAAGA,CAAAA,CAACA,GAAGA,CAACA,CAACA,GAAGA,CAACA,EAAEA,CAACA,GAAGA,MAAMA,CAACA,KAAKA,CAACA,MAAMA,EAAEA,CAACA,EAAEA,EAACA,CAACA;YAC5CA,IAAIA,KAAKA,GAAGA,MAAMA,CAACA,KAAKA,CAACA,CAACA,CAACA,CAACA;YAC5BA,EAAEA,CAAAA,CAACA,aAAaA,CAACA,KAAKA,EAAEA,KAAKA,CAACA,CAACA,CAAAA,CAACA;gBAC/BA,MAAMA,CAACA,KAAKA,CAACA,MAAMA,CAACA,CAACA,EAAEA,CAACA,CAACA,CAACA;gBAC1BA,KAAKA,CAACA;YACPA,CAACA;QACFA,CAACA;IACFA,CAACA;IAReL,mBAAWA,cAQ1BA,CAAAA;IAEDA;;MAEEA;IACFA,kBAAyBA,MAAaA,EAAEA,KAAWA;QAClDM,EAAEA,CAAAA,CAACA,KAAKA,IAAIA,IAAIA,IAAIA,KAAKA,IAAIA,SAASA,CAACA;YACtCA,MAAMA,CAACA,KAAKA,CAACA,IAAIA,CAACA,KAAKA,CAACA,CAACA;IAC3BA,CAACA;IAHeN,gBAAQA,WAGvBA,CAAAA;IAEDA;QAMCO;YALOC,YAAOA,GAAgBA,EAAEA,CAACA;YAC1BA,gBAAWA,GAAqBA,EAAEA,CAACA;YACnCA,eAAUA,GAAcA,EAAEA,CAACA;YAC3BA,oBAAeA,GAAeA,EAAEA,CAACA;YAGvCA,IAAIA,CAACA,aAAaA,EAAEA,CAACA;QACtBA,CAACA;QAEMD,2CAAaA,GAApBA;YACCE,IAAIA,CAACA,gBAAgBA,EAAEA,CAACA;YACxBA,IAAIA,CAACA,iBAAiBA,EAAEA,CAACA;YACzBA,wBAAwBA;QACzBA,CAACA;QACSF,8CAAgBA,GAAvBA;YACCG,IAAIA,MAAMA,GAACA,IAAIA,CAACA;YAChBA,CAACA,CAACA,IAAIA,CAACA;gBACTA,KAAKA,EAAEA,KAAKA;gBACZA,IAAIA,EAAGA,MAAMA;gBACbA,GAAGA,EAAGA,+BAA+BA;gBACrCA,OAAOA,EAAGA,UAASA,IAAIA;oBACnB,EAAE,CAAA,CAAC,IAAI,CAAC,CAAA,CAAC;wBACR,MAAM,GAAG,IAAI,CAAC;oBAClB,CAAC;gBACF,CAAC;aACDA,CAACA,CAACA;YACHA,IAAIA,CAACA,OAAOA,GAAEA,IAAIA,CAACA,KAAKA,CAACA,MAAMA,CAACA,CAACA;YAC9BA,aAAaA,CAACA,IAAIA,CAACA,OAAOA,CAACA,CAACA;QAChCA,CAACA;QAEDH;;;;;;;;;;;;;;WAcGA;QAEIA,+CAAiBA,GAAxBA;YACCI,IAAIA,MAAMA,GAACA,IAAIA,CAACA;YAChBA,CAACA,CAACA,IAAIA,CAACA;gBACNA,KAAKA,EAAEA,KAAKA;gBACZA,IAAIA,EAAGA,MAAMA;gBACbA,GAAGA,EAAGA,+BAA+BA;gBACrCA,OAAOA,EAAGA,UAASA,IAAIA;oBACnB,EAAE,CAAA,CAAC,IAAI,CAAC,CAAA,CAAC;wBACR,MAAM,GAAG,IAAI,CAAC;oBAClB,CAAC;gBACF,CAAC;aACDA,CAACA,CAACA;YACHA,IAAIA,CAACA,WAAWA,GAAGA,MAAMA,CAACA;QAC3BA,CAACA;QAEMJ,mDAAqBA,GAA5BA,UAA6BA,IAAYA;YACxCK,EAAEA,CAAAA,CAACA,IAAIA,CAACA,OAAOA,KAAGA,IAAIA,CAACA;gBACtBA,MAAMA,CAACA,IAAIA,CAACA;YACbA,GAAGA,CAAAA,CAACA,GAAGA,CAAEA,CAACA,GAACA,CAACA,EAAEA,CAACA,GAAEA,IAAIA,CAACA,OAAOA,CAACA,MAAMA,EAAEA,CAACA,EAAEA,EAACA,CAACA;gBAC1CA,EAAEA,CAAAA,CAACA,IAAIA,CAACA,OAAOA,CAACA,CAACA,CAACA,CAACA,IAAIA,KAAKA,IAAIA,CAACA;oBAChCA,MAAMA,CAACA,IAAIA,CAACA,OAAOA,CAACA,CAACA,CAACA,CAACA,MAAMA,CAACA;YAChCA,CAACA;QACFA,CAACA;QACFL,0BAACA;IAADA,CAACA,AAtEDP,IAsECA;IAtEYA,2BAAmBA,sBAsE/BA,CAAAA;IAEEA,eAAOA,CAACA,OAAOA,CAACA,cAAcA,EAAEA,CAACA,YAAYA,EAAEA,OAAOA,EAAEA,WAAWA,EAAEA,WAAWA,EAAEA,UAACA,UAAUA,EAAEA,KAAKA,EAAEA,SAASA,EAAEA,SAASA;YACzHA,IAAIA,MAAMA,GAAGA,IAAIA,mBAAmBA,EAAEA,CAACA;YACvCA,MAAMA,CAACA,MAAMA,CAACA;QACfA,CAACA,CAACA,CAACA,CAACA;AACRA,CAACA,EApKM,OAAO,KAAP,OAAO,QAoKb"}
|
|
@ -48,48 +48,18 @@ module Configs{
|
||||||
return object;
|
return object;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
export function downloadFile($scope, $http, url, fileName, fn ? ) {
|
||||||
export function downloadFile($scope, $http, url, fn?){
|
var xhr = new XMLHttpRequest();
|
||||||
$http.get(url, { responseType: 'arraybuffer'})
|
xhr.open('GET', url, true);
|
||||||
.success( function(data, status, headers) {
|
xhr.responseType = "blob";
|
||||||
if(angular.isFunction(fn))
|
xhr.onload = function() {
|
||||||
fn();
|
if (this.status == 200) {
|
||||||
|
var blob = this.response;
|
||||||
var octetStreamMime = 'application/octet-stream';
|
var octetStreamMime = 'application/octet-stream';
|
||||||
var success = false;
|
|
||||||
// Get the headers
|
|
||||||
headers = headers();
|
|
||||||
// Get the filename from the x-filename header or default to "服务列表"
|
// Get the filename from the x-filename header or default to "服务列表"
|
||||||
var filename = "服务文件";
|
var filename = fileName;
|
||||||
var params = headers['content-disposition'].split(";");
|
|
||||||
for(var i = 0; i< params.length; i++){
|
|
||||||
if(params[i].indexOf("filename") != -1){
|
|
||||||
var tmp = params[i].split("=");
|
|
||||||
if(tmp.length == 2)
|
|
||||||
filename = tmp[1].replace(new RegExp("\"", "gm"),"");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Determine the content type from the header or default to "application/octet-stream"
|
// Determine the content type from the header or default to "application/octet-stream"
|
||||||
var contentType = headers['content-type'] || octetStreamMime;
|
var contentType = octetStreamMime;
|
||||||
try{
|
|
||||||
// Try using msSaveBlob if supported
|
|
||||||
console.log("Trying saveBlob method ...");
|
|
||||||
var blob = new Blob([data], { type: contentType });
|
|
||||||
if(navigator.msSaveBlob)
|
|
||||||
navigator.msSaveBlob(blob, filename);
|
|
||||||
else {
|
|
||||||
// Try using other saveBlob implementations, if available
|
|
||||||
var saveBlob = navigator["webkitSaveBlob"] || navigator["mozSaveBlob"] || navigator["saveBlob"];
|
|
||||||
if(saveBlob === undefined) throw "Not supported";
|
|
||||||
saveBlob(blob, filename);
|
|
||||||
}
|
|
||||||
console.log("saveBlob succeeded");
|
|
||||||
success = true;
|
|
||||||
} catch(ex){
|
|
||||||
console.log("saveBlob method failed with the following exception:");
|
|
||||||
console.log(ex);
|
|
||||||
}
|
|
||||||
if(!success){
|
|
||||||
// Get the blob url creator
|
// Get the blob url creator
|
||||||
var urlCreator = window.URL || window["webkitURL"] || window["mozURL"] || window["msURL"];
|
var urlCreator = window.URL || window["webkitURL"] || window["mozURL"] || window["msURL"];
|
||||||
if (urlCreator) {
|
if (urlCreator) {
|
||||||
|
@ -100,7 +70,7 @@ module Configs{
|
||||||
try {
|
try {
|
||||||
// Prepare a blob URL
|
// Prepare a blob URL
|
||||||
console.log("Trying download link method with simulated click ...");
|
console.log("Trying download link method with simulated click ...");
|
||||||
var blob = new Blob([data], { type: contentType });
|
|
||||||
var url = urlCreator.createObjectURL(blob);
|
var url = urlCreator.createObjectURL(blob);
|
||||||
link.setAttribute('href', url);
|
link.setAttribute('href', url);
|
||||||
// Set the download attribute (Supported in Chrome 14+ / Firefox 20+)
|
// Set the download attribute (Supported in Chrome 14+ / Firefox 20+)
|
||||||
|
@ -110,51 +80,97 @@ module Configs{
|
||||||
event.initMouseEvent('click', true, true, window, 1, 0, 0, 0, 0, false, false, false, false, 0, null);
|
event.initMouseEvent('click', true, true, window, 1, 0, 0, 0, 0, false, false, false, false, 0, null);
|
||||||
link.dispatchEvent(event);
|
link.dispatchEvent(event);
|
||||||
console.log("Download link method with simulated click succeeded");
|
console.log("Download link method with simulated click succeeded");
|
||||||
success = true;
|
Configs.customAlert("提示", "文件下载完成", '', null, 0, "success");
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
console.log("Download link method with simulated click failed with the following exception:");
|
console.log("Download link method with simulated click failed with the following exception:");
|
||||||
console.log(ex);
|
console.log(ex);
|
||||||
|
Configs.customAlert("提示", "文件下载失败", '', null, 0, "error");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(!success){
|
} else {
|
||||||
// Fallback to window.location method
|
|
||||||
try{
|
|
||||||
// Prepare a blob URL
|
|
||||||
// Use application/octet-stream when using window.location to force download
|
|
||||||
console.log("Trying download link method with window.location ...");
|
|
||||||
var blob = new Blob([data], { type: octetStreamMime });
|
|
||||||
var url = urlCreator.createObjectURL(blob);
|
|
||||||
window.location = url;
|
|
||||||
console.log("Download link method with window.location succeeded");
|
|
||||||
success = true;
|
|
||||||
}catch(ex){
|
|
||||||
console.log("Download link method with window.location failed with the following exception:");
|
|
||||||
console.log(ex);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(!success){
|
|
||||||
// Fallback to window.open method
|
// Fallback to window.open method
|
||||||
console.log("No methods worked for saving the arraybuffer, using last resort window.open");
|
console.log("No methods worked for saving the arraybuffer, using last resort window.open");
|
||||||
window.open('_blank', '');
|
window.open('_blank', '');
|
||||||
Configs.customAlert("提示", "文件下载失败", '', null, 0, "error");
|
Configs.customAlert("提示", "文件下载失败", '', null, 0, "error");
|
||||||
}
|
}
|
||||||
}).error(function(data, status) {
|
|
||||||
console.log("Request failed with status: " + status);
|
|
||||||
// Optionally write the error out to scope
|
|
||||||
fn();
|
|
||||||
Configs.customAlert("提示", "文件下载失败", '',null, 0, "error");
|
|
||||||
$scope.errorDetails = "Request failed with status: " + status;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
if (angular.isFunction(fn))
|
||||||
|
fn();
|
||||||
|
}
|
||||||
|
xhr.send();
|
||||||
|
}
|
||||||
|
// export function downloadFile($scope, $http, url, fn ? ) {
|
||||||
|
// $http.get(url, { responseType: 'arraybuffer' }).then(function successCallback(response) {
|
||||||
|
// $scope.names = response.data.sites;
|
||||||
|
// }, function errorCallback(response) {
|
||||||
|
// // 请求失败执行代码
|
||||||
|
// });
|
||||||
|
// .success(function(data, status, headers) {
|
||||||
|
// var octetStreamMime = 'application/octet-stream';
|
||||||
|
// var success = false;
|
||||||
|
// // Get the headers
|
||||||
|
// headers = headers();
|
||||||
|
// // Get the filename from the x-filename header or default to "服务列表"
|
||||||
|
// var filename = "服务文件";
|
||||||
|
// var params = headers['content-disposition'].split(";");
|
||||||
|
// for (var i = 0; i < params.length; i++) {
|
||||||
|
// if (params[i].indexOf("filename") != -1) {
|
||||||
|
// var tmp = params[i].split("=");
|
||||||
|
// if (tmp.length == 2)
|
||||||
|
// filename = tmp[1].replace(new RegExp("\"", "gm"), "");
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// // Determine the content type from the header or default to "application/octet-stream"
|
||||||
|
// var contentType = octetStreamMime;
|
||||||
|
|
||||||
|
// // Get the blob url creator
|
||||||
|
// var urlCreator = window.URL || window["webkitURL"] || window["mozURL"] || window["msURL"];
|
||||||
|
// if (urlCreator) {
|
||||||
|
// // Try to use a download link
|
||||||
|
// var link = document.createElement('a');
|
||||||
|
// if ('download' in link) {
|
||||||
|
// // Try to simulate a click
|
||||||
|
// try {
|
||||||
|
// // Prepare a blob URL
|
||||||
|
// console.log("Trying download link method with simulated click ...");
|
||||||
|
// var blob = new Blob([data], { type: contentType });
|
||||||
|
// var url = urlCreator.createObjectURL(blob);
|
||||||
|
// link.setAttribute('href', url);
|
||||||
|
// // Set the download attribute (Supported in Chrome 14+ / Firefox 20+)
|
||||||
|
// link.setAttribute("download", filename);
|
||||||
|
// // Simulate clicking the download link
|
||||||
|
// var event = document.createEvent('MouseEvents');
|
||||||
|
// event.initMouseEvent('click', true, true, window, 1, 0, 0, 0, 0, false, false, false, false, 0, null);
|
||||||
|
// link.dispatchEvent(event);
|
||||||
|
// console.log("Download link method with simulated click succeeded");
|
||||||
|
|
||||||
|
// } catch (ex) {
|
||||||
|
// console.log("Download link method with simulated click failed with the following exception:");
|
||||||
|
// console.log(ex);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// } else {
|
||||||
|
// // Fallback to window.open method
|
||||||
|
// console.log("No methods worked for saving the arraybuffer, using last resort window.open");
|
||||||
|
// window.open('_blank', '');
|
||||||
|
// Configs.customAlert("提示", "文件下载失败", '', null, 0, "error");
|
||||||
|
// }
|
||||||
|
// }).error(function(data, status) {
|
||||||
|
// console.log("Request failed with status: " + status);
|
||||||
|
// // Optionally write the error out to scope
|
||||||
|
// Configs.customAlert("提示", "文件下载失败", '', null, 0, "error");
|
||||||
|
// $scope.errorDetails = "Request failed with status: " + status;
|
||||||
|
// });
|
||||||
|
// }
|
||||||
|
|
||||||
export function FileInputPlugin(fn: Function, isMultiple ? : boolean) {
|
export function FileInputPlugin(fn: Function, isMultiple ? : boolean) {
|
||||||
var inputObj = document.createElement('input');
|
var inputObj = document.createElement('input');
|
||||||
inputObj.setAttribute('id', 'myFileInput');
|
inputObj.setAttribute('id', 'myFileInput');
|
||||||
inputObj.setAttribute('type', 'file');
|
inputObj.setAttribute('type', 'file');
|
||||||
inputObj.setAttribute("style", 'visibility:hidden');
|
inputObj.setAttribute("style", 'visibility:hidden');
|
||||||
inputObj.setAttribute("accept", "application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet");
|
// inputObj.setAttribute("accept", "application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet");
|
||||||
|
inputObj.setAttribute("accept", "application/sql");
|
||||||
if (isMultiple)
|
if (isMultiple)
|
||||||
inputObj.setAttribute("multiple", "multiple");
|
inputObj.setAttribute("multiple", "multiple");
|
||||||
document.body.appendChild(inputObj);
|
document.body.appendChild(inputObj);
|
||||||
|
|
|
@ -0,0 +1,117 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
var Configs;
|
||||||
|
(function (Configs) {
|
||||||
|
function customAlert(title, content, func, cancel, focus, icon) {
|
||||||
|
/*
|
||||||
|
自定义 alert框
|
||||||
|
title :
|
||||||
|
text :
|
||||||
|
func :
|
||||||
|
cancel:
|
||||||
|
focus :
|
||||||
|
icon :
|
||||||
|
*/
|
||||||
|
icon = "../../../new/images/msgbox_" + icon + ".png";
|
||||||
|
create_mask();
|
||||||
|
var temp = "<div class=\"custom-alert\" >"
|
||||||
|
+ "<div class=\"custom-alert-title\">" + title + "</div>"
|
||||||
|
+ "<table class=\"custom-alert-body\"><tr><td class=\"custom-alert-td\"><img src=\""
|
||||||
|
+ icon + "\" class=\"custom-alert-img\"></td>"
|
||||||
|
+ "<td ><div calss=\"custom-alert-content\">"
|
||||||
|
+ content + "</div></td></tr></table>"
|
||||||
|
+ "<div class=\"custom-alert-bottom\"><input type='button' "
|
||||||
|
+ " class=\"custom-alert-ok\" value='确认' id=\"msgconfirmb\" onclick=\"Configs.remove();"
|
||||||
|
+ func + ";\">";
|
||||||
|
if (null != cancel) {
|
||||||
|
temp += " <input type='button' class=\"custom-alert-cancel\" onClick='Configs.remove()'>";
|
||||||
|
}
|
||||||
|
temp += "</div></div>";
|
||||||
|
create_msgbox(400, 200, temp);
|
||||||
|
if (focus == 0 || focus == "0" || null == focus) {
|
||||||
|
document.getElementById("msgconfirmb").focus();
|
||||||
|
}
|
||||||
|
else if (focus == 1 || focus == "1") {
|
||||||
|
document.getElementById("msgcancelb").focus();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Configs.customAlert = customAlert;
|
||||||
|
function get_width() {
|
||||||
|
return (document.body.clientWidth + document.body.scrollLeft);
|
||||||
|
}
|
||||||
|
function get_height() {
|
||||||
|
return (document.body.clientHeight + document.body.scrollTop);
|
||||||
|
}
|
||||||
|
function get_left(w) {
|
||||||
|
var bw = document.body.clientWidth;
|
||||||
|
var bh = document.body.clientHeight;
|
||||||
|
w = parseFloat(w);
|
||||||
|
return (bw / 2 - w / 2 + document.body.scrollLeft);
|
||||||
|
}
|
||||||
|
function get_top(h) {
|
||||||
|
var bw = document.body.clientWidth;
|
||||||
|
var bh = document.body.clientHeight;
|
||||||
|
h = parseFloat(h);
|
||||||
|
return (bh / 2 - h / 2 + document.body.scrollTop);
|
||||||
|
}
|
||||||
|
function create_mask() {
|
||||||
|
var mask = document.createElement("div");
|
||||||
|
mask.id = "mask";
|
||||||
|
mask.style.position = "absolute";
|
||||||
|
mask.style.filter = "progid:DXImageTransform.Microsoft.Alpha(style=4,opacity=25)";
|
||||||
|
mask.style.opacity = "0.4";
|
||||||
|
mask.style.background = "black";
|
||||||
|
mask.style.top = "0px";
|
||||||
|
mask.style.left = "0px";
|
||||||
|
mask.style.width = get_width() + "px";
|
||||||
|
mask.style.height = get_height() + "px";
|
||||||
|
mask.style.zIndex = "1000000000";
|
||||||
|
document.body.appendChild(mask);
|
||||||
|
}
|
||||||
|
Configs.create_mask = create_mask;
|
||||||
|
function create_msgbox(w, h, t) {
|
||||||
|
var box = document.createElement("div");
|
||||||
|
box.id = "msgbox";
|
||||||
|
box.style.position = "absolute";
|
||||||
|
box.style.width = w + "px";
|
||||||
|
box.style.height = h + "px";
|
||||||
|
box.style.overflow = "visible";
|
||||||
|
box.innerHTML = t;
|
||||||
|
box.style.zIndex = "1000000001";
|
||||||
|
document.body.appendChild(box);
|
||||||
|
re_pos();
|
||||||
|
}
|
||||||
|
function re_mask() {
|
||||||
|
var mask = document.getElementById("mask");
|
||||||
|
if (null == mask)
|
||||||
|
return;
|
||||||
|
mask.style.width = get_width() + "px";
|
||||||
|
mask.style.height = get_height() + "px";
|
||||||
|
}
|
||||||
|
function re_pos() {
|
||||||
|
var box = document.getElementById("msgbox");
|
||||||
|
if (null != box) {
|
||||||
|
var w = box.style.width;
|
||||||
|
var h = box.style.height;
|
||||||
|
box.style.left = get_left(w) + "px";
|
||||||
|
box.style.top = get_top(h) + "px";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function remove() {
|
||||||
|
var mask = document.getElementById("mask");
|
||||||
|
var msgbox = document.getElementById("msgbox");
|
||||||
|
if (null == mask && null == msgbox)
|
||||||
|
return;
|
||||||
|
document.body.removeChild(mask);
|
||||||
|
document.body.removeChild(msgbox);
|
||||||
|
}
|
||||||
|
Configs.remove = remove;
|
||||||
|
function re_show() {
|
||||||
|
re_pos();
|
||||||
|
re_mask();
|
||||||
|
}
|
||||||
|
function load_func() {
|
||||||
|
window.onresize = re_show;
|
||||||
|
window.onscroll = re_show;
|
||||||
|
}
|
||||||
|
})(Configs || (Configs = {}));
|
||||||
|
//# sourceMappingURL=customAlert.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"customAlert.js","sourceRoot":"","sources":["customAlert.ts"],"names":["Configs","Configs.customAlert","Configs.get_width","Configs.get_height","Configs.get_left","Configs.get_top","Configs.create_mask","Configs.create_msgbox","Configs.re_mask","Configs.re_pos","Configs.remove","Configs.re_show","Configs.load_func"],"mappings":"AAAA,yCAAyC;AACzC,IAAO,OAAO,CAwHb;AAxHD,WAAO,OAAO,EAAA,CAAC;IACdA,qBAA4BA,KAAKA,EAAEA,OAAOA,EAAEA,IAAIA,EAAEA,MAAMA,EAAEA,KAAKA,EAAEA,IAAIA;QACpEC;;;;;;;;UAQQA;QACFA,IAAIA,GAAGA,6BAA6BA,GAAGA,IAAIA,GAAGA,MAAMA,CAACA;QACrDA,WAAWA,EAAEA,CAACA;QACdA,IAAIA,IAAIA,GAAGA,+BAA+BA;cACvCA,oCAAoCA,GAAGA,KAAKA,GAAGA,QAAQA;cACvDA,mFAAmFA;cACnFA,IAAIA,GAAGA,qCAAqCA;cAC5CA,2CAA2CA;cAC3CA,OAAOA,GAAGA,0BAA0BA;cACpCA,0DAA0DA;cAC1DA,sFAAsFA;cACtFA,IAAIA,GAAGA,MAAMA,CAACA;QACjBA,EAAEA,CAACA,CAACA,IAAIA,IAAIA,MAAMA,CAACA,CAACA,CAACA;YACjBA,IAAIA,IAAIA,kGAAkGA,CAACA;QAC/GA,CAACA;QACDA,IAAIA,IAAIA,cAAcA,CAACA;QAEvBA,aAAaA,CAACA,GAAGA,EAAEA,GAAGA,EAAEA,IAAIA,CAACA,CAACA;QAE9BA,EAAEA,CAACA,CAACA,KAAKA,IAAIA,CAACA,IAAIA,KAAKA,IAAIA,GAAGA,IAAIA,IAAIA,IAAIA,KAAKA,CAACA,CAACA,CAACA;YAC9CA,QAAQA,CAACA,cAAcA,CAACA,aAAaA,CAACA,CAACA,KAAKA,EAAEA,CAACA;QACnDA,CAACA;QAACA,IAAIA,CAACA,EAAEA,CAACA,CAACA,KAAKA,IAAIA,CAACA,IAAIA,KAAKA,IAAIA,GAAGA,CAACA,CAACA,CAACA;YACpCA,QAAQA,CAACA,cAAcA,CAACA,YAAYA,CAACA,CAACA,KAAKA,EAAEA,CAACA;QAClDA,CAACA;IACLA,CAACA;IAjCYD,mBAAWA,cAiCvBA,CAAAA;IAEDA;QACIE,MAAMA,CAACA,CAACA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,UAAUA,CAACA,CAACA;IAClEA,CAACA;IAEDF;QACIG,MAAMA,CAACA,CAACA,QAAQA,CAACA,IAAIA,CAACA,YAAYA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,SAASA,CAACA,CAACA;IAClEA,CAACA;IAEDH,kBAAkBA,CAACA;QACfI,IAAIA,EAAEA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA;QACnCA,IAAIA,EAAEA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,YAAYA,CAACA;QACpCA,CAACA,GAAGA,UAAUA,CAACA,CAACA,CAACA,CAACA;QAClBA,MAAMA,CAACA,CAACA,EAAEA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,UAAUA,CAACA,CAACA;IACvDA,CAACA;IAEDJ,iBAAiBA,CAACA;QACdK,IAAIA,EAAEA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA;QACnCA,IAAIA,EAAEA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,YAAYA,CAACA;QACpCA,CAACA,GAAGA,UAAUA,CAACA,CAACA,CAACA,CAACA;QAClBA,MAAMA,CAACA,CAACA,EAAEA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,QAAQA,CAACA,IAAIA,CAACA,SAASA,CAACA,CAACA;IACtDA,CAACA;IAEDL;QACIM,IAAIA,IAAIA,GAAGA,QAAQA,CAACA,aAAaA,CAACA,KAAKA,CAACA,CAACA;QACzCA,IAAIA,CAACA,EAAEA,GAAGA,MAAMA,CAACA;QACjBA,IAAIA,CAACA,KAAKA,CAACA,QAAQA,GAAGA,UAAUA,CAACA;QACjCA,IAAIA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,6DAA6DA,CAACA;QAClFA,IAAIA,CAACA,KAAKA,CAACA,OAAOA,GAAGA,KAAKA,CAACA;QAC3BA,IAAIA,CAACA,KAAKA,CAACA,UAAUA,GAAGA,OAAOA,CAACA;QAChCA,IAAIA,CAACA,KAAKA,CAACA,GAAGA,GAAGA,KAAKA,CAACA;QACvBA,IAAIA,CAACA,KAAKA,CAACA,IAAIA,GAAGA,KAAKA,CAACA;QACxBA,IAAIA,CAACA,KAAKA,CAACA,KAAKA,GAAGA,SAASA,EAAEA,GAAGA,IAAIA,CAACA;QACtCA,IAAIA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,UAAUA,EAAEA,GAAGA,IAAIA,CAACA;QACxCA,IAAIA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,YAAYA,CAACA;QACjCA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA,IAAIA,CAACA,CAACA;IACpCA,CAACA;IAbeN,mBAAWA,cAa1BA,CAAAA;IAEDA,uBAAuBA,CAACA,EAAEA,CAACA,EAAEA,CAACA;QAC1BO,IAAIA,GAAGA,GAAGA,QAAQA,CAACA,aAAaA,CAACA,KAAKA,CAACA,CAACA;QACxCA,GAAGA,CAACA,EAAEA,GAAGA,QAAQA,CAACA;QAClBA,GAAGA,CAACA,KAAKA,CAACA,QAAQA,GAAGA,UAAUA,CAACA;QAChCA,GAAGA,CAACA,KAAKA,CAACA,KAAKA,GAAGA,CAACA,GAAGA,IAAIA,CAACA;QAC3BA,GAAGA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,CAACA,GAAGA,IAAIA,CAACA;QAC5BA,GAAGA,CAACA,KAAKA,CAACA,QAAQA,GAAGA,SAASA,CAACA;QAC/BA,GAAGA,CAACA,SAASA,GAAGA,CAACA,CAACA;QAClBA,GAAGA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,YAAYA,CAACA;QAChCA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA,GAAGA,CAACA,CAACA;QAC/BA,MAAMA,EAAEA,CAACA;IACbA,CAACA;IAEDP;QACIQ,IAAIA,IAAIA,GAAGA,QAAQA,CAACA,cAAcA,CAACA,MAAMA,CAACA,CAACA;QAC3CA,EAAEA,CAACA,CAACA,IAAIA,IAAIA,IAAIA,CAACA;YAACA,MAAMA,CAACA;QACzBA,IAAIA,CAACA,KAAKA,CAACA,KAAKA,GAAGA,SAASA,EAAEA,GAAGA,IAAIA,CAACA;QACtCA,IAAIA,CAACA,KAAKA,CAACA,MAAMA,GAAGA,UAAUA,EAAEA,GAAGA,IAAIA,CAACA;IAC5CA,CAACA;IAEDR;QACIS,IAAIA,GAAGA,GAAGA,QAAQA,CAACA,cAAcA,CAACA,QAAQA,CAACA,CAACA;QAC5CA,EAAEA,CAACA,CAACA,IAAIA,IAAIA,GAAGA,CAACA,CAACA,CAACA;YACdA,IAAIA,CAACA,GAAGA,GAAGA,CAACA,KAAKA,CAACA,KAAKA,CAACA;YACxBA,IAAIA,CAACA,GAAGA,GAAGA,CAACA,KAAKA,CAACA,MAAMA,CAACA;YACzBA,GAAGA,CAACA,KAAKA,CAACA,IAAIA,GAAGA,QAAQA,CAACA,CAACA,CAACA,GAAGA,IAAIA,CAACA;YACpCA,GAAGA,CAACA,KAAKA,CAACA,GAAGA,GAAGA,OAAOA,CAACA,CAACA,CAACA,GAAGA,IAAIA,CAACA;QACtCA,CAACA;IACLA,CAACA;IAEDT;QACIU,IAAIA,IAAIA,GAAGA,QAAQA,CAACA,cAAcA,CAACA,MAAMA,CAACA,CAACA;QAC3CA,IAAIA,MAAMA,GAAGA,QAAQA,CAACA,cAAcA,CAACA,QAAQA,CAACA,CAACA;QAC/CA,EAAEA,CAACA,CAACA,IAAIA,IAAIA,IAAIA,IAAIA,IAAIA,IAAIA,MAAMA,CAACA;YAACA,MAAMA,CAACA;QAC3CA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA,IAAIA,CAACA,CAACA;QAChCA,QAAQA,CAACA,IAAIA,CAACA,WAAWA,CAACA,MAAMA,CAACA,CAACA;IACtCA,CAACA;IANeV,cAAMA,SAMrBA,CAAAA;IAEDA;QACIW,MAAMA,EAAEA,CAACA;QACTA,OAAOA,EAAEA,CAACA;IACdA,CAACA;IAEDX;QACIY,MAAMA,CAACA,QAAQA,GAAGA,OAAOA,CAACA;QAC1BA,MAAMA,CAACA,QAAQA,GAAGA,OAAOA,CAACA;IAC9BA,CAACA;AACLZ,CAACA,EAxHM,OAAO,KAAP,OAAO,QAwHb"}
|
|
@ -76,7 +76,7 @@ module Configs{
|
||||||
Configs.create_mask(); //创建遮罩层
|
Configs.create_mask(); //创建遮罩层
|
||||||
Kubernetes.create_locadEffect("正在更新云盘信息,请稍等!"); //创建数据加载效果层
|
Kubernetes.create_locadEffect("正在更新云盘信息,请稍等!"); //创建数据加载效果层
|
||||||
var target = document.getElementById('loading')
|
var target = document.getElementById('loading')
|
||||||
spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
|
// spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
|
||||||
},
|
},
|
||||||
complete: (XMLHttpRequest, textStatus) => {
|
complete: (XMLHttpRequest, textStatus) => {
|
||||||
if(XMLHttpRequest.status == 200){
|
if(XMLHttpRequest.status == 200){
|
||||||
|
@ -145,7 +145,7 @@ module Configs{
|
||||||
Configs.create_mask(); //创建遮罩层
|
Configs.create_mask(); //创建遮罩层
|
||||||
Kubernetes.create_locadEffect("正在更新云盘信息,请稍等!"); //创建数据加载效果层
|
Kubernetes.create_locadEffect("正在更新云盘信息,请稍等!"); //创建数据加载效果层
|
||||||
var target = document.getElementById('loading')
|
var target = document.getElementById('loading')
|
||||||
spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
|
// spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
|
||||||
},
|
},
|
||||||
complete: (XMLHttpRequest, textStatus) => {
|
complete: (XMLHttpRequest, textStatus) => {
|
||||||
if(XMLHttpRequest.status == 200){
|
if(XMLHttpRequest.status == 200){
|
||||||
|
|
|
@ -5,11 +5,17 @@
|
||||||
|
|
||||||
module Configs {
|
module Configs {
|
||||||
|
|
||||||
export var KubeController = controller('KubeController', ["$scope", "$templateCache", "$location", "$routeParams", "$http", "$timeout","ConfigsModel",
|
export var KubeController = controller('KubeController', ["$scope", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "ConfigsModel", "DataModel", "$modal",
|
||||||
($scope, $templateCache:ng.ITemplateCacheService, $location, $routeParams, $http, $timeout, ConfigsModel) => {
|
($scope, $templateCache: ng.ITemplateCacheService, $location, $routeParams, $http, $timeout, ConfigsModel, DataModel, $modal) => {
|
||||||
$scope.model = ConfigsModel;
|
$scope.model = ConfigsModel;
|
||||||
$scope.model.updateOracleParam();
|
$scope.model.updateOracleParam();
|
||||||
$scope.submitted = false;
|
$scope.submitted = false;
|
||||||
|
$scope.submittedCreateDatabase = false;
|
||||||
|
$scope.DataModel = DataModel;
|
||||||
|
|
||||||
|
console.log(ConfigsModel.oracleParam);
|
||||||
|
console.log("Configs00000000");
|
||||||
|
|
||||||
|
|
||||||
$scope.tableConfig = {
|
$scope.tableConfig = {
|
||||||
data: 'model.oracleParam',
|
data: 'model.oracleParam',
|
||||||
|
@ -44,18 +50,20 @@ module Configs{
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: "suffix",
|
field: "suffix",
|
||||||
displayName: "表后缀"
|
displayName: "用户名后缀"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: "type",
|
field: "type",
|
||||||
displayName: "标准表汇总库",
|
displayName: "标准表汇总库",
|
||||||
cellTemplate: $templateCache.get("strandColumn.html")
|
cellTemplate: $templateCache.get("strandColumn.html")
|
||||||
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: "entity",
|
field: "entity",
|
||||||
displayName: "操作",
|
displayName: "操作",
|
||||||
cellTemplate: $templateCache.get("tableEdit.html")
|
cellTemplate: $templateCache.get("tableEdit.html")
|
||||||
}],
|
}
|
||||||
|
],
|
||||||
enableRowClickSelection: false,
|
enableRowClickSelection: false,
|
||||||
showSelectionCheckbox: false,
|
showSelectionCheckbox: false,
|
||||||
multiSelect: false,
|
multiSelect: false,
|
||||||
|
@ -71,26 +79,51 @@ module Configs{
|
||||||
$scope.submitted = false;
|
$scope.submitted = false;
|
||||||
$scope.add = true;
|
$scope.add = true;
|
||||||
$scope.edit = false;
|
$scope.edit = false;
|
||||||
|
$scope.createDatabase = false;
|
||||||
$scope.tableForm = {};
|
$scope.tableForm = {};
|
||||||
$scope.tableForm["id"] = 0;
|
$scope.tableForm["id"] = 0;
|
||||||
$scope.tableForm["type"] = 0;
|
$scope.tableForm["type"] = 0;
|
||||||
$scope.tableForm["name"]='请输入2-20个字符的数据名称';
|
$scope.tableForm["name"] = '';
|
||||||
$scope.tableForm["ip"]='oracle的IP,例如:0.0.0.0';
|
$scope.tableForm["ip"] = '';
|
||||||
$scope.tableForm["port"]='oracle的的端口,1~65535';
|
$scope.tableForm["port"] = '';
|
||||||
$scope.tableForm["user"]='oracle的用户名,2-15个字母、数字或下划线';
|
$scope.tableForm["user"] = '';
|
||||||
$scope.tableForm["password"]='oracle的密码,2-15个字母、数字或下划线';
|
$scope.tableForm["password"] = '';
|
||||||
$scope.tableForm["databaseName"]='oracle的实例名,1-10个字母,例如ORCL';
|
$scope.tableForm["databaseName"] = '';
|
||||||
$scope.tableForm["tableName"]='oracle的表空间名,1-15个字母、数字或下划线';
|
$scope.tableForm["tableName"] = '';
|
||||||
$scope.tableForm["suffix"]='汇总生成新表的后缀名,1-10个字母、数字或下划线';
|
$scope.tableForm["suffix"] = '';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$scope.createGatherDababase = () => {
|
||||||
|
$scope.submittedCreateDatabase = false;
|
||||||
|
|
||||||
|
$scope.add = false;
|
||||||
|
$scope.edit = false;
|
||||||
|
$scope.createDatabase = true;
|
||||||
|
|
||||||
|
$scope.tableForm = {};
|
||||||
|
|
||||||
|
$scope.tableForm["dataVersion"] = 1;
|
||||||
|
$scope.tableForm["systemName"] = '汇总库';
|
||||||
|
$scope.tableForm["startTime"] = '';
|
||||||
|
$scope.tableForm["endTime"] = '';
|
||||||
|
$scope.tableForm["contact"] = '';
|
||||||
|
$scope.tableForm["phone"] = '';
|
||||||
|
$scope.tableForm["encoding"] = 'UTF8';
|
||||||
|
|
||||||
|
}
|
||||||
$scope.cancel = () => {
|
$scope.cancel = () => {
|
||||||
$scope.tableForm = null;
|
$scope.tableForm = null;
|
||||||
$scope.add = false;
|
$scope.add = false;
|
||||||
$scope.edit = false;
|
$scope.edit = false;
|
||||||
$scope.submitted = false;
|
$scope.submitted = false;
|
||||||
}
|
}
|
||||||
|
$scope.cancelCreateDatabase = () => {
|
||||||
|
$scope.tableForm = null;
|
||||||
|
$scope.createDatabase = false;
|
||||||
|
|
||||||
|
$scope.submittedCreateDatabase = false;
|
||||||
|
}
|
||||||
$scope.onSubmit = (oracle) => {
|
$scope.onSubmit = (oracle) => {
|
||||||
if ($scope.tableForm["name"] == '请输入2-20个字符的数据名称')
|
if ($scope.tableForm["name"] == '请输入2-20个字符的数据名称')
|
||||||
$scope.tableForm["name"] = '';
|
$scope.tableForm["name"] = '';
|
||||||
|
@ -109,15 +142,21 @@ module Configs{
|
||||||
if ($scope.tableForm["suffix"] == '汇总生成新表的后缀名,1-10个字母、数字或下划线')
|
if ($scope.tableForm["suffix"] == '汇总生成新表的后缀名,1-10个字母、数字或下划线')
|
||||||
$scope.tableForm["suffix"] = '';
|
$scope.tableForm["suffix"] = '';
|
||||||
|
|
||||||
|
|
||||||
if ($scope.validForm.$valid && $scope.validForm.$dirty) {
|
if ($scope.validForm.$valid && $scope.validForm.$dirty) {
|
||||||
$scope.edit = false;
|
$scope.edit = false;
|
||||||
$scope.add = false;
|
$scope.add = false
|
||||||
|
console.log(oracle);
|
||||||
oracleInfoOperate($http, "/java/console/api/oracle", OperateType.UPDATE, oracle, (result, status) => {
|
oracleInfoOperate($http, "/java/console/api/oracle", OperateType.UPDATE, oracle, (result, status) => {
|
||||||
if(status===200){
|
|
||||||
|
if (status == 200) {
|
||||||
$scope.model.updateOracleParam();
|
$scope.model.updateOracleParam();
|
||||||
|
Configs.customAlert("提示", "汇总库更新成功", '', null, 0, "success");
|
||||||
|
} else if (status == 400) {
|
||||||
|
console.log(result);
|
||||||
|
Configs.customAlert("提示", "汇总库更新失败,名称不能重复", '', null, 0, "error");
|
||||||
} else {
|
} else {
|
||||||
throw "资源请求失败";
|
console.log(result);
|
||||||
|
Configs.customAlert("提示", "汇总库配置失败: 系统异常!", '', null, 0, "error");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
@ -125,11 +164,44 @@ module Configs{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$scope.onSubmitCreateDatabase = (oracle) => {
|
||||||
|
|
||||||
|
if ($scope.tableForm["systemName"] == '请输入2-20个字符的汇总库系统名称')
|
||||||
|
$scope.tableForm["systemName"] = '';
|
||||||
|
if ($scope.tableForm["startTime"] == '开始时间,格式为yyyy-MM 例如:2018-02')
|
||||||
|
$scope.tableForm["startTime"] = '';
|
||||||
|
if ($scope.tableForm["endTime"] == '结束时间,格式为yyyy-MM 例如:2018-02')
|
||||||
|
$scope.tableForm["endTime"] = '';
|
||||||
|
if ($scope.tableForm["contact"] == '联系人')
|
||||||
|
$scope.tableForm["contact"] = '';
|
||||||
|
if ($scope.tableForm["phone"] == '联系方式')
|
||||||
|
$scope.tableForm["phone"] = '';
|
||||||
|
|
||||||
|
if ($scope.createDatabaseForm.$valid && $scope.createDatabaseForm.$dirty) {
|
||||||
|
$scope.createDatabase = false;
|
||||||
|
|
||||||
|
console.log(oracle);
|
||||||
|
Configs.customAlert("提示", "准备创建汇总库,请稍后前往数据管理页面查看创建的汇总库", '', null, 0, "success");
|
||||||
|
oracleInfoOperate($http, "/java/console/api/oracle", OperateType.CREATE_DATABASE, oracle, (result, status) => {
|
||||||
|
|
||||||
|
if (status === 200) {
|
||||||
|
Configs.customAlert("提示", "汇总库创建成功,请前往数据管理页面中启动创建的汇总库并查看参数在配置服务集群", '', null, 0, "success");
|
||||||
|
} else {
|
||||||
|
console.log(result);
|
||||||
|
Configs.customAlert("提示", "汇总库创建失败!\n" + result.msg, '', null, 0, "error");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
$scope.submittedCreateDatabase = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
$scope.$on("editRow", (event, data) => {
|
$scope.$on("editRow", (event, data) => {
|
||||||
$scope.submitted = false;
|
$scope.submitted = false;
|
||||||
$scope.tableForm = deepCopy(data);
|
$scope.tableForm = deepCopy(data);
|
||||||
$scope.edit = true;
|
$scope.edit = true;
|
||||||
$scope.add = false;
|
$scope.add = false;
|
||||||
|
$scope.createDatabase = false;
|
||||||
|
|
||||||
//$scope.rowId = data.id
|
//$scope.rowId = data.id
|
||||||
//createNewObejct($scope.tableConfig.columnDefs, data);
|
//createNewObejct($scope.tableConfig.columnDefs, data);
|
||||||
//removeElementsByValue($scope.tableForm, [{key: "name", value: "序号"},{key: "name", value: "连接状态"},{key: "name", value: "操作"}]);
|
//removeElementsByValue($scope.tableForm, [{key: "name", value: "序号"},{key: "name", value: "连接状态"},{key: "name", value: "操作"}]);
|
||||||
|
@ -137,14 +209,21 @@ module Configs{
|
||||||
|
|
||||||
$scope.$on("deleteRow", (event, data) => {
|
$scope.$on("deleteRow", (event, data) => {
|
||||||
oracleInfoOperate($http, "/java/console/api/oracle", OperateType.DELETE, data, (result, status) => {
|
oracleInfoOperate($http, "/java/console/api/oracle", OperateType.DELETE, data, (result, status) => {
|
||||||
if(status===200){
|
if (status == 200) {
|
||||||
console.log("准备更新");
|
|
||||||
$scope.model.updateOracleParam();
|
$scope.model.updateOracleParam();
|
||||||
|
Configs.customAlert("提示", "汇总库删除成功", '', null, 0, "success");
|
||||||
} else {
|
} else {
|
||||||
throw "资源请求失败";
|
console.log(result);
|
||||||
|
Configs.customAlert("提示", "汇总库配置失败: 系统异常!", '', null, 0, "error");
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
//removeElementByValue($scope.model, data._id, "_id");
|
//removeElementByValue($scope.model, data._id, "_id");
|
||||||
});
|
});
|
||||||
}]);
|
|
||||||
|
}
|
||||||
|
|
||||||
|
]);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
|
@ -78,13 +78,13 @@ module Configs{
|
||||||
}
|
}
|
||||||
}]);
|
}]);
|
||||||
|
|
||||||
export var SystemInfoController = controller('SystemInfoController', ['$scope', ($scope) =>{
|
export var SystemInfoController = controller('SystemInfoController', ['$scope', ($scope) => {}]);
|
||||||
}]);
|
|
||||||
|
|
||||||
export var SqlViewController = controller('SqlViewController', ['$scope', '$http', ($scope, $http) => {
|
export var SqlViewController = controller('SqlViewController', ['$scope', '$http', ($scope, $http) => {
|
||||||
$scope.title = shareInit($scope.ngDialogData);
|
$scope.title = shareInit($scope.ngDialogData);
|
||||||
$scope.content = "";
|
$scope.content = "";
|
||||||
getSqlContent();
|
getSqlContent();
|
||||||
|
|
||||||
function getSqlContent() {
|
function getSqlContent() {
|
||||||
$http({
|
$http({
|
||||||
url: "/java/console/api/filePackage/readSqlFile",
|
url: "/java/console/api/filePackage/readSqlFile",
|
||||||
|
@ -181,8 +181,7 @@ module Configs{
|
||||||
if (null == $scope.content || $scope.content == "") {
|
if (null == $scope.content || $scope.content == "") {
|
||||||
console.log("上传的内容不能为空");
|
console.log("上传的内容不能为空");
|
||||||
$scope.closeThisDialog();
|
$scope.closeThisDialog();
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
$scope.$emit("onOk", {
|
$scope.$emit("onOk", {
|
||||||
url: "/java/console/api/filePackage/handleSqlFile",
|
url: "/java/console/api/filePackage/handleSqlFile",
|
||||||
item: $scope.ngDialogData.item,
|
item: $scope.ngDialogData.item,
|
||||||
|
@ -214,6 +213,7 @@ module Configs{
|
||||||
});
|
});
|
||||||
$scope.closeThisDialog();
|
$scope.closeThisDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
function getSqlContent() {
|
function getSqlContent() {
|
||||||
$http({
|
$http({
|
||||||
url: "/java/console/api/filePackage/readSqlFile",
|
url: "/java/console/api/filePackage/readSqlFile",
|
||||||
|
@ -283,8 +283,7 @@ module Configs{
|
||||||
if ($event.target.checked) {
|
if ($event.target.checked) {
|
||||||
if ($scope.checkboxItmes.indexOf(name) == -1)
|
if ($scope.checkboxItmes.indexOf(name) == -1)
|
||||||
$scope.checkboxItmes.push(name)
|
$scope.checkboxItmes.push(name)
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
for (var i = 0; i < $scope.checkboxItmes.length; i++) {
|
for (var i = 0; i < $scope.checkboxItmes.length; i++) {
|
||||||
if ($scope.checkboxItmes[i] === name) {
|
if ($scope.checkboxItmes[i] === name) {
|
||||||
$scope.checkboxItmes.splice(i, 1);
|
$scope.checkboxItmes.splice(i, 1);
|
||||||
|
@ -325,6 +324,142 @@ module Configs{
|
||||||
}
|
}
|
||||||
}]);
|
}]);
|
||||||
|
|
||||||
|
export var dataExportController = controller("dataExportController", ['$scope', '$http', 'DataModel', 'ConfigsModel', ($scope, $http, DataModel: Developer.DataModelService, ConfigsModel: Configs.ConfigsModelService) => {
|
||||||
|
|
||||||
|
$scope.model = DataModel;
|
||||||
|
|
||||||
|
getUniqueData($scope);
|
||||||
|
$scope.gatherOracles = ConfigsModel.oracleParam;
|
||||||
|
// $scope.gatherOracles = ["2017汇总库"];
|
||||||
|
$scope.export = [{ "type": 1, "exportName": "原始数据" }, { "type": 2, "exportName": "汇总库" }, { "type": 3, "exportName": "标准表抽取脚本" }];
|
||||||
|
$scope.gatherOracleSelected = false;
|
||||||
|
$scope.idList = [];
|
||||||
|
$scope.typeList = [];
|
||||||
|
$scope.selectGatherOracleName = "";
|
||||||
|
$scope.gatherOracleList = [];
|
||||||
|
$scope.flag = false;
|
||||||
|
|
||||||
|
|
||||||
|
$scope.ischeckedId = function(id) {
|
||||||
|
return $scope.idList.indexOf(id) >= 0;
|
||||||
|
}
|
||||||
|
$scope.selectId = function(id, event) {
|
||||||
|
var action = event.target;
|
||||||
|
if (action.checked) {
|
||||||
|
if ($scope.idList.indexOf(id) == -1) {
|
||||||
|
$scope.idList.push(id);
|
||||||
|
return $scope.idList;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
var idx = $scope.idList.indexOf(id);
|
||||||
|
if (idx != -1) {
|
||||||
|
$scope.idList.splice(idx, 1);
|
||||||
|
return $scope.idList;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.ischeckedType = function(type) {
|
||||||
|
|
||||||
|
return $scope.typeList.indexOf(type) >= 0;
|
||||||
|
}
|
||||||
|
$scope.selectType = function(type, event) {
|
||||||
|
var action = event.target;
|
||||||
|
|
||||||
|
|
||||||
|
if (action.checked) {
|
||||||
|
if (type == 2) {
|
||||||
|
$scope.gatherOracleSelected = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($scope.typeList.indexOf(type) == -1) {
|
||||||
|
|
||||||
|
$scope.typeList.push(type);
|
||||||
|
return $scope.typeList;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (type == 2) {
|
||||||
|
$scope.gatherOracleSelected = false;
|
||||||
|
}
|
||||||
|
var idx = $scope.typeList.indexOf(type);
|
||||||
|
if (idx != -1) {
|
||||||
|
$scope.typeList.splice(idx, 1);
|
||||||
|
return $scope.typeList;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.selectAll = function(flag) {
|
||||||
|
if ($scope.flag) {
|
||||||
|
flag = false;
|
||||||
|
angular.forEach($scope.uniqueData, function(item, index) {
|
||||||
|
$scope.idList.push(item.id);
|
||||||
|
});
|
||||||
|
return $scope.idList;
|
||||||
|
} else {
|
||||||
|
flag = true;
|
||||||
|
$scope.idList = [];
|
||||||
|
return $scope.idList;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.cancel = () => {
|
||||||
|
$scope.closeThisDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.onsubmit = (idList, typeList, selectGatherOracleName) => {
|
||||||
|
if (!idList.length) {
|
||||||
|
Configs.customAlert("提示", "请选择需要导出的数据", '', null, 0, "error");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!typeList.length) {
|
||||||
|
Configs.customAlert("提示", "请选择需要导出的类型", '', null, 0, "error");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ((selectGatherOracleName == undefined || selectGatherOracleName == "") && $scope.gatherOracleSelected) {
|
||||||
|
Configs.customAlert("提示", "请选择汇总库汇总库", '', null, 0, "error");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// var idListStr="";
|
||||||
|
// var typeListStr="";
|
||||||
|
// var gatherOracleName="selectGatherOracleName";
|
||||||
|
|
||||||
|
// for( var id in idList){
|
||||||
|
// idList
|
||||||
|
// }
|
||||||
|
|
||||||
|
$scope.gatherOracleList.push(selectGatherOracleName);
|
||||||
|
var exportDataFrom = {
|
||||||
|
idList: idList,
|
||||||
|
typeList: typeList,
|
||||||
|
gatherOracleList: $scope.gatherOracleList,
|
||||||
|
};
|
||||||
|
$.ajax({
|
||||||
|
async: false,
|
||||||
|
type: "POST",
|
||||||
|
contentType: "application/json; charset=utf-8",
|
||||||
|
url: UrlHelpers.join("/java/console/api/oracle/exportData"),
|
||||||
|
dataType: 'json',
|
||||||
|
|
||||||
|
// data: JSON.stringify({ "idList": idList, "typeList": typeList, "gatherOracleList": $scope.gatherOracleList }),
|
||||||
|
data: JSON.stringify(exportDataFrom),
|
||||||
|
|
||||||
|
|
||||||
|
success: (data) => {
|
||||||
|
|
||||||
|
Configs.customAlert("提示", "正在导出,查看详情请点击查看导出日志!", '', null, 0, "success");
|
||||||
|
|
||||||
|
},
|
||||||
|
error: (data) => {
|
||||||
|
Configs.customAlert("提示", "导出失败:" + data.responseText, '', null, 0, "error");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
$scope.closeThisDialog();
|
||||||
|
}
|
||||||
|
}]);
|
||||||
|
|
||||||
function shareInit(ngDialogData) {
|
function shareInit(ngDialogData) {
|
||||||
var title = "";
|
var title = "";
|
||||||
if (ngDialogData.type != 'undefined') {
|
if (ngDialogData.type != 'undefined') {
|
||||||
|
@ -343,4 +478,25 @@ module Configs{
|
||||||
}
|
}
|
||||||
return title;
|
return title;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getUniqueData($scope) {
|
||||||
|
var result;
|
||||||
|
$.ajax({
|
||||||
|
async: false,
|
||||||
|
type: "POST",
|
||||||
|
contentType: "application/json;charset=utf-8",
|
||||||
|
url: UrlHelpers.join("/java/console/api/getAllData"),
|
||||||
|
dataType: 'json',
|
||||||
|
|
||||||
|
success: (data) => {
|
||||||
|
$scope.uniqueData = data;
|
||||||
|
result = data;
|
||||||
|
return "success";
|
||||||
|
},
|
||||||
|
error: (data) => {
|
||||||
|
|
||||||
|
return "获取数据失败";
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -1,38 +0,0 @@
|
||||||
<div ng-controller="Developer.HomeController">
|
|
||||||
<div class="jumbotron">
|
|
||||||
<h1>Perspectives</h1>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
Please choose the perspective you would like to use:
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
|
|
||||||
<div class="col-md-6">
|
|
||||||
<p class="text-center">
|
|
||||||
<a class="btn btn-lg btn-primary" href="/workspaces" role="button"
|
|
||||||
title="Create or work on Projects">
|
|
||||||
<i class="fa fa-tasks"></i>
|
|
||||||
 Develop 禄
|
|
||||||
</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p class="text-center">
|
|
||||||
Work on projects and source code
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-6">
|
|
||||||
<p class="text-center">
|
|
||||||
<a class="btn btn-lg btn-primary" href="/namespaces" role="button"
|
|
||||||
title="Look around the various Namespaces at running Pods and Services">
|
|
||||||
<i class="fa fa-cubes"></i>
|
|
||||||
Operate 禄
|
|
||||||
</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p class="text-center">
|
|
||||||
Manage and run Pods and Services
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
|
@ -7,7 +7,6 @@
|
||||||
<ul class="nav nav-tabs sj_nav_taps fl" ng-show="navbarItems.length">
|
<ul class="nav nav-tabs sj_nav_taps fl" ng-show="navbarItems.length">
|
||||||
<li role="presentation" ng-repeat="item in navbarItems" class="{{item.class}}"><a href="#" ng-click="selectBatchItem(item)">{{item.label}}</a></li>
|
<li role="presentation" ng-repeat="item in navbarItems" class="{{item.class}}"><a href="#" ng-click="selectBatchItem(item)">{{item.label}}</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<div class="fr sj_searchbox">
|
<div class="fr sj_searchbox">
|
||||||
<input type="text" class="sj_search_input" ng-model="keyQuery" placeholder="请选择或输入关键字,多关键字请用空格隔开" onkeydown="if(event.keyCode==13){searchButton.click()}" />
|
<input type="text" class="sj_search_input" ng-model="keyQuery" placeholder="请选择或输入关键字,多关键字请用空格隔开" onkeydown="if(event.keyCode==13){searchButton.click()}" />
|
||||||
<a href="#" class="sj_search_btn" id="searchButton" ng-click="search()"></a>
|
<a href="#" class="sj_search_btn" id="searchButton" ng-click="search()"></a>
|
||||||
|
@ -67,7 +66,7 @@
|
||||||
<label class="col-sm-3 control-label sj_contro_label" for="selectedItem ">
|
<label class="col-sm-3 control-label sj_contro_label" for="selectedItem ">
|
||||||
请选择迁移集群
|
请选择迁移集群
|
||||||
</label>
|
</label>
|
||||||
<select ng-model="migrationClick.selectedItem " class="col-sm-3 sj_modal_select" id="selectedItem " ng-options="x.name for x in volumes " />
|
<select ng-model="migrationClick.selectedItem " class="col-sm-3 sj_modal_select" id="selectedItem " ng-change="change()" ng-options="x.name for x in volumes " />
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<div class="col-sm-12 alert alert-warning" ng-show="!volumes || volumes.length == 0">
|
<div class="col-sm-12 alert alert-warning" ng-show="!volumes || volumes.length == 0">
|
||||||
|
@ -77,17 +76,22 @@
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div ng-hide="!volumes || volumes.length == 0">
|
<!-- 迁移的时候不选择具体的存储位置,具体的存储位置自动选择 -->
|
||||||
|
<!-- <div ng-hide="!volumes || volumes.length == 0"> -->
|
||||||
|
<div ng-hide="1 == 1">
|
||||||
<treecontrol class="tree-classic" tree-model="migrationClick.selectedItem.folder" options="treeOptions" on-selection="showSelected(node)" selected-node="selectNode">
|
<treecontrol class="tree-classic" tree-model="migrationClick.selectedItem.folder" options="treeOptions" on-selection="showSelected(node)" selected-node="selectNode">
|
||||||
{{node.name}}
|
{{node.name}}
|
||||||
</treecontrol>
|
</treecontrol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer ">
|
<div class="modal-footer ">
|
||||||
<input class="btn btn-primary sj_btn_blue" type="submit" ng-disabled="!selectNode || selectNode.children.length <= 0" value="确定">
|
<!-- <input class="btn btn-primary sj_btn_blue" type="submit" ng-disabled="!selectNode || selectNode.children.length <= 0" value="确定"> -->
|
||||||
|
<input class="btn btn-primary sj_btn_blue" type="submit" value="确定">
|
||||||
<button class="btn btn-warning cancel sj_btn_grey" type="button" ng-click="migrationClick.close()">取消</button>
|
<button class="btn btn-warning cancel sj_btn_grey" type="button" ng-click="migrationClick.close()">取消</button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="prettify "></div>
|
<div class="prettify "></div>
|
||||||
</div>
|
</div>
|
||||||
|
<script type="text/javascript">
|
||||||
|
</script>
|
|
@ -0,0 +1,68 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="developerNavigation.ts"/>
|
||||||
|
/// <reference path="developerHelpers.ts"/>
|
||||||
|
var Developer;
|
||||||
|
(function (Developer) {
|
||||||
|
var log = Logger.get('developer-navigation');
|
||||||
|
function createCurrentSubNavBar($scope, $location, $routeParams) {
|
||||||
|
return Developer.activateCurrent([
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "cold/data-type/all"),
|
||||||
|
label: "冷区数据管理",
|
||||||
|
title: "数据汇总任务",
|
||||||
|
items: [{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "cold/data-type/all"),
|
||||||
|
label: "全部",
|
||||||
|
title: "全部数据"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "cold/data-type/financial"),
|
||||||
|
label: "财政",
|
||||||
|
title: "财政数据"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview/", "cold/data-type/social-security"),
|
||||||
|
label: "社保",
|
||||||
|
title: "社保数据"
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "hot/data-type/all"),
|
||||||
|
label: "热区数据管理",
|
||||||
|
title: "查看所有数据",
|
||||||
|
items: [{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "hot/data-type/all"),
|
||||||
|
label: "全部",
|
||||||
|
title: "全部数据"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "hot/data-type/financial"),
|
||||||
|
label: "财政",
|
||||||
|
title: "财政数据"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview/", "hot/data-type/social-security"),
|
||||||
|
label: "社保",
|
||||||
|
title: "社保数据"
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview/", "task/done"),
|
||||||
|
label: "任务管理",
|
||||||
|
title: "任务查看",
|
||||||
|
items: [{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview", "task/done"),
|
||||||
|
label: "已完成的任务",
|
||||||
|
title: "已完成的迁移任务"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(Developer.context, "Overview/", "task/running"),
|
||||||
|
label: "正在迁移的任务",
|
||||||
|
title: "正在迁移的任务"
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
Developer.createCurrentSubNavBar = createCurrentSubNavBar;
|
||||||
|
})(Developer || (Developer = {}));
|
||||||
|
//# sourceMappingURL=dataManagerHelper.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"dataManagerHelper.js","sourceRoot":"","sources":["dataManagerHelper.ts"],"names":["Developer","Developer.createCurrentSubNavBar"],"mappings":"AAAA,yCAAyC;AACzC,8CAA8C;AAC9C,2CAA2C;AAC3C,IAAO,SAAS,CA6Df;AA7DD,WAAO,SAAS,EAAA,CAAC;IACbA,IAAIA,GAAGA,GAAGA,MAAMA,CAACA,GAAGA,CAACA,sBAAsBA,CAACA,CAACA;IAC7CA,gCAAuCA,MAAMA,EAAEA,SAASA,EAAEA,YAAYA;QACxEC,MAAMA,CAACA,yBAAeA,CAACA;YACtBA;gBACCA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,oBAAoBA,CAACA;gBAC9DA,KAAKA,EAAEA,QAAQA;gBACfA,KAAKA,EAAEA,QAAQA;gBACfA,KAAKA,EAAEA,CAACA;wBACLA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,oBAAoBA,CAACA;wBAC9DA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACbA;oBACDA;wBACAA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,0BAA0BA,CAACA;wBACnEA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACbA;oBACDA;wBACCA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,WAAWA,EAACA,gCAAgCA,CAACA;wBAC3EA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACbA,CAACA;aACJA;YACDA;gBACCA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,mBAAmBA,CAACA;gBAC7DA,KAAKA,EAAEA,QAAQA;gBACfA,KAAKA,EAAEA,QAAQA;gBACfA,KAAKA,EAAEA,CAACA;wBACJA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,mBAAmBA,CAACA;wBAC7DA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACdA;oBACDA;wBACCA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,yBAAyBA,CAACA;wBAClEA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACdA;oBACDA;wBACEA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,WAAWA,EAACA,+BAA+BA,CAACA;wBAC1EA,KAAKA,EAAEA,IAAIA;wBACXA,KAAKA,EAAEA,MAAMA;qBACbA,CAACA;aACLA;YACDA;gBACEA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,WAAWA,EAACA,WAAWA,CAACA;gBACtDA,KAAKA,EAAEA,MAAMA;gBACbA,KAAKA,EAAEA,MAAMA;gBACbA,KAAKA,EAAEA,CAACA;wBACLA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,UAAUA,EAACA,WAAWA,CAACA;wBACrDA,KAAKA,EAAEA,QAAQA;wBACfA,KAAKA,EAAEA,UAAUA;qBACjBA;oBACDA;wBACCA,IAAIA,EAAEA,UAAUA,CAACA,IAAIA,CAACA,iBAAOA,EAACA,WAAWA,EAACA,cAAcA,CAACA;wBACzDA,KAAKA,EAAEA,SAASA;wBAChBA,KAAKA,EAAEA,SAASA;qBAChBA,CAACA;aACLA;SACDA,CAACA,CAACA;IACJA,CAACA;IA1DkBD,gCAAsBA,yBA0DxCA,CAAAA;AACFA,CAACA,EA7DM,SAAS,KAAT,SAAS,QA6Df"}
|
|
@ -30,7 +30,8 @@ module Developer{
|
||||||
if (extendValue.indexOf(key))
|
if (extendValue.indexOf(key))
|
||||||
result[key] = value;
|
result[key] = value;
|
||||||
});
|
});
|
||||||
|
console.log(result);
|
||||||
|
console.log("参数");
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -42,6 +43,7 @@ module Developer{
|
||||||
return num;
|
return num;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function createLabel(cityName: string, districtName: string, systemName: string, version: string, year: string) {
|
function createLabel(cityName: string, districtName: string, systemName: string, version: string, year: string) {
|
||||||
return {
|
return {
|
||||||
cityName: cityName,
|
cityName: cityName,
|
||||||
|
@ -51,9 +53,11 @@ module Developer{
|
||||||
year: year
|
year: year
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function createAlias(cityName: string, districtName: string, systemName: string, version: string, year: string) {
|
function createAlias(cityName: string, districtName: string, systemName: string, version: string, year: string) {
|
||||||
return cityName + "_" + districtName + "_" + systemName + "_" + year + "_版本" + version;
|
return cityName + "_" + districtName + "_" + systemName + "_" + year + "_版本" + version;
|
||||||
}
|
}
|
||||||
|
|
||||||
function createKey(regionalismCode, systemId, version) {
|
function createKey(regionalismCode, systemId, version) {
|
||||||
return regionalismCode + "-" + systemId + "-" + version;
|
return regionalismCode + "-" + systemId + "-" + version;
|
||||||
}
|
}
|
||||||
|
@ -140,6 +144,8 @@ module Developer{
|
||||||
}
|
}
|
||||||
result.push(item);
|
result.push(item);
|
||||||
});
|
});
|
||||||
|
// console.log(result);
|
||||||
|
// console.log("formatTask");
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -169,6 +175,8 @@ module Developer{
|
||||||
paramOptions.totlePage = data.page.totlePage;
|
paramOptions.totlePage = data.page.totlePage;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
console.log(result);
|
||||||
|
console.log("getDataModel");
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,280 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="../../kubernetes/ts/kubernetesHelpers.ts" />
|
||||||
|
var Developer;
|
||||||
|
(function (Developer) {
|
||||||
|
Developer.context = '/workspaces';
|
||||||
|
Developer.hash = '#' + Developer.context;
|
||||||
|
Developer.pluginName = 'Developer';
|
||||||
|
Developer.pluginPath = 'plugins/developer/';
|
||||||
|
Developer.templatePath = Developer.pluginPath + 'html/';
|
||||||
|
Developer.log = Logger.get(Developer.pluginName);
|
||||||
|
Developer.jenkinsServiceName = "jenkins";
|
||||||
|
Developer.jenkinsServiceNameAndPort = Developer.jenkinsServiceName + ":http";
|
||||||
|
Developer.jenkinsHttpConfig = {
|
||||||
|
headers: {
|
||||||
|
Accept: "application/json, text/x-json, text/plain"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Returns true if the value hasn't changed from the last cached JSON version of this object
|
||||||
|
*/
|
||||||
|
function hasObjectChanged(value, state) {
|
||||||
|
var json = angular.toJson(value || "");
|
||||||
|
var oldJson = state.json;
|
||||||
|
state.json = json;
|
||||||
|
return !oldJson || json !== oldJson;
|
||||||
|
}
|
||||||
|
Developer.hasObjectChanged = hasObjectChanged;
|
||||||
|
function projectForScope($scope) {
|
||||||
|
if ($scope) {
|
||||||
|
return $scope.buildConfig || $scope.entity || ($scope.model || {}).project;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
Developer.projectForScope = projectForScope;
|
||||||
|
/**
|
||||||
|
* Lets load the project versions for the given namespace
|
||||||
|
*/
|
||||||
|
function loadProjectVersions($scope, $element, project, env, ns, answer, caches) {
|
||||||
|
var projectAnnotation = "project";
|
||||||
|
var versionAnnotation = "version";
|
||||||
|
var projectNamespace = project.$namespace;
|
||||||
|
var projectName = project.$name;
|
||||||
|
var cache = caches[ns];
|
||||||
|
if (!cache) {
|
||||||
|
cache = {};
|
||||||
|
caches[ns] = cache;
|
||||||
|
}
|
||||||
|
var status = {
|
||||||
|
rcs: [],
|
||||||
|
pods: [],
|
||||||
|
routes: [],
|
||||||
|
services: []
|
||||||
|
};
|
||||||
|
var imageStreamTags = [];
|
||||||
|
function updateModel() {
|
||||||
|
var projectInfos = {};
|
||||||
|
var model = $scope.model || {};
|
||||||
|
angular.forEach(status.rcs, function (item) {
|
||||||
|
var metadata = item.metadata || {};
|
||||||
|
var name = metadata.name;
|
||||||
|
var labels = metadata.labels || {};
|
||||||
|
var annotations = metadata.annotations || {};
|
||||||
|
var spec = item.spec || {};
|
||||||
|
var selector = spec.selector;
|
||||||
|
var project = labels[projectAnnotation];
|
||||||
|
var version = labels[versionAnnotation];
|
||||||
|
// lets try the S2I defaults...
|
||||||
|
if (!project) {
|
||||||
|
project = labels["app"];
|
||||||
|
}
|
||||||
|
if (!version) {
|
||||||
|
version = annotations["openshift.io/deployment-config.latest-version"];
|
||||||
|
}
|
||||||
|
if (project && version && project === projectName) {
|
||||||
|
var projects = projectInfos[project];
|
||||||
|
if (!projects) {
|
||||||
|
projects = {
|
||||||
|
project: project,
|
||||||
|
versions: {}
|
||||||
|
};
|
||||||
|
projectInfos[project] = projects;
|
||||||
|
}
|
||||||
|
var versionInfo = projects.versions[version];
|
||||||
|
if (!versionInfo) {
|
||||||
|
versionInfo = {
|
||||||
|
replicationControllers: {}
|
||||||
|
};
|
||||||
|
projects.versions[version] = versionInfo;
|
||||||
|
}
|
||||||
|
if (name) {
|
||||||
|
versionInfo.replicationControllers[name] = item;
|
||||||
|
item.$name = name;
|
||||||
|
if (projectNamespace && projectName) {
|
||||||
|
item.$viewLink = UrlHelpers.join("/workspaces/", projectNamespace, "projects", projectName, "namespace", ns, "replicationControllers", name);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
Developer.log.warn("Missing project data! " + projectNamespace + " name " + projectName);
|
||||||
|
}
|
||||||
|
item.$services = [];
|
||||||
|
var rcLink = null;
|
||||||
|
status.services.forEach(function (service) {
|
||||||
|
var repSelector = Kubernetes.getSelector(item);
|
||||||
|
var serviceSelector = Kubernetes.getSelector(service);
|
||||||
|
if (serviceSelector && repSelector &&
|
||||||
|
Kubernetes.selectorMatches(serviceSelector, repSelector) &&
|
||||||
|
Kubernetes.getNamespace(service) === Kubernetes.getNamespace(item)) {
|
||||||
|
status.routes.forEach(function (route) {
|
||||||
|
var serviceName = Kubernetes.getName(service);
|
||||||
|
if (serviceName === Kubernetes.getName(route)) {
|
||||||
|
service["$route"] = route;
|
||||||
|
service["$host"] = Core.pathGet(route, ["spec", "host"]);
|
||||||
|
item.$services.push(service);
|
||||||
|
if (!rcLink) {
|
||||||
|
var url = Kubernetes.serviceLinkUrl(service, true);
|
||||||
|
if (url) {
|
||||||
|
// TODO find icon etc?
|
||||||
|
rcLink = {
|
||||||
|
name: serviceName,
|
||||||
|
href: url
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
item["$serviceLink"] = rcLink;
|
||||||
|
}
|
||||||
|
item.$buildId = annotations["fabric8.io/build-id"] || item.$buildId;
|
||||||
|
item.$buildUrl = annotations["fabric8.io/build-url"] || item.$buildUrl;
|
||||||
|
item.$gitCommit = annotations["fabric8.io/git-commit"] || item.$gitCommit;
|
||||||
|
item.$gitUrl = annotations["fabric8.io/git-url"] || item.$gitUrl;
|
||||||
|
item.$gitBranch = annotations["fabric8.io/git-branch"] || item.$gitBranch;
|
||||||
|
if (!item.$gitCommit) {
|
||||||
|
var image = getImage(item);
|
||||||
|
if (image) {
|
||||||
|
if (!$scope.$isWatchImages) {
|
||||||
|
$scope.$isWatchImages = true;
|
||||||
|
Kubernetes.watch($scope, $element, "images", null, function (data) {
|
||||||
|
imageStreamTags = data;
|
||||||
|
checkForMissingMetadata();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
checkForMissingMetadata();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function getImage(item) {
|
||||||
|
var image = "";
|
||||||
|
// lets see if we can find the commit id from a S2I image name
|
||||||
|
// TODO needs this issue fixed to find it via an OpenShift annotation:
|
||||||
|
// https://github.com/openshift/origin/issues/6241
|
||||||
|
var containers = Core.pathGet(item, ["spec", "template", "spec", "containers"]);
|
||||||
|
if (containers && containers.length) {
|
||||||
|
var container = containers[0];
|
||||||
|
if (container) {
|
||||||
|
image = container.image;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return image;
|
||||||
|
}
|
||||||
|
function checkForMissingMetadata() {
|
||||||
|
angular.forEach(projects.versions, function (vi) {
|
||||||
|
angular.forEach(vi.replicationControllers, function (item, name) {
|
||||||
|
if (!item.$gitCommit) {
|
||||||
|
var image = getImage(item);
|
||||||
|
if (image) {
|
||||||
|
angular.forEach(imageStreamTags, function (imageStreamTag) {
|
||||||
|
var imageName = imageStreamTag.dockerImageReference;
|
||||||
|
if (imageName && imageName === image) {
|
||||||
|
var foundISTag = imageStreamTag;
|
||||||
|
var manifestJSON = imageStreamTag.dockerImageManifest;
|
||||||
|
if (manifestJSON) {
|
||||||
|
var manifest = angular.fromJson(manifestJSON) || {};
|
||||||
|
var history = manifest.history;
|
||||||
|
if (history && history.length) {
|
||||||
|
var v1 = history[0].v1Compatibility;
|
||||||
|
if (v1) {
|
||||||
|
var data = angular.fromJson(v1);
|
||||||
|
var env = Core.pathGet(data, ["config", "Env"]);
|
||||||
|
angular.forEach(env, function (envExp) {
|
||||||
|
if (envExp) {
|
||||||
|
var values = envExp.split("=");
|
||||||
|
if (values.length === 2 && values[0] == "OPENSHIFT_BUILD_NAME") {
|
||||||
|
var buildName = values[1];
|
||||||
|
if (buildName) {
|
||||||
|
item.$buildId = buildName;
|
||||||
|
item.$buildUrl = Developer.projectWorkspaceLink(ns, projectName, "buildLogs/" + buildName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var labels = Core.pathGet(data, ["config", "Labels"]);
|
||||||
|
if (labels) {
|
||||||
|
item.$gitCommit = labels["io.openshift.build.commit.id"] || item.$gitCommit;
|
||||||
|
item.$gitCommitAuthor = labels["io.openshift.build.commit.author"] || item.$gitCommitAuthor;
|
||||||
|
item.$gitCommitDate = labels["io.openshift.build.commit.date"] || item.$gitCommitDate;
|
||||||
|
item.$gitCommitMessage = labels["io.openshift.build.commit.message"] || item.$gitCommitMessage;
|
||||||
|
item.$gitBranch = labels["io.openshift.build.commit.ref"] || item.$gitBranch;
|
||||||
|
if (!item.$gitUrl && item.$gitCommit) {
|
||||||
|
item.$gitUrl = Developer.projectWorkspaceLink(ns, projectName, "wiki/commitDetail///" + item.$gitCommit);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (selector) {
|
||||||
|
var selectorText = Kubernetes.labelsToString(selector, ",");
|
||||||
|
var podLinkUrl = UrlHelpers.join(Developer.projectLink(projectName), "namespace", ns, "pods");
|
||||||
|
item.pods = [];
|
||||||
|
item.$podCounters = Kubernetes.createPodCounters(selector, status.pods, item.pods, selectorText, podLinkUrl);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
// lets check for a project name if we have lots of RCs with no pods, lets remove them!
|
||||||
|
angular.forEach(projectInfos, function (project, projectName) {
|
||||||
|
var rcsNoPods = [];
|
||||||
|
var rcsWithPods = [];
|
||||||
|
angular.forEach(project.versions, function (versionInfo) {
|
||||||
|
var rcs = versionInfo.replicationControllers;
|
||||||
|
angular.forEach(rcs, function (item, name) {
|
||||||
|
var count = Kubernetes.podCounterTotal(item.$podCounters);
|
||||||
|
if (count) {
|
||||||
|
rcsWithPods.push(name);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
rcsNoPods.push(function () {
|
||||||
|
delete rcs[name];
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
if (rcsWithPods.length) {
|
||||||
|
// lets remove all the empty RCs
|
||||||
|
angular.forEach(rcsNoPods, function (fn) {
|
||||||
|
fn();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if (hasObjectChanged(projectInfos, cache)) {
|
||||||
|
Developer.log.debug("project versions has changed!");
|
||||||
|
answer[ns] = projectInfos;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Kubernetes.watch($scope, $element, "replicationcontrollers", ns, function (data) {
|
||||||
|
if (data) {
|
||||||
|
status.rcs = data;
|
||||||
|
updateModel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Kubernetes.watch($scope, $element, "services", ns, function (data) {
|
||||||
|
if (data) {
|
||||||
|
status.services = data;
|
||||||
|
updateModel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Kubernetes.watch($scope, $element, "routes", ns, function (data) {
|
||||||
|
if (data) {
|
||||||
|
status.routes = data;
|
||||||
|
updateModel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Kubernetes.watch($scope, $element, "pods", ns, function (data) {
|
||||||
|
if (data) {
|
||||||
|
status.pods = data;
|
||||||
|
updateModel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
Developer.loadProjectVersions = loadProjectVersions;
|
||||||
|
})(Developer || (Developer = {}));
|
||||||
|
//# sourceMappingURL=developerHelpers.js.map
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,687 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
var Developer;
|
||||||
|
(function (Developer) {
|
||||||
|
var log = Logger.get('developer-navigation');
|
||||||
|
function developBreadcrumb() {
|
||||||
|
return {
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces"),
|
||||||
|
label: "Teams",
|
||||||
|
title: "View all the available teams",
|
||||||
|
isActive: function (subTab, path) { return false; }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
function operateBreadcrumb() {
|
||||||
|
return {
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/namespaces"),
|
||||||
|
label: "Manage",
|
||||||
|
title: "Manage the projects and resources inside them"
|
||||||
|
};
|
||||||
|
}
|
||||||
|
function workspaceLink() {
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", Kubernetes.currentKubernetesNamespace());
|
||||||
|
}
|
||||||
|
Developer.workspaceLink = workspaceLink;
|
||||||
|
function projectLink(projectId) {
|
||||||
|
var link = workspaceLink();
|
||||||
|
if (projectId) {
|
||||||
|
return UrlHelpers.join(link, "/projects", projectId);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return link;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Developer.projectLink = projectLink;
|
||||||
|
function createWorkspacesBreadcrumbs(developPerspective) {
|
||||||
|
return [developBreadcrumb()];
|
||||||
|
}
|
||||||
|
Developer.createWorkspacesBreadcrumbs = createWorkspacesBreadcrumbs;
|
||||||
|
function createWorkspacesSubNavBars(developPerspective) {
|
||||||
|
return activateCurrent([
|
||||||
|
developBreadcrumb(),
|
||||||
|
operateBreadcrumb()
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
Developer.createWorkspacesSubNavBars = createWorkspacesSubNavBars;
|
||||||
|
function createWorkspaceBreadcrumbs(children, workspaceName) {
|
||||||
|
if (children === void 0) { children = null; }
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
var answer = createWorkspacesBreadcrumbs(true);
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
if (workspaceName) {
|
||||||
|
answer.push({
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces/", workspaceName),
|
||||||
|
label: workspaceName,
|
||||||
|
title: "View the project: " + workspaceName,
|
||||||
|
isActive: function (subTab, path) { return false; }
|
||||||
|
});
|
||||||
|
return processChildren(answer, children);
|
||||||
|
}
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
Developer.createWorkspaceBreadcrumbs = createWorkspaceBreadcrumbs;
|
||||||
|
function createEnvironmentBreadcrumbs($scope, $location, $routeParams) {
|
||||||
|
var ns = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var namespacesLink = UrlHelpers.join(HawtioCore.documentBase(), "/kubernetes/namespace");
|
||||||
|
var workspaceName = $routeParams.workspace;
|
||||||
|
var project = $routeParams.project;
|
||||||
|
var environment = $routeParams.namespace;
|
||||||
|
if (workspaceName && project) {
|
||||||
|
var projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", project);
|
||||||
|
$scope.$projectLink = projectLink;
|
||||||
|
$scope.$projectNamespaceLink = UrlHelpers.join(projectLink, "namespace", ns);
|
||||||
|
namespacesLink = UrlHelpers.join(projectLink, "namespace");
|
||||||
|
var children = [
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(projectLink, "environments"),
|
||||||
|
label: "Environments",
|
||||||
|
title: "View the environments for this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(namespacesLink, ns, "apps"),
|
||||||
|
label: function () { return environmentName(workspaceName, ns); },
|
||||||
|
title: "View the runtime of the workspace: " + ns
|
||||||
|
}
|
||||||
|
];
|
||||||
|
return createProjectBreadcrumbs(project, children, workspaceName);
|
||||||
|
}
|
||||||
|
else if (workspaceName && environment && workspaceName != environment) {
|
||||||
|
// find label for namespace environment
|
||||||
|
var children = [
|
||||||
|
{
|
||||||
|
href: environmentsLink(workspaceName),
|
||||||
|
label: "Environments",
|
||||||
|
title: "View the environments for this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: environmentLink(workspaceName, environment),
|
||||||
|
label: function () { return environmentName(workspaceName, environment); },
|
||||||
|
title: "View this environment"
|
||||||
|
}
|
||||||
|
];
|
||||||
|
return createProjectBreadcrumbs(project, children, workspaceName);
|
||||||
|
}
|
||||||
|
else if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
var answer = createWorkspaceBreadcrumbs(workspaceName);
|
||||||
|
answer.push({
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "workspaces", workspaceName, "namespace", ns, "apps"),
|
||||||
|
label: 'Runtime',
|
||||||
|
title: "View the runtime of the workspace: " + ns
|
||||||
|
});
|
||||||
|
return activateCurrent(answer);
|
||||||
|
}
|
||||||
|
Developer.createEnvironmentBreadcrumbs = createEnvironmentBreadcrumbs;
|
||||||
|
/**
|
||||||
|
* Returns the name of the given environment namespace
|
||||||
|
*/
|
||||||
|
function environmentName(workspaceName, environment) {
|
||||||
|
/*var model = Kubernetes.getKubernetesModel();
|
||||||
|
if (model) {
|
||||||
|
return model.environmentName(workspaceName, environment);
|
||||||
|
}*/
|
||||||
|
return environment;
|
||||||
|
}
|
||||||
|
function createProjectBreadcrumbs(projectName, children, workspaceName) {
|
||||||
|
if (projectName === void 0) { projectName = null; }
|
||||||
|
if (children === void 0) { children = null; }
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
var answer = createWorkspaceBreadcrumbs(null, workspaceName);
|
||||||
|
if (workspaceName) {
|
||||||
|
if (projectName) {
|
||||||
|
answer.push({
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects"),
|
||||||
|
label: "Apps",
|
||||||
|
title: "View all the apps in this project"
|
||||||
|
});
|
||||||
|
answer.push({
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName),
|
||||||
|
label: projectName,
|
||||||
|
title: "View the project: " + projectName
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return processChildren(answer, children);
|
||||||
|
}
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
Developer.createProjectBreadcrumbs = createProjectBreadcrumbs;
|
||||||
|
function createProjectSettingsBreadcrumbs(projectName, workspaceName) {
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
var children = [];
|
||||||
|
if (!projectName) {
|
||||||
|
children = [{
|
||||||
|
label: "New App",
|
||||||
|
title: "Lets make a new app"
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
return createProjectBreadcrumbs(projectName, children, workspaceName);
|
||||||
|
}
|
||||||
|
Developer.createProjectSettingsBreadcrumbs = createProjectSettingsBreadcrumbs;
|
||||||
|
function createWorkspaceSubNavBars() {
|
||||||
|
var workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
return activateCurrent([
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName),
|
||||||
|
label: "Dashboard",
|
||||||
|
class: "fa fa-tachometer",
|
||||||
|
title: "View the dashboard for the apps, environments and pipelines in this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "apps"),
|
||||||
|
label: "Apps",
|
||||||
|
class: "fa fa-rocket",
|
||||||
|
title: "View the apps in this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return jenkinsLink(); },
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "jenkinsJob"),
|
||||||
|
label: "Builds",
|
||||||
|
class: "fa fa-code",
|
||||||
|
title: "View the builds in this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: environmentsLink(),
|
||||||
|
label: "Environments",
|
||||||
|
class: "fa fa-cubes",
|
||||||
|
title: "View the environments for this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: namespaceRuntimeLink(workspaceName),
|
||||||
|
label: "Runtime",
|
||||||
|
class: "fa fa-cube",
|
||||||
|
title: "View the Runtime perspective for this project"
|
||||||
|
}
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
Developer.createWorkspaceSubNavBars = createWorkspaceSubNavBars;
|
||||||
|
function namespaceRuntimeLink(workspaceName) {
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "workspaces", workspaceName, "namespace", workspaceName, "apps");
|
||||||
|
}
|
||||||
|
Developer.namespaceRuntimeLink = namespaceRuntimeLink;
|
||||||
|
function createBuildsLink(workspaceName, projectName, jenkinsJobId) {
|
||||||
|
workspaceName = workspaceName || Kubernetes.currentKubernetesNamespace();
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "jenkinsJob", jenkinsJobId);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Creates a routing function that loads a template and inject the needed directives to properly
|
||||||
|
* display/update the Developer module managed tabs and bread crumbs for when the route is active.
|
||||||
|
*
|
||||||
|
* Example Usage:
|
||||||
|
*
|
||||||
|
* var route = Developer.createTabRoutingFunction("/app/somedir");
|
||||||
|
* $routeProvider.when('/profiles', route('view.html', false, [{
|
||||||
|
* label: "Profiles",
|
||||||
|
* title: "Browse the profiles of this project"
|
||||||
|
* }]
|
||||||
|
* ));
|
||||||
|
*
|
||||||
|
* @param baseURL
|
||||||
|
* @returns {function(string, boolean=, Array<Developer.BreadcrumbConfig>=): {template: string, reloadOnSearch: boolean, controller: string|string|(function(any, ng.route.IRouteParamsService): undefined)[]}}
|
||||||
|
*/
|
||||||
|
function createTabRoutingFunction(baseURL) {
|
||||||
|
return function (templateName, reloadOnSearch, children) {
|
||||||
|
if (reloadOnSearch === void 0) { reloadOnSearch = true; }
|
||||||
|
return {
|
||||||
|
template: "<div hawtio-breadcrumbs></div><div hawtio-tabs></div><ng-include src='contentTemplateUrl'></ng-include>",
|
||||||
|
reloadOnSearch: reloadOnSearch,
|
||||||
|
controller: ["$scope", "$routeParams", function ($scope, $routeParams) {
|
||||||
|
if ($routeParams["namespace"] == null) {
|
||||||
|
log.error("The :namespace route parameter was not defined for the route.");
|
||||||
|
}
|
||||||
|
if ($routeParams["projectId"] == null) {
|
||||||
|
log.error("The :projectId route parameter was not defined for the route.");
|
||||||
|
}
|
||||||
|
$scope.namespace = $routeParams["namespace"];
|
||||||
|
$scope.projectId = $routeParams["projectId"];
|
||||||
|
$scope.contentTemplateUrl = UrlHelpers.join(baseURL, templateName);
|
||||||
|
$scope.breadcrumbConfig = Developer.createProjectBreadcrumbs($scope.projectId, children);
|
||||||
|
$scope.subTabConfig = Developer.createProjectSubNavBars($scope.projectId);
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
Developer.createTabRoutingFunction = createTabRoutingFunction;
|
||||||
|
function createProjectSubNavBars(projectName, jenkinsJobId, $scope) {
|
||||||
|
if (jenkinsJobId === void 0) { jenkinsJobId = null; }
|
||||||
|
if ($scope === void 0) { $scope = null; }
|
||||||
|
var workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName);
|
||||||
|
var buildsLink = UrlHelpers.join(projectLink, "builds");
|
||||||
|
if (!jenkinsJobId) {
|
||||||
|
jenkinsJobId = projectName;
|
||||||
|
}
|
||||||
|
var jenkinsBuildLink = null;
|
||||||
|
var pipelinesLink = null;
|
||||||
|
if (projectName && jenkinsJobId) {
|
||||||
|
jenkinsBuildLink = createBuildsLink(workspaceName, projectName, jenkinsJobId);
|
||||||
|
pipelinesLink = UrlHelpers.join(jenkinsBuildLink, "pipelines");
|
||||||
|
}
|
||||||
|
function isJenkinsBuild() {
|
||||||
|
var answer = jenkinsLink() && jenkinsBuildLink;
|
||||||
|
if (answer && $scope) {
|
||||||
|
var entity = Developer.projectForScope($scope);
|
||||||
|
if (entity) {
|
||||||
|
return answer && entity.$jenkinsJob;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
var answer = [
|
||||||
|
/*
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName),
|
||||||
|
label: "All Apps",
|
||||||
|
class: 'fa fa-angle-double-left',
|
||||||
|
title: "View the apps in this project"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
template: `<div ng-include="'plugins/developer/html/projectSelector.html'"></div>`
|
||||||
|
},
|
||||||
|
*/
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "environments"),
|
||||||
|
isActive: function (subTab, path) {
|
||||||
|
var href = normalizeHref(subTab.href);
|
||||||
|
//console.log("subTab: ", subTab, " path: ", path);
|
||||||
|
if (path === href) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
var rootPath = href.replace(/\/environments/, '');
|
||||||
|
if (path === rootPath) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
},
|
||||||
|
//href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName),
|
||||||
|
label: "Dashboard",
|
||||||
|
class: "fa fa-tachometer",
|
||||||
|
title: "View the app dashboard for the activity, environments and pipelines"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return isJenkinsBuild() && pipelinesLink; },
|
||||||
|
id: "pipelines",
|
||||||
|
href: pipelinesLink,
|
||||||
|
label: "Pipelines",
|
||||||
|
class: "fa fa-ellipsis-h",
|
||||||
|
title: "View the pipeline builds for this app"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return !isJenkinsBuild(); },
|
||||||
|
href: buildsLink,
|
||||||
|
label: "Builds",
|
||||||
|
class: "fa fa-bars",
|
||||||
|
title: "View the builds for this app"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return isJenkinsBuild(); },
|
||||||
|
isActive: function (item, path) {
|
||||||
|
if (path.indexOf('/log/') > 0) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (path.indexOf('/jenkinsJob/') > 0) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
},
|
||||||
|
id: "builds",
|
||||||
|
href: jenkinsBuildLink,
|
||||||
|
label: "Builds",
|
||||||
|
class: "fa fa-bars",
|
||||||
|
title: "View the Jenkins builds for this app"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return isJenkinsBuild(); },
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "jenkinsJob", jenkinsJobId, "metrics"),
|
||||||
|
label: "Metrics",
|
||||||
|
class: "fa fa-bar-chart",
|
||||||
|
title: "View the metrics for this project"
|
||||||
|
},
|
||||||
|
/*
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "tools"),
|
||||||
|
label: "Tools",
|
||||||
|
title: "View the tools for this project"
|
||||||
|
},
|
||||||
|
*/
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "buildConfigEdit"),
|
||||||
|
label: "Settings",
|
||||||
|
class: "fa fa-cog",
|
||||||
|
title: "View the app configuration",
|
||||||
|
isActive: function (subTab, path) {
|
||||||
|
if (_.endsWith(path, '/buildConfigEdit')) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (_.endsWith(path, '/forge/secrets')) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (_.endsWith(path, '/forge/command/devops-edit')) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
];
|
||||||
|
var context = {
|
||||||
|
workspaceName: workspaceName,
|
||||||
|
projectName: projectName,
|
||||||
|
projectLink: projectLink,
|
||||||
|
jenkinsJobId: jenkinsJobId,
|
||||||
|
$scope: $scope
|
||||||
|
};
|
||||||
|
angular.forEach(Developer.customProjectSubTabFactories, function (fn) {
|
||||||
|
if (angular.isFunction(fn)) {
|
||||||
|
var subtab = fn(context);
|
||||||
|
if (subtab) {
|
||||||
|
if (angular.isArray(subtab)) {
|
||||||
|
angular.forEach(subtab, function (t) {
|
||||||
|
answer.push(t);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
answer.push(subtab);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return activateCurrent(answer);
|
||||||
|
}
|
||||||
|
Developer.createProjectSubNavBars = createProjectSubNavBars;
|
||||||
|
function createProjectSettingsSubNavBars(projectName, jenkinsJobId) {
|
||||||
|
if (jenkinsJobId === void 0) { jenkinsJobId = null; }
|
||||||
|
if (!projectName) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
var workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName);
|
||||||
|
if (!jenkinsJobId) {
|
||||||
|
jenkinsJobId = projectName;
|
||||||
|
}
|
||||||
|
var answer = [
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, "buildConfigEdit"),
|
||||||
|
label: "Core",
|
||||||
|
title: "View the core build configuration"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: projectSecretsLink(workspaceName, projectName),
|
||||||
|
label: "Secrets",
|
||||||
|
title: "View or change the secrets used to edit source code in the source control system"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
href: editPipelineLink(workspaceName, projectName),
|
||||||
|
label: "Pipeline",
|
||||||
|
title: "View the DevOps and pipeline configuration"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
isValid: function () { return forgeProjectHasBuilder("maven"); },
|
||||||
|
href: editMavenBuildLink(workspaceName, projectName),
|
||||||
|
label: "Maven",
|
||||||
|
title: "View the Maven build configuration"
|
||||||
|
}
|
||||||
|
];
|
||||||
|
return activateCurrent(answer);
|
||||||
|
}
|
||||||
|
Developer.createProjectSettingsSubNavBars = createProjectSettingsSubNavBars;
|
||||||
|
function forgeProjectHasBuilder(name) {
|
||||||
|
var forgeProject = Kubernetes.inject("ForgeProject");
|
||||||
|
if (forgeProject) {
|
||||||
|
return forgeProject.hasBuilder(name);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Developer.forgeProjectHasBuilder = forgeProjectHasBuilder;
|
||||||
|
function forgeProjectHasPerspective(name) {
|
||||||
|
var forgeProject = Kubernetes.inject("ForgeProject");
|
||||||
|
if (forgeProject) {
|
||||||
|
return forgeProject.hasPerspective(name);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Developer.forgeProjectHasPerspective = forgeProjectHasPerspective;
|
||||||
|
function editPipelineLinkScope($scope) {
|
||||||
|
return editPipelineLink($scope.namespace, $scope.projectId || $scope.projectName || $scope.project);
|
||||||
|
}
|
||||||
|
Developer.editPipelineLinkScope = editPipelineLinkScope;
|
||||||
|
function createProjectLink(workspaceName) {
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "/forge/createProject");
|
||||||
|
}
|
||||||
|
Developer.createProjectLink = createProjectLink;
|
||||||
|
function editPipelineLink(workspaceName, projectName) {
|
||||||
|
return projectWorkspaceLink(workspaceName, projectName, "forge/command/devops-edit");
|
||||||
|
}
|
||||||
|
Developer.editPipelineLink = editPipelineLink;
|
||||||
|
function editMavenBuildLink(workspaceName, projectName) {
|
||||||
|
return projectWorkspaceLink(workspaceName, projectName, "forge/command/fabric8-setup");
|
||||||
|
}
|
||||||
|
Developer.editMavenBuildLink = editMavenBuildLink;
|
||||||
|
function projectSecretsLink(workspaceName, projectName) {
|
||||||
|
return projectWorkspaceLink(workspaceName, projectName, "forge/secrets", false);
|
||||||
|
}
|
||||||
|
Developer.projectSecretsLink = projectSecretsLink;
|
||||||
|
function secretsNamespaceLink(workspaceName, projectName, secretsNamespace) {
|
||||||
|
var prefix = projectWorkspaceLink(workspaceName, projectName, "") || "kubernetes";
|
||||||
|
return UrlHelpers.join(prefix, "namespace", secretsNamespace, "secrets");
|
||||||
|
}
|
||||||
|
Developer.secretsNamespaceLink = secretsNamespaceLink;
|
||||||
|
function projectWorkspaceLink(workspaceName, projectName, path, ignoreBlankProject) {
|
||||||
|
if (ignoreBlankProject === void 0) { ignoreBlankProject = true; }
|
||||||
|
if (ignoreBlankProject && !projectName) {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", projectName, path);
|
||||||
|
}
|
||||||
|
Developer.projectWorkspaceLink = projectWorkspaceLink;
|
||||||
|
function environmentsLink(workspaceName) {
|
||||||
|
if (workspaceName === void 0) { workspaceName = null; }
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "environments");
|
||||||
|
}
|
||||||
|
Developer.environmentsLink = environmentsLink;
|
||||||
|
function environmentLink(workspaceName, environmentNamespace, path, ignoreBlankProject) {
|
||||||
|
if (path === void 0) { path = ""; }
|
||||||
|
if (ignoreBlankProject === void 0) { ignoreBlankProject = true; }
|
||||||
|
if (ignoreBlankProject && !environmentNamespace) {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
if (!workspaceName) {
|
||||||
|
workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "namespace", environmentNamespace, path);
|
||||||
|
}
|
||||||
|
Developer.environmentLink = environmentLink;
|
||||||
|
Developer.customProjectSubTabFactories = [];
|
||||||
|
function createJenkinsBreadcrumbs(projectName, jobId, buildId) {
|
||||||
|
var workspaceName = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var children = [
|
||||||
|
{
|
||||||
|
id: "builds",
|
||||||
|
href: createBuildsLink(workspaceName, projectName, jobId),
|
||||||
|
label: "Builds",
|
||||||
|
title: "View the builds for this app"
|
||||||
|
}
|
||||||
|
];
|
||||||
|
if (buildId) {
|
||||||
|
children.push({
|
||||||
|
id: "",
|
||||||
|
href: "",
|
||||||
|
label: "#" + buildId,
|
||||||
|
title: "Build #" + buildId
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return createProjectBreadcrumbs(projectName, children);
|
||||||
|
}
|
||||||
|
Developer.createJenkinsBreadcrumbs = createJenkinsBreadcrumbs;
|
||||||
|
function createJenkinsSubNavBars(projectName, jenkinsJobId, buildId, extraOption) {
|
||||||
|
if (extraOption === void 0) { extraOption = null; }
|
||||||
|
var answer = createProjectSubNavBars(projectName, jenkinsJobId);
|
||||||
|
if (extraOption) {
|
||||||
|
// extraOption.active = true;
|
||||||
|
answer.push(extraOption);
|
||||||
|
}
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
Developer.createJenkinsSubNavBars = createJenkinsSubNavBars;
|
||||||
|
function createEnvironmentSubNavBars($scope, $location, $routeParams) {
|
||||||
|
var ns = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var workspaceName = $routeParams.workspace;
|
||||||
|
var project = $routeParams.project;
|
||||||
|
var environment = $routeParams.namespace;
|
||||||
|
var projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/kubernetes");
|
||||||
|
/*console.log("=====================")
|
||||||
|
console.log(projectLink);
|
||||||
|
if (workspaceName && project) {
|
||||||
|
projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/kubernetes", workspaceName, "projects", project);
|
||||||
|
} else {
|
||||||
|
projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/kubernetes", workspaceName || ns);
|
||||||
|
}*/
|
||||||
|
var namespacesLink = UrlHelpers.join(projectLink, "namespace");
|
||||||
|
return activateCurrent([
|
||||||
|
{
|
||||||
|
href: UrlHelpers.join(namespacesLink, ns, "replicationControllers"),
|
||||||
|
label: "服务管理",
|
||||||
|
class: "fa fa-clone",
|
||||||
|
title: "View the Replicas for this project"
|
||||||
|
},
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
Developer.createEnvironmentSubNavBars = createEnvironmentSubNavBars;
|
||||||
|
function environmentInstanceLink(env, projectName) {
|
||||||
|
if (projectName === void 0) { projectName = null; }
|
||||||
|
if (env) {
|
||||||
|
var envNamespace = env["namespace"];
|
||||||
|
if (envNamespace) {
|
||||||
|
if (projectName) {
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", Kubernetes.currentKubernetesNamespace(), "projects", projectName, "namespace", envNamespace);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", Kubernetes.currentKubernetesNamespace(), "namespace", envNamespace);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
Developer.environmentInstanceLink = environmentInstanceLink;
|
||||||
|
function namespaceLink($scope, $routeParams, path) {
|
||||||
|
if (path === void 0) { path = null; }
|
||||||
|
var ns = Kubernetes.currentKubernetesNamespace();
|
||||||
|
var workspaceName = $routeParams.workspace;
|
||||||
|
var project = $routeParams.project;
|
||||||
|
var projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/kubernetes");
|
||||||
|
if (workspaceName && project) {
|
||||||
|
projectLink = UrlHelpers.join(HawtioCore.documentBase(), "/workspaces", workspaceName, "projects", project);
|
||||||
|
}
|
||||||
|
return UrlHelpers.join(projectLink, "namespace", ns, path);
|
||||||
|
}
|
||||||
|
Developer.namespaceLink = namespaceLink;
|
||||||
|
/**
|
||||||
|
* Removes the URL query string if its inside the given text
|
||||||
|
*/
|
||||||
|
function trimQuery(text) {
|
||||||
|
if (text) {
|
||||||
|
var idx = text.indexOf("?");
|
||||||
|
if (idx >= 0) {
|
||||||
|
return text.substring(0, idx);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return text;
|
||||||
|
}
|
||||||
|
// Cater for the app running at some weird document base
|
||||||
|
function normalizeHref(href) {
|
||||||
|
if (!href) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
var regex = new RegExp('^' + HawtioCore.documentBase().replace('/', '\\/'));
|
||||||
|
return href.replace(regex, '/');
|
||||||
|
}
|
||||||
|
Developer.normalizeHref = normalizeHref;
|
||||||
|
function activateCurrent(navBarItems) {
|
||||||
|
navBarItems = _.compact(navBarItems);
|
||||||
|
var injector = HawtioCore.injector;
|
||||||
|
var $location = injector ? injector.get("$location") : null;
|
||||||
|
if ($location) {
|
||||||
|
var path = normalizeHref(trimQuery($location.path()));
|
||||||
|
var found = false;
|
||||||
|
function makeActive(item) {
|
||||||
|
item.active = true;
|
||||||
|
found = true;
|
||||||
|
}
|
||||||
|
function getHref(item) {
|
||||||
|
var href = item.href;
|
||||||
|
var trimHref = trimQuery(href);
|
||||||
|
return normalizeHref(trimHref);
|
||||||
|
}
|
||||||
|
angular.forEach(navBarItems, function (item) {
|
||||||
|
if (!found && item) {
|
||||||
|
if (angular.isFunction(item.isActive)) {
|
||||||
|
if (item.isActive(item, path)) {
|
||||||
|
makeActive(item);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var trimHref = getHref(item);
|
||||||
|
if (!trimHref) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (trimHref === path) {
|
||||||
|
makeActive(item);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
// Maybe it's a sub-item of a tab, let's fall back to that maybe
|
||||||
|
if (!found) {
|
||||||
|
angular.forEach(navBarItems, function (item) {
|
||||||
|
if (!found) {
|
||||||
|
if (!angular.isFunction(item.isActive)) {
|
||||||
|
var trimHref = getHref(item);
|
||||||
|
if (!trimHref) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (_.startsWith(path, trimHref)) {
|
||||||
|
makeActive(item);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
// still not found, let's log it
|
||||||
|
if (!found) {
|
||||||
|
log.debug("No navigation tab found for path:", path);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return navBarItems;
|
||||||
|
}
|
||||||
|
Developer.activateCurrent = activateCurrent;
|
||||||
|
function processChildren(answer, children) {
|
||||||
|
if (children) {
|
||||||
|
if (angular.isArray(children)) {
|
||||||
|
answer = answer.concat(children);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
answer.push(children);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
activateCurrent(answer);
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
})(Developer || (Developer = {}));
|
||||||
|
//# sourceMappingURL=developerNavigation.js.map
|
File diff suppressed because one or more lines are too long
|
@ -8,7 +8,6 @@
|
||||||
/// <reference path="dataManagerModel.ts"/>
|
/// <reference path="dataManagerModel.ts"/>
|
||||||
/// <reference path="../../configs/ts/configsHelper.ts"/>
|
/// <reference path="../../configs/ts/configsHelper.ts"/>
|
||||||
/// <reference path="../../configs/ts/customAlert.ts"/>
|
/// <reference path="../../configs/ts/customAlert.ts"/>
|
||||||
|
|
||||||
module Developer {
|
module Developer {
|
||||||
export var WorkspacesController = controller("WorkspacesController", ["$scope", "KubernetesModel", "DataModel", "ConfigsModel", "KubernetesState", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "KubernetesApiURL", "$element", "ngDialog",
|
export var WorkspacesController = controller("WorkspacesController", ["$scope", "KubernetesModel", "DataModel", "ConfigsModel", "KubernetesState", "$templateCache", "$location", "$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, KubernetesModel: Kubernetes.KubernetesModelService, DataModel: Developer.DataModelService, ConfigsModel: Configs.ConfigsModelService, KubernetesState, $templateCache: ng.ITemplateCacheService, $location: ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL, $element, ngDialog) => {
|
||||||
|
@ -19,7 +18,6 @@ module Developer {
|
||||||
$scope.pageSizeChoses = DataModel.paramOptions.pagerSizeOption;
|
$scope.pageSizeChoses = DataModel.paramOptions.pagerSizeOption;
|
||||||
var result = getDataType($location);
|
var result = getDataType($location);
|
||||||
|
|
||||||
|
|
||||||
$scope.treeOptions = {
|
$scope.treeOptions = {
|
||||||
nodeChildren: "childNodes",
|
nodeChildren: "childNodes",
|
||||||
dirSelectable: true,
|
dirSelectable: true,
|
||||||
|
@ -45,8 +43,7 @@ module Developer {
|
||||||
filterOptions: {
|
filterOptions: {
|
||||||
filterText: $location.search()["q"] || ''
|
filterText: $location.search()["q"] || ''
|
||||||
},
|
},
|
||||||
columnDefs: [
|
columnDefs: [{
|
||||||
{
|
|
||||||
field: "_key",
|
field: "_key",
|
||||||
displayName: '编码'
|
displayName: '编码'
|
||||||
},
|
},
|
||||||
|
@ -223,6 +220,11 @@ module Developer {
|
||||||
}).open();
|
}).open();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//测试代码
|
||||||
|
// $scope.change= function (){
|
||||||
|
// console.info($scope.model.data);
|
||||||
|
// }
|
||||||
|
|
||||||
$scope.migrationClick = {
|
$scope.migrationClick = {
|
||||||
items: null,
|
items: null,
|
||||||
selectedItem: { "name": "当前没有可以迁移的集群" },
|
selectedItem: { "name": "当前没有可以迁移的集群" },
|
||||||
|
@ -233,15 +235,18 @@ module Developer {
|
||||||
向后台发生数据迁移请求,$http:发生http异步请求;第二个参数:请求url;第三个参数:请求操作类型;第四个参数:请求携带的数据;第五个参数:
|
向后台发生数据迁移请求,$http:发生http异步请求;第二个参数:请求url;第三个参数:请求操作类型;第四个参数:请求携带的数据;第五个参数:
|
||||||
一个回调函数,请求响应后的回调函数。
|
一个回调函数,请求响应后的回调函数。
|
||||||
*/
|
*/
|
||||||
|
//$scope.tableConfig.selectedItems[0].volumePath $scope.vlome
|
||||||
|
|
||||||
if(Kubernetes.alreadyExitInFolder($scope.tableConfig.selectedItems, $scope.selectNode)){
|
var volumePath = migrationClick.selectedItem.path;
|
||||||
|
if (Kubernetes.alreadyExitInCluster($scope.tableConfig.selectedItems, volumePath)) {
|
||||||
migrationClick.close();
|
migrationClick.close();
|
||||||
Configs.customAlert("提示", "操作失败:" + "数据已在当前目录!", '',null, 0, "error");
|
Configs.customAlert("提示", "操作失败:" + "数据已在当前集群中!", '', null, 0, "error");
|
||||||
return;
|
return;
|
||||||
};
|
};
|
||||||
|
|
||||||
Configs.oracleInfoOperate($http, "/java/console/api/volume", Configs.OperateType.MOVE,
|
$scope.selectNode = $scope.migrationClick.selectedItem.folder[0];
|
||||||
{
|
// $scope.selectNode.path=volumePath;
|
||||||
|
Configs.oracleInfoOperate($http, "/java/console/api/volume", Configs.OperateType.MOVE, {
|
||||||
"name": migrationClick.selectedItem.name,
|
"name": migrationClick.selectedItem.name,
|
||||||
"selectItems": $scope.tableConfig.selectedItems,
|
"selectItems": $scope.tableConfig.selectedItems,
|
||||||
"selectNode": $scope.selectNode
|
"selectNode": $scope.selectNode
|
||||||
|
@ -287,7 +292,10 @@ module Developer {
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.createOracleService = (items) => {
|
$scope.createOracleService = (items) => {
|
||||||
|
console.log($scope.tableConfig.selectedItems);
|
||||||
|
console.log("selected");
|
||||||
var exitedItems = Kubernetes.checkForCreateOracle($scope.model.transferTasks, items);
|
var exitedItems = Kubernetes.checkForCreateOracle($scope.model.transferTasks, items);
|
||||||
|
console.log(items);
|
||||||
for (var i = 0; i < items.length; ++i) {
|
for (var i = 0; i < items.length; ++i) {
|
||||||
// code...
|
// code...
|
||||||
if (items[i].dataBaseType != 'ORACLE') {
|
if (items[i].dataBaseType != 'ORACLE') {
|
||||||
|
@ -319,7 +327,7 @@ module Developer {
|
||||||
isTarget: "false",
|
isTarget: "false",
|
||||||
isExtract: item.extractStatus
|
isExtract: item.extractStatus
|
||||||
}, (rc) => {
|
}, (rc) => {
|
||||||
Kubernetes.connectOracle($http, $timeout, "/java/console/api/connectOracle", "create", rc, 0);
|
Kubernetes.connectOracle($http, $timeout, "/java/console/api/connectOracle", "create", rc, 50000000000);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -365,7 +373,8 @@ module Developer {
|
||||||
title: "查看批次B的数据",
|
title: "查看批次B的数据",
|
||||||
class: "",
|
class: "",
|
||||||
alias: "B"
|
alias: "B"
|
||||||
}];
|
}
|
||||||
|
];
|
||||||
|
|
||||||
if (!($location.path().indexOf("hot") > -1)) {
|
if (!($location.path().indexOf("hot") > -1)) {
|
||||||
$scope.tableConfig.columnDefs.splice(7, 0, {
|
$scope.tableConfig.columnDefs.splice(7, 0, {
|
||||||
|
@ -409,5 +418,6 @@ module Developer {
|
||||||
"volumeType": volumeType
|
"volumeType": volumeType
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}]);
|
}
|
||||||
|
]);
|
||||||
}
|
}
|
|
@ -0,0 +1,6 @@
|
||||||
|
/// <reference path="../libs/hawtio-forms/defs.d.ts"/>
|
||||||
|
/// <reference path="../libs/hawtio-kubernetes-api/defs.d.ts"/>
|
||||||
|
/// <reference path="../libs/hawtio-oauth/defs.d.ts"/>
|
||||||
|
/// <reference path="../libs/hawtio-ui/defs.d.ts"/>
|
||||||
|
/// <reference path="../libs/hawtio-utilities/defs.d.ts"/>
|
||||||
|
//# sourceMappingURL=includes.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"includes.js","sourceRoot":"","sources":["includes.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,+DAA+D;AAC/D,sDAAsD;AACtD,mDAAmD;AACnD,0DAA0D"}
|
|
@ -233,7 +233,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script type="text/ng-template" id="taskRecordEdit.html">
|
<script type="text/ng-template" id="taskRecordEdit.html">
|
||||||
<div class="ngCellText" ng-init="entity=row.entity" ng-controller="Kubernetes.TaskRecordEdit">
|
<div class="ngCellText" ng-init="entity=row.entity" ng-controller="Kubernetes.TaskRecordEdit">
|
||||||
<button class="btn sj_btn" style="border:0;background:none;" ng-click="showDeleteOne.open(entity)" ng-disabled="entity.status == 1 || entity.status == 0">
|
<button class="btn sj_btn" style="border:0;background:none;" ng-click="showDeleteOne.open(entity)" ng-disabled="entity.status == 1 || entity.status == 0">
|
||||||
|
@ -260,7 +259,6 @@
|
||||||
<div style="position:relative;text-align:right;width:100%;height:15px;line-height:90%">
|
<div style="position:relative;text-align:right;width:100%;height:15px;line-height:90%">
|
||||||
<span>{{entity.process}}%</span>
|
<span>{{entity.process}}%</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- <div ng-show="entity.status ===3" class="progress-bar progress-bar-danger active sj_progress_bar" role="progressbar" aria-valuenow="{{entity.process}}" aria-valuemin="30" aria-valuemax="100" style="width: 100%" title="{{entity.process}}%">
|
<!-- <div ng-show="entity.status ===3" class="progress-bar progress-bar-danger active sj_progress_bar" role="progressbar" aria-valuenow="{{entity.process}}" aria-valuemin="30" aria-valuemax="100" style="width: 100%" title="{{entity.process}}%">
|
||||||
<span class="sj_progress_font">{{entity.process}}%</span>
|
<span class="sj_progress_font">{{entity.process}}%</span>
|
||||||
</div> -->
|
</div> -->
|
||||||
|
@ -319,12 +317,34 @@
|
||||||
</script>
|
</script>
|
||||||
<script type="text/ng-template" id="isExistHot.html">
|
<script type="text/ng-template" id="isExistHot.html">
|
||||||
<div class="ngCellText" ng-init="entity=row.entity">
|
<div class="ngCellText" ng-init="entity=row.entity">
|
||||||
<div ng-show="true" title="是否是标准表汇总库">
|
<div ng-show="true" title="是否在热区">
|
||||||
<span ng-show="entity.existHotData == 0"> 否</span>
|
<span ng-show="entity.existHotData == 0"> 否</span>
|
||||||
<span ng-show="entity.existHotData == 1"> 是</span>
|
<span ng-show="entity.existHotData == 1"> 是</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</script>
|
</script>
|
||||||
|
<script type="text/ng-template" id="modal.html">
|
||||||
|
<div>
|
||||||
|
<div class="modal-header">
|
||||||
|
<h3 class="modal-title" align="center">
|
||||||
|
标题信息
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
<div align="center">
|
||||||
|
{{data}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button class="btn btn-primary" ng-click="ok()">
|
||||||
|
确认
|
||||||
|
</button>
|
||||||
|
<button class="btn btn-warning" ng-click="cancel()">
|
||||||
|
退出
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</script>
|
||||||
<div ng-controller="Kubernetes.TopLevel">
|
<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="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>
|
<div class="row kubernetes-view" ng-view></div>
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
<span class="fa fa-caret-down"></span>
|
<span class="fa fa-caret-down"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="terminal-title" ng-mousedown="mouseDown($event)" ng-mouseup="mouseUp($event)" ng-mousemove="mouseMove($event)">
|
<div class="terminal-title" ng-mousedown="mouseDown($event)" ng-mouseup="mouseUp($event)" ng-mousemove="mouseMove($event)">
|
||||||
<h5 class="top-bottom-middle">{{containerName}}的抽取日志</h5>
|
<h5 class="top-bottom-middle" ng-hide="isExportLog">{{containerName}}的抽取日志</h5>
|
||||||
|
<h5 class="top-bottom-middle" ng-hide="!isExportLog">导出日志</h5>
|
||||||
<i class="fa fa-remove pull-right clickable" title="Close and exit this log" ng-click="close()"></i>
|
<i class="fa fa-remove pull-right clickable" title="Close and exit this log" ng-click="close()"></i>
|
||||||
<i class="fa fa-square-o pull-right clickable" title="Maximize this log" ng-click="maximize($event)"></i>
|
<i class="fa fa-square-o pull-right clickable" title="Maximize this log" ng-click="maximize($event)"></i>
|
||||||
<i class="fa fa-sort-desc pull-right clickable" ng-hide="maximized()" title="Minimize this log" ng-click="minimize($event)"></i>
|
<i class="fa fa-sort-desc pull-right clickable" ng-hide="maximized()" title="Minimize this log" ng-click="minimize($event)"></i>
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
|
@ -1850,12 +1850,12 @@ module Kubernetes {
|
||||||
},
|
},
|
||||||
complete: (XMLHttpRequest, textStatus) => {
|
complete: (XMLHttpRequest, textStatus) => {
|
||||||
if(XMLHttpRequest.status == 200){
|
if(XMLHttpRequest.status == 200){
|
||||||
//spinner.spin();
|
spinner.spin();
|
||||||
Kubernetes.createSuccessInfo("success", "连接汇总库成功,即将执行汇总或抽取操作!");
|
Kubernetes.createSuccessInfo("success", "连接汇总库成功,即将执行汇总或抽取操作!");
|
||||||
setTimeout("Kubernetes.removeMask()", 1500);
|
setTimeout("Kubernetes.removeMask()", 1500);
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
//spinner.spin();
|
spinner.spin();
|
||||||
Kubernetes.createSuccessInfo("error", "连接汇总库失败,请检查服务集群中的汇总库配置是否正确!");
|
Kubernetes.createSuccessInfo("error", "连接汇总库失败,请检查服务集群中的汇总库配置是否正确!");
|
||||||
setTimeout("Kubernetes.removeMask()", 1500);
|
setTimeout("Kubernetes.removeMask()", 1500);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,213 @@
|
||||||
|
var Kubernetes;
|
||||||
|
(function (Kubernetes) {
|
||||||
|
var consts = (function () {
|
||||||
|
function consts() {
|
||||||
|
}
|
||||||
|
Object.defineProperty(consts.prototype, "NAMESPACE_STORAGE_KEY", {
|
||||||
|
get: function () { return "k8sSelectedNamespace"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
return consts;
|
||||||
|
})();
|
||||||
|
Kubernetes.consts = consts;
|
||||||
|
Kubernetes.Constants = new consts();
|
||||||
|
var WatchTypes = (function () {
|
||||||
|
function WatchTypes() {
|
||||||
|
}
|
||||||
|
Object.defineProperty(WatchTypes, "ENDPOINTS", {
|
||||||
|
get: function () { return "endpoints"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "EVENTS", {
|
||||||
|
get: function () { return "events"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "NAMESPACES", {
|
||||||
|
get: function () { return "namespaces"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "NODES", {
|
||||||
|
get: function () { return "nodes"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "PERSISTENT_VOLUMES", {
|
||||||
|
get: function () { return "persistentvolumes"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "PERSISTENT_VOLUME_CLAIMS", {
|
||||||
|
get: function () { return "persistentvolumeclaims"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "PODS", {
|
||||||
|
get: function () { return "pods"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "REPLICATION_CONTROLLERS", {
|
||||||
|
get: function () { return "replicationcontrollers"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "RESOURCE_QUOTAS", {
|
||||||
|
get: function () { return "resourcequotas"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "OAUTH_CLIENTS", {
|
||||||
|
get: function () { return "oauthclients"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "SECRETS", {
|
||||||
|
get: function () { return "secrets"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "SERVICES", {
|
||||||
|
get: function () { return "services"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "SERVICE_ACCOUNTS", {
|
||||||
|
get: function () { return "serviceaccounts"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "TEMPLATES", {
|
||||||
|
get: function () { return "templates"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "ROUTES", {
|
||||||
|
get: function () { return "routes"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "BUILD_CONFIGS", {
|
||||||
|
get: function () { return "buildconfigs"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "BUILDS", {
|
||||||
|
get: function () { return "builds"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "DEPLOYMENT_CONFIGS", {
|
||||||
|
get: function () { return "deploymentconfigs"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "IMAGE_STREAMS", {
|
||||||
|
get: function () { return "imagestreams"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "POLICIES", {
|
||||||
|
get: function () { return "policies"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "POLICY_BINDINGS", {
|
||||||
|
get: function () { return "policybindings"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "PROJECTS", {
|
||||||
|
get: function () { return "projects"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "ROLE_BINDINGS", {
|
||||||
|
get: function () { return "rolebindings"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchTypes, "ROLES", {
|
||||||
|
get: function () { return "roles"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
return WatchTypes;
|
||||||
|
})();
|
||||||
|
Kubernetes.WatchTypes = WatchTypes;
|
||||||
|
var NamespacedTypes = (function () {
|
||||||
|
function NamespacedTypes() {
|
||||||
|
}
|
||||||
|
Object.defineProperty(NamespacedTypes, "k8sTypes", {
|
||||||
|
get: function () {
|
||||||
|
return [
|
||||||
|
WatchTypes.ENDPOINTS,
|
||||||
|
WatchTypes.EVENTS,
|
||||||
|
WatchTypes.NODES,
|
||||||
|
WatchTypes.PERSISTENT_VOLUMES,
|
||||||
|
WatchTypes.PERSISTENT_VOLUME_CLAIMS,
|
||||||
|
WatchTypes.PODS,
|
||||||
|
WatchTypes.REPLICATION_CONTROLLERS,
|
||||||
|
WatchTypes.RESOURCE_QUOTAS,
|
||||||
|
WatchTypes.PERSISTENT_VOLUMES,
|
||||||
|
WatchTypes.SECRETS,
|
||||||
|
WatchTypes.SERVICES,
|
||||||
|
WatchTypes.SERVICE_ACCOUNTS
|
||||||
|
];
|
||||||
|
},
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(NamespacedTypes, "osTypes", {
|
||||||
|
get: function () {
|
||||||
|
return [
|
||||||
|
WatchTypes.TEMPLATES,
|
||||||
|
WatchTypes.BUILD_CONFIGS,
|
||||||
|
WatchTypes.ROUTES,
|
||||||
|
WatchTypes.BUILDS,
|
||||||
|
WatchTypes.BUILD_CONFIGS,
|
||||||
|
WatchTypes.DEPLOYMENT_CONFIGS,
|
||||||
|
WatchTypes.IMAGE_STREAMS,
|
||||||
|
WatchTypes.OAUTH_CLIENTS,
|
||||||
|
WatchTypes.POLICIES,
|
||||||
|
WatchTypes.POLICY_BINDINGS,
|
||||||
|
WatchTypes.PROJECTS,
|
||||||
|
];
|
||||||
|
},
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
return NamespacedTypes;
|
||||||
|
})();
|
||||||
|
Kubernetes.NamespacedTypes = NamespacedTypes;
|
||||||
|
var WatchActions = (function () {
|
||||||
|
function WatchActions() {
|
||||||
|
}
|
||||||
|
Object.defineProperty(WatchActions, "ANY", {
|
||||||
|
get: function () { return "*"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchActions, "ADDED", {
|
||||||
|
get: function () { return "ADDED"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchActions, "MODIFIED", {
|
||||||
|
get: function () { return "MODIFIED"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
Object.defineProperty(WatchActions, "DELETED", {
|
||||||
|
get: function () { return "DELETED"; },
|
||||||
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
return WatchActions;
|
||||||
|
})();
|
||||||
|
Kubernetes.WatchActions = WatchActions;
|
||||||
|
})(Kubernetes || (Kubernetes = {}));
|
||||||
|
//# sourceMappingURL=kubernetesInterfaces.js.map
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,237 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="kubernetesHelpers.ts"/>
|
||||||
|
var Kubernetes;
|
||||||
|
(function (Kubernetes) {
|
||||||
|
Kubernetes._module = angular.module(Kubernetes.pluginName, ['hawtio-core', 'hawtio-ui', 'ui.codemirror', 'ui.validate', 'kubernetesUI']);
|
||||||
|
Kubernetes.controller = PluginHelpers.createControllerFunction(Kubernetes._module, Kubernetes.pluginName);
|
||||||
|
Kubernetes.route = PluginHelpers.createRoutingFunction(Kubernetes.templatePath);
|
||||||
|
Kubernetes._module.config(['$routeProvider', function ($routeProvider) {
|
||||||
|
$routeProvider
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, '/pods'), Kubernetes.route('pods.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'replicationControllers'), Kubernetes.route('replicationControllers.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'services'), Kubernetes.route('services.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'events'), Kubernetes.route('events.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'apps'), Kubernetes.route('apps.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'apps/:namespace'), Kubernetes.route('apps.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'templates'), Kubernetes.route('templates.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'hosts'), Kubernetes.route('hosts.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'hosts/:id'), Kubernetes.route('host.html', true))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'pipelines'), Kubernetes.route('pipelines.html', false))
|
||||||
|
.when(UrlHelpers.join(Kubernetes.context, 'overview'), Kubernetes.route('overview.html', true))
|
||||||
|
.when(Kubernetes.context, { redirectTo: UrlHelpers.join(Kubernetes.context, 'replicationControllers') });
|
||||||
|
angular.forEach([Kubernetes.context, "/workspaces/:workspace/projects/:project"], function (context) {
|
||||||
|
$routeProvider
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/podCreate'), Kubernetes.route('podCreate.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/podEdit/:id'), Kubernetes.route('podEdit.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/pods'), Kubernetes.route('pods.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/pods/:id'), Kubernetes.route('pod.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/replicationControllers'), Kubernetes.route('replicationControllers.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/replicationControllers/:id'), Kubernetes.route('replicationController.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/replicationControllerCreate'), Kubernetes.route('replicationControllerCreate.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/replicationControllerEdit/:id'), Kubernetes.route('replicationControllerEdit.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/secrets'), Kubernetes.route('secrets.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/secrets/:id'), Kubernetes.route('secret.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/secretCreate'), Kubernetes.route('secret.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/services'), Kubernetes.route('services.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/services/:id'), Kubernetes.route('service.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/serviceCreate'), Kubernetes.route('serviceCreate.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/serviceEdit/:id'), Kubernetes.route('serviceEdit.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/events'), Kubernetes.route('events.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/apps'), Kubernetes.route('apps.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/overview'), Kubernetes.route('overview.html', true))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace/templates/:targetNamespace'), Kubernetes.route('templates.html', false))
|
||||||
|
.when(UrlHelpers.join(context, '/namespace/:namespace'), Kubernetes.route('apps.html', false))
|
||||||
|
.when(UrlHelpers.join(context, 'builds'), Kubernetes.route('builds.html', false))
|
||||||
|
.when(UrlHelpers.join(context, 'builds/:id'), Kubernetes.route('build.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'buildLogs/:id'), Kubernetes.route('buildLogs.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'buildConfigs'), Kubernetes.route('buildConfigs.html', false))
|
||||||
|
.when(UrlHelpers.join(context, 'buildConfigs/:id'), Kubernetes.route('buildConfig.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'buildConfigEdit/:id'), Kubernetes.route('buildConfigEdit.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'deploymentConfigs'), Kubernetes.route('deploymentConfigs.html', false))
|
||||||
|
.when(UrlHelpers.join(context, 'deploymentConfigs/:id'), Kubernetes.route('deploymentConfig.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'imageRepositories'), Kubernetes.route('imageRepositories.html', false));
|
||||||
|
});
|
||||||
|
angular.forEach([Kubernetes.context, "/workspaces/:workspace", "/workspaces/:workspace/projects/:project"], function (context) {
|
||||||
|
$routeProvider
|
||||||
|
.when(UrlHelpers.join(context, 'buildConfigEdit'), Kubernetes.route('buildConfigEdit.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'buildConfigEdit/:id'), Kubernetes.route('buildConfigEdit.html', true))
|
||||||
|
.when(UrlHelpers.join(context, 'importProject'), Kubernetes.route('importProject.html', true));
|
||||||
|
});
|
||||||
|
}]);
|
||||||
|
Kubernetes._module.factory('AppLibraryURL', ['$rootScope', function ($rootScope) {
|
||||||
|
return UrlHelpers.join(Kubernetes.kubernetesApiUrl(), "/proxy", Kubernetes.kubernetesNamespacePath(), "/services/app-library");
|
||||||
|
}]);
|
||||||
|
Kubernetes._module.factory('WikiGitUrlPrefix', function () {
|
||||||
|
return UrlHelpers.join(Kubernetes.kubernetesApiUrl(), "/proxy", Kubernetes.kubernetesNamespacePath(), "services/app-library");
|
||||||
|
});
|
||||||
|
Kubernetes._module.factory('wikiRepository', ["$location", "localStorage", function ($location, localStorage) {
|
||||||
|
return false;
|
||||||
|
}]);
|
||||||
|
Kubernetes._module.factory('ConnectDialogService', ['$rootScope', function ($rootScope) {
|
||||||
|
return {
|
||||||
|
dialog: new UI.Dialog(),
|
||||||
|
saveCredentials: false,
|
||||||
|
userName: null,
|
||||||
|
password: null,
|
||||||
|
jolokiaUrl: null,
|
||||||
|
containerName: null,
|
||||||
|
view: null
|
||||||
|
};
|
||||||
|
}]);
|
||||||
|
Kubernetes._module.filter('kubernetesPageLink', function () { return Kubernetes.entityPageLink; });
|
||||||
|
Kubernetes._module.filter('relativeTime', function () {
|
||||||
|
return function (date) {
|
||||||
|
return humandate.relativeTime(date);
|
||||||
|
};
|
||||||
|
});
|
||||||
|
Kubernetes._module.run(['viewRegistry', 'ServiceRegistry', 'HawtioNav', 'KubernetesModel', '$templateCache', function (viewRegistry, ServiceRegistry, HawtioNav, KubernetesModel, $templateCache) {
|
||||||
|
Kubernetes.log.debug("Running");
|
||||||
|
viewRegistry['kubernetes'] = Kubernetes.templatePath + 'layoutKubernetes.html';
|
||||||
|
//viewRegistry['kubernetes'] = Configs.templatePath + 'shareLayout.html';
|
||||||
|
var builder = HawtioNav.builder();
|
||||||
|
var apps = builder.id('kube-apps')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'apps'); })
|
||||||
|
.title(function () { return 'Apps'; })
|
||||||
|
.build();
|
||||||
|
var services = builder.id('kube-services')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'services'); })
|
||||||
|
.title(function () { return 'Services'; })
|
||||||
|
.build();
|
||||||
|
var controllers = builder.id('kube-controllers')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'replicationControllers'); })
|
||||||
|
.title(function () { return 'oracle服务'; })
|
||||||
|
.build();
|
||||||
|
var pods = builder.id('kube-pods')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'pods'); })
|
||||||
|
.title(function () { return '测试页面'; })
|
||||||
|
.build();
|
||||||
|
var events = builder.id('kube-events')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'events'); })
|
||||||
|
.title(function () { return '服务启动日志'; })
|
||||||
|
.build();
|
||||||
|
var hosts = builder.id('kube-hosts')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'hosts'); })
|
||||||
|
.title(function () { return '集群节点'; })
|
||||||
|
.build();
|
||||||
|
var overview = builder.id('kube-overview')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'overview'); })
|
||||||
|
.title(function () { return 'Diagram'; })
|
||||||
|
.build();
|
||||||
|
var builds = builder.id('kube-builds')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'builds'); })
|
||||||
|
.title(function () { return 'Builds'; })
|
||||||
|
.build();
|
||||||
|
var buildConfigs = builder.id('kube-buildConfigs')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'buildConfigs'); })
|
||||||
|
.title(function () { return 'Build Configs'; })
|
||||||
|
.build();
|
||||||
|
var deploys = builder.id('kube-deploys')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'deploymentConfigs'); })
|
||||||
|
.title(function () { return 'Deploys'; })
|
||||||
|
.build();
|
||||||
|
var imageRepositories = builder.id('kube-imageRepositories')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'imageRepositories'); })
|
||||||
|
.title(function () { return 'Registries'; })
|
||||||
|
.build();
|
||||||
|
var pipelines = builder.id('kube-pipelines')
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'pipelines'); })
|
||||||
|
.title(function () { return 'Pipelines'; })
|
||||||
|
.build();
|
||||||
|
var repos = builder.id('kube-repos')
|
||||||
|
.href(function () { return "/forge/repos"; })
|
||||||
|
.isValid(function () { return ServiceRegistry.hasService(Kubernetes.fabric8ForgeServiceName) && ServiceRegistry.hasService(Kubernetes.gogsServiceName); })
|
||||||
|
.title(function () { return 'Repositories'; })
|
||||||
|
.build();
|
||||||
|
var mainTab = builder.id('kubernetes')
|
||||||
|
.rank(100)
|
||||||
|
.defaultPage({
|
||||||
|
rank: 20,
|
||||||
|
isValid: function (yes, no) {
|
||||||
|
yes();
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, "/namespace/default/replicationControllers"); })
|
||||||
|
.title(function () { return '服务集群'; })
|
||||||
|
.tabs(controllers, pods, events)
|
||||||
|
.build();
|
||||||
|
HawtioNav.add(mainTab);
|
||||||
|
/* testKubernetesModel
|
||||||
|
HawtioNav.add({
|
||||||
|
id: 'k8sAppSwitcher',
|
||||||
|
title: () => '', // not used as 'template' below overrides this
|
||||||
|
isValid: () => KubernetesModel.serviceApps.length > 0,
|
||||||
|
context: true,
|
||||||
|
template: () => $templateCache.get(UrlHelpers.join(templatePath, 'serviceApps.html'))
|
||||||
|
});
|
||||||
|
*/
|
||||||
|
var projectsTab = builder.id('openshift')
|
||||||
|
.rank(100)
|
||||||
|
.href(function () { return UrlHelpers.join(Kubernetes.context, 'buildConfigs') + '?sub-tab=kube-buildConfigs'; })
|
||||||
|
.title(function () { return 'Projects'; })
|
||||||
|
.tabs(repos, buildConfigs, builds, deploys, imageRepositories)
|
||||||
|
.build();
|
||||||
|
//HawtioNav.add(projectsTab);
|
||||||
|
}]);
|
||||||
|
hawtioPluginLoader.registerPreBootstrapTask({
|
||||||
|
name: 'KubernetesInit',
|
||||||
|
task: function (next) {
|
||||||
|
$.getScript('osconsole/config.js')
|
||||||
|
.done(function (script, textStatus) {
|
||||||
|
var config = Kubernetes.osConfig = window['OPENSHIFT_CONFIG'];
|
||||||
|
Kubernetes.log.debug("Fetched OAuth config: ", config);
|
||||||
|
var master = config.master_uri;
|
||||||
|
if (!master && config.api && config.api.k8s) {
|
||||||
|
var masterUri = new URI().host(config.api.k8s.hostPort).path("").query("");
|
||||||
|
if (config.api.k8s.proto) {
|
||||||
|
masterUri.protocol(config.api.k8s.proto);
|
||||||
|
}
|
||||||
|
master = masterUri.toString();
|
||||||
|
}
|
||||||
|
OSOAuthConfig = config.openshift;
|
||||||
|
GoogleOAuthConfig = config.google;
|
||||||
|
KeycloakConfig = config.keycloak;
|
||||||
|
if (OSOAuthConfig && !master) {
|
||||||
|
// TODO auth.master_uri no longer used right?
|
||||||
|
// master = OSOAuthConfig.master_uri;
|
||||||
|
if (!master) {
|
||||||
|
var oauth_authorize_uri = OSOAuthConfig.oauth_authorize_uri;
|
||||||
|
if (oauth_authorize_uri) {
|
||||||
|
var text = oauth_authorize_uri;
|
||||||
|
var idx = text.indexOf("://");
|
||||||
|
if (idx > 0) {
|
||||||
|
idx += 3;
|
||||||
|
idx = text.indexOf("/", idx);
|
||||||
|
if (idx > 0) {
|
||||||
|
master = text.substring(0, ++idx);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ((!Kubernetes.masterUrl || Kubernetes.masterUrl === "/") && (!master || master === "/")) {
|
||||||
|
// lets default the master to the current protocol and host/port
|
||||||
|
// in case the master url is "/" and we are
|
||||||
|
// serving up static content from inside /api/v1/namespaces/default/services/fabric8 or something like that
|
||||||
|
var href = location.href;
|
||||||
|
if (href) {
|
||||||
|
master = new URI(href).query("").path("").toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (master) {
|
||||||
|
Kubernetes.masterUrl = master;
|
||||||
|
next();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.fail(function (response) {
|
||||||
|
Kubernetes.log.debug("Error fetching OAUTH config: ", response);
|
||||||
|
})
|
||||||
|
.always(function () {
|
||||||
|
next();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}, true);
|
||||||
|
hawtioPluginLoader.addModule('ngResource');
|
||||||
|
hawtioPluginLoader.addModule(Kubernetes.pluginName);
|
||||||
|
})(Kubernetes || (Kubernetes = {}));
|
||||||
|
//# sourceMappingURL=kubernetesPlugin.js.map
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,509 @@
|
||||||
|
/*
|
||||||
|
read a object from jiangsu province , such as nanjing with some information
|
||||||
|
读取江苏的某个地区的信息,以及系统信息
|
||||||
|
*/
|
||||||
|
var Kubernetes;
|
||||||
|
(function (Kubernetes) {
|
||||||
|
Kubernetes.system_arr = [{ "sys_name": "部门预算", "sys_id": "1" }, { "sys_name": "非税收入收缴管理系统", "sys_id": "2" },
|
||||||
|
{ "sys_name": "预算执行系统", "sys_id": "3" }, { "sys_name": "资产管理系统", "sys_id": "4" }, { "sys_name": "用友财政综合管理信息系统", "sys_id": "5" },
|
||||||
|
{ "sys_name": "用友A++", "sys_id": "6" }, { "sys_name": "浦口财政一体化", "sys_id": "7" }, { "sys_name": "栖霞区财政业务信息管理系统", "sys_id": "8" },
|
||||||
|
{ "sys_name": "一体化系统", "sys_id": "9" }, { "sys_name": "财政管理一体化系统", "sys_id": "10" }, { "sys_name": "滨江开发区财政分局", "sys_id": "11" },
|
||||||
|
{ "sys_name": "江宁经济技术开发区财政分局", "sys_id": "12" }, { "sys_name": "江宁科学园财政分局", "sys_id": "13" }, { "sys_name": "财政一体化系统", "sys_id": "14" },
|
||||||
|
{ "sys_name": "A++财政一体化平台", "sys_id": "15" }, { "sys_name": "非税系统", "sys_id": "16" }, { "sys_name": "一体化预算执行系统", "sys_id": "17" },
|
||||||
|
{ "sys_name": "一体化", "sys_id": "18" }, { "sys_name": "国库集中支付管理信息系统", "sys_id": "19" }, { "sys_name": "国库集中支付", "sys_id": "20" },
|
||||||
|
{ "sys_name": "财政专户核算及非税系统", "sys_id": "21" }, { "sys_name": "集中支付系统", "sys_id": "22" }, { "sys_name": "财政专户核算系统", "sys_id": "23" },
|
||||||
|
{ "sys_name": "非税收缴系统", "sys_id": "24" }, { "sys_name": "财政一体化平台", "sys_id": "25" }, { "sys_name": "富深预算执行", "sys_id": "26" },
|
||||||
|
{ "sys_name": "用友非税及票据", "sys_id": "27" }, { "sys_name": "用友预算执行", "sys_id": "28" }, { "sys_name": "江苏省财政预算执行系统", "sys_id": "29" },
|
||||||
|
{ "sys_name": "用友通用软件", "sys_id": "30" }, { "sys_name": "联友软件/通用财务", "sys_id": "31" }, { "sys_name": "用友GRPG-U8R10财政管理软件", "sys_id": "32" },
|
||||||
|
{ "sys_name": "用友GPP-R10财政管理软件", "sys_id": "33" }, { "sys_name": "富深协通财政一体化管理信息系统", "sys_id": "34" }, { "sys_name": "财务统一核算系统", "sys_id": "35" },
|
||||||
|
{ "sys_name": "公共财政管理软件", "sys_id": "36" }, { "sys_name": "A++财政一体化信息平台", "sys_id": "37" }, { "sys_name": "新中大公共财务管理软件", "sys_id": "38" },
|
||||||
|
{ "sys_name": "富深财政一体化管理系统", "sys_id": "39" }, { "sys_name": "新中大公共财政管理系统", "sys_id": "40" }, { "sys_name": "富深协通财政一体化业务管理系统软件", "sys_id": "41" },
|
||||||
|
{ "sys_name": "新中大公共财政管理软件Gsoft", "sys_id": "42" }, { "sys_name": "财政一体化业务系统", "sys_id": "43" }, { "sys_name": "财政一体化软件", "sys_id": "44" },
|
||||||
|
{ "sys_name": "非税收入系统", "sys_id": "45" }, { "sys_name": "总预算系统", "sys_id": "46" }, { "sys_name": "国库集中支付系统", "sys_id": "47" }, { "sys_name": "用款计划系统", "sys_id": "48" },
|
||||||
|
{ "sys_name": "指标管理系统", "sys_id": "49" }, { "sys_name": "财政综合业务管理平台", "sys_id": "50" }, { "sys_name": "财政一体化管理信息系统", "sys_id": "51" }, { "sys_name": "工资统发", "sys_id": "52" },
|
||||||
|
{ "sys_name": "国有资产", "sys_id": "53" }, { "sys_name": "乡镇非税收入", "sys_id": "54" }, { "sys_name": "乡镇集中支付", "sys_id": "55" }, { "sys_name": "非税征缴系统", "sys_id": "56" },
|
||||||
|
{ "sys_name": "预算编制与执行系统", "sys_id": "57" }, { "sys_name": "预算管理综合业务平台", "sys_id": "58" }, { "sys_name": "u8管理软件", "sys_id": "59" }, { "sys_name": "财政指标管理系统", "sys_id": "60" },
|
||||||
|
{ "sys_name": "用友GRP-R9财务管理软件", "sys_id": "61" }, { "sys_name": "用友GRP-U8财政管理软件", "sys_id": "62" }, { "sys_name": "账务处理系统", "sys_id": "63" }, { "sys_name": "R9i财政管理软件", "sys_id": "64" },
|
||||||
|
{ "sys_name": "u8财政管理软件", "sys_id": "65" }, { "sys_name": "相城区财政综合管理信息系统", "sys_id": "66" }, { "sys_name": "财政非税综合管理系统", "sys_id": "67" }, { "sys_name": "财政综合管理平台", "sys_id": "68" },
|
||||||
|
{ "sys_name": "吴江区财政一体化", "sys_id": "69" }, { "sys_name": "用友R9", "sys_id": "70" }, { "sys_name": "财政公共应用服务平台", "sys_id": "71" }, { "sys_name": "金蝶K/3创新管理平台", "sys_id": "72" }, { "sys_name": "账务数据系统", "sys_id": "73" },
|
||||||
|
{ "sys_name": "公共财政服务平台", "sys_id": "74" }, { "sys_name": "会计核算系统", "sys_id": "75" }, { "sys_name": "项目库", "sys_id": "76" }, { "sys_name": "财政总预算(外)专户管理系统", "sys_id": "77" },
|
||||||
|
{ "sys_name": "城建资金专户管理系统", "sys_id": "78" }, { "sys_name": "农保专户管理系统", "sys_id": "79" }, { "sys_name": "农业发展基金专户管理系统", "sys_id": "80" },
|
||||||
|
{ "sys_name": "失地农民保障资金专户", "sys_id": "81" }, { "sys_name": "非税收入征管系统", "sys_id": "82" }, { "sys_name": "工资统发人员信息", "sys_id": "83" },
|
||||||
|
{ "sys_name": "预算指标-国库集中支付系统", "sys_id": "84" }, { "sys_name": "总预算会计核算系统", "sys_id": "85" }, { "sys_name": "部门预算编审系统", "sys_id": "86" },
|
||||||
|
{ "sys_name": "公务消费管理系统", "sys_id": "87" }, { "sys_name": "国有资产管理系统", "sys_id": "88" }, { "sys_name": "区镇财政管理“一体化”系统", "sys_id": "89" },
|
||||||
|
{ "sys_name": "县本级财政管理“一体化”系统", "sys_id": "90" }, { "sys_name": "用友政务", "sys_id": "91" }, { "sys_name": "财政专户核算(行政口专项资金)", "sys_id": "92" },
|
||||||
|
{ "sys_name": "财政专户核算(经建口专项资金)", "sys_id": "93" }, { "sys_name": "财政专户核算(农业保险专账)", "sys_id": "94" }, { "sys_name": "财政专户核算(农业综合开发专账)", "sys_id": "95" },
|
||||||
|
{ "sys_name": "财政专户核算(社保资金专账)", "sys_id": "96" }, { "sys_name": "财政专户核算(土地出让专账)", "sys_id": "97" }, { "sys_name": "财政专户核算(综合口专项资金)", "sys_id": "98" },
|
||||||
|
{ "sys_name": "非税收入管理系统", "sys_id": "99" }, { "sys_name": "农业专向及农业发展基金专项", "sys_id": "100" }, { "sys_name": "总预算会计核算", "sys_id": "101" }, { "sys_name": "金财工程一体化支撑平台", "sys_id": "102" },
|
||||||
|
{ "sys_name": "非税收缴", "sys_id": "103" }, { "sys_name": "学校预算执行", "sys_id": "104" }, { "sys_name": "预算执行", "sys_id": "105" }, { "sys_name": "专项资金", "sys_id": "106" },
|
||||||
|
{ "sys_name": "总预算", "sys_id": "107" }, { "sys_name": "部门预算系统", "sys_id": "108" }, { "sys_name": "财政专户核算", "sys_id": "109" }, { "sys_name": "财政专户账务系统", "sys_id": "110" },
|
||||||
|
{ "sys_name": "富深财政一体化业务管理系统", "sys_id": "111" }, { "sys_name": "国有资产系统", "sys_id": "112" }, { "sys_name": "国库专项资金管理系统", "sys_id": "113" },
|
||||||
|
{ "sys_name": "非税收缴管理系统", "sys_id": "114" }, { "sys_name": "财政管理系统(新农保)", "sys_id": "115" }, { "sys_name": "财政管理系统(城市居民医疗统筹)", "sys_id": "116" },
|
||||||
|
{ "sys_name": "财政管理系统(集中支付中心)", "sys_id": "117" }, { "sys_name": "财政管理系统(解困金)", "sys_id": "118" }, { "sys_name": "财政管理系统(旧城改造)", "sys_id": "119" },
|
||||||
|
{ "sys_name": "财政管理系统(社保资金账户)", "sys_id": "120" }, { "sys_name": "财政管理系统(土地出让专帐)", "sys_id": "121" }, { "sys_name": "财政管理系统(预拨及非集中支付中心)", "sys_id": "122" },
|
||||||
|
{ "sys_name": "财政管理系统(预算外资金)", "sys_id": "123" }, { "sys_name": "总预算会计", "sys_id": "124" }, { "sys_name": "财务核算系统", "sys_id": "125" }, { "sys_name": "工资统发系统", "sys_id": "126" },
|
||||||
|
{ "sys_name": "预算编审系统", "sys_id": "127" }, { "sys_name": "预算管理系统", "sys_id": "128" }, { "sys_name": "预算外资金(从联网审计中取数)", "sys_id": "129" },
|
||||||
|
{ "sys_name": "G6-E财务管理系统", "sys_id": "130" }, { "sys_name": "新中大公共财政管理软件", "sys_id": "131" }, { "sys_name": "用友GRP/R9财政管理软件", "sys_id": "132" },
|
||||||
|
{ "sys_name": "用友GRP-U8R10", "sys_id": "133" }, { "sys_name": "财政一体化管理系统(基建户)", "sys_id": "134" }, { "sys_name": "财政一体化管理系统(集中支付中心)", "sys_id": "135" },
|
||||||
|
{ "sys_name": "财政一体化管理系统(农业综合开发)", "sys_id": "136" }, { "sys_name": "财政一体化管理系统(预算外资金)", "sys_id": "137" }, { "sys_name": "财政一体化管理系统(支农专户)", "sys_id": "138" },
|
||||||
|
{ "sys_name": "财政一体化管理系统(总预算)", "sys_id": "139" }, { "sys_name": "国资管理系统", "sys_id": "140" }, { "sys_name": "乡财县管系统", "sys_id": "141" }, { "sys_name": "预算编制管理系统", "sys_id": "142" },
|
||||||
|
{ "sys_name": "盐城市_市本级_部门预算", "sys_id": "143" }, { "sys_name": "盐城市_市本级_非税收管理系统", "sys_id": "144" }, { "sys_name": "盐城市_市本级_预算执行系统", "sys_id": "145" },
|
||||||
|
{ "sys_name": "盐城市_亭湖区_财政专户", "sys_id": "146" }, { "sys_name": "盐城市_亭湖区_非税收入管理", "sys_id": "147" }, { "sys_name": "盐城市_亭湖区_国库集中支付管理", "sys_id": "148" },
|
||||||
|
{ "sys_name": "盐城市_亭湖区_预算指标管理", "sys_id": "149" }, { "sys_name": "盐城市_亭湖区_总预算会计核算", "sys_id": "150" }, { "sys_name": "盐城市_盐都区_财政专户核算系统", "sys_id": "151" },
|
||||||
|
{ "sys_name": "盐城市_盐都区_非税收入管理系统", "sys_id": "152" }, { "sys_name": "盐城市_盐都区_国库集中支付系统", "sys_id": "153" }, { "sys_name": "盐城市_盐都区_总预算会计核算系统", "sys_id": "154" },
|
||||||
|
{ "sys_name": "盐城市_响水县_部门预算管理系统", "sys_id": "155" }, { "sys_name": "盐城市_响水县_财政一体化信息系统", "sys_id": "156" }, { "sys_name": "盐城市_响水县_非税收入收缴管理系统", "sys_id": "157" },
|
||||||
|
{ "sys_name": "盐城市_滨海县财政一体化", "sys_id": "158" }, { "sys_name": "盐城市_阜宁县_财政管理软件", "sys_id": "159" }, { "sys_name": "盐城市_阜宁县_财政管理软件用友U8", "sys_id": "160" },
|
||||||
|
{ "sys_name": "盐城市_射阳县_财政预算执行一体化系统", "sys_id": "161" }, { "sys_name": "盐城市_建湖县_非税收缴", "sys_id": "162" },
|
||||||
|
{ "sys_name": "盐城市_建湖县_财政一体化", "sys_id": "163" }, { "sys_name": "盐城市_建湖县_国库集中支付", "sys_id": "164" },
|
||||||
|
{ "sys_name": "盐城市_东台市_部门预算编审系统", "sys_id": "165" }, { "sys_name": "盐城市_东台市_财政一体化信息系统", "sys_id": "166" },
|
||||||
|
{ "sys_name": "盐城市_东台市_财政专户核算系统", "sys_id": "167" }, { "sys_name": "盐城市_东台市_非税收入收缴管理系统", "sys_id": "168" },
|
||||||
|
{ "sys_name": "盐城市_东台市_总预算会计核算系统", "sys_id": "169" }, { "sys_name": "盐城市_大丰区_部门预算系统", "sys_id": "170" },
|
||||||
|
{ "sys_name": "盐城市_大丰区_财政一体化", "sys_id": "171" }, { "sys_name": "盐城市_大丰区_总预算会计核算财务软件", "sys_id": "172" },
|
||||||
|
{ "sys_name": "盐城市_经济技术开发区_部门预算软件", "sys_id": "173" }, { "sys_name": "盐城市_经济技术开发区_国库集中支付", "sys_id": "174" },
|
||||||
|
{ "sys_name": "老非税收入征缴系统", "sys_id": "175" }, { "sys_name": "扬州财政一体化信息管理系统", "sys_id": "176" }, { "sys_name": "非税收入征收", "sys_id": "177" },
|
||||||
|
{ "sys_name": "部门预算编制", "sys_id": "178" }, { "sys_name": "非税收入收缴", "sys_id": "179" }, { "sys_name": "行政事业性单位国有资产管理", "sys_id": "180" },
|
||||||
|
{ "sys_name": "财政业务系统", "sys_id": "181" }, { "sys_name": "财政业务综合系统", "sys_id": "182" }, { "sys_name": "江都开发区预算执行系统", "sys_id": "183" },
|
||||||
|
{ "sys_name": "财政一体化", "sys_id": "184" }, { "sys_name": "富深协通财政一体化业务管理系统", "sys_id": "185" }, { "sys_name": "富深协通非税收缴系统", "sys_id": "186" },
|
||||||
|
{ "sys_name": "富深协通工资统发系统", "sys_id": "187" }, { "sys_name": "非税收入", "sys_id": "188" }, { "sys_name": "财政综合业务系统", "sys_id": "189" },
|
||||||
|
{ "sys_name": "泰州市_市本级_部门预算系统", "sys_id": "190" }, { "sys_name": "泰州市_市本级_非税收入系统", "sys_id": "191" }, { "sys_name": "泰州市_市本级_绩效管理系统", "sys_id": "192" },
|
||||||
|
{ "sys_name": "泰州市_市本级_预算执行系统", "sys_id": "193" }, { "sys_name": "泰州市_市本级_综合治税系统", "sys_id": "194" }, { "sys_name": "泰州市_海陵区_部门预算编制系统", "sys_id": "195" },
|
||||||
|
{ "sys_name": "泰州市_海陵区_县区财政一体化", "sys_id": "196" }, { "sys_name": "泰州市_高港区_预算执行系统", "sys_id": "197" },
|
||||||
|
{ "sys_name": "泰州市_姜堰区_部门预算系统", "sys_id": "198" }, { "sys_name": "泰州市_姜堰区_财政一体化系统", "sys_id": "199" },
|
||||||
|
{ "sys_name": "泰州市_姜堰区_非税收缴系统", "sys_id": "200" }, { "sys_name": "泰州市_姜堰区_预算执行系统", "sys_id": "201" },
|
||||||
|
{ "sys_name": "泰州市_医药高新区_财政一体化系统", "sys_id": "202" }, { "sys_name": "泰州市_兴化市_部门预算", "sys_id": "203" },
|
||||||
|
{ "sys_name": "泰州市_兴化市_非税收缴", "sys_id": "204" }, { "sys_name": "泰州市_兴化市_国库集中支付", "sys_id": "205" },
|
||||||
|
{ "sys_name": "泰州市_靖江市_预算执行系统", "sys_id": "206" }, { "sys_name": "泰州市_靖江市_非税收入收缴", "sys_id": "207" },
|
||||||
|
{ "sys_name": "泰州市_靖江市_部门预算编审系统", "sys_id": "208" }, { "sys_name": "泰州市_泰兴市_部门预算系统", "sys_id": "209" },
|
||||||
|
{ "sys_name": "泰州市_泰兴市_非税收入管理系统", "sys_id": "210" }, { "sys_name": "泰州市_泰兴市_预算执行系统", "sys_id": "211" },
|
||||||
|
{ "sys_name": "部门预算管理系统", "sys_id": "212" }, { "sys_name": "财政一体化平台及国库集中支付系统", "sys_id": "213" },
|
||||||
|
{ "sys_name": "新中大非税收入管理", "sys_id": "214" }, { "sys_name": "联友财务管理系统", "sys_id": "215" }, { "sys_name": "国库集中支付、指标管理系统", "sys_id": "216" },
|
||||||
|
{ "sys_name": "开发区总预算系统", "sys_id": "217" }, { "sys_name": "国库账务系统", "sys_id": "218" }, { "sys_name": "化学工业园区非税收入管理系统", "sys_id": "219" },
|
||||||
|
{ "sys_name": "非税收入账套", "sys_id": "220" }, { "sys_name": "化学工业园区预算执行系统", "sys_id": "221" }, { "sys_name": "会计核算", "sys_id": "222" },
|
||||||
|
{ "sys_name": "总预算会计账", "sys_id": "223" }, { "sys_name": "预算内外收支核算系统", "sys_id": "224" }, { "sys_name": "账户核算系统", "sys_id": "225" },
|
||||||
|
{ "sys_name": "总预算核算系统", "sys_id": "226" }, { "sys_name": "账务处理系统(收支分类改革升级版)", "sys_id": "227" }, { "sys_name": "财政预算外业务", "sys_id": "228" },
|
||||||
|
{ "sys_name": "用友U8R10财政一体化平台", "sys_id": "229" }, { "sys_name": "开发区财政系统", "sys_id": "230" }, { "sys_name": "高新区总预算系统", "sys_id": "231" },
|
||||||
|
{ "sys_name": "开发区公共财政服务平台", "sys_id": "232" }, { "sys_name": "用友GRP-U8管理软件", "sys_id": "233" }, { "sys_name": "盐城市_城南新区_国库集中支付系统", "sys_id": "234" },
|
||||||
|
{ "sys_name": "盐城市_城南新区_总预算账务处理系统", "sys_id": "235" }, { "sys_name": "财政预算指标管理", "sys_id": "236" }, { "sys_name": "泰州市_市本级_行政管理系统", "sys_id": "237" },
|
||||||
|
{ "sys_name": "新中大财务软件", "sys_id": "238" }, { "sys_name": "开发区新中大财务核算系统", "sys_id": "239" }, { "sys_name": "开发区账务系统", "sys_id": "240" }];
|
||||||
|
Kubernetes.origin_place_arr = [{ "city_code": "3201", "city": "南京市", "county": "市本级", "county_code": "320100", "sys_name": "部门预算", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "市本级", "county_code": "320100", "sys_name": "非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "市本级", "county_code": "320100", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "市本级", "county_code": "320100", "sys_name": "资产管理系统", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "玄武区", "county_code": "320102", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "秦淮区", "county_code": "320104", "sys_name": "用友财政综合管理信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "建邺区", "county_code": "320105", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "鼓楼区", "county_code": "320106", "sys_name": "用友A++", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "浦口区", "county_code": "320111", "sys_name": "浦口财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "栖霞区", "county_code": "320113", "sys_name": "栖霞区财政业务信息管理系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "雨花台区", "county_code": "320114", "sys_name": "一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "江宁区", "county_code": "320115", "sys_name": "财政管理一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "江宁区", "county_code": "320115", "sys_name": "滨江开发区财政分局", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "江宁区", "county_code": "320115", "sys_name": "江宁经济技术开发区财政分局", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "江宁区", "county_code": "320115", "sys_name": "江宁科学园财政分局", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "六合区", "county_code": "320116", "sys_name": "一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "高淳区", "county_code": "320118", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "溧水区", "county_code": "320124", "sys_name": "A++财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "市本级", "county_code": "320200", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "市本级", "county_code": "320200", "sys_name": "非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "崇安区", "county_code": "320202", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "崇安区", "county_code": "320202", "sys_name": "一体化预算执行系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "南长区", "county_code": "320203", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "南长区", "county_code": "320203", "sys_name": "一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "北塘区", "county_code": "320204", "sys_name": "国库集中支付管理信息系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "锡山区", "county_code": "320205", "sys_name": "国库集中支付", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "锡山区", "county_code": "320205", "sys_name": "财政专户核算及非税系统", "sys_code": "ZHHS_FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "惠山区", "county_code": "320206", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "滨湖区", "county_code": "320211", "sys_name": "集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "滨湖区", "county_code": "320211", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "滨湖区", "county_code": "320211", "sys_name": "财政专户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "新区", "county_code": "320214", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "新区", "county_code": "320214", "sys_name": "非税收缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "新区", "county_code": "320214", "sys_name": "财政专户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "江阴市", "county_code": "320281", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "宜兴市", "county_code": "320282", "sys_name": "非税收缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "宜兴市", "county_code": "320282", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "市本级", "county_code": "320300", "sys_name": "富深预算执行", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "市本级", "county_code": "320300", "sys_name": "用友非税及票据", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "市本级", "county_code": "320300", "sys_name": "用友预算执行", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "鼓楼区", "county_code": "320302", "sys_name": "江苏省财政预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "鼓楼区", "county_code": "320302", "sys_name": "用友通用软件", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "云龙区", "county_code": "320303", "sys_name": "江苏省财政预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "云龙区", "county_code": "320303", "sys_name": "联友软件/通用财务", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "云龙区", "county_code": "320303", "sys_name": "用友GRPG-U8R10财政管理软件", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "贾汪区", "county_code": "320305", "sys_name": "用友GPP-R10财政管理软件", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "泉山区", "county_code": "320311", "sys_name": "富深协通财政一体化管理信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "铜山区", "county_code": "320312", "sys_name": "财务统一核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "铜山区", "county_code": "320312", "sys_name": "非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "铜山区", "county_code": "320312", "sys_name": "公共财政管理软件", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "丰县", "county_code": "320321", "sys_name": "A++财政一体化信息平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "丰县", "county_code": "320321", "sys_name": "新中大公共财务管理软件", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "沛县", "county_code": "320322", "sys_name": "富深财政一体化管理系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "沛县", "county_code": "320322", "sys_name": "新中大公共财政管理系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "睢宁县", "county_code": "320324", "sys_name": "富深协通财政一体化业务管理系统软件", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "睢宁县", "county_code": "320324", "sys_name": "新中大公共财政管理软件Gsoft", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "新沂市", "county_code": "320381", "sys_name": "江苏省财政预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "邳州", "county_code": "320382", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "本级", "county_code": "320400", "sys_name": "财政一体化业务系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "天宁区", "county_code": "320402", "sys_name": "财政一体化软件", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "天宁区", "county_code": "320402", "sys_name": "非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "天宁区", "county_code": "320402", "sys_name": "总预算系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区", "county_code": "320404", "sys_name": "非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区", "county_code": "320404", "sys_name": "国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区", "county_code": "320404", "sys_name": "用款计划系统", "sys_code": "JHGL" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区", "county_code": "320404", "sys_name": "指标管理系统", "sys_code": "ZBGL" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区", "county_code": "320404", "sys_name": "总预算系统", "sys_code": "ZYS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "新北区", "county_code": "320411", "sys_name": "财政综合业务管理平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "武进区", "county_code": "320412", "sys_name": "财政一体化管理信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳市", "county_code": "320481", "sys_name": "部门预算", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳市", "county_code": "320481", "sys_name": "工资统发", "sys_code": "GZTF" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳市", "county_code": "320481", "sys_name": "国有资产", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳市", "county_code": "320481", "sys_name": "乡镇非税收入", "sys_code": "XZFS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳市", "county_code": "320481", "sys_name": "乡镇集中支付", "sys_code": "XZGK" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "金坛区", "county_code": "320482", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "市本级", "county_code": "320500", "sys_name": "非税征缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "市本级", "county_code": "320500", "sys_name": "预算编制与执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "工业园区", "county_code": "320501", "sys_name": "预算管理综合业务平台", "sys_code": "YSGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "u8管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "财政指标管理系统", "sys_code": "ZBGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "用友GRP-R9财务管理软件", "sys_code": "CWGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "用友GRP-U8财政管理软件", "sys_code": "CWGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "虎丘区", "county_code": "320505", "sys_name": "账务处理系统", "sys_code": "ZWCL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "吴中区", "county_code": "320506", "sys_name": "R9i财政管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "吴中区", "county_code": "320506", "sys_name": "部门预算", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "吴中区", "county_code": "320506", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "吴中区", "county_code": "320506", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "相城区", "county_code": "320507", "sys_name": "u8财政管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "相城区", "county_code": "320507", "sys_name": "相城区财政综合管理信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "姑苏区", "county_code": "320508", "sys_name": "财政非税综合管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "姑苏区", "county_code": "320508", "sys_name": "财政综合管理平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "吴江区", "county_code": "320509", "sys_name": "吴江区财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "常熟市", "county_code": "320581", "sys_name": "非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "常熟市", "county_code": "320581", "sys_name": "用友R9", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "常熟市", "county_code": "320581", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "张家港市", "county_code": "320582", "sys_name": "财政公共应用服务平台", "sys_code": "GGFW" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "张家港市", "county_code": "320582", "sys_name": "金蝶K/3创新管理平台", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "张家港市", "county_code": "320582", "sys_name": "账务数据系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "昆山市", "county_code": "320583", "sys_name": "非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "昆山市", "county_code": "320583", "sys_name": "公共财政服务平台", "sys_code": "GGFW" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "昆山市", "county_code": "320583", "sys_name": "国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市", "county_code": "320585", "sys_name": "非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市", "county_code": "320585", "sys_name": "会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市", "county_code": "320585", "sys_name": "项目库", "sys_code": "XMK" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市", "county_code": "320585", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "本级", "county_code": "320600", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "崇川区", "county_code": "320602", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "财政总预算(外)专户管理系统", "sys_code": "YSWZH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "城建资金专户管理系统", "sys_code": "CJZH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "农保专户管理系统", "sys_code": "NBZH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "农业发展基金专户管理系统", "sys_code": "NFJJ" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "失地农民保障资金专户", "sys_code": "SDNM" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "港闸区", "county_code": "320611", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "通州区", "county_code": "320612", "sys_name": "非税收入征管系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "通州区", "county_code": "320612", "sys_name": "工资统发人员信息", "sys_code": "GZTF" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "通州区", "county_code": "320612", "sys_name": "预算指标-国库集中支付系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "通州区", "county_code": "320612", "sys_name": "总预算会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海安县", "county_code": "320621", "sys_name": "部门预算编审系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海安县", "county_code": "320621", "sys_name": "公务消费管理系统", "sys_code": "GWXF" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海安县", "county_code": "320621", "sys_name": "国有资产管理系统", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海安县", "county_code": "320621", "sys_name": "区镇财政管理“一体化”系统", "sys_code": "XZYTH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海安县", "county_code": "320621", "sys_name": "县本级财政管理“一体化”系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "如东县", "county_code": "320623", "sys_name": "用友政务", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(行政口专项资金)", "sys_code": "ZHXZ" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(经建口专项资金)", "sys_code": "ZHJJ" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(农业保险专账)", "sys_code": "ZHNB" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(农业综合开发专账)", "sys_code": "ZHNF" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(社保资金专账)", "sys_code": "ZHSB" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(土地出让专账)", "sys_code": "ZHTD" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "财政专户核算(综合口专项资金)", "sys_code": "ZHZH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "农业专向及农业发展基金专项", "sys_code": "NFZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "启东市", "county_code": "320681", "sys_name": "总预算会计核算", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "如皋市", "county_code": "320682", "sys_name": "金财工程一体化支撑平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "非税收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "学校预算执行", "sys_code": "YSZXXX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "预算执行", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "专项资金", "sys_code": "ZXZJ" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "海门市", "county_code": "320684", "sys_name": "总预算", "sys_code": "ZYS" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "市本级", "county_code": "320700", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "市本级", "county_code": "320700", "sys_name": "财政专户核算", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "市本级", "county_code": "320700", "sys_name": "非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "市本级", "county_code": "320700", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "连云区", "county_code": "320703", "sys_name": "财政专户账务系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "连云区", "county_code": "320703", "sys_name": "富深财政一体化管理系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "海州区", "county_code": "320706", "sys_name": "富深财政一体化业务管理系统", "sys_code": "" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "海州区", "county_code": "320706", "sys_name": "新中大公共财政管理系统", "sys_code": "" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "赣榆区", "county_code": "320721", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "赣榆区", "county_code": "320721", "sys_name": "国有资产系统", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "东海县", "county_code": "320722", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "东海县", "county_code": "320722", "sys_name": "国库专项资金管理系统", "sys_code": "ZXZJ" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "东海县", "county_code": "320722", "sys_name": "国有资产管理系统", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "东海县", "county_code": "320722", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "灌云县", "county_code": "320723", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "灌南县", "county_code": "320724", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "灌南县", "county_code": "320724", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "市本级", "county_code": "320800", "sys_name": "非税收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "市本级", "county_code": "320800", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(新农保)", "sys_code": "ZHNB" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(城市居民医疗统筹)", "sys_code": "ZHYB" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(集中支付中心)", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(解困金)", "sys_code": "ZHJK" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(旧城改造)", "sys_code": "ZHCG" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(社保资金账户)", "sys_code": "ZHSB" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(土地出让专帐)", "sys_code": "ZHTD" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(预拨及非集中支付中心)", "sys_code": "ZHYB" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "财政管理系统(预算外资金)", "sys_code": "YSW" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清河区", "county_code": "320802", "sys_name": "总预算会计", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "财务核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "工资统发系统", "sys_code": "GZTF" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "用友政务", "sys_code": "YYZW" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "预算编审系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "预算管理系统", "sys_code": "YSGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "预算外资金(从联网审计中取数)", "sys_code": "YSW" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "预算编审系统", "sys_code": "YSBS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮阴区", "county_code": "320804", "sys_name": "G6-E财务管理系统", "sys_code": "CWGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮阴区", "county_code": "320804", "sys_name": "江苏省财政预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮阴区", "county_code": "320804", "sys_name": "新中大公共财政管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮阴区", "county_code": "320804", "sys_name": "用友GRP/R9财政管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮阴区", "county_code": "320804", "sys_name": "用友GRP-U8R10", "sys_code": "CWGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "淮安区", "county_code": "320803", "sys_name": "预算编审系统", "sys_code": "YSBS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(基建户)", "sys_code": "ZHJJ" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(集中支付中心)", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(农业综合开发)", "sys_code": "ZHNF" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(预算外资金)", "sys_code": "YSW" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(支农专户)", "sys_code": "ZHZN" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "清浦区", "county_code": "320811", "sys_name": "财政一体化管理系统(总预算)", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "非税征缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "国资管理系统", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "乡财县管系统", "sys_code": "XCXG" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "乡财县管系统", "sys_code": "XCXG" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "预算编制管理系统", "sys_code": "YSBS" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "涟水县", "county_code": "320826", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "洪泽县", "county_code": "320829", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "洪泽县", "county_code": "320829", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "盱眙县", "county_code": "320830", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "金湖县", "county_code": "320831", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "市本级", "county_code": "320900", "sys_name": "盐城市_市本级_部门预算", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "市本级", "county_code": "320900", "sys_name": "盐城市_市本级_非税收管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "市本级", "county_code": "320900", "sys_name": "盐城市_市本级_预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "亭湖区", "county_code": "320902", "sys_name": "盐城市_亭湖区_财政专户", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "亭湖区", "county_code": "320902", "sys_name": "盐城市_亭湖区_非税收入管理", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "亭湖区", "county_code": "320902", "sys_name": "盐城市_亭湖区_国库集中支付管理", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "亭湖区", "county_code": "320902", "sys_name": "盐城市_亭湖区_预算指标管理", "sys_code": "ZBGL" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "亭湖区", "county_code": "320902", "sys_name": "盐城市_亭湖区_总预算会计核算", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "盐都区", "county_code": "320903", "sys_name": "盐城市_盐都区_财政专户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "盐都区", "county_code": "320903", "sys_name": "盐城市_盐都区_非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "盐都区", "county_code": "320903", "sys_name": "盐城市_盐都区_国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "盐都区", "county_code": "320903", "sys_name": "盐城市_盐都区_总预算会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "响水县", "county_code": "320921", "sys_name": "盐城市_响水县_部门预算管理系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "响水县", "county_code": "320921", "sys_name": "盐城市_响水县_财政一体化信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "响水县", "county_code": "320921", "sys_name": "盐城市_响水县_非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "滨海县", "county_code": "320922", "sys_name": "盐城市_滨海县财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "阜宁县", "county_code": "320923", "sys_name": "盐城市_阜宁县_财政管理软件", "sys_code": "CZGL" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "阜宁县", "county_code": "320923", "sys_name": "盐城市_阜宁县_财政管理软件用友U8", "sys_code": "YYZW" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "射阳县", "county_code": "320924", "sys_name": "盐城市_射阳县_财政预算执行一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "建湖县", "county_code": "320925", "sys_name": "盐城市_建湖县_非税收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "建湖县", "county_code": "320925", "sys_name": "盐城市_建湖县_财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "建湖县", "county_code": "320925", "sys_name": "盐城市_建湖县_国库集中支付", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "东台市", "county_code": "320981", "sys_name": "盐城市_东台市_部门预算编审系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "东台市", "county_code": "320981", "sys_name": "盐城市_东台市_财政一体化信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "东台市", "county_code": "320981", "sys_name": "盐城市_东台市_财政专户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "东台市", "county_code": "320981", "sys_name": "盐城市_东台市_非税收入收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "东台市", "county_code": "320981", "sys_name": "盐城市_东台市_总预算会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "大丰区", "county_code": "320982", "sys_name": "盐城市_大丰区_部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "大丰区", "county_code": "320982", "sys_name": "盐城市_大丰区_财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "大丰区", "county_code": "320982", "sys_name": "盐城市_大丰区_总预算会计核算财务软件", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "经济技术开发区", "county_code": "320991", "sys_name": "盐城市_经济技术开发区_部门预算软件", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "经济技术开发区", "county_code": "320991", "sys_name": "盐城市_经济技术开发区_国库集中支付", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "市本级", "county_code": "321000", "sys_name": "财政专户核算", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "市本级", "county_code": "321000", "sys_name": "老非税收入征缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "市本级", "county_code": "321000", "sys_name": "扬州财政一体化信息管理系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "广陵区", "county_code": "321002", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "广陵区", "county_code": "321002", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "邗江区", "county_code": "321003", "sys_name": "财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "邗江区", "county_code": "321003", "sys_name": "非税系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "邗江区", "county_code": "321003", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "宝应县", "county_code": "321023", "sys_name": "非税收入征收", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "宝应县", "county_code": "321023", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "仪征市", "county_code": "321081", "sys_name": "部门预算编制", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "仪征市", "county_code": "321081", "sys_name": "非税收入收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "仪征市", "county_code": "321081", "sys_name": "行政事业性单位国有资产管理", "sys_code": "ZCGL" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "仪征市", "county_code": "321081", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "高邮市", "county_code": "321084", "sys_name": "财政业务系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "江都区", "county_code": "321088", "sys_name": "财政业务综合系统", "sys_code": "ZHYW" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "江都区", "county_code": "321088", "sys_name": "江都开发区预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "市本级", "county_code": "321100", "sys_name": "财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "京口区", "county_code": "321102", "sys_name": "富深协通财政一体化业务管理系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "京口区", "county_code": "321102", "sys_name": "富深协通非税收缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "京口区", "county_code": "321102", "sys_name": "富深协通工资统发系统", "sys_code": "GZTF" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "润州区", "county_code": "321111", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "润州区", "county_code": "321111", "sys_name": "财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "润州区", "county_code": "321111", "sys_name": "非税收入", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "丹徒区", "county_code": "321112", "sys_name": "财政综合业务系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "丹阳市", "county_code": "321181", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "丹阳市", "county_code": "321181", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "扬中市", "county_code": "321182", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "扬中市", "county_code": "321182", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "句容市", "county_code": "321183", "sys_name": "非税收入", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "句容市", "county_code": "321183", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_绩效管理系统", "sys_code": "JXGL" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_综合治税系统", "sys_code": "ZHZS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "海陵区", "county_code": "321202", "sys_name": "泰州市_海陵区_部门预算编制系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "海陵区", "county_code": "321202", "sys_name": "泰州市_海陵区_县区财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "高港区", "county_code": "321203", "sys_name": "泰州市_高港区_预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "姜堰区", "county_code": "321204", "sys_name": "泰州市_姜堰区_部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "姜堰区", "county_code": "321204", "sys_name": "泰州市_姜堰区_财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "姜堰区", "county_code": "321204", "sys_name": "泰州市_姜堰区_非税收缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "姜堰区", "county_code": "321204", "sys_name": "泰州市_姜堰区_预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "医药高新区", "county_code": "321205", "sys_name": "泰州市_医药高新区_财政一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "兴化市", "county_code": "321281", "sys_name": "泰州市_兴化市_部门预算", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "兴化市", "county_code": "321281", "sys_name": "泰州市_兴化市_非税收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "兴化市", "county_code": "321281", "sys_name": "泰州市_兴化市_国库集中支付", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "靖江市", "county_code": "321282", "sys_name": "泰州市_靖江市_预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "靖江市", "county_code": "321282", "sys_name": "泰州市_靖江市_非税收入收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "靖江市", "county_code": "321282", "sys_name": "泰州市_靖江市_部门预算编审系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "泰兴市", "county_code": "321283", "sys_name": "泰州市_泰兴市_部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "泰兴市", "county_code": "321283", "sys_name": "泰州市_泰兴市_非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "泰兴市", "county_code": "321283", "sys_name": "泰州市_泰兴市_预算执行系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "市本级", "county_code": "321300", "sys_name": "部门预算管理系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "市本级", "county_code": "321300", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "市本级", "county_code": "321300", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿城区", "county_code": "321302", "sys_name": "财政一体化平台及国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿城区", "county_code": "321302", "sys_name": "新中大非税收入管理", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿城区", "county_code": "321302", "sys_name": "总预算会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿豫区", "county_code": "321311", "sys_name": "非税收缴管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿豫区", "county_code": "321311", "sys_name": "联友财务管理系统", "sys_code": "CWGL" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿豫区", "county_code": "321311", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "沭阳县", "county_code": "321322", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "沭阳县", "county_code": "321322", "sys_name": "国库集中支付、指标管理系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "沭阳县", "county_code": "321322", "sys_name": "开发区总预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "沭阳县", "county_code": "321322", "sys_name": "总预算会计核算", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗阳县", "county_code": "321323", "sys_name": "预算执行", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗洪县", "county_code": "321324", "sys_name": "部门预算系统", "sys_code": "BMYS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗洪县", "county_code": "321324", "sys_name": "非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗洪县", "county_code": "321324", "sys_name": "国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗洪县", "county_code": "321324", "sys_name": "国库账务系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "高新区", "county_code": "320100GXQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "化工园区", "county_code": "320100HGY", "sys_name": "化学工业园区非税收入管理系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "经济技术开发区", "county_code": "320100JKQ", "sys_name": "非税收入账套", "sys_code": "FSZT" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "化工园区", "county_code": "320101HGY", "sys_name": "化学工业园区预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "经济技术开发区", "county_code": "320101JKQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "化工园区", "county_code": "320102HGY", "sys_name": "会计核算", "sys_code": "KYHS" },
|
||||||
|
{ "city_code": "3201", "city": "南京市", "county": "经济技术开发区", "county_code": "320102JKQ", "sys_name": "总预算会计账", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "锡山开发区", "county_code": "320205KFQ", "sys_name": "预算内外收支核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "滨湖区马山开发区", "county_code": "320211KFQ", "sys_name": "账户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "江阴开发区", "county_code": "320281kfq", "sys_name": "财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "江阴开发区", "county_code": "320281kfq", "sys_name": "账户核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "宜兴环科园", "county_code": "320282KFQ", "sys_name": "财务核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3202", "city": "无锡市", "county": "宜兴开发区", "county_code": "320282KFQ", "sys_name": "总预算核算系统", "sys_code": "ZHHS" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "经济技术开发区", "county_code": "320300JKQ", "sys_name": "富深协通财政一体化业务管理系统软件", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3203", "city": "徐州市", "county": "经济技术开发区", "county_code": "320300JKQ", "sys_name": "账务处理系统(收支分类改革升级版)", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "天宁经开区", "county_code": "320402JKQ", "sys_name": "账务处理系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区开发区", "county_code": "320404KFQ", "sys_name": "国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区开发区", "county_code": "320405KFQ", "sys_name": "用款计划系统", "sys_code": "JHGL" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区开发区", "county_code": "320406KFQ", "sys_name": "指标管理系统", "sys_code": "ZBGL" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "钟楼区开发区", "county_code": "320407KFQ", "sys_name": "总预算系统", "sys_code": "ZYS" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "经开区", "county_code": "320412JKQ", "sys_name": "财政预算外业务", "sys_code": "YSW" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "经开区", "county_code": "320412JKQ", "sys_name": "非税收缴系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "经开区", "county_code": "320412JKQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "武进高新区", "county_code": "320413GXQ", "sys_name": "财政一体化管理信息系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳中关村", "county_code": "320481ZGC", "sys_name": "用友U8R10财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3204", "city": "常州市", "county": "溧阳中关村开发区", "county_code": "320481ZGCKF", "sys_name": "用友U8R10财政一体化平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "相城区开发区", "county_code": "320507KFQ", "sys_name": "开发区财政系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "常熟市高新区", "county_code": "320581GXQ", "sys_name": "高新区总预算系统", "sys_code": "ZYS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "昆山市开发区", "county_code": "320583KFQ", "sys_name": "开发区公共财政服务平台", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市新区", "county_code": "320585XQ", "sys_name": "非税收入系统", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市新区", "county_code": "320586XQ", "sys_name": "会计核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3205", "city": "苏州市", "county": "太仓市新区", "county_code": "320587XQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "开发区", "county_code": "320600KFQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "苏通园区", "county_code": "320600STY", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3206", "city": "南通市", "county": "通州湾示范区", "county_code": "320600TZW", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3207", "city": "连云港市", "county": "开发区", "county_code": "320701KFQ", "sys_name": "非税收入", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3208", "city": "淮安市", "county": "开发区", "county_code": "320800KFQ", "sys_name": "用友GRP-U8管理软件", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "城南新区", "county_code": "320900CZXQ", "sys_name": "盐城市_城南新区_国库集中支付系统", "sys_code": "GKZF" },
|
||||||
|
{ "city_code": "3209", "city": "盐城市", "county": "城南新区", "county_code": "320901CZXQ", "sys_name": "盐城市_城南新区_总预算账务处理系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "化工园区", "county_code": "321000HGY", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "开发区", "county_code": "321000KFQ", "sys_name": "非税收入收缴", "sys_code": "FSSR" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "科技新城", "county_code": "321000KJC", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "蜀冈-瘦西湖风景名胜区", "county_code": "321000SXH", "sys_name": "财政预算指标管理", "sys_code": "ZBGL" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "蜀冈-瘦西湖风景名胜区", "county_code": "321000SXH", "sys_name": "总预算会计核算", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "开发区", "county_code": "321001KFQ", "sys_name": "一体化系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "开发区", "county_code": "321002KFQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3210", "city": "扬州市", "county": "高邮开发区", "county_code": "321084KFQ", "sys_name": "财政业务系统", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3211", "city": "镇江市", "county": "新区", "county_code": "321100XQ", "sys_name": "财政一体化", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3212", "city": "泰州市", "county": "市本级", "county_code": "321200", "sys_name": "泰州市_市本级_行政管理系统", "sys_code": "XZGL" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "湖滨新城", "county_code": "321300HBXC", "sys_name": "新中大财务软件", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "经开区", "county_code": "321300JKQ", "sys_name": "新中大公共财政管理软件", "sys_code": "YTH" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "洋河新区", "county_code": "321300YHXQ", "sys_name": "预算执行系统", "sys_code": "YSZX" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "宿豫区开发区", "county_code": "321311KFQ", "sys_name": "开发区新中大财务核算系统", "sys_code": "KJHS" },
|
||||||
|
{ "city_code": "3213", "city": "宿迁市", "county": "泗洪县开发区", "county_code": "321324KFQ", "sys_name": "开发区账务系统", "sys_code": "KJHS" }];
|
||||||
|
function getCountyByCode(code) {
|
||||||
|
//var jsobj = JSON.parse(origin_place_arr);
|
||||||
|
var jsobj = Kubernetes.origin_place_arr;
|
||||||
|
var jsonlength = jsobj.length;
|
||||||
|
for (var i = 0; i < jsonlength; i++) {
|
||||||
|
if (jsobj[i].county_code == code) {
|
||||||
|
return jsobj[i].city + jsobj[i].county;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
Kubernetes.getCountyByCode = getCountyByCode;
|
||||||
|
function getCodeByCounty(place) {
|
||||||
|
place = place.replace(/\s*\t*/gim, "");
|
||||||
|
//var jsobj = JSON.parse(origin_place_arr);
|
||||||
|
var jsobj = Kubernetes.origin_place_arr;
|
||||||
|
var jsonlength = jsobj.length;
|
||||||
|
for (var i = 0; i < jsonlength; i++) {
|
||||||
|
if (jsobj[i].city === "" || jsobj[i].city == undefined)
|
||||||
|
continue;
|
||||||
|
if (jsobj[i].county === "" || jsobj[i].county == undefined)
|
||||||
|
continue;
|
||||||
|
if ((place.indexOf(jsobj[i].city) != -1) && (place.indexOf(jsobj[i].county) != -1)) {
|
||||||
|
return jsobj[i].county_code;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return place;
|
||||||
|
}
|
||||||
|
Kubernetes.getCodeByCounty = getCodeByCounty;
|
||||||
|
function getSystemNameById(id) {
|
||||||
|
var temJson = Kubernetes.system_arr;
|
||||||
|
var sys_size = temJson.length;
|
||||||
|
for (var i = 0; i < sys_size; i++) {
|
||||||
|
if (temJson[i].sys_id == id) {
|
||||||
|
return temJson[i].sys_name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
Kubernetes.getSystemNameById = getSystemNameById;
|
||||||
|
function getIdBySystemName(name) {
|
||||||
|
var temJson = Kubernetes.system_arr;
|
||||||
|
var sys_size = temJson.length;
|
||||||
|
for (var i = 0; i < sys_size; i++) {
|
||||||
|
if (temJson[i].sys_name == name) {
|
||||||
|
return temJson[i].sys_id;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
Kubernetes.getIdBySystemName = getIdBySystemName;
|
||||||
|
function getCodeBySystemName(name) {
|
||||||
|
var jsobj = Kubernetes.origin_place_arr;
|
||||||
|
var jsonlength = jsobj.length;
|
||||||
|
for (var i = 0; i < jsonlength; i++) {
|
||||||
|
if (jsobj[i].sys_name == name) {
|
||||||
|
return jsobj[i].sys_code;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
Kubernetes.getCodeBySystemName = getCodeBySystemName;
|
||||||
|
})(Kubernetes || (Kubernetes = {}));
|
||||||
|
//# sourceMappingURL=readPlacedivision.js.map
|
File diff suppressed because one or more lines are too long
|
@ -4,8 +4,7 @@
|
||||||
|
|
||||||
module Kubernetes {
|
module Kubernetes {
|
||||||
|
|
||||||
export var ReplicationControllerController = controller("ReplicationControllerController",
|
export var ReplicationControllerController = controller("ReplicationControllerController", ["$scope", "KubernetesModel", "KubernetesState", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "KubernetesApiURL",
|
||||||
["$scope", "KubernetesModel", "KubernetesState", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "KubernetesApiURL",
|
|
||||||
($scope, KubernetesModel: Kubernetes.KubernetesModelService, KubernetesState,
|
($scope, KubernetesModel: Kubernetes.KubernetesModelService, KubernetesState,
|
||||||
$templateCache: ng.ITemplateCacheService, $location: ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL) => {
|
$templateCache: ng.ITemplateCacheService, $location: ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL) => {
|
||||||
|
|
||||||
|
@ -53,5 +52,6 @@ module Kubernetes {
|
||||||
}
|
}
|
||||||
Core.$apply($scope);
|
Core.$apply($scope);
|
||||||
}
|
}
|
||||||
}]);
|
}
|
||||||
|
]);
|
||||||
}
|
}
|
|
@ -6,9 +6,9 @@
|
||||||
module Kubernetes {
|
module Kubernetes {
|
||||||
|
|
||||||
export var ReplicationControllers = controller("ReplicationControllers",
|
export var ReplicationControllers = controller("ReplicationControllers",
|
||||||
["$scope", "KubernetesModel", "KubernetesReplicationControllers", "KubernetesPods", "ConfigsModel", "KubernetesState", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "KubernetesApiURL",
|
["$scope", "KubernetesModel", "KubernetesReplicationControllers", "KubernetesPods", "ConfigsModel", "KubernetesState", "$templateCache", "$location", "$routeParams", "$http", "$timeout", "KubernetesApiURL", "ngDialog",
|
||||||
($scope, KubernetesModel: Kubernetes.KubernetesModelService, KubernetesReplicationControllers:ng.resource.IResourceClass<any>, KubernetesPods:ng.resource.IResourceClass<any>, ConfigsModel, KubernetesState,
|
($scope, KubernetesModel: Kubernetes.KubernetesModelService, KubernetesReplicationControllers:ng.resource.IResourceClass<any>, KubernetesPods:ng.resource.IResourceClass<any>, ConfigsModel, KubernetesState,
|
||||||
$templateCache, $location:ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL) => {
|
$templateCache, $location:ng.ILocationService, $routeParams, $http, $timeout, KubernetesApiURL, ngDialog) => {
|
||||||
|
|
||||||
$scope.kubernetes = KubernetesState;
|
$scope.kubernetes = KubernetesState;
|
||||||
$scope.configs = ConfigsModel;
|
$scope.configs = ConfigsModel;
|
||||||
|
@ -295,5 +295,7 @@ module Kubernetes {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}]);
|
}]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,6 +24,7 @@ module Kubernetes {
|
||||||
|
|
||||||
_module.service('TerminalService', ($rootScope, $document, $compile, $interval, $templateCache) => {
|
_module.service('TerminalService', ($rootScope, $document, $compile, $interval, $templateCache) => {
|
||||||
var body = $document.find('body');
|
var body = $document.find('body');
|
||||||
|
|
||||||
function positionTerminals(terminals) {
|
function positionTerminals(terminals) {
|
||||||
var total = _.keys(terminals).length;
|
var total = _.keys(terminals).length;
|
||||||
var dist = (body.width() - 225) / total;
|
var dist = (body.width() - 225) / total;
|
||||||
|
@ -51,6 +52,9 @@ module Kubernetes {
|
||||||
return terminalId;
|
return terminalId;
|
||||||
}
|
}
|
||||||
var scope = $rootScope.$new();
|
var scope = $rootScope.$new();
|
||||||
|
if (containerName == "") {
|
||||||
|
scope.isExportLog = true;
|
||||||
|
}
|
||||||
getLogs(entity, scope, url);
|
getLogs(entity, scope, url);
|
||||||
scope.podLink = podLink;
|
scope.podLink = podLink;
|
||||||
scope.containerName = containerName;
|
scope.containerName = containerName;
|
||||||
|
@ -74,6 +78,7 @@ module Kubernetes {
|
||||||
positionTerminals(self.terminals);
|
positionTerminals(self.terminals);
|
||||||
return terminalId;
|
return terminalId;
|
||||||
},
|
},
|
||||||
|
|
||||||
closeTerminal: (id) => {
|
closeTerminal: (id) => {
|
||||||
var term = self.terminals[id];
|
var term = self.terminals[id];
|
||||||
var timer = self.httpTask[id];
|
var timer = self.httpTask[id];
|
||||||
|
@ -324,4 +329,3 @@ module Kubernetes {
|
||||||
xhr.send(null);
|
xhr.send(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"out": "",
|
||||||
|
"sourceMap": true,
|
||||||
|
"target": "es5"
|
||||||
|
},
|
||||||
|
"files": [
|
||||||
|
"kubernetesPlugin.ts"
|
||||||
|
]
|
||||||
|
}
|
|
@ -0,0 +1,382 @@
|
||||||
|
/// <reference path="../../includes.ts"/>
|
||||||
|
/// <reference path="./kubernetesHelpers.ts"/>
|
||||||
|
var Kubernetes;
|
||||||
|
(function (Kubernetes) {
|
||||||
|
Kubernetes.hostPorts = [];
|
||||||
|
/**
|
||||||
|
* Sorts the the ip field
|
||||||
|
*
|
||||||
|
* @param ip the ip such as '10.1.2.13'
|
||||||
|
* @returns {any}
|
||||||
|
*/
|
||||||
|
function sortByPodIp(ip) {
|
||||||
|
// i guess there is maybe nicer ways of sort this without parsing and slicing
|
||||||
|
var regex = /(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})/;
|
||||||
|
var groups = regex.exec(ip);
|
||||||
|
if (angular.isDefined(groups)) {
|
||||||
|
var g1 = ("00" + groups[1]).slice(-3);
|
||||||
|
var g2 = ("00" + groups[2]).slice(-3);
|
||||||
|
var g3 = ("00" + groups[3]).slice(-3);
|
||||||
|
var g4 = ("00" + groups[4]).slice(-3);
|
||||||
|
var answer = g1 + g2 + g3 + g4;
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Kubernetes.sortByPodIp = sortByPodIp;
|
||||||
|
function ramdomPort() {
|
||||||
|
var hostPort = Math.floor(30000 + Math.random() * (65535 - 30000));
|
||||||
|
while (Kubernetes.hostPorts.indexOf(hostPort) === 0) {
|
||||||
|
hostPort = Math.floor(30000 + Math.random() * (65535 - 30000));
|
||||||
|
}
|
||||||
|
Kubernetes.hostPorts.push(hostPort);
|
||||||
|
return hostPort;
|
||||||
|
}
|
||||||
|
Kubernetes.ramdomPort = ramdomPort;
|
||||||
|
function getRandomString(len) {
|
||||||
|
len = len || 32;
|
||||||
|
var $chars = 'abcdefhijkmnprstwxyz'; // 默认去掉了容易混淆的字符oOLl,9gq,Vv,Uu,I1
|
||||||
|
var maxPos = $chars.length;
|
||||||
|
var pwd = '';
|
||||||
|
for (var i = 0; i < len; i++) {
|
||||||
|
pwd += $chars.charAt(Math.floor(Math.random() * maxPos));
|
||||||
|
}
|
||||||
|
return pwd;
|
||||||
|
}
|
||||||
|
Kubernetes.getRandomString = getRandomString;
|
||||||
|
var resourceRCTemplate = (function () {
|
||||||
|
function resourceRCTemplate() {
|
||||||
|
this.image = "oracle:utf8";
|
||||||
|
this.names = ["oradata"];
|
||||||
|
}
|
||||||
|
resourceRCTemplate.prototype.createRC = function (Obj) {
|
||||||
|
var labels = {
|
||||||
|
"style": "oracle",
|
||||||
|
"status": "0",
|
||||||
|
"isExtract": Obj.isExtract + "" || "0",
|
||||||
|
"isTarget": Obj.isTarget
|
||||||
|
};
|
||||||
|
for (var item in Obj.labels)
|
||||||
|
labels[item] = Obj.labels[item];
|
||||||
|
return {
|
||||||
|
"apiVersion": Kubernetes.defaultApiVersion,
|
||||||
|
"kind": "ReplicationController",
|
||||||
|
"metadata": {
|
||||||
|
"name": Obj.name,
|
||||||
|
"labels": labels,
|
||||||
|
"annotations": Obj.annotations
|
||||||
|
},
|
||||||
|
"spec": {
|
||||||
|
replicas: Obj.replicas || 1,
|
||||||
|
"template": this.createTemplate(Obj)
|
||||||
|
}
|
||||||
|
};
|
||||||
|
};
|
||||||
|
resourceRCTemplate.prototype.createVolumeMounts = function () {
|
||||||
|
var volumeMounts = [];
|
||||||
|
for (var item in this.names) {
|
||||||
|
if (this.names[item] === 'flash-recovery-area')
|
||||||
|
volumeMounts.push({
|
||||||
|
"name": this.names[item],
|
||||||
|
"mountPath": "/opt/oracle/app/flash_recovery_area"
|
||||||
|
});
|
||||||
|
else
|
||||||
|
volumeMounts.push({
|
||||||
|
"name": this.names[item],
|
||||||
|
"mountPath": "/opt/oracle/app/" + this.names[item]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return volumeMounts;
|
||||||
|
};
|
||||||
|
resourceRCTemplate.prototype.createVolumes = function (rootPath) {
|
||||||
|
var volumes = [];
|
||||||
|
for (var item in this.names) {
|
||||||
|
if (this.names[item] === 'flash-recovery-area')
|
||||||
|
volumes.push({
|
||||||
|
"name": this.names[item],
|
||||||
|
"hostPath": {
|
||||||
|
"path": rootPath + "flash_recovery_area"
|
||||||
|
}
|
||||||
|
});
|
||||||
|
else
|
||||||
|
volumes.push({
|
||||||
|
"name": this.names[item],
|
||||||
|
"hostPath": {
|
||||||
|
"path": rootPath + this.names[item]
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return volumes;
|
||||||
|
};
|
||||||
|
resourceRCTemplate.prototype.createContainers = function (Obj) {
|
||||||
|
var containers = [];
|
||||||
|
containers.push({
|
||||||
|
"name": "oracle",
|
||||||
|
"image": this.image,
|
||||||
|
"imagePullPolicy": "IfNotPresent",
|
||||||
|
"command": ["/assets/entrypoint.sh"],
|
||||||
|
"ports": [{
|
||||||
|
"containerPort": 1521,
|
||||||
|
"hostPort": Obj.port || ramdomPort()
|
||||||
|
}],
|
||||||
|
"resources": {
|
||||||
|
"cpu": "100m",
|
||||||
|
"memory": "3Gi"
|
||||||
|
},
|
||||||
|
"volumeMounts": this.createVolumeMounts()
|
||||||
|
});
|
||||||
|
return containers;
|
||||||
|
};
|
||||||
|
resourceRCTemplate.prototype.createTemplate = function (Obj) {
|
||||||
|
return {
|
||||||
|
"metadata": {
|
||||||
|
//"name": Obj.name,
|
||||||
|
"labels": Obj.labels
|
||||||
|
},
|
||||||
|
"spec": {
|
||||||
|
"terminationGracePeriodSeconds": 0,
|
||||||
|
"containers": this.createContainers(Obj),
|
||||||
|
"volumes": this.createVolumes(Obj.path)
|
||||||
|
}
|
||||||
|
};
|
||||||
|
};
|
||||||
|
return resourceRCTemplate;
|
||||||
|
})();
|
||||||
|
Kubernetes.resourceRCTemplate = resourceRCTemplate;
|
||||||
|
function labelToChinese(labels) {
|
||||||
|
var answer = {};
|
||||||
|
angular.forEach(labels, function (value, key) {
|
||||||
|
answer[key] = labelChangeToChines(value, key);
|
||||||
|
});
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
Kubernetes.labelToChinese = labelToChinese;
|
||||||
|
function findSameNameReplicationControllers(replicationControllers, name) {
|
||||||
|
var names = [];
|
||||||
|
replicationControllers.forEach(function (rc) {
|
||||||
|
var rcName = Kubernetes.getName(rc);
|
||||||
|
if (rcName.indexof(name) !== -1)
|
||||||
|
names.push(rcName);
|
||||||
|
});
|
||||||
|
if (names.length === 0) {
|
||||||
|
return name + "_1";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var max = 0;
|
||||||
|
names.forEach(function (value) {
|
||||||
|
var answer = value.split("_");
|
||||||
|
var key = parseInt(answer[1]);
|
||||||
|
if (max < key)
|
||||||
|
max = key;
|
||||||
|
});
|
||||||
|
return name + (max + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Kubernetes.findSameNameReplicationControllers = findSameNameReplicationControllers;
|
||||||
|
function isFilterRC(rc) {
|
||||||
|
var answer = false;
|
||||||
|
angular.forEach(Core.pathGet(rc, ["metadata", "labels"]), function (value, key) {
|
||||||
|
if (key === 'isTarget' && value === 'true') {
|
||||||
|
answer = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return answer;
|
||||||
|
}
|
||||||
|
Kubernetes.isFilterRC = isFilterRC;
|
||||||
|
function isInclude(rcs, rc) {
|
||||||
|
for (var i in rcs) {
|
||||||
|
if (Kubernetes.getName(rcs[i]) === Kubernetes.getName(rc))
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Kubernetes.isInclude = isInclude;
|
||||||
|
function labelChangeToChines(value, key) {
|
||||||
|
var trueValue = '';
|
||||||
|
switch (key) {
|
||||||
|
case 'type':
|
||||||
|
if (value === '01')
|
||||||
|
trueValue = '财政';
|
||||||
|
else if (value === '02')
|
||||||
|
trueValue = '社保';
|
||||||
|
else
|
||||||
|
trueValue = value;
|
||||||
|
break;
|
||||||
|
case 'batch':
|
||||||
|
if (value === 'A')
|
||||||
|
trueValue = '批次A';
|
||||||
|
else if (value === 'B')
|
||||||
|
trueValue = '批次B';
|
||||||
|
else
|
||||||
|
trueValue = value;
|
||||||
|
break;
|
||||||
|
case 'region':
|
||||||
|
trueValue = Kubernetes.getCountyByCode(value);
|
||||||
|
break;
|
||||||
|
case 'system':
|
||||||
|
trueValue = Kubernetes.getSystemNameById(value);
|
||||||
|
break;
|
||||||
|
case 'version':
|
||||||
|
var reg = new RegExp('^[0-9]$').exec(value);
|
||||||
|
if (reg)
|
||||||
|
trueValue = '版本' + reg[0];
|
||||||
|
else
|
||||||
|
trueValue = value;
|
||||||
|
break;
|
||||||
|
case 'isTarget':
|
||||||
|
if (value === 'true')
|
||||||
|
trueValue = '汇总数据库';
|
||||||
|
else
|
||||||
|
trueValue = value;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
trueValue = value;
|
||||||
|
}
|
||||||
|
return trueValue;
|
||||||
|
}
|
||||||
|
Kubernetes.labelChangeToChines = labelChangeToChines;
|
||||||
|
function checkForExit(replicationControllers, selectItem) {
|
||||||
|
for (var index in replicationControllers) {
|
||||||
|
var replicas = replicationControllers[index];
|
||||||
|
if (Kubernetes.getName(replicas) == selectItem._key && getAnnotationValueBykey(replicas, "year") == selectItem["year"])
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Kubernetes.checkForExit = checkForExit;
|
||||||
|
function getAnnotationValueBykey(replicationController, key) {
|
||||||
|
var annotations = Kubernetes.getAnnotations(replicationController);
|
||||||
|
if (annotations && annotations != undefined) {
|
||||||
|
return annotations[key];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
启动oracle时检查是否正在迁移
|
||||||
|
*/
|
||||||
|
function checkForCreateOracle(transferTasks, selectItems) {
|
||||||
|
var result = [];
|
||||||
|
angular.forEach(selectItems, function (item) {
|
||||||
|
if (checkForExitTask(transferTasks, item))
|
||||||
|
result.push(item);
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Kubernetes.checkForCreateOracle = checkForCreateOracle;
|
||||||
|
function checkForExitTask(transferTasks, selectItem) {
|
||||||
|
for (var index in transferTasks) {
|
||||||
|
var task = transferTasks[index];
|
||||||
|
if (task["_key"] == selectItem["_key"] && selectItem["year"] == task.labels.dataYear) {
|
||||||
|
if (task.status == 2 || task.status == 3)
|
||||||
|
return false;
|
||||||
|
else
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
|
||||||
|
**/
|
||||||
|
function checkForExtract(replicationControllers) {
|
||||||
|
var result = [];
|
||||||
|
angular.forEach(replicationControllers, function (replicas) {
|
||||||
|
var labels = Kubernetes.getLabels(replicas);
|
||||||
|
if (labels["isExtract"] == "1")
|
||||||
|
result.push(replicas);
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Kubernetes.checkForExtract = checkForExtract;
|
||||||
|
function checkIsStartSuccess(replicationControllers) {
|
||||||
|
var result = [];
|
||||||
|
angular.forEach(replicationControllers, function (replicas) {
|
||||||
|
var labels = Kubernetes.getLabels(replicas);
|
||||||
|
if (labels["status"] != "2")
|
||||||
|
result.push(replicas);
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Kubernetes.checkIsStartSuccess = checkIsStartSuccess;
|
||||||
|
;
|
||||||
|
/*
|
||||||
|
检查数据否已挂载使用或正在迁移。
|
||||||
|
*/
|
||||||
|
function checkForMigration(replicationControllers, transferTasks, selectItem, type) {
|
||||||
|
var message = "";
|
||||||
|
for (var index in selectItem) {
|
||||||
|
var item = selectItem[index];
|
||||||
|
var id = null;
|
||||||
|
if (type == 'manager')
|
||||||
|
id = item.id;
|
||||||
|
if (type == 'verify')
|
||||||
|
id = item.dataId;
|
||||||
|
/*
|
||||||
|
检查迁移文件是否正在迁移
|
||||||
|
*/
|
||||||
|
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;
|
||||||
|
}*/
|
||||||
|
if (transferTasks[i].fkid == id && (transferTasks[i]["status"] == "1" || transferTasks[i]["status"] == "0")) {
|
||||||
|
message = "数据正在迁移";
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
数据是否在热区,如果在则需要判断数据是否已启动
|
||||||
|
*/
|
||||||
|
if (item["mark"] == 1)
|
||||||
|
continue;
|
||||||
|
/*
|
||||||
|
检查迁移文件是否已挂载使用
|
||||||
|
*/
|
||||||
|
for (var i in replicationControllers) {
|
||||||
|
var labels = Kubernetes.getLabels(replicationControllers[i]);
|
||||||
|
if (Kubernetes.getName(replicationControllers[i]) == item._key && getAnnotationValueBykey(replicationControllers[i], "year") == item["year"]) {
|
||||||
|
message = "数据正在使用";
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
Kubernetes.checkForMigration = checkForMigration;
|
||||||
|
function eliminateChechBoxClick() {
|
||||||
|
var element = $("#tableConfig > thead > tr input:checkbox");
|
||||||
|
if (element.is(':checked'))
|
||||||
|
element.click();
|
||||||
|
}
|
||||||
|
Kubernetes.eliminateChechBoxClick = eliminateChechBoxClick;
|
||||||
|
/*
|
||||||
|
是否已存在当前
|
||||||
|
*/
|
||||||
|
function alreadyExitInFolder(selectedItems, selectNode) {
|
||||||
|
var childNodes = selectNode.childNodes;
|
||||||
|
for (var i in selectedItems) {
|
||||||
|
var itemName = selectedItems[i].regionalismCode + "_" + selectedItems[i].systemCode;
|
||||||
|
for (var j in childNodes) {
|
||||||
|
if (childNodes[j].name == itemName) {
|
||||||
|
var childrens = childNodes[j].childNodes;
|
||||||
|
for (var k in childrens)
|
||||||
|
if (childrens[k].name == selectedItems[i].dataVersion)
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Kubernetes.alreadyExitInFolder = alreadyExitInFolder;
|
||||||
|
function alreadyExitInCluster(selectedItems, volumePath) {
|
||||||
|
for (var i in selectedItems) {
|
||||||
|
if (selectedItems[i].datapath.startWith(volumePath)) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Kubernetes.alreadyExitInCluster = alreadyExitInCluster;
|
||||||
|
})(Kubernetes || (Kubernetes = {}));
|
||||||
|
//# sourceMappingURL=utilHelpers.js.map
|
File diff suppressed because one or more lines are too long
|
@ -115,14 +115,12 @@ module Kubernetes {
|
||||||
|
|
||||||
public createContainers(Obj) {
|
public createContainers(Obj) {
|
||||||
var containers = [];
|
var containers = [];
|
||||||
containers.push(
|
containers.push({
|
||||||
{
|
|
||||||
"name": "oracle",
|
"name": "oracle",
|
||||||
"image": this.image,
|
"image": this.image,
|
||||||
"imagePullPolicy": "IfNotPresent",
|
"imagePullPolicy": "IfNotPresent",
|
||||||
"command": ["/assets/entrypoint.sh"],
|
"command": ["/assets/entrypoint.sh"],
|
||||||
"ports": [
|
"ports": [{
|
||||||
{
|
|
||||||
"containerPort": 1521,
|
"containerPort": 1521,
|
||||||
"hostPort": Obj.port || ramdomPort()
|
"hostPort": Obj.port || ramdomPort()
|
||||||
}],
|
}],
|
||||||
|
@ -137,8 +135,7 @@ module Kubernetes {
|
||||||
|
|
||||||
public createTemplate(Obj) {
|
public createTemplate(Obj) {
|
||||||
return {
|
return {
|
||||||
"metadata":
|
"metadata": {
|
||||||
{
|
|
||||||
//"name": Obj.name,
|
//"name": Obj.name,
|
||||||
"labels": Obj.labels
|
"labels": Obj.labels
|
||||||
},
|
},
|
||||||
|
@ -385,4 +382,16 @@ module Kubernetes {
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function alreadyExitInCluster(selectedItems: Array < any > , volumePath) {
|
||||||
|
|
||||||
|
|
||||||
|
for (var i = 0; i < selectedItems.length; ++i) {
|
||||||
|
if (selectedItems[i].dataPath.indexOf(volumePath) == 0) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -13,10 +13,22 @@
|
||||||
<i class="glyphicon glyphicon-export"></i> Excel导出
|
<i class="glyphicon glyphicon-export"></i> Excel导出
|
||||||
</button>
|
</button>
|
||||||
<span class="pull-right"> </span>
|
<span class="pull-right"> </span>
|
||||||
<button class="sj_btn_green fl mr5" ng-click="upLoadExcelFile()">
|
<button class="sj_btn_green mr5" ng-click="upLoadExcelFile()">
|
||||||
<i class="glyphicon glyphicon-import"></i>Excel导入
|
<i class="glyphicon glyphicon-import"></i>Excel导入
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row clear fr mb10">
|
||||||
|
<!--<input type="checkbox" class="fl mr5 " style="margin-top: 8px;" />
|
||||||
|
<label class="fl mr5 " style="margin-top: 5px; font-style:nomal;">全选</label>-->
|
||||||
|
<button class="btn pull-right sj_btn_grey mr20" ng-click="openLog()">
|
||||||
|
<i class="glyphicon glyphicon-export"></i> 导出日志查看
|
||||||
|
</button>
|
||||||
|
<span class="pull-right"> </span>
|
||||||
|
<button class="sj_btn_green mr5" ng-click="dataManagementExport()">
|
||||||
|
<i class="glyphicon glyphicon-export"></i> 导出
|
||||||
|
</button>
|
||||||
|
<span class="pull-right"> </span>
|
||||||
|
</div>
|
||||||
<div ng-show="true">
|
<div ng-show="true">
|
||||||
<div class="col-md-12" >
|
<div class="col-md-12" >
|
||||||
<div ng-show="model.length == 0" class="alert alert-warning sj_alert-warning">
|
<div ng-show="model.length == 0" class="alert alert-warning sj_alert-warning">
|
||||||
|
|
|
@ -95,7 +95,8 @@ module System{
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var checked = 0, unchecked = 0,
|
var checked = 0,
|
||||||
|
unchecked = 0,
|
||||||
total = $scope.model.length;
|
total = $scope.model.length;
|
||||||
angular.forEach($scope.model, function(item) {
|
angular.forEach($scope.model, function(item) {
|
||||||
checked += ($scope.checkboxes.items[item.id]) || 0;
|
checked += ($scope.checkboxes.items[item.id]) || 0;
|
||||||
|
@ -205,7 +206,8 @@ module System{
|
||||||
});
|
});
|
||||||
|
|
||||||
function shareUpdate(data, value) {
|
function shareUpdate(data, value) {
|
||||||
var filter = data, result = [];
|
var filter = data,
|
||||||
|
result = [];
|
||||||
if (value.x != "all") {
|
if (value.x != "all") {
|
||||||
angular.forEach(filter, (item) => {
|
angular.forEach(filter, (item) => {
|
||||||
if (item.cityName == value.x)
|
if (item.cityName == value.x)
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
/// <reference path="../../configs/ts/configsUtils.ts"/>
|
/// <reference path="../../configs/ts/configsUtils.ts"/>
|
||||||
|
|
||||||
module System {
|
module System {
|
||||||
export var SystemListController = controller('SystemListController', ['$scope', '$location', '$http', '$templateCache', 'Upload', 'NgTableParams', 'ngDialog', 'SystemModel', ($scope, $location, $http, $templateCache, Upload, NgTableParams, ngDialog, SystemModel) => {
|
export var SystemListController = controller('SystemListController', ['$scope', '$interval', '$location', '$http', '$templateCache', 'Upload', 'NgTableParams', 'ngDialog', 'SystemModel', 'TerminalService', ($scope, $interval, $location, $http, $templateCache, Upload, NgTableParams, ngDialog, SystemModel, TerminalService) => {
|
||||||
shareInit($scope);
|
shareInit($scope);
|
||||||
|
|
||||||
$scope.modelServices = SystemModel;
|
$scope.modelServices = SystemModel;
|
||||||
|
@ -60,7 +60,7 @@ module System{
|
||||||
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);
|
||||||
|
// var Resumable = require('resumable');
|
||||||
var r = new Resumable({
|
var r = new Resumable({
|
||||||
target: '/java/console/api/fileOperation/file/upload',
|
target: '/java/console/api/fileOperation/file/upload',
|
||||||
chunkSize: 1 * 1024 * 1024,
|
chunkSize: 1 * 1024 * 1024,
|
||||||
|
@ -85,11 +85,11 @@ module System{
|
||||||
});
|
});
|
||||||
|
|
||||||
r.on('complete', function() {
|
r.on('complete', function() {
|
||||||
$('#loadmsg').html("所以文件上传完毕,正在读取文件中的数据,此过程时间可能会较长,请稍等...");
|
$('#loadmsg').html("所有文件上传完毕,正在读取文件中的数据,此过程时间可能会较长,请稍等...");
|
||||||
$.ajax({
|
$.ajax({
|
||||||
|
async: false,
|
||||||
type: "POST",
|
type: "POST",
|
||||||
url: UrlHelpers.join("/java/console/api/fileOperation/importExcel"),
|
url: UrlHelpers.join("/java/console/api/fileOperation/importExcel"),
|
||||||
timeout: 8000 * fileNameList.length,
|
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
data: JSON.stringify(fileNameList),
|
data: JSON.stringify(fileNameList),
|
||||||
contentType: "application/json; charset=utf-8",
|
contentType: "application/json; charset=utf-8",
|
||||||
|
@ -136,21 +136,46 @@ module System{
|
||||||
|
|
||||||
//excel下载
|
//excel下载
|
||||||
$scope.downLoadExcelFile = () => {
|
$scope.downLoadExcelFile = () => {
|
||||||
Configs.downloadFile($scope, $http, '/java/console/api/fileOperation/file/download', () =>{
|
Configs.create_mask();
|
||||||
Configs.customAlert("提示","导出成功,文件下载完成",'',null,0,"success");
|
Kubernetes.create_locadEffect("正在导出excel文件,请稍等...");
|
||||||
|
var target = document.getElementById('loading');
|
||||||
|
var spinner = new Spinner(Kubernetes.loadConfigs()).spin(target);
|
||||||
|
Configs.downloadFile($scope, $http, '/java/console/api/fileOperation/file/download', "export.xls", () => {
|
||||||
|
$("#load").remove();
|
||||||
|
Kubernetes.removeMask();
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$scope.downloadFilePackage = () => {
|
$scope.downloadFilePackage = () => {
|
||||||
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);
|
||||||
Configs.downloadFile($scope, $http, '/java/console/api/filePackage/download', () =>{
|
|
||||||
|
Configs.downloadFile($scope, $http, '/java/console/api/filePackage/download', "package.zip", () => {
|
||||||
$("#load").remove();
|
$("#load").remove();
|
||||||
Kubernetes.removeMask();
|
Kubernetes.removeMask();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.dataManagementExport = () => {
|
||||||
|
ngDialog.open({
|
||||||
|
template: 'dataExport.html',
|
||||||
|
width: 1005,
|
||||||
|
height: 600,
|
||||||
|
// data: {id : id},
|
||||||
|
scope: $scope,
|
||||||
|
className: 'ngdialog-theme-default',
|
||||||
|
controller: 'Configs.dataExportController',
|
||||||
|
closeByDocument: false
|
||||||
|
});
|
||||||
|
}
|
||||||
|
$scope.openLog = () => {
|
||||||
|
|
||||||
|
TerminalService.newTerminal($interval, "exportData", "", "export_data", "/java/console/api/oracle/exportData/log", $templateCache.get(UrlHelpers.join(Kubernetes.templatePath, 'logShell.html')));
|
||||||
}
|
}
|
||||||
|
|
||||||
//boolean选择条件:是/否
|
//boolean选择条件:是/否
|
||||||
|
|
|
@ -29,17 +29,26 @@ module System{
|
||||||
$scope.y = "all";
|
$scope.y = "all";
|
||||||
if (x != 'all') {
|
if (x != 'all') {
|
||||||
$scope.countries = classifyCountry(SystemModel.regionalismInfo, x);
|
$scope.countries = classifyCountry(SystemModel.regionalismInfo, x);
|
||||||
$http({
|
$.ajax({
|
||||||
url: "/java/console/api/checkout/findByCity",
|
async: false,
|
||||||
method: "POST",
|
type: "POST",
|
||||||
data: x
|
contentType: "application/json; charset=utf-8",
|
||||||
}).success((data, header, config, status) => {
|
url: UrlHelpers.join("/java/console/api/checkout/findByCity"),
|
||||||
|
dataType: 'json',
|
||||||
|
data: JSON.stringify(x),
|
||||||
|
// data: { "idList": idList, "typeList": typeList },
|
||||||
|
// data: JSON.stringify(formData),
|
||||||
|
|
||||||
|
success: (data) => {
|
||||||
$scope.tableData = data.data;
|
$scope.tableData = data.data;
|
||||||
$scope.tableParams.settings({
|
$scope.tableParams.settings({
|
||||||
dataset: $scope.tableData
|
dataset: $scope.tableData
|
||||||
});
|
});
|
||||||
}).error((data, header, config, status) => {
|
|
||||||
throw "请求失败"
|
},
|
||||||
|
error: (data) => {
|
||||||
|
Configs.customAlert("提示", "请求失败!", '', null, 0, "error");
|
||||||
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
//$scope.countries=[];
|
//$scope.countries=[];
|
||||||
|
@ -101,7 +110,8 @@ module System{
|
||||||
*/
|
*/
|
||||||
Configs.customAlert("提示", "操作失败:选择的系统存在没有数据的系统", '', null, 0, "error");
|
Configs.customAlert("提示", "操作失败:选择的系统存在没有数据的系统", '', null, 0, "error");
|
||||||
return;
|
return;
|
||||||
}7
|
}
|
||||||
|
7
|
||||||
|
|
||||||
item["_key"] = item.areaCode + "-" + item.sysCode + "-" + item.dataVersion;
|
item["_key"] = item.areaCode + "-" + item.sysCode + "-" + item.dataVersion;
|
||||||
if (item.dataBaseType == 'ORACLE') {
|
if (item.dataBaseType == 'ORACLE') {
|
||||||
|
@ -335,7 +345,9 @@ module System{
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var checked = 0, unchecked = 0, total = -1;
|
var checked = 0,
|
||||||
|
unchecked = 0,
|
||||||
|
total = -1;
|
||||||
if ($scope.tableData && ($scope.tableData instanceof Array))
|
if ($scope.tableData && ($scope.tableData instanceof Array))
|
||||||
total = $scope.tableData.length;
|
total = $scope.tableData.length;
|
||||||
angular.forEach($scope.tableData, function(item) {
|
angular.forEach($scope.tableData, function(item) {
|
||||||
|
@ -382,8 +394,7 @@ module System{
|
||||||
$scope.tableParams.settings({
|
$scope.tableParams.settings({
|
||||||
dataset: result
|
dataset: result
|
||||||
});
|
});
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
Configs.customAlert("提示", "操作失败!", '', null, 0, "error");
|
Configs.customAlert("提示", "操作失败!", '', null, 0, "error");
|
||||||
}).error(function(data, header, config, status) {
|
}).error(function(data, header, config, status) {
|
||||||
Configs.customAlert("提示", "操作失败:发生请求失败,不能删除!", '', null, 0, "error");
|
Configs.customAlert("提示", "操作失败:发生请求失败,不能删除!", '', null, 0, "error");
|
||||||
|
|
Loading…
Reference in New Issue