Commit 13d42070 authored by 刘殿昕's avatar 刘殿昕

fixed all

parent 01ebd0ff
...@@ -114,11 +114,11 @@ export default { ...@@ -114,11 +114,11 @@ export default {
}, },
addToCart() { addToCart() {
// console.log("addToCart"); // console.log("addToCart");
console.log(this.datas)
this.$http this.$http
.post("/apaas/serviceapp/v3/shopcart/add", { .post("/apaas/serviceapp/v3/shopcart/add", {
service_id: 0, // 0表示不是服务 service_id: 0, // 0表示不是服务
app_id: parseFloat(this.data.app_id), app_id: parseFloat(this.datas.app_id),
spec_id: this.specificationID, spec_id: this.specificationID,
duration: 1, duration: 1,
duration_method: 1, duration_method: 1,
...@@ -151,7 +151,7 @@ export default { ...@@ -151,7 +151,7 @@ export default {
this.$router.push({ this.$router.push({
path: "/shop/shop_car_apply", path: "/shop/shop_car_apply",
query: { query: {
app_id: parseFloat(this.data.app_id), app_id: parseFloat(this.datas.app_id),
spec_id: this.specificationID, spec_id: this.specificationID,
duration: 1, duration: 1,
duration_unit: 1, duration_unit: 1,
......
...@@ -113,7 +113,8 @@ export default { ...@@ -113,7 +113,8 @@ export default {
this.$api.serviceShop this.$api.serviceShop
.getExtendedInfo({ id: this.id }) .getExtendedInfo({ id: this.id })
.then((response) => { .then((response) => {
this.baseInfo.app_id = data.data.app_id; console.log(data)
this.baseInfo.app_id = response.data.data.app_id;
this.baseInfo.app_name = data.data.app_name; this.baseInfo.app_name = data.data.app_name;
this.baseInfo.apply_id = data.data.apply_id; this.baseInfo.apply_id = data.data.apply_id;
this.baseInfo.apply_times = data.data.apply_times; this.baseInfo.apply_times = data.data.apply_times;
...@@ -137,13 +138,14 @@ export default { ...@@ -137,13 +138,14 @@ export default {
this.baseInfo.price_style = response.data.data.price_style; this.baseInfo.price_style = response.data.data.price_style;
this.baseInfo.sale = response.data.data.sale; this.baseInfo.sale = response.data.data.sale;
this.baseInfo.star = response.data.data.star; this.baseInfo.star = response.data.data.star;
this.detailData[1].value = {
online_state_name: data.data.online_state_name,
type_name: data.data.type_name,
ywly_name: data.data.ywly_name,
create_date: data.data.create_date,
};
console.log(this.baseInfo)
}); });
this.detailData[1].value = {
online_state_name: data.data.online_state_name,
type_name: data.data.type_name,
ywly_name: data.data.ywly_name,
create_date: data.data.create_date,
};
}) })
.catch(function (error) { .catch(function (error) {
console.log(error); console.log(error);
......
...@@ -41,7 +41,11 @@ ...@@ -41,7 +41,11 @@
</el-select> </el-select>
<div <div
class="port_bg_box" class="port_bg_box"
style="padding:20px;background-color:#f8f9fd;margin-top:10px;" style="
padding: 20px;
background-color: #f8f9fd;
margin-top: 10px;
"
> >
<info-list :list_arr="port_solt_arr"> <info-list :list_arr="port_solt_arr">
<table-um <table-um
...@@ -888,20 +892,39 @@ export default { ...@@ -888,20 +892,39 @@ export default {
"info", "info",
data.create_time == "0001-01-01T00:00:00Z" data.create_time == "0001-01-01T00:00:00Z"
? "-" ? "-"
: data.create_time.replace("T", " ").split("+")[0] : data.create_time
.replace("T", " ")
.replace("Z", "")
.split("+")[0]
); );
this.$set( this.$set(
this.servicead_arr[0], this.servicead_arr[0],
"info", "info",
this.request_arr[data.req_type] this.request_arr[data.service_apply_info.urls[0].req_type]
); );
this.$set( this.$set(
this.servicead_arr[1], this.servicead_arr[1],
"info", "info",
data.req_query ? data.req_query : "" data.service_apply_info.urls[0].req_fields != ""
? data.service_apply_info.urls[0].req_fields
: data.service_apply_info.urls[0].req_query != ""
? data.service_apply_info.urls[0].req_query
: ""
);
this.$set(
this.servicead_arr[2],
"info",
data.service_apply_info.urls[0].req_fields_example != ""
? data.service_apply_info.urls[0].req_fields_example
: data.service_apply_info.urls[0].req_query_example != ""
? data.service_apply_info.urls[0].req_query_example
: ""
);
this.$set(
this.servicead_arr[3],
"info",
data.service_apply_info.urls[0].encode_method
); );
this.$set(this.servicead_arr[2], "info", data.req_fields);
this.$set(this.servicead_arr[3], "info", data.encode_method);
// this.$set(this.apply_arr[0], "info", data.apply_user_info.phone); // this.$set(this.apply_arr[0], "info", data.apply_user_info.phone);
this.$set(this.apply_arr[1], "info", data.descript); this.$set(this.apply_arr[1], "info", data.descript);
this.$set( this.$set(
...@@ -926,22 +949,22 @@ export default { ...@@ -926,22 +949,22 @@ export default {
"url", "url",
data.service_apply_info.apply_file data.service_apply_info.apply_file
); );
console.log(data);
let spcs = ""; let spcs = "";
if (data.service_apply_info.spcs_type === 1) { if (data.service_apply_info.spcs_type === 1) {
spcs = `${data.service_apply_info.single_money}金币/${data.service_apply_info.spcs_count}次`; spcs = `${data.service_apply_info.single_money}金币/${data.service_apply_info.spcs_count}次`;
} else { } else {
spcs = `${data.service_apply_info.single_money}金币/${ spcs = `${data.service_apply_info.single_money}金币/月`;
data.service_apply_info.duration_unit == 1 ? "" : ""
}`;
} }
this.$set(this.apply_arr[6], "info", spcs); this.$set(this.apply_arr[6], "info", spcs);
this.$set( this.$set(
this.apply_arr[7], this.apply_arr[7],
"info", "info",
data.service_apply_info.duration + data.service_apply_info.spcs_type == 1
(data.service_apply_info.duration_unit == 1 ? "" : "") ? "不限时长"
: data.service_apply_info.duration +
(data.service_apply_info.duration_unit == 1 ? "" : "")
); );
this.$set( this.$set(
this.apply_arr[8], this.apply_arr[8],
...@@ -953,7 +976,7 @@ export default { ...@@ -953,7 +976,7 @@ export default {
this.$set( this.$set(
this.apply_arr[9], this.apply_arr[9],
"info", "info",
data.service_apply_info.total_money data.service_apply_info.total_money + "金币"
); );
this.res_table_arr = JSON.parse( this.res_table_arr = JSON.parse(
data.service_apply_info.res_fields || "[]" data.service_apply_info.res_fields || "[]"
...@@ -961,12 +984,15 @@ export default { ...@@ -961,12 +984,15 @@ export default {
if (this.res_table_arr.length === 0) { if (this.res_table_arr.length === 0) {
this.$set(this.servicead_arr[4], "info", "无响应参数"); this.$set(this.servicead_arr[4], "info", "无响应参数");
} }
this.res_code_arr = data.res_fields_example || ""; // 响应示例 this.res_code_arr =
data.service_apply_info.urls[0].res_fields_example || ""; // 响应示例
if (!this.res_code_arr) { if (!this.res_code_arr) {
this.$set(this.servicead_arr[5], "type", ""); this.$set(this.servicead_arr[5], "type", "");
this.$set(this.servicead_arr[5], "info", "无响应示例"); this.$set(this.servicead_arr[5], "info", "无响应示例");
} }
console.log(this.res_table_arr); if (data.data_service_type1_name != "数据服务") {
this.servicead_arr = this.servicead_arr.slice(0, 4);
}
if (data.service_apply_info.approval_process) { if (data.service_apply_info.approval_process) {
data.service_apply_info.approval_process.forEach((e) => { data.service_apply_info.approval_process.forEach((e) => {
this.use_approval_arr.push({ this.use_approval_arr.push({
...@@ -1010,7 +1036,7 @@ export default { ...@@ -1010,7 +1036,7 @@ export default {
} }
this.res_data = JSON.parse(data.res_fields); this.res_data = JSON.parse(data.res_fields);
}) })
.catch(function(response) {}); .catch(function (response) {});
}, },
}, },
}; };
......
...@@ -9,41 +9,75 @@ ...@@ -9,41 +9,75 @@
<div class="type_box"> <div class="type_box">
<div class="type_title"> <div class="type_title">
<div <div
v-for="(item,index) in service_arr" v-for="(item, index) in service_arr"
:key="index+1000" :key="index + 1000"
class="type_select" class="type_select"
@click="now_service=index" @click="now_service = index"
:style="now_service==index?{borderBottom: '4px solid #f5ab4c'}:{}" :style="
>{{item}}</div> now_service == index ? { borderBottom: '4px solid #f5ab4c' } : {}
"
>
{{ item }}
</div>
</div> </div>
<div class="type_box_select"> <div class="type_box_select">
<info-list @download="download" :list_arr="now_service==0?list_arr:servicead_arr[now_user]"> <info-list
<table-um :headers="header_arr" :datas="zd_table_arr" slot="zd_table"></table-um> @download="download"
<process-card type="approval" :data="approval_arr[now_user]" slot="sp_card" v-if="(now_user==1&&service_header_arr['first'][2].text!=='待审批')||now_user==2"></process-card> :list_arr="now_service == 0 ? list_arr : servicead_arr[now_user]"
<div class="info_contain1" slot="sp_result" v-if="service_header_arr['first'][2].text=='待审批'"> >
<el-form ref="form" :rules="rules" :model="form" label-width="0px"> <table-um
:headers="header_arr"
:datas="zd_table_arr"
slot="zd_table"
></table-um>
<process-card
type="approval"
:data="approval_arr[now_user]"
slot="sp_card"
v-if="
(now_user == 1 &&
service_header_arr['first'][2].text !== '待审批') ||
now_user == 2
"
></process-card>
<div
class="info_contain1"
slot="sp_result"
v-if="service_header_arr['first'][2].text == '待审批'"
>
<el-form
ref="form"
:rules="rules"
:model="form"
label-width="0px"
>
<el-form-item prop="result"> <el-form-item prop="result">
<p class="formname">审批结果:</p> <p class="formname">审批结果:</p>
<el-select v-model="form.result" placeholder="请选择"> <el-select v-model="form.result" placeholder="请选择">
<el-option <el-option
v-for="item in resultoptions" v-for="item in resultoptions"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value"> :value="item.value"
</el-option> >
</el-select> </el-option>
</el-select>
</el-form-item> </el-form-item>
<el-form-item prop="option"> <el-form-item prop="option">
<p class="formname">审批意见:</p> <p class="formname">审批意见:</p>
<el-input v-model="form.option" placeholder="请输入审批意见,不少于10个字"></el-input> <el-input
v-model="form.option"
placeholder="请输入审批意见,不少于10个字"
></el-input>
</el-form-item> </el-form-item>
<el-form-item class="btnsty"> <el-form-item class="btnsty">
<el-button @click="onSubmit('form')" class="right">提交</el-button> <el-button @click="onSubmit('form')" class="right"
<el-button class="right" @click="backpage">取消</el-button> >提交</el-button
>
<el-button class="right" @click="backpage">取消</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
</info-list> </info-list>
</div> </div>
</div> </div>
...@@ -56,107 +90,108 @@ import serviceHeader from "@/components/service-header"; ...@@ -56,107 +90,108 @@ import serviceHeader from "@/components/service-header";
import infoList from "@/components/infoList"; import infoList from "@/components/infoList";
import tableUm from "@/components/table/table-um"; import tableUm from "@/components/table/table-um";
import processCard from "@/components/process-card"; import processCard from "@/components/process-card";
import { mapGetters,mapState } from 'vuex' import { mapGetters, mapState } from "vuex";
export default { export default {
props: {}, props: {},
components: { components: {
serviceHeader, serviceHeader,
infoList, infoList,
tableUm, tableUm,
processCard processCard,
}, },
data() { data() {
return { return {
form:{ form: {
result:'', result: "",
option:'' option: "",
}, },
id:'', id: "",
zd_table_arr:[], zd_table_arr: [],
now_user: 0, //0:普通用户,1:组织管理员,2:超级管理员 now_user: 0, //0:普通用户,1:组织管理员,2:超级管理员
rules:{ rules: {
result:[ result: [{ required: true, message: "请选择意见", trigger: "change" }],
{ required: true, message: '请选择意见', trigger: 'change' }, option: [
], { required: true, message: "请输入意见", trigger: "blur" },
option:[ {
{ required: true, message: '请输入意见', trigger: 'blur' }, min: 10,
{ max: 200,
min: 10,max:200, message: '长度应大于10个小于200个字符', trigger: 'blur' message: "长度应大于10个小于200个字符",
} trigger: "blur",
] },
],
}, },
resultvalue: "", resultvalue: "",
resultoptions: [ resultoptions: [
{ {
label: "通过", label: "通过",
value: 1 value: 1,
}, },
{ {
label: "不通过", label: "不通过",
value: -1 value: -1,
} },
], ],
approval_arr:[ approval_arr: [
[], [],
[], [],
[ [
// { // {
// title:'一级审批', // title:'一级审批',
// result:'', // result:'',
// arr:[ // arr:[
// { // {
// title:'审批时间:', // title:'审批时间:',
// info:'' // info:''
// }, // },
// { // {
// title:'审批单位:', // title:'审批单位:',
// info:'' // info:''
// }, // },
// { // {
// title:'审批人:', // title:'审批人:',
// info:'' // info:''
// }, // },
// { // {
// title:'审批意见:', // title:'审批意见:',
// info:'' // info:''
// }, // },
// ] // ]
// }, // },
]
], ],
],
header_arr: [ header_arr: [
{ {
prop: "name", prop: "name",
label: "字段名称", label: "字段名称",
minWidth: "20%", minWidth: "20%",
align: "left" align: "left",
}, },
{ {
prop: "field_type", prop: "field_type",
label: "字段编码", label: "字段编码",
width: "100px", width: "100px",
align: "center" align: "center",
}, },
{ {
prop: "show_type", prop: "show_type",
label: "字段类型", label: "字段类型",
width: "100px", width: "100px",
align: "center" align: "center",
}, },
{ {
prop: "descript", prop: "descript",
label: "字段说明", label: "字段说明",
minWidth: "30%", minWidth: "30%",
align: "left" align: "left",
}, },
{ {
prop: "example", prop: "example",
label: "字段示例数值", label: "字段示例数值",
width: "120px", width: "120px",
align: "left" align: "left",
} },
], ],
color_arr:['#e15260','"#ef9433','#515fe7'], color_arr: ["#e15260", '"#ef9433', "#515fe7"],
service_header_arr: { service_header_arr: {
id: "", id: "",
isMap: false, isMap: false,
...@@ -165,127 +200,124 @@ export default { ...@@ -165,127 +200,124 @@ export default {
first: [ first: [
{ {
name: "服务类型", name: "服务类型",
text: "" text: "",
}, },
{ {
name: "服务领域", name: "服务领域",
text: "" text: "",
}, },
{ {
name: "审批状态", name: "审批状态",
text: "", text: "",
color: "#ef9433" color: "#ef9433",
} },
], ],
second: [ second: [
{ {
name: "申请时间", name: "申请时间",
text: "" text: "",
} },
], ],
fixed: false fixed: false,
}, },
service_arr: ["服务申请信息", "服务审批"], service_arr: ["服务申请信息", "服务审批"],
now_service: 0, now_service: 0,
servicead_arr: [ servicead_arr: [
[], [],
[ [
{ {
title: "审批信息:", title: "审批信息:",
prop: "title", prop: "title",
type: "solt", type: "solt",
solt_name: "sp_card" solt_name: "sp_card",
}, },
{ {
title: "一级审批:", title: "一级审批:",
prop: "title", prop: "title",
type: "solt", type: "solt",
solt_name: "sp_result" solt_name: "sp_result",
}, },
], ],
[ [
{ {
title: "审批信息:", title: "审批信息:",
prop: "title", prop: "title",
type: "solt", type: "solt",
solt_name: "sp_card" solt_name: "sp_card",
}, },
{ {
title: "二级审批:", title: "二级审批:",
prop: "title", prop: "title",
type: "solt", type: "solt",
solt_name: "sp_result" solt_name: "sp_result",
}, },
] ],
], ],
list_arr: [ list_arr: [
{ {
title: "申请单位:", title: "申请单位:",
info: "" info: "",
}, },
{ {
title: "申请人:", title: "申请人:",
info: "" info: "",
}, },
{ {
title: "申请人联系电话:", title: "申请人联系电话:",
info: "" info: "",
}, },
{ {
title: "业务系统名称:", title: "业务系统名称:",
info: "" info: "",
}, },
{ {
title: "业务系统访问地址:", title: "业务系统访问地址:",
info: "" info: "",
}, },
{ {
title: "场景描述:", title: "场景描述:",
info: "" info: "",
}, },
{ {
title: "申请文件:", title: "申请文件:",
info: "", info: "",
url:'', url: "",
type: "down" type: "down",
}, },
{ {
title: "申请内容:", title: "申请内容:",
info: "", info: "",
type: "solt", type: "solt",
solt_name: "zd_table" solt_name: "zd_table",
}, },
{ {
title: "申请时长:", title: "申请时长:",
info: "" info: "",
}, },
{ {
title: "申请规格:", title: "申请规格:",
info: "" info: "",
}, },
{ {
title: "总价:", title: "总价:",
info: "", info: "",
}, },
] ],
}; };
}, },
watch: {}, watch: {},
computed: { computed: {
...mapGetters([ ...mapGetters(["level"]),
'level', ...mapState(["userInfo"]),
]),
...mapState(['userInfo']),
}, },
created() { created() {
console.log(this.level); console.log(this.level);
if(this.userInfo){ if (this.userInfo) {
this.now_user = this.level this.now_user = this.level;
this.get_service_info() this.get_service_info();
}else{ } else {
this.getCurrentUser() this.getCurrentUser();
} }
}, },
mounted() {}, mounted() {},
methods: { methods: {
...@@ -293,125 +325,225 @@ export default { ...@@ -293,125 +325,225 @@ export default {
this.$api.user.getNowUser().then(({ data }) => { this.$api.user.getNowUser().then(({ data }) => {
if (data.success == 1) { if (data.success == 1) {
this.$store.commit("userInfofun", data.data); this.$store.commit("userInfofun", data.data);
this.now_user = this.level this.now_user = this.level;
this.get_service_info() this.get_service_info();
console.log(this.level); console.log(this.level);
} else { } else {
console.log(data.errMsg); console.log(data.errMsg);
} }
}); });
}, },
onSubmit(formName){ onSubmit(formName) {
this.$refs[formName].validate((valid) => { this.$refs[formName].validate((valid) => {
if (valid) { if (valid) {
this.set_approval() this.set_approval();
} else {
console.log("error submit!!");
return false;
}
});
},
backpage() {
this.$router.back(-1);
},
set_approval() {
this.$http
.post("/apaas/service/v3/service/approval/applied/approval", {
apply_id: this.id,
state: this.form.result,
message: this.form.option,
})
.then((res) => {
console.log(res);
if (res.data.success) {
this.$message.success("审批成功");
this.$router.back(-1);
} else { } else {
console.log('error submit!!'); this.$message.error("审批失败");
return false;
} }
})
.catch((res) => {
this.$message.error(res);
}); });
}, },
backpage(){ download(val) {
this.$router.back(-1) console.log(val);
}, },
set_approval(){ get_service_info() {
this.$http.post('/apaas/service/v3/service/approval/applied/approval',{ this.$http
apply_id:this.id, .get(
state:this.form.result, `/apaas/service/v3/service/approval/applied?apply_id=${this.$route.params.id}`
message:this.form.option )
}).then((res)=>{ .then((response) => {
console.log(res); console.log(response.data.data);
if(res.data.success){ if (!response.data.success) {
this.$message.success('审批成功') this.$message.error(response.data.errMsg);
this.$router.back(-1) return;
}else{ }
this.$message.error('审批失败') let data = response.data.data;
this.$set(this.service_header_arr, "portal_id", data.portal_id); // 时空服务id
this.$set(this.service_header_arr, "workflows_id", data.workflows_id); // 时空服务id
this.$set(
this.service_header_arr,
"isMap",
data.data_service_type1 === 6
);
this.$set(
this.service_header_arr,
"isProcess",
data.data_service_type2 === 24
);
this.$set(this.service_header_arr, "name", data.name);
this.$set(
this.service_header_arr["first"][0],
"text",
data.data_service_type1_name
);
this.$set(
this.service_header_arr["first"][1],
"text",
data.sectors_name
);
this.$set(
this.service_header_arr["first"][2],
"text",
data.service_apply_info.approval_status == 0
? "待审批"
: data.service_apply_info.approval_status == 1
? "审批通过"
: "审批未通过"
);
this.$set(
this.service_header_arr["first"][2],
"color",
this.color_arr[data.service_apply_info.approval_status + 1]
);
this.$set(
this.service_header_arr["second"][0],
"text",
data.service_apply_info.apply_time.replace("T", " ").split("+")[0]
);
this.$set(this.service_header_arr, "url", data.cover);
this.$set(
this.list_arr[0],
"info",
data.service_apply_info.apply_user_info.department_name
);
this.$set(
this.list_arr[1],
"info",
data.service_apply_info.apply_user_info.user_name
);
this.$set(
this.list_arr[2],
"info",
data.service_apply_info.apply_user_info.phone
);
this.$set(
this.list_arr[3],
"info",
data.service_apply_info.business_name
);
this.$set(
this.list_arr[4],
"info",
data.service_apply_info.business_url
);
this.$set(this.list_arr[5], "info", data.descript);
this.$set(
this.list_arr[6],
"info",
data.service_apply_info.apply_file.split("/")[
data.service_apply_info.apply_file.split("/").length - 1
]
);
this.$set(
this.list_arr[6],
"url",
data.service_apply_info.apply_file
);
this.$set(
this.list_arr[8],
"info",
data.service_apply_info.spcs_type == 1
? "不限时长"
: data.service_apply_info.duration + ""
);
this.$set(
this.list_arr[9],
"info",
data.service_apply_info.spcs_type == 1
? data.service_apply_info.single_money +
"金币/" +
data.service_apply_info.spcs_count +
""
: data.service_apply_info.single_money + "金币/月"
);
this.$set(
this.list_arr[10],
"info",
data.service_apply_info.total_money + "金币"
);
this.id = data.service_apply_info.id;
if (data.service_apply_info.approval_status !== 0) {
this.servicead_arr[this.now_user].splice(1, 1);
}
if (
!(
(this.now_user == 1 &&
this.service_header_arr["first"][2].text !== "待审批") ||
this.now_user == 2
)
) {
this.servicead_arr[this.now_user].splice(0, 1);
} }
}).catch((res)=>{ if (data.service_apply_info.approval_process) {
this.$message.error(res) data.service_apply_info.approval_process.forEach((e) => {
this.approval_arr[this.now_user].push({
title: e.level == 1 ? "一级审批" : "二级审批",
result:
e.status == -1
? "审批未通过"
: e.status == 0
? "审批中"
: "审批通过",
});
if (e.status !== 0) {
this.approval_arr[this.now_user][
this.approval_arr[this.now_user].length - 1
]["arr"] = [
{
title: "审批时间:",
info: e.approval_time.split("+")[0].replace("T", " "),
},
{
title: "审批单位:",
info: e.user_info.department_name
? e.user_info.department_name
: "",
},
{
title: "审批人:",
info: e.user_info.user_name,
},
{
title: "审批意见:",
info: e.comments,
},
];
}
});
}
console.log(this.approval_arr);
this.zd_table_arr = data.service_apply_info.res_fields
? JSON.parse(data.service_apply_info.res_fields)
: [];
}) })
}, .catch(function (response) {
download(val){ this.$message.error("请求失败");
console.log(val); });
}, },
get_service_info(){ },
this.$http
.get(`/apaas/service/v3/service/approval/applied?apply_id=${this.$route.params.id}`)
.then((response) => {
console.log(response.data.data);
if(!response.data.success){
this.$message.error(response.data.errMsg)
return
}
let data = response.data.data;
this.$set(this.service_header_arr, "portal_id", data.portal_id); // 时空服务id
this.$set(this.service_header_arr, "workflows_id", data.workflows_id); // 时空服务id
this.$set(this.service_header_arr, "isMap", data.data_service_type1 === 6);
this.$set(this.service_header_arr, "isProcess", data.data_service_type2 === 24);
this.$set(this.service_header_arr, "name", data.name);
this.$set(this.service_header_arr['first'][0], 'text', data.data_service_type1_name);
this.$set(this.service_header_arr['first'][1], 'text', data.sectors_name);
this.$set(this.service_header_arr['first'][2], 'text', data.service_apply_info.approval_status==0?'待审批':data.service_apply_info.approval_status==1?'审批通过':'审批未通过');
this.$set(this.service_header_arr['first'][2], 'color', this.color_arr[data.service_apply_info.approval_status+1]);
this.$set(this.service_header_arr['second'][0], "text", data.service_apply_info.apply_time.replace('T'," ").split('+')[0]);
this.$set(this.service_header_arr, "url", data.cover);
this.$set(this.list_arr[0], "info", data.service_apply_info.apply_user_info.department_name);
this.$set(this.list_arr[1], "info", data.service_apply_info.apply_user_info.user_name);
this.$set(this.list_arr[2], "info", data.service_apply_info.apply_user_info.phone);
this.$set(this.list_arr[3], "info", data.service_apply_info.business_name);
this.$set(this.list_arr[4], "info", data.service_apply_info.business_url);
this.$set(this.list_arr[5], "info", data.descript);
this.$set(this.list_arr[6], "info", data.service_apply_info.apply_file.split('/')[data.service_apply_info.apply_file.split('/').length - 1]);
this.$set(this.list_arr[6], "url", data.service_apply_info.apply_file);
this.$set(this.list_arr[8], "info", data.service_apply_info.duration+(data.service_apply_info.duration_unit==1?'':''));
this.$set(this.list_arr[9], "info", "访问次数:"+(data.service_apply_info.request_spcs&&data.service_apply_info.request_spcs.pv||'-')+"次/日 访问量:"+(data.service_apply_info.request_spcs&&data.service_apply_info.request_spcs.count||'-')+"次/日");
this.$set(this.list_arr[10], "info", data.service_apply_info.total_money);
this.id = data.service_apply_info.id
if(data.service_apply_info.approval_status!==0){
this.servicead_arr[this.now_user].splice(1,1)
}
if(!((this.now_user==1&&this.service_header_arr['first'][2].text!=='待审批')||this.now_user==2)){
this.servicead_arr[this.now_user].splice(0,1)
}
if(data.service_apply_info.approval_process){
data.service_apply_info.approval_process.forEach(e => {
this.approval_arr[this.now_user].push(
{
title:e.level==1?'一级审批':'二级审批',
result:e.status==-1?'审批未通过':e.status==0?'审批中':'审批通过',
}
)
if(e.status!==0){
this.approval_arr[this.now_user][this.approval_arr[this.now_user].length - 1]['arr']=[
{
title:'审批时间:',
info:e.approval_time.split('+')[0].replace("T",' ')
},
{
title:'审批单位:',
info:e.user_info.department_name?e.user_info.department_name:''
},
{
title:'审批人:',
info:e.user_info.user_name
},
{
title:'审批意见:',
info:e.comments
},
]
}
});
}
console.log(this.approval_arr);
this.zd_table_arr = data.service_apply_info.res_fields?JSON.parse(data.service_apply_info.res_fields):[]
})
.catch(function(response) {
this.$message.error('请求失败')
});
},
}
}; };
</script> </script>
...@@ -420,21 +552,21 @@ export default { ...@@ -420,21 +552,21 @@ export default {
.type_box_select .el-form { .type_box_select .el-form {
width: 1022px; width: 1022px;
} }
.info_contain1 .el-input__inner{ .info_contain1 .el-input__inner {
background-color: #f7f8f9; background-color: #f7f8f9;
width: 1022px; width: 1022px;
} }
.info_contain1 .el-input{ .info_contain1 .el-input {
width: 1022px; width: 1022px;
} }
.btnsty .el-button{ .btnsty .el-button {
background-color: #c3caf8; background-color: #c3caf8;
color: #0f2683; color: #0f2683;
} }
.btnsty .el-button:nth-of-type(1){ .btnsty .el-button:nth-of-type(1) {
background-color: #0f2683; background-color: #0f2683;
color: #f8f9fd; color: #f8f9fd;
} }
</style> </style>
<style scoped> <style scoped>
...@@ -480,19 +612,19 @@ export default { ...@@ -480,19 +612,19 @@ export default {
padding: 30px 10px 10px 10px; padding: 30px 10px 10px 10px;
width: 100%; width: 100%;
} }
.formname{ .formname {
color: #58617a; color: #58617a;
} }
.right{ .right {
float: right; float: right;
margin-left: 20px; margin-left: 20px;
} }
.btnsty{ .btnsty {
position: absolute; position: absolute;
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.info_contain1{ .info_contain1 {
margin-bottom: 70px; margin-bottom: 70px;
} }
</style> </style>
...@@ -1385,7 +1385,6 @@ export default { ...@@ -1385,7 +1385,6 @@ export default {
"info", "info",
data.create_time.replace("T", " ").split("+")[0] data.create_time.replace("T", " ").split("+")[0]
); );
// 接口详情信息 // 接口详情信息
this.$set( this.$set(
this.servicead_arr[0], this.servicead_arr[0],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment