diff --git a/src/components/app-list/app-card.vue b/src/components/app-list/app-card.vue index 4402e332a464554f3ee89d8f57b8155e14b9845a..ef20ea296ea422b86350ce1514b5c8a2e2835721 100644 --- a/src/components/app-list/app-card.vue +++ b/src/components/app-list/app-card.vue @@ -62,7 +62,7 @@ export default { this.$router.push( `${this.detailsUrl}${ this.cardType == 0 - ? this.data.app_id + ? this.data.app_id+`?source=${this.data.source}` : this.data.deploy_id + `?app_id=${this.data.app_id}` }` ); diff --git a/src/components/service-header.vue b/src/components/service-header.vue index c70ae66c2f04f93caefff5c5bd2ba84cbca8da24..188a9346e25f648d1fe885333f8ce4d15ceda98d 100644 --- a/src/components/service-header.vue +++ b/src/components/service-header.vue @@ -95,7 +95,7 @@ export default { subevent(val){ if(val == 0){ // this.$emit('deploy',this.data) - this.$router.push(`/yygl/${this.$route.params.level}/${this.$route.params.type}/deployment/${this.$route.params.id}`) + this.$router.push(`/yygl/${this.$route.params.level}/${this.$route.params.type}/deployment/${this.$route.params.id}?source=${this.$route.query.source}`) console.log(this.$route); }else if(val == 1){ this.$emit('editapp') diff --git a/src/pages/workbench/fwgl/serviceEdit.vue b/src/pages/workbench/fwgl/serviceEdit.vue index eaf1a302957ca3746dbfbf251c2a950259613582..c5d027fcbaf6a44839438ffd859324c22538c314 100644 --- a/src/pages/workbench/fwgl/serviceEdit.vue +++ b/src/pages/workbench/fwgl/serviceEdit.vue @@ -40,7 +40,7 @@ ]" >

所属组织:

- + @@ -508,17 +509,17 @@ export default { [ "/apaas/service/v3/service/manager/list", "/apaas/service/v3/service/apply/service/list", - "/apaas/service/v3/service/manager/list" + "/apaas/service/v3/resource/user/apply/list" ], [ "/apaas/service/v3/service/manager/list", "/apaas/service/v3/service/approval/applied/list", - "nor_cloud" + "/apaas/service/v3/resource/user/apply/list" ], [ "/apaas/service/v3/service/manager/list", "/apaas/service/v3/service/approval/applied/list", - "nor_cloud_manage" + "/apaas/service/v3/resource/user/apply/list" ] ], service_head: [ @@ -581,33 +582,7 @@ export default { ], [ { - prop: "fwmc", - label: "服务名称", - width: "250px", - align: "left" - }, - { - prop: "fwlx", - label: "服务类型", - width: "120px", - align: "center" - }, - { - prop: "spsj", - label: "审批时间", - width: "200px", - align: "center" - }, - { - prop: "spzt", - label: "审批状态", - width: "110px", - align: "center" - } - ], - [ - { - prop: "gzqy", + prop: "name_space", label: "工作区域", width: "150px", align: "left" @@ -625,7 +600,7 @@ export default { align: "center" }, { - prop: "ncgb", + prop: "memory", label: "内存(GB)", width: "90px", align: "center" @@ -637,7 +612,7 @@ export default { align: "center" }, { - prop: "sqzt", + prop: "approve_state_name", label: "申请状态", width: "110px", align: "center" @@ -703,7 +678,7 @@ export default { ], [ { - prop: "gzqy", + prop: "name_space", label: "工作区域", width: "100px", align: "left" @@ -721,7 +696,7 @@ export default { align: "center" }, { - prop: "ncgb", + prop: "memory", label: "内存(GB)", width: "80px", align: "center" @@ -809,7 +784,7 @@ export default { ], [ { - prop: "sszz", + prop: "department_name ", label: "所属组织", width: "170px", align: "left" @@ -821,7 +796,7 @@ export default { align: "center" }, { - prop: "ncgb", + prop: "memory", label: "内存使用量(GB)", width: "130px", align: "center" @@ -1123,7 +1098,7 @@ export default { .get( `${this.service_url_arr[this.now_user][this.now_type]}?page=${ this.currentPage - }&size=${this.pageSize}` + }&size=${this.pageSize}&limit=${this.pageSize}` ) .then(response => { console.log(response); @@ -1131,47 +1106,53 @@ export default { return; } let data = response.data.data; - this.service_data = data.data; - this.service_data.forEach(e => { - if (e.create_time) { - e.create_time = e.create_time.split("+")[0].replace("T", " "); - } + if(this.now_type==2){ + this.service_data = data.cloud_apply_list + this.listTotal = response.data.total; + }else{ + this.service_data = data.data; + this.service_data.forEach(e => { + if (e.create_time) { + e.create_time = e.create_time.split("+")[0].replace("T", " "); + } - if (e.service_apply_info && e.service_apply_info.approval_time) { - e.approval_time = helper.dateStringTransform( - e.service_apply_info.approval_time - ); - } else { - e.approval_time = ""; - } + if (e.service_apply_info && e.service_apply_info.approval_time) { + e.approval_time = helper.dateStringTransform( + e.service_apply_info.approval_time + ); + } else { + e.approval_time = ""; + } - if (e.service_apply_info && e.service_apply_info.apply_time) { - e.apply_time = helper.dateStringTransform( - e.service_apply_info.apply_time - ); - } else { - e.apply_time = ""; - } + if (e.service_apply_info && e.service_apply_info.apply_time) { + e.apply_time = helper.dateStringTransform( + e.service_apply_info.apply_time + ); + } else { + e.apply_time = ""; + } - if (e.service_apply_info && e.service_apply_info.approval_status) { - if (this.now_user !== 0 && this.now_user !== 4) { - e.approval_status = ["-", "已审批", "待审批"][ - e.service_apply_info.approval_status - ]; + if (e.service_apply_info && e.service_apply_info.approval_status) { + if (this.now_user !== 0 && this.now_user !== 4) { + e.approval_status = ["-", "已审批", "待审批"][ + e.service_apply_info.approval_status + ]; + } else { + e.approval_status = [ + "-", + "待审批", + "审批中", + "审批通过", + "审批未通过" + ][e.service_apply_info.approval_status]; + } } else { - e.approval_status = [ - "-", - "待审批", - "审批中", - "审批通过", - "审批未通过" - ][e.service_apply_info.approval_status]; + e.approval_status = ""; } - } else { - e.approval_status = ""; - } - }); - this.listTotal = data.total; + }); + this.listTotal = data.total; + } + }) .catch(function(response) {}); }, diff --git a/src/pages/workbench/yygl/app_edit.vue b/src/pages/workbench/yygl/app_edit.vue index 299f6102a61eb462e321707eeed4120b15eda03d..360334c4588b3e4912e95805ab74b3e8a25c3ede 100644 --- a/src/pages/workbench/yygl/app_edit.vue +++ b/src/pages/workbench/yygl/app_edit.vue @@ -60,7 +60,7 @@ ]" >

所属组织:

- +

- {{it.disk_serial_number}} ({{'用量:'+it.disk_cap+'Gi'+' '+' ' +'类型:'+it.store_type}}) + {{it.disk_serial_number}} ({{'用量:'+it.disk_cap+'Gi'+' '+' ' +'类型:'+it.store_type}})

@@ -277,6 +277,7 @@ export default { namespace: "", name: "", }, + select_volumn:'', app_set: {}, app_set_info: {}, area_options: [ @@ -369,7 +370,9 @@ export default { e["cpu"] = parseInt(cpu); // this.deal_key_value(this.app_set_info,e.name,'resource',[memory,cpu]) } else if(e.type == "volume") { + this.select_volumn='' e['check_type'] = 0 + console.log(this.pvc_list); e['value'] = this.pvc_list[0].disk_serial_number // this.deal_key_value(this.app_set_info,e.name,e.type,e.value) }else{ @@ -430,8 +433,9 @@ export default { } }else{//云存储 temp[e] = { - claimName:value[0] + claimName:value[0].split(';')[0] } + this.select_volumn = value[0].split(';')[1] } }else{ temp[e] = value; @@ -471,9 +475,10 @@ export default { up_userid: this.$store.state.userInfo.user_id, name: this.baseInfoForm.name, namespace: this.baseInfoForm.namespace, - uu: this.evtUuid, + uu: this.evtUuid, values: this.app_set_info, - source: this.$route.query.source == "apply" ? "apply" : "" + source: this.$route.query.source == "apply" ? "apply" : "", + pvc_id: parseInt(this.select_volumn) }; } else { //编辑提交