parent
bcf4b19d27
commit
dcacdc4979
6 changed files with 2436 additions and 745 deletions
@ -0,0 +1,13 @@ |
|||||||
|
import request from "@/router/axios"; |
||||||
|
//查询物流信息
|
||||||
|
export const getWuliuInfo = (param) => { |
||||||
|
return request({ |
||||||
|
url: "/pollApi/poll/query.do", |
||||||
|
// url: "https://poll.kuaidi100.com/poll/query.do",
|
||||||
|
method: "post", |
||||||
|
headers: { |
||||||
|
"Content-Type": "application/x-www-form-urlencoded", |
||||||
|
}, |
||||||
|
params: param, |
||||||
|
}); |
||||||
|
}; |
||||||
@ -0,0 +1,906 @@ |
|||||||
|
<template> |
||||||
|
<!-- 订单管理页面 --> |
||||||
|
<basic-container> |
||||||
|
<avue-crud |
||||||
|
:option="option" |
||||||
|
:table-loading="loading" |
||||||
|
:data="data" |
||||||
|
:page.sync="page" |
||||||
|
ref="crud" |
||||||
|
v-model="form" |
||||||
|
:permission="permissionList" |
||||||
|
:before-open="beforeOpen" |
||||||
|
@search-change="searchChange" |
||||||
|
@search-reset="searchReset" |
||||||
|
@selection-change="selectionChange" |
||||||
|
@current-change="currentChange" |
||||||
|
@size-change="sizeChange" |
||||||
|
@refresh-change="refreshChange" |
||||||
|
> |
||||||
|
<!-- <template slot-scope="scope" slot="materialSearch"> |
||||||
|
<el-select v-model="form.material" placeholder="请选择枕头类型"> |
||||||
|
<el-option |
||||||
|
v-for="item in materialData" |
||||||
|
:key="item.value" |
||||||
|
:label="item.label" |
||||||
|
:value="item.value" |
||||||
|
></el-option> |
||||||
|
</el-select> |
||||||
|
</template> --> |
||||||
|
<template slot-scope="scope" slot="nameSearch"> |
||||||
|
<el-input v-model="form.name" placeholder="请输入来访人姓名"></el-input> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="phonenumberSearch"> |
||||||
|
<el-input |
||||||
|
v-model="form.phonenumber" |
||||||
|
placeholder="请输入手机" |
||||||
|
></el-input> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="orderNumberSearch"> |
||||||
|
<el-input |
||||||
|
v-model="form.orderNumber" |
||||||
|
placeholder="请输入订单编号" |
||||||
|
></el-input> |
||||||
|
</template> |
||||||
|
<template slot-scope="{ row }" slot="menu"> |
||||||
|
<el-button size="small" @click="handleDetail(row)">查看详情</el-button> |
||||||
|
<!-- <el-button size="small" @click="handleDelete(row)">删除</el-button> --> |
||||||
|
<el-button :disabled='row.orderStatus == 1' size="small" @click="handleSend(row)">发货</el-button> |
||||||
|
</template> |
||||||
|
<!-- <template slot-scope="scope" slot="sleepingPosture"> |
||||||
|
<div v-show="scope.row.sleepingPosture == 1">仰睡</div> |
||||||
|
<div v-show="scope.row.sleepingPosture == 2">侧睡</div> |
||||||
|
</template> --> |
||||||
|
<template slot-scope="scope" slot="orderStatus"> |
||||||
|
<div v-show="scope.row.orderStatus == 1">已发货</div> |
||||||
|
<div v-show="scope.row.orderStatus == 0">未发货</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="menuLeft"> |
||||||
|
<el-button type="danger" size="small" @click="deleteItem" |
||||||
|
>删除</el-button |
||||||
|
> |
||||||
|
<el-button type="primary" size="small" @click="exportData" |
||||||
|
>导出</el-button |
||||||
|
> |
||||||
|
</template> |
||||||
|
</avue-crud> |
||||||
|
<el-dialog |
||||||
|
:visible.sync="dialogVisible" |
||||||
|
width="60%" |
||||||
|
:title="diaTitle" |
||||||
|
:append-to-body="true" |
||||||
|
custom-class="dis_class" |
||||||
|
center |
||||||
|
> |
||||||
|
<div class="basic_box" v-show="!isShowInfo"> |
||||||
|
<el-descriptions :column="2" class="margin-top" size="small" border> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">姓名</template> |
||||||
|
<div>{{ checkaccept.username }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">手机</template> |
||||||
|
<div>{{ checkaccept.phone }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">订单编号</template> |
||||||
|
<div>{{ checkaccept.orderNo }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label"> |
||||||
|
<div>地址</div> |
||||||
|
</template> |
||||||
|
<div style="width: 158px">{{ checkaccept.position }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">订单状态</template> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.orderStatus == 1 |
||||||
|
? "已发货" |
||||||
|
: checkaccept.orderStatus == 0 |
||||||
|
? "未发货" |
||||||
|
: "" |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
</el-descriptions> |
||||||
|
<div class="number_box" v-show="diaType == 'send'"> |
||||||
|
<p>请选择快递公司:</p> |
||||||
|
<el-select v-model="company"> |
||||||
|
<el-option v-for="item in companyData" :key="item.value" :value="item.value" :label="item.label"></el-option> |
||||||
|
</el-select> |
||||||
|
</div> |
||||||
|
<div class="number_box" v-show="diaType == 'send'"> |
||||||
|
<p>请输入快递单号:</p> |
||||||
|
<el-input></el-input> |
||||||
|
</div> |
||||||
|
<div class="info_box" v-show="diaType == 'view' && checkaccept.orderStatus == 1"> |
||||||
|
<p>物流信息:</p> |
||||||
|
<p class="info_view" @click="viewWiliu">查看物流信息</p> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
<div v-show="isShowInfo"> |
||||||
|
<el-timeline :reverse="false"> |
||||||
|
<el-timeline-item |
||||||
|
v-for="(activity, index) in activities" |
||||||
|
:key="index" |
||||||
|
:timestamp="activity.time" |
||||||
|
:color="activity.color"> |
||||||
|
<div> |
||||||
|
<p>{{activity.status == '揽收' ? '已揽件' : activity.status == '运输中' ? '运输中' : activity.status == '派件' ? '派件中' : activity.status == '投柜或驿站' ? '投柜或驿站' : ''}}</p> |
||||||
|
<p>{{activity.context}}</p> |
||||||
|
</div> |
||||||
|
|
||||||
|
</el-timeline-item> |
||||||
|
</el-timeline> |
||||||
|
</div> |
||||||
|
<span slot="footer" class="dialog-footer" v-show="diaType == 'send'"> |
||||||
|
<el-button type="primary" @click="dialogVisible = false">确 定</el-button> |
||||||
|
</span> |
||||||
|
<span slot="footer" class="dialog-footer" v-show="isShowInfo"> |
||||||
|
<el-button type="primary" @click="dialogVisible = false">关 闭</el-button> |
||||||
|
</span> |
||||||
|
</el-dialog> |
||||||
|
</basic-container> |
||||||
|
</template> |
||||||
|
|
||||||
|
<script> |
||||||
|
// import { mapGetters } from "vuex"; |
||||||
|
// import {getBaseList,getTypeList} from "@/api/base" |
||||||
|
import { |
||||||
|
getList, |
||||||
|
exportList, |
||||||
|
deleteList, |
||||||
|
detailList, |
||||||
|
} from "@/api/statistics/statistics"; |
||||||
|
import {getWuliuInfo} from "@/api/order/order" |
||||||
|
// import { getToken } from "@/util/auth"; |
||||||
|
import md5 from "js-md5"; |
||||||
|
export default { |
||||||
|
data() { |
||||||
|
return { |
||||||
|
activities: [{ |
||||||
|
status:'在途', |
||||||
|
content: '【昆明市】 快件已到达 昆明中转', |
||||||
|
time: '2023-08-15 15:30:16' |
||||||
|
}, { |
||||||
|
status:'在途', |
||||||
|
content: '【丽江市】 快件已发往 昆明中转', |
||||||
|
time: '2023-08-14 19:02:02' |
||||||
|
}, { |
||||||
|
status:'揽收', |
||||||
|
content: '【丽江市】 【丽江华坪县】(0888-8834031) 的 P1陈平(15108866686) 已揽收', |
||||||
|
time: '2023-08-14 19:01:18' |
||||||
|
}], |
||||||
|
active: "1", |
||||||
|
form: {}, |
||||||
|
dialogVisible: false, |
||||||
|
statusData: [ |
||||||
|
{ label: "待处理", value: "0" }, |
||||||
|
{ label: "正在处理", value: "1" }, |
||||||
|
{ label: "达成协议", value: "2" }, |
||||||
|
{ label: "调解成功", value: "3" }, |
||||||
|
], |
||||||
|
headers: { |
||||||
|
"Blade-Auth": "", |
||||||
|
}, //认证 |
||||||
|
listData: [], |
||||||
|
materialData: [ |
||||||
|
{ label: "羽丝绒枕", value: 1 }, |
||||||
|
{ label: "草本植物枕(荞麦、决明子等)", value: 2 }, |
||||||
|
{ label: "乳胶枕", value: 3 }, |
||||||
|
{ label: "慢回弹记忆枕", value: 4 }, |
||||||
|
{ label: "软管枕", value: 5 }, |
||||||
|
{ label: "其他", value: 6 }, |
||||||
|
], |
||||||
|
hardnessData: [ |
||||||
|
{ label: "偏硬", value: 1 }, |
||||||
|
{ label: "适中", value: 2 }, |
||||||
|
{ label: "偏软", value: 3 }, |
||||||
|
], |
||||||
|
checkaccept: {}, |
||||||
|
query: {}, |
||||||
|
loading: true, |
||||||
|
page: { |
||||||
|
pageSize: 10, |
||||||
|
currentPage: 1, |
||||||
|
total: 0, |
||||||
|
}, |
||||||
|
selectionList: [], |
||||||
|
option: { |
||||||
|
selection: true, |
||||||
|
searchShowBtn: false, |
||||||
|
refreshBtn: false, |
||||||
|
columnBtn: false, |
||||||
|
height: "auto", |
||||||
|
calcHeight: 30, |
||||||
|
tip: false, |
||||||
|
searchShow: true, |
||||||
|
searchMenuSpan: 4, |
||||||
|
searchSpan: 6, |
||||||
|
border: false, |
||||||
|
addBtn: false, |
||||||
|
viewBtn: false, |
||||||
|
editBtn: false, |
||||||
|
delBtn: false, |
||||||
|
column: [ |
||||||
|
{ |
||||||
|
label: "姓名", |
||||||
|
prop: "name", |
||||||
|
search: true, |
||||||
|
searchslot: true, |
||||||
|
hide: true, |
||||||
|
// searchSpan: 4, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "手机", |
||||||
|
prop: "phonenumber", |
||||||
|
search: true, |
||||||
|
searchslot: true, |
||||||
|
hide: true, |
||||||
|
// searchSpan: 4, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "订单编号", |
||||||
|
prop: "orderNumber", |
||||||
|
search: true, |
||||||
|
searchslot: true, |
||||||
|
hide: true, |
||||||
|
// searchSpan: 4, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "姓名", |
||||||
|
prop: "username", |
||||||
|
align: "center", |
||||||
|
overHidden:true, |
||||||
|
width:80, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "手机", |
||||||
|
overHidden:true, |
||||||
|
width:150, |
||||||
|
prop: "phone", |
||||||
|
align: "center", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "订单编号", |
||||||
|
prop: "orderNo", |
||||||
|
align: "center", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "地址", |
||||||
|
overHidden:true, |
||||||
|
prop: "position", |
||||||
|
slot:true, |
||||||
|
align: "center", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "订单状态", |
||||||
|
slot:true, |
||||||
|
prop: "orderStatus", |
||||||
|
align: "center", |
||||||
|
} |
||||||
|
], |
||||||
|
}, |
||||||
|
ageData: [ |
||||||
|
{ label: "18~30", value: "18~30" }, |
||||||
|
{ label: "31~50", value: "31~50" }, |
||||||
|
{ label: "51~60", value: "51~60" }, |
||||||
|
{ label: "60以上", value: "60以上" }, |
||||||
|
], |
||||||
|
data: [], |
||||||
|
time: "", |
||||||
|
date: "", |
||||||
|
isWinDis: false, |
||||||
|
formData: [ |
||||||
|
{ |
||||||
|
label: "姓名", |
||||||
|
key: "username", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
isSearch:true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "手机", |
||||||
|
key: "phone", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
validateFunction: /^1(3|4|5|6|7|8|9)\d{9}$/, |
||||||
|
isSearch:true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "地区", |
||||||
|
formType: "picker", |
||||||
|
province: "", |
||||||
|
city: "", |
||||||
|
district: "", |
||||||
|
locationArr: "", |
||||||
|
multiIndex: [0, 0, 0], |
||||||
|
key: "position", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "身高", |
||||||
|
key: "height", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "体重", |
||||||
|
key: "weight", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "肩颈宽度", |
||||||
|
key: "neckShoulderWidth", |
||||||
|
formType: "input", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "颈长", |
||||||
|
key: "neckLength", |
||||||
|
formType: "input", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "年龄", |
||||||
|
key: "ageRange", |
||||||
|
formType: "select", |
||||||
|
isSearch:true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
label: "18~30", |
||||||
|
value: "18~30", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "31~50", |
||||||
|
value: "31~50", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "51~60", |
||||||
|
value: "51~60", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "60以上", |
||||||
|
value: "60以上", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您每晚的睡眠时间", |
||||||
|
key: "sleepLength", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "2~4小时", |
||||||
|
value: "2~4小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "4~6小时", |
||||||
|
value: "4~6小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "6~8小时", |
||||||
|
value: "6~8小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "8小时以上", |
||||||
|
value: "8小时以上", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的睡眠姿势", |
||||||
|
key: "sleepLength", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "仰睡", |
||||||
|
value: 1, |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "侧睡", |
||||||
|
value: 2, |
||||||
|
}, |
||||||
|
], |
||||||
|
imgData: [ |
||||||
|
{ text: "仰睡", img: "../../../static/image/yang.jpg" }, |
||||||
|
{ text: "侧睡", img: "../../../static/image/ce.jpg" }, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的枕头软硬度", |
||||||
|
key: "pillowHardness", |
||||||
|
formType: "check", |
||||||
|
required: true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "偏硬", |
||||||
|
value: "1", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "适中", |
||||||
|
value: "2", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "偏软", |
||||||
|
value: "3", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的枕头类型", |
||||||
|
key: "pillowMaterial", |
||||||
|
formType: "check", |
||||||
|
required: true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "羽丝绒枕", |
||||||
|
value: "1", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "草本植物枕(荞麦、决明子等)", |
||||||
|
value: "2", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "乳胶枕", |
||||||
|
value: "3", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "慢回弹记忆枕", |
||||||
|
value: "4", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "软管枕", |
||||||
|
value: "5", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "其他", |
||||||
|
value: "6", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您现在的颈椎出现问题了吗", |
||||||
|
key: "cervicalVertebra", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "是", |
||||||
|
value: 1, |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "否", |
||||||
|
value: 0, |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您的其他需求", |
||||||
|
key: "workcontent", |
||||||
|
formType: "textarea", |
||||||
|
}, |
||||||
|
], |
||||||
|
diaType:'', |
||||||
|
diaTitle:'', |
||||||
|
isShowInfo:false, |
||||||
|
companyData:[ |
||||||
|
{value:'yuantong',label:'圆通'}, |
||||||
|
{value:'shentong',label:'申通'}, |
||||||
|
{value:'zhongtong',label:'中通'}, |
||||||
|
], |
||||||
|
company:'' |
||||||
|
}; |
||||||
|
}, |
||||||
|
computed: { |
||||||
|
// ...mapGetters(["permission","userInfo"]), |
||||||
|
ids() { |
||||||
|
let ids = []; |
||||||
|
this.selectionList.forEach((ele) => { |
||||||
|
ids.push(ele.id); |
||||||
|
}); |
||||||
|
return ids.join(","); |
||||||
|
}, |
||||||
|
}, |
||||||
|
created() { |
||||||
|
// this.headers["Blade-Auth"] = "bearer " + getToken(); |
||||||
|
// this.getTime(); |
||||||
|
// this.getWinData(); |
||||||
|
// this.getTypeData(); |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
methods: { |
||||||
|
sizeChange(pageSize) { |
||||||
|
this.page.pageSize = pageSize; |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
handleDetail(row) { |
||||||
|
this.isShowInfo = false |
||||||
|
this.diaType="view"; |
||||||
|
this.diaTitle = '查看详情' |
||||||
|
this.dialogVisible = true; |
||||||
|
this.checkaccept = row; |
||||||
|
// detailList({ id: row.id }).then((res) => { |
||||||
|
// console.log(res); |
||||||
|
// this.checkaccept = res.data.data; |
||||||
|
// this.checkaccept.position = |
||||||
|
// this.checkaccept.province + |
||||||
|
// this.checkaccept.city + |
||||||
|
// this.checkaccept.district + |
||||||
|
// this.checkaccept.detail; |
||||||
|
// }); |
||||||
|
}, |
||||||
|
// 发货页面弹窗 |
||||||
|
handleSend(row){ |
||||||
|
this.dialogVisible = true; |
||||||
|
this.isShowInfo = false |
||||||
|
this.diaTitle = '发货' |
||||||
|
this.diaType="send" |
||||||
|
detailList({ id: row.id }).then((res) => { |
||||||
|
console.log(res); |
||||||
|
this.checkaccept = res.data.data; |
||||||
|
this.checkaccept.position = |
||||||
|
this.checkaccept.province + |
||||||
|
this.checkaccept.city + |
||||||
|
this.checkaccept.district + |
||||||
|
this.checkaccept.detail; |
||||||
|
}); |
||||||
|
}, |
||||||
|
// 查看物流信息 |
||||||
|
viewWiliu(){ |
||||||
|
this.isShowInfo = true |
||||||
|
let param = { |
||||||
|
customer: "1C32AD38DC92D3A1950391AD766C7F6D", |
||||||
|
sign: "", |
||||||
|
param: JSON.stringify({ |
||||||
|
"com": 'zhongtong', |
||||||
|
"num": '78713552736238', |
||||||
|
"phone": '17852327323', |
||||||
|
"from": "", |
||||||
|
"to": "", |
||||||
|
"resultv2": "4", |
||||||
|
"show": "0", |
||||||
|
"order": "desc" |
||||||
|
}) |
||||||
|
} |
||||||
|
param.sign = md5(param.param + 'ubdRnSOv5517' + param.customer).toUpperCase(); |
||||||
|
this.activities = [ |
||||||
|
{ |
||||||
|
status:'投柜或驿站', |
||||||
|
context: '【青岛市】 快件已被 菜鸟的【青岛康泰源惠客友超市店】代收,【取件地址:青岛康泰源惠客友超市店】,请及时取件。如有疑问请联系:15805321109,投诉电话:0532-88985563', |
||||||
|
time: '2023-08-18 10:33:33' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'派件', |
||||||
|
context: '【青岛市】青岛市中五二部(0532-88985563)业务员【杨金梅,19106394524】正在为您派件(95720为中通快递员外呼专属号码,请放心接听,如有问题可联系投诉电话:0532-88985563)', |
||||||
|
time: '2023-08-18 08:08:38' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'在途', |
||||||
|
context: '【青岛市】 快件已到达 青岛市中五二部', |
||||||
|
time: '2023-08-18 08:08:33' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'在途', |
||||||
|
context: '【青岛市】 快件已发往 青岛市中五二部', |
||||||
|
time: '2023-08-18 04:36:56' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'在途', |
||||||
|
context: '【青岛市】 快件已到达 青岛中转部', |
||||||
|
time: '2023-08-18 01:04:40' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'在途', |
||||||
|
context: '【昆明市】 快件已发往 青岛中转部', |
||||||
|
time: '2023-08-16 00:51:30' |
||||||
|
}, |
||||||
|
{ |
||||||
|
status:'在途', |
||||||
|
context: '【昆明市】 快件已到达 昆明中转', |
||||||
|
time: '2023-08-15 15:30:16' |
||||||
|
}, { |
||||||
|
status:'在途', |
||||||
|
context: '【丽江市】 快件已发往 昆明中转', |
||||||
|
time: '2023-08-14 19:02:02' |
||||||
|
}, { |
||||||
|
status:'揽收', |
||||||
|
context: '【丽江市】 【丽江华坪县】(0888-8834031) 的 P1陈平(15108866686) 已揽收', |
||||||
|
time: '2023-08-14 19:01:18' |
||||||
|
}], |
||||||
|
this.activities[0].status = this.activities[0].status == '在途' ? '运输中' : this.activities[0].status |
||||||
|
this.activities[0].color = '#0bbd87' |
||||||
|
console.log(this.activities) |
||||||
|
// getWuliuInfo(param).then(res =>{ |
||||||
|
// console.log(res) |
||||||
|
// this.activities = res.data.data |
||||||
|
// }) |
||||||
|
}, |
||||||
|
selectionChange(data) { |
||||||
|
this.selectionList = data; |
||||||
|
}, |
||||||
|
currentChange(currentPage) { |
||||||
|
this.page.currentPage = currentPage; |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
getWinData() { |
||||||
|
getBaseList().then((res) => { |
||||||
|
this.winData = res.data.data; |
||||||
|
let tmp = this.winData.find((item) => item.id == this.userInfo.user_id); |
||||||
|
if (tmp) { |
||||||
|
this.form.windows = tmp.id; |
||||||
|
this.isWinDis = true; |
||||||
|
} |
||||||
|
}); |
||||||
|
}, |
||||||
|
getTypeData() { |
||||||
|
getTypeList().then((res) => { |
||||||
|
this.typeData = res.data.data; |
||||||
|
}); |
||||||
|
}, |
||||||
|
handleList(row) { |
||||||
|
console.log(row); |
||||||
|
this.dialogVisible = true; |
||||||
|
getResolveList({ appealId: row.id }).then((res) => { |
||||||
|
console.log("res", res); |
||||||
|
this.listData = res.data.data; |
||||||
|
}); |
||||||
|
}, |
||||||
|
searchReset() { |
||||||
|
this.query = {}; |
||||||
|
this.form = {}; |
||||||
|
this.onLoad(this.page); |
||||||
|
}, |
||||||
|
searchChange(params, done) { |
||||||
|
console.log(params) |
||||||
|
this.form = params |
||||||
|
console.log(this.form); |
||||||
|
|
||||||
|
this.query = this.form; |
||||||
|
this.page.currentPage = 1; |
||||||
|
this.onLoad(this.page, this.form); |
||||||
|
done(); |
||||||
|
}, |
||||||
|
handleSuccess(res) { |
||||||
|
console.log(res); |
||||||
|
if (res.code == 200) { |
||||||
|
this.$message.success("上传成功"); |
||||||
|
} |
||||||
|
}, |
||||||
|
fn(str) { |
||||||
|
let num = null; |
||||||
|
str >= 10 ? (num = str) : (num = "0" + str); |
||||||
|
return num; |
||||||
|
}, |
||||||
|
getTime() { |
||||||
|
//获取当前时间 |
||||||
|
var date = new Date(); |
||||||
|
var year = date.getFullYear(); //当前年份 |
||||||
|
var month = date.getMonth(); //当前月份 |
||||||
|
var data = date.getDate(); //天 |
||||||
|
var hours = date.getHours(); //小时 |
||||||
|
var minute = date.getMinutes(); //分 |
||||||
|
var second = date.getSeconds(); //秒 |
||||||
|
this.day = date.getDay(); //获取当前星期几 |
||||||
|
// this.getWeek(this.day); |
||||||
|
this.time = this.fn(hours) + ":" + this.fn(minute); |
||||||
|
this.date = year + "-" + (month + 1) + "-" + data; |
||||||
|
}, |
||||||
|
onLoad() { |
||||||
|
let params = {}; |
||||||
|
// params = { |
||||||
|
// username:this.form.name ? this.form.name : '', |
||||||
|
// phone:this.form.phonenumber ? this.form.phonenumber : '', |
||||||
|
// pillowHardness:this.form.hardness ? this.form.hardness : '', |
||||||
|
// pillowMaterial:this.form.material ? this.form.material : '' |
||||||
|
// } |
||||||
|
|
||||||
|
if (!this.form.timeArr) { |
||||||
|
params = { |
||||||
|
username: this.form.username ? this.form.username : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.ageRange ? this.form.ageRange : "", |
||||||
|
}; |
||||||
|
} else { |
||||||
|
params = { |
||||||
|
username: this.form.username ? this.form.username : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.ageRange ? this.form.ageRange : "", |
||||||
|
startTime: this.form.timeArr[0], |
||||||
|
endTime: this.form.timeArr[1], |
||||||
|
}; |
||||||
|
} |
||||||
|
console.log("par", params); |
||||||
|
|
||||||
|
// getList({ |
||||||
|
// current: this.page.currentPage, |
||||||
|
// size: this.page.pageSize, |
||||||
|
// ...params, |
||||||
|
// }).then((res) => { |
||||||
|
// console.log("res==>", res); |
||||||
|
// this.loading = false; |
||||||
|
// this.data = res.data.data.records; |
||||||
|
// this.page.total = res.data.data.total; |
||||||
|
// }); |
||||||
|
this.data = [ |
||||||
|
{username:'张大仙',phone:'13201241125',orderNo:'321456789520',position:'山东省青岛市市南区香港中路',orderStatus:'0'}, |
||||||
|
{username:'张伟',phone:'13201241125',orderNo:'321456789520',position:'山东省青岛市市南区香港中路',orderStatus:'1'}, |
||||||
|
{username:'王五',phone:'13201241125',orderNo:'321456789520',position:'山东省青岛市市南区香港中路',orderStatus:'0'}, |
||||||
|
{username:'张三',phone:'13201241125',orderNo:'321456789520',position:'山东省青岛市市南区香港中路',orderStatus:'0'}, |
||||||
|
{username:'李四',phone:'13201241125',orderNo:'321456789520',position:'山东省青岛市市南区香港中路',orderStatus:'0'}, |
||||||
|
] |
||||||
|
this.loading = false; |
||||||
|
}, |
||||||
|
addRegister() { |
||||||
|
this.$router.push({ path: "/register/add", query: { type: "add" } }); |
||||||
|
}, |
||||||
|
exportData() { |
||||||
|
let params = {}; |
||||||
|
if (!this.form.timeArr) { |
||||||
|
params = { |
||||||
|
username: this.form.name ? this.form.name : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.age ? this.form.age : "", |
||||||
|
}; |
||||||
|
} else { |
||||||
|
params = { |
||||||
|
username: this.form.name ? this.form.name : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.age ? this.form.age : "", |
||||||
|
startTime: this.form.timeArr[0], |
||||||
|
endTime: this.form.timeArr[1], |
||||||
|
}; |
||||||
|
} |
||||||
|
exportList(params).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (!res || !res.data) { |
||||||
|
this.$message({ |
||||||
|
type: "error", |
||||||
|
message: "导出失败!", |
||||||
|
}); |
||||||
|
return; |
||||||
|
} |
||||||
|
let blob = new Blob([res.data]); //response.data为后端传的流文件 |
||||||
|
let downloadFilename = "统计" + ".xlsx"; //设置导出的文件名 |
||||||
|
if (window.navigator && window.navigator.msSaveOrOpenBlob) { |
||||||
|
//兼容ie浏览器 |
||||||
|
window.navigator.msSaveOrOpenBlob(blob, downloadFilename); |
||||||
|
} else { |
||||||
|
//谷歌,火狐等浏览器 |
||||||
|
let url = window.URL.createObjectURL(blob); |
||||||
|
let downloadElement = document.createElement("a"); |
||||||
|
downloadElement.style.display = "none"; |
||||||
|
downloadElement.href = url; |
||||||
|
downloadElement.download = downloadFilename; |
||||||
|
document.body.appendChild(downloadElement); |
||||||
|
downloadElement.click(); |
||||||
|
document.body.removeChild(downloadElement); |
||||||
|
window.URL.revokeObjectURL(url); |
||||||
|
} |
||||||
|
this.$message({ type: "success", message: "导出成功!" }); |
||||||
|
}); |
||||||
|
}, |
||||||
|
deleteItem() { |
||||||
|
if (this.selectionList.length == 0) { |
||||||
|
this.$message.warning("请至少选择一条数据"); |
||||||
|
return; |
||||||
|
} |
||||||
|
this.$confirm(`确认删除当前数据吗?`, { |
||||||
|
confirmButtonText: "确定", |
||||||
|
cancelButtonText: "取消", |
||||||
|
type: "warning", |
||||||
|
}).then(() => { |
||||||
|
deleteList(this.ids).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (res.data.code == 200) { |
||||||
|
this.$message.success("删除成功"); |
||||||
|
this.page.pageSize = 1; |
||||||
|
this.onLoad(); |
||||||
|
} |
||||||
|
}); |
||||||
|
}); |
||||||
|
}, |
||||||
|
importRegister() {}, |
||||||
|
handleEdit() { |
||||||
|
this.$router.push({ path: "/request/add" }); |
||||||
|
}, |
||||||
|
handleDelete(row) { |
||||||
|
this.$confirm(`确认删除当前数据吗?`, { |
||||||
|
confirmButtonText: "确定", |
||||||
|
cancelButtonText: "取消", |
||||||
|
type: "warning", |
||||||
|
}).then(() => { |
||||||
|
deleteList(row.id).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (res.data.code == 200) { |
||||||
|
this.$message.success("删除成功"); |
||||||
|
this.page.currentPage = 1; |
||||||
|
this.onLoad(); |
||||||
|
} |
||||||
|
}); |
||||||
|
}); |
||||||
|
}, |
||||||
|
}, |
||||||
|
}; |
||||||
|
</script> |
||||||
|
|
||||||
|
<style lang="scss"> |
||||||
|
.resi_list { |
||||||
|
.list { |
||||||
|
width: 80%; |
||||||
|
max-height: 246px; |
||||||
|
overflow-y: auto; |
||||||
|
|
||||||
|
.list_box { |
||||||
|
width: 100%; |
||||||
|
height: 41px; |
||||||
|
font-size: 20px; |
||||||
|
display: flex; |
||||||
|
align-items: center; |
||||||
|
|
||||||
|
& :hover { |
||||||
|
cursor: pointer; |
||||||
|
// .time_txt{ |
||||||
|
color: #4095e5; |
||||||
|
|
||||||
|
// } |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
.upload-demo { |
||||||
|
float: right; |
||||||
|
} |
||||||
|
</style> |
||||||
|
<style lang="scss"> |
||||||
|
.dis_class { |
||||||
|
.el-dialog__body{ |
||||||
|
height: 500px; |
||||||
|
overflow-y:auto ; |
||||||
|
} |
||||||
|
.is-bordered-label { |
||||||
|
width: 15% !important; |
||||||
|
} |
||||||
|
.el-descriptions .is-bordered .el-descriptions-item__cell { |
||||||
|
width: 35%; |
||||||
|
height: 50px; |
||||||
|
} |
||||||
|
.number_box{ |
||||||
|
width: 100%; |
||||||
|
display: flex; |
||||||
|
align-items: center; |
||||||
|
margin-top: 20px; |
||||||
|
|
||||||
|
.el-input{ |
||||||
|
width: 400px; |
||||||
|
} |
||||||
|
} |
||||||
|
.info_box{ |
||||||
|
width: 100%; |
||||||
|
display: flex; |
||||||
|
align-items: center; |
||||||
|
margin-top: 20px; |
||||||
|
|
||||||
|
.info_view{ |
||||||
|
margin-left: 10px; |
||||||
|
|
||||||
|
&:hover{ |
||||||
|
color: blue; |
||||||
|
cursor: pointer; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
.el-dialog__footer{ |
||||||
|
text-align: right !important; |
||||||
|
} |
||||||
|
} |
||||||
|
</style> |
||||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,984 @@ |
|||||||
|
<template> |
||||||
|
<basic-container> |
||||||
|
<avue-crud |
||||||
|
:option="option" |
||||||
|
:table-loading="loading" |
||||||
|
:data="data" |
||||||
|
:page.sync="page" |
||||||
|
ref="crud" |
||||||
|
v-model="form" |
||||||
|
:permission="permissionList" |
||||||
|
:before-open="beforeOpen" |
||||||
|
@search-change="searchChange" |
||||||
|
@search-reset="searchReset" |
||||||
|
@selection-change="selectionChange" |
||||||
|
@current-change="currentChange" |
||||||
|
@size-change="sizeChange" |
||||||
|
@refresh-change="refreshChange" |
||||||
|
> |
||||||
|
<!-- <template slot-scope="scope" slot="materialSearch"> |
||||||
|
<el-select v-model="form.material" placeholder="请选择枕头类型"> |
||||||
|
<el-option |
||||||
|
v-for="item in materialData" |
||||||
|
:key="item.value" |
||||||
|
:label="item.label" |
||||||
|
:value="item.value" |
||||||
|
></el-option> |
||||||
|
</el-select> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="ageSearch"> |
||||||
|
<el-select v-model="form.age" placeholder="请选择年龄范围"> |
||||||
|
<el-option |
||||||
|
v-for="item in ageData" |
||||||
|
:key="item.value" |
||||||
|
:label="item.label" |
||||||
|
:value="item.value" |
||||||
|
></el-option> |
||||||
|
</el-select> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="timeArrSearch"> |
||||||
|
<el-date-picker |
||||||
|
v-model="form.timeArr" |
||||||
|
type="daterange" |
||||||
|
range-separator="至" |
||||||
|
start-placeholder="开始日期" |
||||||
|
end-placeholder="结束日期" |
||||||
|
value-format="yyyy-MM-dd" |
||||||
|
format="yyyy-MM-dd" |
||||||
|
> |
||||||
|
</el-date-picker> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="hardnessSearch"> |
||||||
|
<el-select |
||||||
|
v-model="form.hardness" |
||||||
|
placeholder="请选择软硬程度" |
||||||
|
:disabled="isWinDis" |
||||||
|
> |
||||||
|
<el-option |
||||||
|
v-for="item in hardnessData" |
||||||
|
:key="item.value" |
||||||
|
:label="item.label" |
||||||
|
:value="item.value" |
||||||
|
></el-option> |
||||||
|
</el-select> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="nameSearch"> |
||||||
|
<el-input v-model="form.name" placeholder="请输入来访人姓名"></el-input> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="phonenumberSearch"> |
||||||
|
<el-input |
||||||
|
v-model="form.phonenumber" |
||||||
|
placeholder="请输入手机" |
||||||
|
></el-input> |
||||||
|
</template> --> |
||||||
|
<template slot-scope="{ row }" slot="menu"> |
||||||
|
<el-button size="small" @click="handleDetail(row)">查看详情</el-button> |
||||||
|
<el-button size="small" @click="handleDelete(row)">删除</el-button> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="sleepingPosture"> |
||||||
|
<div v-show="scope.row.sleepingPosture == 1">仰睡</div> |
||||||
|
<div v-show="scope.row.sleepingPosture == 2">侧睡</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="neckShoulderWidth"> |
||||||
|
<div v-show="scope.row.neckShoulderWidth != '-1'"> |
||||||
|
{{ scope.row.neckShoulderWidth }} |
||||||
|
</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="neckLength"> |
||||||
|
<div v-show="scope.row.neckLength != '-1'"> |
||||||
|
{{ scope.row.neckLength }} |
||||||
|
</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="cervicalVertebra"> |
||||||
|
<div v-show="scope.row.cervicalVertebra == 1">是</div> |
||||||
|
<div v-show="scope.row.cervicalVertebra == 0">否</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="pillowHardness"> |
||||||
|
<div v-show="scope.row.pillowHardness == 1">偏硬</div> |
||||||
|
<div v-show="scope.row.pillowHardness == 2">适中</div> |
||||||
|
<div v-show="scope.row.pillowHardness == 3">偏软</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="pillowMaterial"> |
||||||
|
<div v-show="scope.row.pillowMaterial == 1">羽丝绒枕</div> |
||||||
|
<div v-show="scope.row.pillowMaterial == 2"> |
||||||
|
草本植物枕(荞麦、决明子等) |
||||||
|
</div> |
||||||
|
<div v-show="scope.row.pillowMaterial == 3">乳胶枕</div> |
||||||
|
<div v-show="scope.row.pillowMaterial == 4">慢回弹记忆枕</div> |
||||||
|
<div v-show="scope.row.pillowMaterial == 5">软管枕</div> |
||||||
|
<div v-show="scope.row.pillowMaterial == 6">其他</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="finishTime"> |
||||||
|
<div> |
||||||
|
{{ scope.row.finishTime !== "" ? scope.row.finishTime : "---/-/---" }} |
||||||
|
</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="position"> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
(scope.row.province ? scope.row.province : "") + |
||||||
|
(scope.row.city ? scope.row.city : "") + |
||||||
|
(scope.row.district ? scope.row.district : "") + |
||||||
|
(scope.row.detail ? scope.row.detail : "") |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</template> |
||||||
|
<template slot-scope="scope" slot="menuLeft"> |
||||||
|
<el-button type="danger" size="small" @click="deleteItem" |
||||||
|
>删除</el-button |
||||||
|
> |
||||||
|
<el-button type="primary" size="small" @click="exportData" |
||||||
|
>导出</el-button |
||||||
|
> |
||||||
|
</template> |
||||||
|
</avue-crud> |
||||||
|
<el-dialog |
||||||
|
:visible.sync="dialogVisible" |
||||||
|
width="60%" |
||||||
|
title="查看详情" |
||||||
|
:append-to-body="true" |
||||||
|
custom-class="dis_class" |
||||||
|
center |
||||||
|
> |
||||||
|
<el-descriptions :column="2" class="margin-top" size="small" border> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">姓名</template> |
||||||
|
<div>{{ checkaccept.username }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">手机</template> |
||||||
|
<div>{{ checkaccept.phone }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">身高</template> |
||||||
|
<div>{{ checkaccept.height }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label"> |
||||||
|
<div>体重</div> |
||||||
|
</template> |
||||||
|
<div>{{ checkaccept.weight }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label"> |
||||||
|
<div>地址</div> |
||||||
|
</template> |
||||||
|
<div style="width: 158px">{{ checkaccept.position }}</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">睡眠姿势</template> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.sleepingPosture == 1 |
||||||
|
? "仰睡" |
||||||
|
: checkaccept.sleepingPosture == 2 |
||||||
|
? "侧睡" |
||||||
|
: "" |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">枕头软硬度</template> |
||||||
|
<div> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.pillowHardness == 1 |
||||||
|
? "偏硬" |
||||||
|
: checkaccept.pillowHardness == 2 |
||||||
|
? "适中" |
||||||
|
: checkaccept.pillowHardness == 3 |
||||||
|
? "偏软" |
||||||
|
: "" |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">枕头类型</template> |
||||||
|
<div> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.pillowMaterial == 1 |
||||||
|
? "羽丝绒枕" |
||||||
|
: checkaccept.pillowMaterial == 2 |
||||||
|
? "草本植物枕(荞麦、决明子等)" |
||||||
|
: checkaccept.pillowMaterial == 3 |
||||||
|
? "乳胶枕" |
||||||
|
: checkaccept.pillowMaterial == 4 |
||||||
|
? "慢回弹记忆枕" |
||||||
|
: checkaccept.pillowMaterial == 5 |
||||||
|
? "软管枕" |
||||||
|
: checkaccept.pillowMaterial == 6 |
||||||
|
? "其他" |
||||||
|
: "" |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">颈肩宽度</template> |
||||||
|
<div> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.neckShoulderWidth == "-1" |
||||||
|
? "" |
||||||
|
: checkaccept.neckShoulderWidth |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">颈长</template> |
||||||
|
<div> |
||||||
|
<div> |
||||||
|
{{ checkaccept.neckLength == "-1" ? "" : checkaccept.neckLength }} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">年龄范围</template> |
||||||
|
<div> |
||||||
|
<div>{{ checkaccept.ageRange }}</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">睡眠时长</template> |
||||||
|
<div> |
||||||
|
<div>{{ checkaccept.sleepLength }}</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">颈椎是否有问题</template> |
||||||
|
<div> |
||||||
|
<div> |
||||||
|
{{ |
||||||
|
checkaccept.cervicalVertebra == 1 |
||||||
|
? "是" |
||||||
|
: checkaccept.cervicalVertebra == 0 |
||||||
|
? "否" |
||||||
|
: "" |
||||||
|
}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
<el-descriptions-item> |
||||||
|
<template slot="label">其他需求</template> |
||||||
|
<div> |
||||||
|
<div>{{ checkaccept.otherNeed }}</div> |
||||||
|
</div> |
||||||
|
</el-descriptions-item> |
||||||
|
</el-descriptions> |
||||||
|
</el-dialog> |
||||||
|
</basic-container> |
||||||
|
</template> |
||||||
|
|
||||||
|
<script> |
||||||
|
// import { mapGetters } from "vuex"; |
||||||
|
// import {getBaseList,getTypeList} from "@/api/base" |
||||||
|
import { |
||||||
|
getList, |
||||||
|
exportList, |
||||||
|
deleteList, |
||||||
|
detailList, |
||||||
|
} from "@/api/statistics/statistics"; |
||||||
|
// import { getToken } from "@/util/auth"; |
||||||
|
export default { |
||||||
|
data() { |
||||||
|
return { |
||||||
|
active: "1", |
||||||
|
form: {}, |
||||||
|
dialogVisible: false, |
||||||
|
statusData: [ |
||||||
|
{ label: "待处理", value: "0" }, |
||||||
|
{ label: "正在处理", value: "1" }, |
||||||
|
{ label: "达成协议", value: "2" }, |
||||||
|
{ label: "调解成功", value: "3" }, |
||||||
|
], |
||||||
|
headers: { |
||||||
|
"Blade-Auth": "", |
||||||
|
}, //认证 |
||||||
|
listData: [], |
||||||
|
materialData: [ |
||||||
|
{ label: "羽丝绒枕", value: 1 }, |
||||||
|
{ label: "草本植物枕(荞麦、决明子等)", value: 2 }, |
||||||
|
{ label: "乳胶枕", value: 3 }, |
||||||
|
{ label: "慢回弹记忆枕", value: 4 }, |
||||||
|
{ label: "软管枕", value: 5 }, |
||||||
|
{ label: "其他", value: 6 }, |
||||||
|
], |
||||||
|
hardnessData: [ |
||||||
|
{ label: "偏硬", value: 1 }, |
||||||
|
{ label: "适中", value: 2 }, |
||||||
|
{ label: "偏软", value: 3 }, |
||||||
|
], |
||||||
|
checkaccept: {}, |
||||||
|
query: {}, |
||||||
|
loading: true, |
||||||
|
page: { |
||||||
|
pageSize: 10, |
||||||
|
currentPage: 1, |
||||||
|
total: 0, |
||||||
|
}, |
||||||
|
selectionList: [], |
||||||
|
option: { |
||||||
|
selection: true, |
||||||
|
searchShowBtn: false, |
||||||
|
refreshBtn: false, |
||||||
|
columnBtn: false, |
||||||
|
height: "auto", |
||||||
|
calcHeight: 30, |
||||||
|
tip: false, |
||||||
|
searchShow: true, |
||||||
|
searchMenuSpan: 4, |
||||||
|
searchSpan: 6, |
||||||
|
border: false, |
||||||
|
addBtn: false, |
||||||
|
viewBtn: false, |
||||||
|
editBtn: false, |
||||||
|
delBtn: false, |
||||||
|
column: [], |
||||||
|
// column: [ |
||||||
|
// { |
||||||
|
// label: "姓名", |
||||||
|
// prop: "name", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 4, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "手机", |
||||||
|
// prop: "phonenumber", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 4, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "枕头类型", |
||||||
|
// prop: "material", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 4, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "软硬度", |
||||||
|
// prop: "hardness", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 5, |
||||||
|
// // searchLabelWidth:100 |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "年龄范围", |
||||||
|
// prop: "age", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 5, |
||||||
|
// // searchLabelWidth:100 |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "提交时间", |
||||||
|
// prop: "timeArr", |
||||||
|
// search: true, |
||||||
|
// searchslot: true, |
||||||
|
// hide: true, |
||||||
|
// // searchSpan: 5, |
||||||
|
// // searchLabelWidth:100 |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "姓名", |
||||||
|
// prop: "username", |
||||||
|
// align: "center", |
||||||
|
// overHidden:true, |
||||||
|
// width:80, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "手机", |
||||||
|
// overHidden:true, |
||||||
|
// width:150, |
||||||
|
// prop: "phone", |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "身高", |
||||||
|
// prop: "height", |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "体重", |
||||||
|
// overHidden:true, |
||||||
|
// prop: "weight", |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "地址", |
||||||
|
// overHidden:true, |
||||||
|
// prop: "position", |
||||||
|
// slot:true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "睡眠姿势", |
||||||
|
// slot:true, |
||||||
|
// prop: "sleepingPosture", |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "枕头软硬度", |
||||||
|
// overHidden:true, |
||||||
|
// prop: "pillowHardness", |
||||||
|
// align: "center", |
||||||
|
// slot:true, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "枕头类型", |
||||||
|
// prop: "pillowMaterial", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// overHidden:true |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "颈肩宽度", |
||||||
|
// prop: "neckShoulderWidth", |
||||||
|
// align: "center", |
||||||
|
// overHidden:true, |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "颈长", |
||||||
|
// prop: "neckLength", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "年龄范围", |
||||||
|
// prop: "ageRange", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "睡眠时长", |
||||||
|
// prop: "sleepLength", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "颈椎是否有问题", |
||||||
|
// prop: "cervicalVertebra", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label: "其他需求", |
||||||
|
// prop: "otherNeed", |
||||||
|
// slot: true, |
||||||
|
// align: "center", |
||||||
|
// }, |
||||||
|
// { |
||||||
|
// label:'提交时间', |
||||||
|
// prop:'createTime', |
||||||
|
// align:'center', |
||||||
|
// overHidden:true |
||||||
|
// }, |
||||||
|
|
||||||
|
// ], |
||||||
|
}, |
||||||
|
ageData: [ |
||||||
|
{ label: "18~30", value: "18~30" }, |
||||||
|
{ label: "31~50", value: "31~50" }, |
||||||
|
{ label: "51~60", value: "51~60" }, |
||||||
|
{ label: "60以上", value: "60以上" }, |
||||||
|
], |
||||||
|
data: [], |
||||||
|
time: "", |
||||||
|
date: "", |
||||||
|
isWinDis: false, |
||||||
|
formData: [ |
||||||
|
{ |
||||||
|
label: "姓名", |
||||||
|
key: "username", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
isSearch:true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "手机", |
||||||
|
key: "phone", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
validateFunction: /^1(3|4|5|6|7|8|9)\d{9}$/, |
||||||
|
isSearch:true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "地区", |
||||||
|
formType: "picker", |
||||||
|
province: "", |
||||||
|
city: "", |
||||||
|
district: "", |
||||||
|
locationArr: "", |
||||||
|
multiIndex: [0, 0, 0], |
||||||
|
key: "position", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "身高", |
||||||
|
key: "height", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "体重", |
||||||
|
key: "weight", |
||||||
|
formType: "input", |
||||||
|
required: true, |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "肩颈宽度", |
||||||
|
key: "neckShoulderWidth", |
||||||
|
formType: "input", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "颈长", |
||||||
|
key: "neckLength", |
||||||
|
formType: "input", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "年龄", |
||||||
|
key: "ageRange", |
||||||
|
formType: "select", |
||||||
|
isSearch:true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
label: "18~30", |
||||||
|
value: "18~30", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "31~50", |
||||||
|
value: "31~50", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "51~60", |
||||||
|
value: "51~60", |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "60以上", |
||||||
|
value: "60以上", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您每晚的睡眠时间", |
||||||
|
key: "sleepLength", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "2~4小时", |
||||||
|
value: "2~4小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "4~6小时", |
||||||
|
value: "4~6小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "6~8小时", |
||||||
|
value: "6~8小时", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "8小时以上", |
||||||
|
value: "8小时以上", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的睡眠姿势", |
||||||
|
key: "sleepLength", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "仰睡", |
||||||
|
value: 1, |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "侧睡", |
||||||
|
value: 2, |
||||||
|
}, |
||||||
|
], |
||||||
|
imgData: [ |
||||||
|
{ text: "仰睡", img: "../../../static/image/yang.jpg" }, |
||||||
|
{ text: "侧睡", img: "../../../static/image/ce.jpg" }, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的枕头软硬度", |
||||||
|
key: "pillowHardness", |
||||||
|
formType: "check", |
||||||
|
required: true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "偏硬", |
||||||
|
value: "1", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "适中", |
||||||
|
value: "2", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "偏软", |
||||||
|
value: "3", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您习惯的枕头类型", |
||||||
|
key: "pillowMaterial", |
||||||
|
formType: "check", |
||||||
|
required: true, |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "羽丝绒枕", |
||||||
|
value: "1", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "草本植物枕(荞麦、决明子等)", |
||||||
|
value: "2", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "乳胶枕", |
||||||
|
value: "3", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "慢回弹记忆枕", |
||||||
|
value: "4", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "软管枕", |
||||||
|
value: "5", |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "其他", |
||||||
|
value: "6", |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您现在的颈椎出现问题了吗", |
||||||
|
key: "cervicalVertebra", |
||||||
|
formType: "check", |
||||||
|
data: [ |
||||||
|
{ |
||||||
|
text: "是", |
||||||
|
value: 1, |
||||||
|
}, |
||||||
|
{ |
||||||
|
text: "否", |
||||||
|
value: 0, |
||||||
|
}, |
||||||
|
], |
||||||
|
}, |
||||||
|
{ |
||||||
|
label: "您的其他需求", |
||||||
|
key: "workcontent", |
||||||
|
formType: "textarea", |
||||||
|
}, |
||||||
|
], |
||||||
|
}; |
||||||
|
}, |
||||||
|
computed: { |
||||||
|
// ...mapGetters(["permission","userInfo"]), |
||||||
|
ids() { |
||||||
|
let ids = []; |
||||||
|
this.selectionList.forEach((ele) => { |
||||||
|
ids.push(ele.id); |
||||||
|
}); |
||||||
|
return ids.join(","); |
||||||
|
}, |
||||||
|
}, |
||||||
|
created() { |
||||||
|
// this.headers["Blade-Auth"] = "bearer " + getToken(); |
||||||
|
// this.getTime(); |
||||||
|
// this.getWinData(); |
||||||
|
// this.getTypeData(); |
||||||
|
console.log(this.formData); |
||||||
|
this.formData.map((item) => { |
||||||
|
// if(item.) |
||||||
|
this.option.column.push({ |
||||||
|
type:item.formType, |
||||||
|
label: item.label, |
||||||
|
prop: item.key, |
||||||
|
search:item.isSearch, |
||||||
|
dicData:item.data, |
||||||
|
overHidden:true, |
||||||
|
}); |
||||||
|
|
||||||
|
}); |
||||||
|
console.log(this.option.column) |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
methods: { |
||||||
|
sizeChange(pageSize) { |
||||||
|
this.page.pageSize = pageSize; |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
handleDetail(row) { |
||||||
|
this.dialogVisible = true; |
||||||
|
detailList({ id: row.id }).then((res) => { |
||||||
|
console.log(res); |
||||||
|
this.checkaccept = res.data.data; |
||||||
|
this.checkaccept.position = |
||||||
|
this.checkaccept.province + |
||||||
|
this.checkaccept.city + |
||||||
|
this.checkaccept.district + |
||||||
|
this.checkaccept.detail; |
||||||
|
}); |
||||||
|
}, |
||||||
|
selectionChange(data) { |
||||||
|
this.selectionList = data; |
||||||
|
}, |
||||||
|
currentChange(currentPage) { |
||||||
|
this.page.currentPage = currentPage; |
||||||
|
this.onLoad(); |
||||||
|
}, |
||||||
|
getWinData() { |
||||||
|
getBaseList().then((res) => { |
||||||
|
this.winData = res.data.data; |
||||||
|
let tmp = this.winData.find((item) => item.id == this.userInfo.user_id); |
||||||
|
if (tmp) { |
||||||
|
this.form.windows = tmp.id; |
||||||
|
this.isWinDis = true; |
||||||
|
} |
||||||
|
}); |
||||||
|
}, |
||||||
|
getTypeData() { |
||||||
|
getTypeList().then((res) => { |
||||||
|
this.typeData = res.data.data; |
||||||
|
}); |
||||||
|
}, |
||||||
|
handleList(row) { |
||||||
|
console.log(row); |
||||||
|
this.dialogVisible = true; |
||||||
|
getResolveList({ appealId: row.id }).then((res) => { |
||||||
|
console.log("res", res); |
||||||
|
this.listData = res.data.data; |
||||||
|
}); |
||||||
|
}, |
||||||
|
searchReset() { |
||||||
|
this.query = {}; |
||||||
|
this.form = {}; |
||||||
|
this.onLoad(this.page); |
||||||
|
}, |
||||||
|
searchChange(params, done) { |
||||||
|
console.log(params) |
||||||
|
this.form = params |
||||||
|
console.log(this.form); |
||||||
|
|
||||||
|
this.query = this.form; |
||||||
|
this.page.currentPage = 1; |
||||||
|
this.onLoad(this.page, this.form); |
||||||
|
done(); |
||||||
|
}, |
||||||
|
handleSuccess(res) { |
||||||
|
console.log(res); |
||||||
|
if (res.code == 200) { |
||||||
|
this.$message.success("上传成功"); |
||||||
|
} |
||||||
|
}, |
||||||
|
fn(str) { |
||||||
|
let num = null; |
||||||
|
str >= 10 ? (num = str) : (num = "0" + str); |
||||||
|
return num; |
||||||
|
}, |
||||||
|
getTime() { |
||||||
|
//获取当前时间 |
||||||
|
var date = new Date(); |
||||||
|
var year = date.getFullYear(); //当前年份 |
||||||
|
var month = date.getMonth(); //当前月份 |
||||||
|
var data = date.getDate(); //天 |
||||||
|
var hours = date.getHours(); //小时 |
||||||
|
var minute = date.getMinutes(); //分 |
||||||
|
var second = date.getSeconds(); //秒 |
||||||
|
this.day = date.getDay(); //获取当前星期几 |
||||||
|
// this.getWeek(this.day); |
||||||
|
this.time = this.fn(hours) + ":" + this.fn(minute); |
||||||
|
this.date = year + "-" + (month + 1) + "-" + data; |
||||||
|
}, |
||||||
|
onLoad() { |
||||||
|
let params = {}; |
||||||
|
// params = { |
||||||
|
// username:this.form.name ? this.form.name : '', |
||||||
|
// phone:this.form.phonenumber ? this.form.phonenumber : '', |
||||||
|
// pillowHardness:this.form.hardness ? this.form.hardness : '', |
||||||
|
// pillowMaterial:this.form.material ? this.form.material : '' |
||||||
|
// } |
||||||
|
|
||||||
|
if (!this.form.timeArr) { |
||||||
|
params = { |
||||||
|
username: this.form.username ? this.form.username : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.ageRange ? this.form.ageRange : "", |
||||||
|
}; |
||||||
|
} else { |
||||||
|
params = { |
||||||
|
username: this.form.username ? this.form.username : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.ageRange ? this.form.ageRange : "", |
||||||
|
startTime: this.form.timeArr[0], |
||||||
|
endTime: this.form.timeArr[1], |
||||||
|
}; |
||||||
|
} |
||||||
|
console.log("par", params); |
||||||
|
|
||||||
|
getList({ |
||||||
|
current: this.page.currentPage, |
||||||
|
size: this.page.pageSize, |
||||||
|
...params, |
||||||
|
}).then((res) => { |
||||||
|
console.log("res==>", res); |
||||||
|
this.loading = false; |
||||||
|
this.data = res.data.data.records; |
||||||
|
this.page.total = res.data.data.total; |
||||||
|
}); |
||||||
|
}, |
||||||
|
addRegister() { |
||||||
|
this.$router.push({ path: "/register/add", query: { type: "add" } }); |
||||||
|
}, |
||||||
|
exportData() { |
||||||
|
let params = {}; |
||||||
|
if (!this.form.timeArr) { |
||||||
|
params = { |
||||||
|
username: this.form.name ? this.form.name : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.age ? this.form.age : "", |
||||||
|
}; |
||||||
|
} else { |
||||||
|
params = { |
||||||
|
username: this.form.name ? this.form.name : "", |
||||||
|
phone: this.form.phonenumber ? this.form.phonenumber : "", |
||||||
|
pillowHardness: this.form.hardness ? this.form.hardness : "", |
||||||
|
pillowMaterial: this.form.material ? this.form.material : "", |
||||||
|
ageRange: this.form.age ? this.form.age : "", |
||||||
|
startTime: this.form.timeArr[0], |
||||||
|
endTime: this.form.timeArr[1], |
||||||
|
}; |
||||||
|
} |
||||||
|
exportList(params).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (!res || !res.data) { |
||||||
|
this.$message({ |
||||||
|
type: "error", |
||||||
|
message: "导出失败!", |
||||||
|
}); |
||||||
|
return; |
||||||
|
} |
||||||
|
let blob = new Blob([res.data]); //response.data为后端传的流文件 |
||||||
|
let downloadFilename = "统计" + ".xlsx"; //设置导出的文件名 |
||||||
|
if (window.navigator && window.navigator.msSaveOrOpenBlob) { |
||||||
|
//兼容ie浏览器 |
||||||
|
window.navigator.msSaveOrOpenBlob(blob, downloadFilename); |
||||||
|
} else { |
||||||
|
//谷歌,火狐等浏览器 |
||||||
|
let url = window.URL.createObjectURL(blob); |
||||||
|
let downloadElement = document.createElement("a"); |
||||||
|
downloadElement.style.display = "none"; |
||||||
|
downloadElement.href = url; |
||||||
|
downloadElement.download = downloadFilename; |
||||||
|
document.body.appendChild(downloadElement); |
||||||
|
downloadElement.click(); |
||||||
|
document.body.removeChild(downloadElement); |
||||||
|
window.URL.revokeObjectURL(url); |
||||||
|
} |
||||||
|
this.$message({ type: "success", message: "导出成功!" }); |
||||||
|
}); |
||||||
|
}, |
||||||
|
deleteItem() { |
||||||
|
if (this.selectionList.length == 0) { |
||||||
|
this.$message.warning("请至少选择一条数据"); |
||||||
|
return; |
||||||
|
} |
||||||
|
this.$confirm(`确认删除当前数据吗?`, { |
||||||
|
confirmButtonText: "确定", |
||||||
|
cancelButtonText: "取消", |
||||||
|
type: "warning", |
||||||
|
}).then(() => { |
||||||
|
deleteList(this.ids).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (res.data.code == 200) { |
||||||
|
this.$message.success("删除成功"); |
||||||
|
this.page.pageSize = 1; |
||||||
|
this.onLoad(); |
||||||
|
} |
||||||
|
}); |
||||||
|
}); |
||||||
|
}, |
||||||
|
importRegister() {}, |
||||||
|
handleEdit() { |
||||||
|
this.$router.push({ path: "/request/add" }); |
||||||
|
}, |
||||||
|
handleDelete(row) { |
||||||
|
this.$confirm(`确认删除当前数据吗?`, { |
||||||
|
confirmButtonText: "确定", |
||||||
|
cancelButtonText: "取消", |
||||||
|
type: "warning", |
||||||
|
}).then(() => { |
||||||
|
deleteList(row.id).then((res) => { |
||||||
|
console.log(res); |
||||||
|
if (res.data.code == 200) { |
||||||
|
this.$message.success("删除成功"); |
||||||
|
this.page.currentPage = 1; |
||||||
|
this.onLoad(); |
||||||
|
} |
||||||
|
}); |
||||||
|
}); |
||||||
|
}, |
||||||
|
}, |
||||||
|
}; |
||||||
|
</script> |
||||||
|
|
||||||
|
<style lang="scss"> |
||||||
|
.resi_list { |
||||||
|
.list { |
||||||
|
width: 80%; |
||||||
|
max-height: 246px; |
||||||
|
overflow-y: auto; |
||||||
|
|
||||||
|
.list_box { |
||||||
|
width: 100%; |
||||||
|
height: 41px; |
||||||
|
font-size: 20px; |
||||||
|
display: flex; |
||||||
|
align-items: center; |
||||||
|
|
||||||
|
& :hover { |
||||||
|
cursor: pointer; |
||||||
|
// .time_txt{ |
||||||
|
color: #4095e5; |
||||||
|
|
||||||
|
// } |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
.upload-demo { |
||||||
|
float: right; |
||||||
|
} |
||||||
|
</style> |
||||||
|
<style lang="scss"> |
||||||
|
.dis_class { |
||||||
|
.is-bordered-label { |
||||||
|
width: 15% !important; |
||||||
|
} |
||||||
|
.el-descriptions .is-bordered .el-descriptions-item__cell { |
||||||
|
width: 35%; |
||||||
|
height: 50px; |
||||||
|
} |
||||||
|
} |
||||||
|
</style> |
||||||
Loading…
Reference in new issue