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

fixed all

parent 01ebd0ff
......@@ -114,11 +114,11 @@ export default {
},
addToCart() {
// console.log("addToCart");
console.log(this.datas)
this.$http
.post("/apaas/serviceapp/v3/shopcart/add", {
service_id: 0, // 0表示不是服务
app_id: parseFloat(this.data.app_id),
app_id: parseFloat(this.datas.app_id),
spec_id: this.specificationID,
duration: 1,
duration_method: 1,
......@@ -151,7 +151,7 @@ export default {
this.$router.push({
path: "/shop/shop_car_apply",
query: {
app_id: parseFloat(this.data.app_id),
app_id: parseFloat(this.datas.app_id),
spec_id: this.specificationID,
duration: 1,
duration_unit: 1,
......
......@@ -113,7 +113,8 @@ export default {
this.$api.serviceShop
.getExtendedInfo({ id: this.id })
.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.apply_id = data.data.apply_id;
this.baseInfo.apply_times = data.data.apply_times;
......@@ -137,13 +138,14 @@ export default {
this.baseInfo.price_style = response.data.data.price_style;
this.baseInfo.sale = response.data.data.sale;
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) {
console.log(error);
......
......@@ -41,7 +41,11 @@
</el-select>
<div
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">
<table-um
......@@ -888,20 +892,39 @@ export default {
"info",
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.servicead_arr[0],
"info",
this.request_arr[data.req_type]
this.request_arr[data.service_apply_info.urls[0].req_type]
);
this.$set(
this.servicead_arr[1],
"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[1], "info", data.descript);
this.$set(
......@@ -926,22 +949,22 @@ export default {
"url",
data.service_apply_info.apply_file
);
console.log(data);
let spcs = "";
if (data.service_apply_info.spcs_type === 1) {
spcs = `${data.service_apply_info.single_money}金币/${data.service_apply_info.spcs_count}次`;
} else {
spcs = `${data.service_apply_info.single_money}金币/${
data.service_apply_info.duration_unit == 1 ? "" : ""
}`;
spcs = `${data.service_apply_info.single_money}金币/月`;
}
this.$set(this.apply_arr[6], "info", spcs);
this.$set(
this.apply_arr[7],
"info",
data.service_apply_info.duration +
(data.service_apply_info.duration_unit == 1 ? "" : "")
data.service_apply_info.spcs_type == 1
? "不限时长"
: data.service_apply_info.duration +
(data.service_apply_info.duration_unit == 1 ? "" : "")
);
this.$set(
this.apply_arr[8],
......@@ -953,7 +976,7 @@ export default {
this.$set(
this.apply_arr[9],
"info",
data.service_apply_info.total_money
data.service_apply_info.total_money + "金币"
);
this.res_table_arr = JSON.parse(
data.service_apply_info.res_fields || "[]"
......@@ -961,12 +984,15 @@ export default {
if (this.res_table_arr.length === 0) {
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) {
this.$set(this.servicead_arr[5], "type", "");
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) {
data.service_apply_info.approval_process.forEach((e) => {
this.use_approval_arr.push({
......@@ -1010,7 +1036,7 @@ export default {
}
this.res_data = JSON.parse(data.res_fields);
})
.catch(function(response) {});
.catch(function (response) {});
},
},
};
......
......@@ -1385,7 +1385,6 @@ export default {
"info",
data.create_time.replace("T", " ").split("+")[0]
);
// 接口详情信息
this.$set(
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