Commit 32049e33 authored by 刘殿昕's avatar 刘殿昕

服务注册+url/params联动,orderList

parent 52cedb6b
...@@ -141,7 +141,6 @@ export default { ...@@ -141,7 +141,6 @@ export default {
<style scoped> <style scoped>
.com-pagination { .com-pagination {
margin-top: 20px; margin-top: 20px;
padding-bottom: 20px;
font-size: 14px; font-size: 14px;
padding: 0 5%; padding: 0 5%;
display: flex; display: flex;
......
<template> <template>
<div class="order_cell"> <div class="order_cell">
{{ cellItem.id }} <div class="order_cell_head">
<div class="application_time">申请时间:{{ cellItem.applicationTime }}</div>
<div class="order_number">订单编号:{{ cellItem.orderNumber }}</div>
<div class="cell_del_btn">删除</div>
</div>
<el-row class="cell_row">
<el-col :span="10" class="cell_msg">
<img
src="https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg"
class="cell_msg_img"
/>
<div class="cell_msg_right">
<div class="cell_name">
<span>{{ cellItem.name }}</span>
<span v-if="cellItem.mapService" class="tags map_service">mapService</span>
<span v-if="cellItem.state == 1" class="tags shared">共享</span>
<span v-else-if="cellItem.state == 2" class="tags restricted">受限</span>
<span v-else class="tags sensitive">敏感</span>
</div>
<div class="cell_msg_other">
<div class="cell_type">{{ cellItem.type }}</div>
<div class="cell_creator">{{ cellItem.creator }}</div>
</div>
</div>
</el-col>
<el-col :span="6" class="cell_specification">
<div>
<div>规格:访问次数:200/日,访问量:10000/日</div>
<div class="cell_specification_type">申请方式:按月</div>
</div>
</el-col>
<el-col :span="4" class="approval_status">
<div>
<div>已获取</div>
<el-popover
v-if="cellItem.getStatus == 1"
placement="right-start"
width="300"
v-model="visible"
trigger="click"
>
<p>服务评价:</p>
<div class="pop_rate">
<el-rate
v-model="serviceRate"
:colors="colors"
allow-half
show-score
score-template="{value}"
></el-rate>
</div>
<p>填写评价:</p>
<div class="evaluation_text">
<el-input
type="textarea"
placeholder="请输入内容"
v-model="textarea"
maxlength="200"
show-word-limit
:autosize="{ minRows: 4, maxRows: 10 }"
></el-input>
</div>
<div class="pop_btn_group">
<el-button size="small" class="pop_cancel" type="text" @click="visible = false">取消</el-button>
<el-button type="primary" class="pop_submit" size="small" @click="addEvaluation">确定提交</el-button>
</div>
<div class="approval_status_btn" slot="reference">服务评价</div>
</el-popover>
<div
v-else-if="cellItem.getStatus == 2 && !showMsgBox"
class="approval_status_btn"
@click="showMsgBox = true"
>查看评价</div>
<div
v-else-if="cellItem.getStatus == 2 && showMsgBox"
class="approval_status_btn"
@click="showMsgBox = false"
>收起评价</div>
</div>
</el-col>
<el-col :span="4" class="cell_option">
<div>
<el-button size="madium" class="cell_option_btn">查看详情</el-button>
<div class="cell_option_spec">再次申请</div>
</div>
</el-col>
<el-collapse-transition>
<el-col v-if="showMsgBox" :span="24" class="evaluation_msg">
<div class="msg_title">服务评分:</div>
<div class="msg_rate">
<el-rate
v-model="cellItem.evaluationRate"
disabled
show-score
text-color="#ff9900"
score-template="{value}"
></el-rate>
</div>
<div class="msg_title">评价详情:</div>
<div class="msg_text">{{ cellItem.evaluationText }}</div>
</el-col>
</el-collapse-transition>
</el-row>
</div> </div>
</template> </template>
...@@ -15,17 +117,217 @@ export default { ...@@ -15,17 +117,217 @@ export default {
} }
} }
}, },
methods: {} data: () => ({
visible: false,
colors: ["#99A9BF", "#F7BA2A", "#FF9900"],
serviceRate: 0,
textarea: "",
showMsgBox: false
}),
methods: {
addEvaluation() {
console.log(this.serviceRate, this.textarea);
this.visible = false;
}
}
}; };
</script> </script>
<style scoped> <style scoped>
.order_cell { .order_cell {
height: 100px; border: solid 1px #ededed;
border-bottom: 2px #567 solid; border-radius: 8px;
margin: 10px 0; margin-bottom: 20px;
}
.order_cell_head {
height: 48px;
background-color: #e5f0ff;
font-size: 14px;
color: #242c43;
line-height: 48px;
border-radius: 8px 8px 0 0;
}
.application_time {
display: inline-block;
margin-left: 40px;
}
.order_number {
display: inline-block;
margin-left: 60px;
}
.cell_del_btn {
color: #8390ee;
display: flex;
float: right;
margin-right: 40px;
}
.cell_row {
}
.cell_msg {
height: 162px;
padding: 20px 10px 20px 20px;
display: flex;
justify-content: space-between;
border-right: 1px #ededed solid;
}
.cell_msg_img {
width: 118px;
height: 118px;
border-radius: 8px;
}
.cell_msg_right {
width: calc(100% - 140px);
margin: 0 0 0 10px;
position: relative;
}
.cell_name {
width: 100%;
line-height: 24px;
text-overflow: -o-ellipsis-lastline;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
font-size: 16px;
}
.cell_msg_other {
position: absolute;
bottom: 2px;
}
.cell_type {
color: #8890a7;
font-size: 14px;
line-height: 22px;
}
.cell_creator {
color: #8890a7;
font-size: 14px;
line-height: 22px;
}
.tags {
display: inline-block;
margin-left: 10px;
padding: 1px 8px 2px;
font-size: 12px;
font-weight: 500;
line-height: 12px;
border-radius: 4px;
position: relative;
top: -2px;
}
.map_service {
background-color: #626de9;
border: solid 1px #626de9;
color: #fff;
}
.shared {
background-color: #e7fdfc;
border: solid 1px #8bd6d0;
color: #25bdb1;
}
.restricted {
background-color: #fffee8;
border: solid 1px #e4c884;
color: #ef9433;
}
.sensitive {
background-color: #ffefef;
border: solid 1px #d7a4a9;
color: #e15260;
}
.cell_specification {
height: 162px;
color: #8890a7;
display: flex;
justify-content: center;
align-items: center;
line-height: 30px;
padding: 22px 20px;
border-right: 1px #ededed solid;
}
.cell_specification_type {
margin-top: 15px;
}
.approval_status {
height: 162px;
padding: 20px;
text-align: center;
display: flex;
justify-content: center;
align-items: center;
color: #8890a7;
border-right: 1px #ededed solid;
}
.approval_status_btn {
margin-top: 15px;
cursor: pointer;
color: #626de9;
}
.cell_option {
height: 162px;
padding: 20px;
text-align: center;
display: flex;
justify-content: center;
align-items: center;
}
.cell_option_btn {
background-color: #5362ee;
color: #f4f7fc;
}
.cell_option_spec {
margin-top: 15px;
}
.pop_rate {
padding: 0 0 0 50px;
margin: 15px 0;
}
.evaluation_text {
padding: 15px 4px;
}
.pop_cancel {
color: #58617a;
margin-right: 20px;
}
.pop_submit {
background-color: #e56600;
border: 0;
}
.pop_btn_group {
margin-top: 10px;
text-align: center;
}
.evaluation_msg {
height: 100%;
border-top: 1px #ededed solid;
padding: 20px;
}
.msg_title {
color: #8890a7;
margin: 0 0 10px;
}
.msg_rate {
margin: 0 0 10px 20px;
}
.msg_text {
margin-left: 20px;
color: #242c43;
}
</style>
<style>
.pop_rate .el-rate__icon {
font-size: 24px;
}
.pop_rate .el-rate__text {
font-size: 20px;
margin-left: 20px;
position: relative;
top: 1px;
color: #58617a !important;
} }
.order_cell:nth-last-child(1) { .evaluation_text .el-textarea__inner {
border-bottom: 0; border-radius: 8px;
} }
</style> </style>
\ No newline at end of file
...@@ -118,12 +118,56 @@ export default { ...@@ -118,12 +118,56 @@ export default {
} }
], ],
datas: [ datas: [
{ id: "23123" }, {
{ id: "23ss123" }, id: 0,
{ id: "2311223" }, name: "水路货物周转量情况",
{ id: "2311423" }, type: "基础数据服务",
{ id: "23131223" }, creator: "贵州省交通运输厅0",
{ id: "231123" } state: 1,
mapService: 1,
num: 2,
checkedSubscription: false,
specification: 1,
specificationApplication: 2,
evaluationText: "这条服条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用。这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用。",
evaluationRate: 4.7,
applicationTime: "2021-04-24 15:02:00",
orderNumber: "2020042422222222000001",
getStatus: 2
},
{
id: 1,
name: "水路货物周转量情况水路货物周水路货物周转量情况水路货物周",
type: "基础数据服务",
creator: "贵州省交通运输厅1",
state: 1,
num: 2,
checkedSubscription: false,
specification: 1,
specificationApplication: 2,
evaluationText: "这条服务非常好务非常好非常实用这非常实用这条服务非常好非常实用。",
evaluationRate: 3.7,
applicationTime: "2020-04-24 15:02:00",
orderNumber: "202004241502000001",
getStatus: 3
},
{
id: 2,
name: "水路货物周转量情况水路货物周转量情况路货物周转量情况",
type: "基础数据服务",
creator: "贵州省交通运输厅2",
state: 1,
mapService: 1,
num: 2,
checkedSubscription: true,
specification: 1,
specificationApplication: 2,
evaluationText: "这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用。这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用这条服务非常好非常实用。",
evaluationRate: 3.7,
applicationTime: "2020-04-24 15:02:00",
orderNumber: "202004241502000001",
getStatus: 1
}
] ]
}), }),
mounted() { mounted() {
...@@ -173,10 +217,10 @@ export default { ...@@ -173,10 +217,10 @@ export default {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
padding: 0 20px; padding: 0 20px;
border-bottom: 2px #dcdfe6 solid; border-bottom: 1px solid #e9ecf3;
} }
.button_group { .button_group {
padding: 15px 10px; padding: 17px 10px;
} }
.btn_actice { .btn_actice {
background-color: blue; background-color: blue;
...@@ -187,10 +231,8 @@ export default { ...@@ -187,10 +231,8 @@ export default {
padding: 10px; padding: 10px;
} }
.order-pagination { .order-pagination {
margin-top: 20px;
padding-bottom: 20px;
font-size: 14px; font-size: 14px;
padding: 0 5%; padding: 0 5% 20px;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
...@@ -266,4 +308,11 @@ export default { ...@@ -266,4 +308,11 @@ export default {
border: 0; border: 0;
padding: 0; padding: 0;
} }
.button_group .el-button {
border: 0;
}
.button_group .el-button:hover {
background-color: #515fe7;
color: #fff;
}
</style> </style>
<template> <template>
<div> <div class="order_list">
<div class="order_th_pad">
<el-row class="order_th">
<el-col :span="10">服务信息</el-col>
<el-col :span="6">规格</el-col>
<el-col :span="4">审批状态</el-col>
<el-col :span="4">操作</el-col>
</el-row>
</div>
<order-cell v-for="item in datas" :key="item.id" :cellItem="item"></order-cell> <order-cell v-for="item in datas" :key="item.id" :cellItem="item"></order-cell>
</div> </div>
</template> </template>
...@@ -24,4 +32,20 @@ export default { ...@@ -24,4 +32,20 @@ export default {
}; };
</script> </script>
<style scoped> <style scoped>
.order_list {
padding: 20px 20px 0;
}
.order_th_pad {
margin-bottom: 20px;
}
.order_th {
height: 48px;
background-color: #eff1f8;
}
.order_th div {
text-align: center;
line-height: 48px;
color: #8890a7;
font-size: 14px;
}
</style> </style>
\ No newline at end of file
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
>申请方式:{{ specificationApplicationBtns[cellItems.specificationApplication] }}</div> >申请方式:{{ specificationApplicationBtns[cellItems.specificationApplication] }}</div>
<div class="shopping_cell_specification_edit"> <div class="shopping_cell_specification_edit">
<el-popover <el-popover
placement="right" placement="right-start"
width="280" width="280"
v-model="visible" v-model="visible"
@after-leave="setSpecificationPop" @after-leave="setSpecificationPop"
...@@ -252,7 +252,7 @@ export default { ...@@ -252,7 +252,7 @@ export default {
} }
.shopping_cell_msg_other { .shopping_cell_msg_other {
position: absolute; position: absolute;
bottom: 0; bottom: 2px;
} }
.shopping_cell_type { .shopping_cell_type {
color: #8890a7; color: #8890a7;
......
...@@ -96,7 +96,7 @@ export default { ...@@ -96,7 +96,7 @@ export default {
}, },
{ {
id: 2, id: 2,
name: "水路货物周转量情况水路货物周转量情况", name: "水路货物周转量情况水路货物周水路货物周转量情况水路货物周",
type: "基础数据服务", type: "基础数据服务",
creator: "贵州省交通运输厅2", creator: "贵州省交通运输厅2",
state: 1, state: 1,
......
...@@ -604,6 +604,7 @@ export default { ...@@ -604,6 +604,7 @@ export default {
// You can delete the row when the row of data is empty, but I didn't do that // You can delete the row when the row of data is empty, but I didn't do that
// console.log(this.$refs.cesTable) // console.log(this.$refs.cesTable)
this.selectedTabsPage[val.rowId][val.header] = val.inputValue; this.selectedTabsPage[val.rowId][val.header] = val.inputValue;
this.$emit("changeTable", this.selectedTabsPage)
if ( if (
this.autoAdd && this.autoAdd &&
val.inputValue != "" && val.inputValue != "" &&
...@@ -785,7 +786,6 @@ em { ...@@ -785,7 +786,6 @@ em {
} }
.ces-pagination { .ces-pagination {
margin-top: 20px; margin-top: 20px;
padding-bottom: 20px;
font-size: 14px; font-size: 14px;
padding: 0 5%; padding: 0 5%;
display: flex; display: flex;
......
...@@ -30,7 +30,12 @@ ...@@ -30,7 +30,12 @@
</div> </div>
<div class="fwcs_fwdz">服务地址:</div> <div class="fwcs_fwdz">服务地址:</div>
<div class="fwcs_fwdz_inner"> <div class="fwcs_fwdz_inner">
<el-input placeholder="请输入内容" v-model="serviceUrl" class="input-with-select"> <el-input
placeholder="请输入内容"
@input="getUrl"
v-model="serviceUrl"
class="input-with-select"
>
<el-select v-model="select" slot="prepend" placeholder="请选择"> <el-select v-model="select" slot="prepend" placeholder="请选择">
<el-option <el-option
v-for="item in optionType" v-for="item in optionType"
...@@ -55,6 +60,7 @@ ...@@ -55,6 +60,7 @@
:border="true" :border="true"
:headers="sjfw_qqcs" :headers="sjfw_qqcs"
url url
:datas="datasFw"
:searchShow="false" :searchShow="false"
:addRowBtn="false" :addRowBtn="false"
:autoAdd="true" :autoAdd="true"
...@@ -67,6 +73,7 @@ ...@@ -67,6 +73,7 @@
:paginationShow="false" :paginationShow="false"
:pageSizeShow="false" :pageSizeShow="false"
headerCellClassName="th_pink" headerCellClassName="th_pink"
@changeTable="changeTable"
></ces-table> ></ces-table>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="请求体" name="1"> <el-tab-pane label="请求体" name="1">
...@@ -305,7 +312,6 @@ export default { ...@@ -305,7 +312,6 @@ export default {
{ label: "字段名称", prop: "label", type: "input", align: "left" }, { label: "字段名称", prop: "label", type: "input", align: "left" },
{ label: "字段说明", prop: "descript", type: "input", align: "left" } { label: "字段说明", prop: "descript", type: "input", align: "left" }
], ],
url: "",
emptyText: "暂无数据", emptyText: "暂无数据",
resultShow: false, resultShow: false,
resSuccess: false, resSuccess: false,
...@@ -354,11 +360,13 @@ export default { ...@@ -354,11 +360,13 @@ export default {
{ label: "其他", value: 10 } { label: "其他", value: 10 }
], ],
optionsOrganization: [], optionsOrganization: [],
datasFw: [],
datasQqcs: [], datasQqcs: [],
datasFhcs: [], datasFhcs: [],
request_fields: [], request_fields: [],
response_fields: [], response_fields: [],
cover: "" cover: "",
noSearchUrl: ""
}), }),
computed: {}, computed: {},
watch: {}, watch: {},
...@@ -369,6 +377,23 @@ export default { ...@@ -369,6 +377,23 @@ export default {
this.select = "GET"; this.select = "GET";
this.serviceUrl = ""; this.serviceUrl = "";
}, },
getUrl(url) {
if (url.indexOf("?") != -1) {
this.noSearchUrl = url.substring(0, url.indexOf("?"));
let search = url.substring(url.indexOf("?") + 1);
let vars = search.split("&");
let arr = [];
for (let i = 0; i < vars.length; i++) {
if (vars[i] != "") {
let pair = vars[i].split("=");
arr[i] = {};
arr[i].requestEncoding = pair[0] ? pair[0] : "";
arr[i].requestValue = pair[1] ? pair[1] : "";
}
}
this.datasFw = arr;
}
},
clickFwcs() { clickFwcs() {
let headers = {}; let headers = {};
let requestData = {}; let requestData = {};
...@@ -378,6 +403,7 @@ export default { ...@@ -378,6 +403,7 @@ export default {
headers.Authorization[0] = this.sqfsVal + " " + this.tokenVal; headers.Authorization[0] = this.sqfsVal + " " + this.tokenVal;
} }
let request = this.$refs.fwcs_sjfw_qq.getTableData(); let request = this.$refs.fwcs_sjfw_qq.getTableData();
console.log(request);
for (let i = 0; i < request.length; i++) { for (let i = 0; i < request.length; i++) {
if ( if (
request[i] && request[i] &&
...@@ -481,6 +507,17 @@ export default { ...@@ -481,6 +507,17 @@ export default {
.catch(function(response) { .catch(function(response) {
console.log("unkonw error"); console.log("unkonw error");
}); });
},
changeTable(val) {
let search = "?";
for (let i = 0; i < val.length; i++) {
if (val[i].requestEncoding != "") {
search =
search + val[i].requestEncoding + "=" + val[i].requestValue + "&";
}
}
let searchDel = search.substring(0, search.length - 1);
this.serviceUrl = this.noSearchUrl + searchDel;
} }
}, },
mounted() {} mounted() {}
......
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