Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
b96157f2c5
@ -28,6 +28,7 @@ VUE_APP_BAIDU_CODE = fadc1bd5db1a1d6f581df60a1807f8ab
|
|||||||
|
|
||||||
# 大屏设计器服务
|
# 大屏设计器服务
|
||||||
VUE_APP_BIG_SCREEN_SERVER = 'http://127.0.0.1:3000'
|
VUE_APP_BIG_SCREEN_SERVER = 'http://127.0.0.1:3000'
|
||||||
|
VUE_APP_IMAGE_URL = 'http://122.51.230.86:9000/'
|
||||||
|
|
||||||
#小程序推广码前缀
|
#小程序推广码前缀
|
||||||
VUE_APP_REPAIR_PREX = 'https://www.lighting-it.cn/share?inviteId='
|
VUE_APP_REPAIR_PREX = 'https://www.lighting-it.cn/share?inviteId='
|
||||||
|
0
section.docx
Normal file
0
section.docx
Normal file
@ -56,9 +56,10 @@ export function exportOrderInfoExcel(params) {
|
|||||||
|
|
||||||
export function toPay(params) {
|
export function toPay(params) {
|
||||||
return request({
|
return request({
|
||||||
url: '/admin-api/pay/toPayCode',
|
// url: '/admin-api/pay/toPayCode',
|
||||||
|
url: '/repair/order-info/toPay?id=' + params.orderId,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params
|
// params
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -158,3 +158,20 @@ export function addItems(data){
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 修改工单主表,只是主表
|
||||||
|
export function updateTicket(data){
|
||||||
|
return request({
|
||||||
|
url: preUrl + '/updateTicket',
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除工单
|
||||||
|
export function removeTicketById(id){
|
||||||
|
return request({
|
||||||
|
url: preUrl + "/remove?id=" + id,
|
||||||
|
method: 'delete'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
@ -43,6 +43,18 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<el-row :gutter="2">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="开户行" prop="bankAccount">
|
||||||
|
<el-input v-model="formData.bankAccount" placeholder="请输入开户行" maxlength="50"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="收款账户" prop="account">
|
||||||
|
<el-input v-model="formData.account" placeholder="请输入收款账户" maxlength="18"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
<el-row :gutter="2">
|
<el-row :gutter="2">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="联系人" prop="contactName">
|
<el-form-item label="联系人" prop="contactName">
|
||||||
@ -128,7 +140,9 @@ export default {
|
|||||||
loginAccount: undefined,
|
loginAccount: undefined,
|
||||||
password: undefined,
|
password: undefined,
|
||||||
serviceCodeArray: [],
|
serviceCodeArray: [],
|
||||||
serviceCodes:undefined
|
serviceCodes:undefined,
|
||||||
|
bankAccount: null,
|
||||||
|
account: null,
|
||||||
},
|
},
|
||||||
// 表单校验
|
// 表单校验
|
||||||
formRules: {
|
formRules: {
|
||||||
@ -232,7 +246,9 @@ export default {
|
|||||||
loginAccount: undefined,
|
loginAccount: undefined,
|
||||||
password: undefined,
|
password: undefined,
|
||||||
serviceCodeArray: [],
|
serviceCodeArray: [],
|
||||||
serviceCodes:undefined
|
serviceCodes:undefined,
|
||||||
|
bankAccount: null,
|
||||||
|
account: null,
|
||||||
}
|
}
|
||||||
this.resetForm('formRef')
|
this.resetForm('formRef')
|
||||||
}
|
}
|
||||||
|
@ -77,6 +77,8 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="管理员登录账号" align="left" prop="loginAccount" width="180"/>
|
<el-table-column label="管理员登录账号" align="left" prop="loginAccount" width="180"/>
|
||||||
|
<el-table-column label="开户行" align="left" prop="bankAccount" width="180"/>
|
||||||
|
<el-table-column label="收款账户" align="left" prop="account" width="180"/>
|
||||||
<el-table-column fixed="right" label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
<el-table-column fixed="right" label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="openForm(scope.row.id)"
|
<el-button size="mini" type="text" icon="el-icon-edit" @click="openForm(scope.row.id)"
|
||||||
|
@ -2,15 +2,15 @@
|
|||||||
<div class="container_">
|
<div class="container_">
|
||||||
|
|
||||||
|
|
||||||
<div class="top-list">
|
<!-- <div class="top-list">-->
|
||||||
<div class="list-box" v-for="(item, index) in serviceList" :key="item.id" :span="4">
|
<!-- <div class="list-box" v-for="(item, index) in serviceList" :key="item.id" :span="4">-->
|
||||||
<div @click="goRoute(item.id)">
|
<!-- <div @click="goRoute(item.id)">-->
|
||||||
<img :src="imgUrl + item.coverImg"
|
<!-- <img :src="imgUrl + item.coverImg"-->
|
||||||
style="width: 300px; height: 300px;">
|
<!-- style="width: 300px; height: 300px;">-->
|
||||||
<div style="font-weight: bold;text-align: center;font-size: 28px">{{ item.name }}</div>
|
<!-- <div style="font-weight: bold;text-align: center;font-size: 28px">{{ item.name }}</div>-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-select v-model="userSelected" clearable filterable >
|
<el-select v-model="userSelected" clearable filterable :filter-method="handleQuery">
|
||||||
<el-option v-for="user in userList" :key="user.id" :label="user.cusName + ' ' + user.phoneNumber" :value="user.id" />
|
<el-option v-for="user in userList" :key="user.id" :label="user.cusName + ' ' + user.phoneNumber" :value="user.id"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -10,11 +10,11 @@ import {getCustomerMainPage} from "@/api/base/customer";
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "UserChoose",
|
name: "UserChoose",
|
||||||
props:{
|
props: {
|
||||||
value:{
|
value: {
|
||||||
type: Object,
|
type: Object,
|
||||||
},
|
},
|
||||||
inList:{
|
inList: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: null,
|
default: null,
|
||||||
required: false
|
required: false
|
||||||
@ -24,28 +24,30 @@ export default {
|
|||||||
return {
|
return {
|
||||||
userList: [],
|
userList: [],
|
||||||
userSelected: undefined,
|
userSelected: undefined,
|
||||||
queryParams:{
|
queryParams: {
|
||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
pageSize: 10
|
pageSize: 10,
|
||||||
|
cusName: null,
|
||||||
|
phoneNumber: null,
|
||||||
},
|
},
|
||||||
total: 0
|
total: 0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch:{
|
watch: {
|
||||||
userSelected(val){
|
userSelected(val) {
|
||||||
if (val){
|
if (val) {
|
||||||
const user = this.userList.find(item => item.id === val)
|
const user = this.userList.find(item => item.id === val)
|
||||||
this.$emit("input", user)
|
this.$emit("input", user)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
value(val){
|
value(val) {
|
||||||
this.userSelected = val ? val.id : null
|
this.userSelected = val ? val.id : null
|
||||||
},
|
},
|
||||||
inList(val){
|
inList(val) {
|
||||||
if (val){
|
if (val) {
|
||||||
// 不存在才添加
|
// 不存在才添加
|
||||||
const flag = this.userList.findIndex(item => item.id === val.id)
|
const flag = this.userList.findIndex(item => item.id === val.id)
|
||||||
if (flag > 0){
|
if (flag > 0) {
|
||||||
this.userList.splice(flag, 1)
|
this.userList.splice(flag, 1)
|
||||||
}
|
}
|
||||||
this.userList.unshift(val)
|
this.userList.unshift(val)
|
||||||
@ -57,10 +59,18 @@ export default {
|
|||||||
this.listCustomer()
|
this.listCustomer()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async listCustomer(){
|
async listCustomer() {
|
||||||
const res = await getCustomerMainPage(this.queryParams)
|
const res = await getCustomerMainPage(this.queryParams)
|
||||||
this.userList = res.data.records
|
this.userList = res.data.records
|
||||||
this.total = res.data.total
|
this.total = res.data.total
|
||||||
|
},
|
||||||
|
handleQuery(data) {
|
||||||
|
if (/^\d+$/.test(data)) {
|
||||||
|
this.queryParams.phoneNumber = data
|
||||||
|
} else {
|
||||||
|
this.queryParams.cusName = data
|
||||||
|
}
|
||||||
|
this.listCustomer()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="cont">
|
<div class="cont">
|
||||||
<div class="top_">
|
<div class="top_">
|
||||||
<div>车辆维修数据分析</div>
|
<div>车辆维修数据分析</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- -->
|
<!-- -->
|
||||||
<div class="content_">
|
<div class="content_">
|
||||||
<div class="c_left">
|
<div class="c_left">
|
||||||
<div class="six_box">
|
<div class="six_box">
|
||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
客户来源
|
客户来源分析
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box">
|
<div class="echaets_box">
|
||||||
<div id="khly" style="width: 400px; height: 267px;"></div>
|
<div id="khly" style="width: 400px; height: 267px;"></div>
|
||||||
@ -16,36 +16,71 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="six_box">
|
<div class="six_box">
|
||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
月工单数据来源
|
月工单数量走势
|
||||||
|
</div>
|
||||||
|
<div class="echaets_box">
|
||||||
|
<div id="gdslzs" style="width: 400px; height: 267px;"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box"></div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="six_box">
|
<div class="six_box">
|
||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
支付渠道统计
|
支付渠道统计
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box"></div>
|
<div class="echaets_box">
|
||||||
|
<div id="zfqdtj" style="width: 400px; height: 267px;"></div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="c_cont">
|
<div class="c_cont">
|
||||||
<div class="tab_">
|
<div class="tab_">
|
||||||
<div class="tab_buttom tab_acvit" >数量</div>
|
<div @click="countOrAmount()" class="tab_buttom tab_acvit">数量</div>
|
||||||
<div class="tab_buttom">金额</div>
|
<div @click="countOrAmount()" class="tab_buttom">金额</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab_bt">
|
<div v-if="isCount" class="tab_bt">
|
||||||
<div class="yb_">
|
<div class="yb_">
|
||||||
<div class="yb_title">工单总数</div>
|
<div class="yb_title">工单总数</div>
|
||||||
<div class="numlist">
|
<div class="numlist">
|
||||||
<div class="num_box" v-for="(item,index) in 6" :key="index">
|
<!-- <div class="num_box" v-for="(item,index) in 6" :key="index">-->
|
||||||
{{index}}
|
<!-- {{index}}-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
|
<div class="num_box">
|
||||||
|
{{ statistics.totalCount }}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="yb_">
|
<div class="yb_">
|
||||||
<div class="yb_title">今日工单</div>
|
<div class="yb_title">今日工单</div>
|
||||||
<div class="numlist">
|
<div class="numlist">
|
||||||
<div class="num_box" v-for="(item,index) in 6" :key="index">
|
<!-- <div class="num_box" v-for="(item,index) in 6" :key="index">-->
|
||||||
{{index}}
|
<!-- {{index}}-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<div class="num_box">
|
||||||
|
{{ statistics.todayCount }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div v-else class="tab_bt">
|
||||||
|
<div class="yb_">
|
||||||
|
<div class="yb_title">工单总金额(元)</div>
|
||||||
|
<div class="numlist">
|
||||||
|
<!-- <div class="num_box" v-for="(item,index) in 6" :key="index">-->
|
||||||
|
<!-- {{index}}-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<div class="num_box">
|
||||||
|
{{ statistics.totalAmount }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="yb_">
|
||||||
|
<div class="yb_title">今日工单金额(元)</div>
|
||||||
|
<div class="numlist">
|
||||||
|
<!-- <div class="num_box" v-for="(item,index) in 6" :key="index">-->
|
||||||
|
<!-- {{index}}-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<div class="num_box">
|
||||||
|
{{ statistics.todayAmount }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -56,8 +91,8 @@
|
|||||||
<img src="./imgs/1.png" style="width: 60px;height: 60px">
|
<img src="./imgs/1.png" style="width: 60px;height: 60px">
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="f_size">未派工</div>
|
<div class="f_size">{{ statusTickets[3].name }}</div>
|
||||||
<div class="f_num">2082</div>
|
<div class="f_num">{{ statusTickets[3].value }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="f_box">
|
<div class="f_box">
|
||||||
@ -65,8 +100,8 @@
|
|||||||
<img src="./imgs/2.png" style="width: 60px;height: 60px">
|
<img src="./imgs/2.png" style="width: 60px;height: 60px">
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="f_size">施工中</div>
|
<div class="f_size">{{ statusTickets[4].name }}</div>
|
||||||
<div class="f_num">2082</div>
|
<div class="f_num">{{ statusTickets[4].value }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="f_box">
|
<div class="f_box">
|
||||||
@ -74,8 +109,8 @@
|
|||||||
<img src="./imgs/3.png" style="width: 60px;height: 60px">
|
<img src="./imgs/3.png" style="width: 60px;height: 60px">
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="f_size">未结账</div>
|
<div class="f_size">{{ statusTickets[0].name }}</div>
|
||||||
<div class="f_num">2082</div>
|
<div class="f_num">{{ statusTickets[0].value }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="f_box">
|
<div class="f_box">
|
||||||
@ -83,8 +118,8 @@
|
|||||||
<img src="./imgs/4.png" style="width: 60px;height: 60px">
|
<img src="./imgs/4.png" style="width: 60px;height: 60px">
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="f_size">已结账</div>
|
<div class="f_size">{{ statusTickets[1].name }}</div>
|
||||||
<div class="f_num">2082</div>
|
<div class="f_num">{{ statusTickets[1].value }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="f_box">
|
<div class="f_box">
|
||||||
@ -92,13 +127,13 @@
|
|||||||
<img src="./imgs/5.png" style="width: 60px;height: 60px">
|
<img src="./imgs/5.png" style="width: 60px;height: 60px">
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="f_size">挂账</div>
|
<div class="f_size">{{ statusTickets[5].name }}</div>
|
||||||
<div class="f_num">2082</div>
|
<div class="f_num">{{ statusTickets[5].value }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="co_title">
|
<div class="co_title">
|
||||||
最新工单
|
今日工单
|
||||||
</div>
|
</div>
|
||||||
<div class="list_long">
|
<div class="list_long">
|
||||||
<div class="long_title">
|
<div class="long_title">
|
||||||
@ -108,14 +143,13 @@
|
|||||||
<div class="l_four">创建时间</div>
|
<div class="l_four">创建时间</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="ot_vox">
|
<div class="ot_vox">
|
||||||
<div class="long_box" v-for="(item,index) in 16" :key="index">
|
<div class="long_box" v-for="(item,index) in todayTickets" :key="index">
|
||||||
<div class="l_one">1209840149750105501</div>
|
<div class="l_one">{{ item.ticketNo }}</div>
|
||||||
<div class="l_two">张三</div>
|
<div class="l_two">{{ item.userName }}</div>
|
||||||
<div class="l_three">李向东</div>
|
<div class="l_three">{{ item.adviserName }}</div>
|
||||||
<div class="l_four">2024-10-20 12:00</div>
|
<div class="l_four">{{ parseTime(item.createTime) }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="c_right">
|
<div class="c_right">
|
||||||
@ -123,19 +157,36 @@
|
|||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
维修类型统计
|
维修类型统计
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box"></div>
|
<div class="echaets_box">
|
||||||
|
<div id="wxlxtj" style="width: 400px; height: 267px;"></div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="six_box">
|
<div class="six_box">
|
||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
月工单金额走势
|
月工单金额走势
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box"></div>
|
<div class="echaets_box">
|
||||||
|
<div id="gdjezs" style="width: 400px; height: 267px;"></div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="six_box">
|
<div class="six_box">
|
||||||
<div class="s_title">
|
<div class="s_title">
|
||||||
维修工人排行
|
维修工人排行
|
||||||
</div>
|
</div>
|
||||||
<div class="echaets_box"></div>
|
<div class="echaets_box">
|
||||||
|
<div class="list_long">
|
||||||
|
<div class="long_title">
|
||||||
|
<div class="l_one">姓名</div>
|
||||||
|
<div class="l_two">服务工单数</div>
|
||||||
|
</div>
|
||||||
|
<div class="ot_vox">
|
||||||
|
<div class="long_box" v-for="(item,index) in workers" :key="index">
|
||||||
|
<div class="l_one">{{ item.name }}</div>
|
||||||
|
<div class="l_two">{{ item.value }}</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -145,38 +196,71 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import * as echarts from 'echarts';
|
import * as echarts from 'echarts';
|
||||||
|
import * as RepairBigScreenApi from '@/views/repair/screen/api/repairBigScreen';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Index',
|
name: 'Index',
|
||||||
components: {
|
components: {},
|
||||||
|
|
||||||
},
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
//金额数量统计
|
||||||
|
statistics: {},
|
||||||
|
//工单各状态数量
|
||||||
|
statusTickets: [],
|
||||||
|
//金额数量切换
|
||||||
|
isCount: true,
|
||||||
|
//今日工单
|
||||||
|
todayTickets: [],
|
||||||
|
//维修工人排行
|
||||||
|
workers: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
//工单总数、今日工单、工单总金额、今日工单金额
|
||||||
|
this.ticketStatistics()
|
||||||
|
//工单状态数量统计
|
||||||
|
this.ticketStatusCount()
|
||||||
|
//今日工单
|
||||||
|
this.listTicketToday()
|
||||||
|
//维修工人排行
|
||||||
|
this.listWorks()
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.echaerCar();
|
//客户来源分析饼图
|
||||||
|
this.customerSource();
|
||||||
|
//月工单数量走势
|
||||||
|
this.ticketMainCount()
|
||||||
|
//月工单金额走势
|
||||||
|
this.ticketMainAmount()
|
||||||
|
//支付渠道统计
|
||||||
|
this.ticketMainPayWay()
|
||||||
|
//维修类型相关统计分析饼图
|
||||||
|
this.repairTypeStatistics()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
echaerCar(){
|
countOrAmount() {
|
||||||
|
this.isCount = !this.isCount
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户来源分析饼图
|
||||||
|
*/
|
||||||
|
async customerSource() {
|
||||||
|
const res = await RepairBigScreenApi.customerSource();
|
||||||
var chartDom = document.getElementById('khly');
|
var chartDom = document.getElementById('khly');
|
||||||
var myChart = echarts.init(chartDom);
|
var myChart = echarts.init(chartDom);
|
||||||
var option;
|
var option;
|
||||||
option = {
|
option = {
|
||||||
// legend: {
|
|
||||||
// top: 'bottom'
|
|
||||||
// },
|
|
||||||
toolbox: {
|
toolbox: {
|
||||||
show: true,
|
show: true,
|
||||||
|
},
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'item',
|
||||||
|
formatter: "{a} <br/>{b} : {c} ({d}%)"
|
||||||
},
|
},
|
||||||
series: [
|
series: [
|
||||||
{
|
{
|
||||||
name: 'Nightingale Chart',
|
name: '客户来源分析',
|
||||||
type: 'pie',
|
type: 'pie',
|
||||||
radius: [20, 100],
|
radius: [20, 100],
|
||||||
center: ['50%', '50%'],
|
center: ['50%', '50%'],
|
||||||
@ -184,31 +268,195 @@ export default {
|
|||||||
itemStyle: {
|
itemStyle: {
|
||||||
borderRadius: 2
|
borderRadius: 2
|
||||||
},
|
},
|
||||||
data: [
|
data: res.data,
|
||||||
{ value: 40, name: '救援' },
|
|
||||||
{ value: 38, name: '线下' },
|
|
||||||
{ value: 32, name: '小程序预约' },
|
|
||||||
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
option && myChart.setOption(option);
|
option && myChart.setOption(option);
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 月工单数量走势
|
||||||
|
*/
|
||||||
|
async ticketMainCount() {
|
||||||
|
const res = await RepairBigScreenApi.ticketMainCount();
|
||||||
|
var chartDom = document.getElementById('gdslzs');
|
||||||
|
var myChart = echarts.init(chartDom, 'dark');
|
||||||
|
var option;
|
||||||
|
option = {
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'axis'
|
||||||
|
},
|
||||||
|
xAxis: {
|
||||||
|
type: 'category',
|
||||||
|
data: res.data.xData
|
||||||
|
},
|
||||||
|
yAxis: {
|
||||||
|
type: 'value'
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
data: res.data.data,
|
||||||
|
type: 'line',
|
||||||
|
smooth: true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
option && myChart.setOption(option);
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 月工单金额走势
|
||||||
|
*/
|
||||||
|
async ticketMainAmount() {
|
||||||
|
const res = await RepairBigScreenApi.ticketMainAmount();
|
||||||
|
var chartDom = document.getElementById('gdjezs');
|
||||||
|
var myChart = echarts.init(chartDom, 'dark');
|
||||||
|
var option;
|
||||||
|
option = {
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'axis'
|
||||||
|
},
|
||||||
|
xAxis: {
|
||||||
|
type: 'category',
|
||||||
|
data: res.data.xData
|
||||||
|
},
|
||||||
|
yAxis: {
|
||||||
|
type: 'value'
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
data: res.data.data,
|
||||||
|
type: 'line',
|
||||||
|
smooth: true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
option && myChart.setOption(option);
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 支付渠道统计
|
||||||
|
*/
|
||||||
|
async ticketMainPayWay() {
|
||||||
|
const res = await RepairBigScreenApi.ticketMainPayWay();
|
||||||
|
var chartDom = document.getElementById('zfqdtj');
|
||||||
|
var myChart = echarts.init(chartDom, 'dark');
|
||||||
|
var option;
|
||||||
|
option = {
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'axis',
|
||||||
|
axisPointer: {
|
||||||
|
type: 'shadow'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
xAxis: {
|
||||||
|
type: 'category',
|
||||||
|
data: res.data.xData
|
||||||
|
},
|
||||||
|
yAxis: {
|
||||||
|
type: 'value'
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
data: res.data.data,
|
||||||
|
type: 'bar'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
option && myChart.setOption(option);
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 维修类型相关统计分析饼图
|
||||||
|
*/
|
||||||
|
async repairTypeStatistics() {
|
||||||
|
const res = await RepairBigScreenApi.repairTypeStatistics();
|
||||||
|
var chartDom = document.getElementById('wxlxtj');
|
||||||
|
var myChart = echarts.init(chartDom, 'dark');
|
||||||
|
var option;
|
||||||
|
option = {
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'item'
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
top: '5%',
|
||||||
|
left: 'center'
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: '维修类型统计',
|
||||||
|
type: 'pie',
|
||||||
|
radius: ['40%', '70%'],
|
||||||
|
avoidLabelOverlap: false,
|
||||||
|
padAngle: 5,
|
||||||
|
itemStyle: {
|
||||||
|
borderRadius: 10
|
||||||
|
},
|
||||||
|
label: {
|
||||||
|
show: false,
|
||||||
|
position: 'center'
|
||||||
|
},
|
||||||
|
emphasis: {
|
||||||
|
label: {
|
||||||
|
show: true,
|
||||||
|
fontSize: 40,
|
||||||
|
fontWeight: 'bold'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
labelLine: {
|
||||||
|
show: false
|
||||||
|
},
|
||||||
|
data: res.data
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
option && myChart.setOption(option);
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 单总数、今日工单、工单总金额、今日工单金额
|
||||||
|
*/
|
||||||
|
async ticketStatistics() {
|
||||||
|
const res = await RepairBigScreenApi.ticketStatistics();
|
||||||
|
this.statistics = res.data
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 工单状态数量统计
|
||||||
|
*/
|
||||||
|
async ticketStatusCount() {
|
||||||
|
const res = await RepairBigScreenApi.ticketStatusCount();
|
||||||
|
this.statusTickets = res.data
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 今日工单
|
||||||
|
*/
|
||||||
|
async listTicketToday() {
|
||||||
|
const res = await RepairBigScreenApi.listTicketToday();
|
||||||
|
this.todayTickets = res.data
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 维修工人排行
|
||||||
|
*/
|
||||||
|
async listWorks() {
|
||||||
|
const res = await RepairBigScreenApi.listWorks();
|
||||||
|
this.workers = res.data
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.cont{
|
.cont {
|
||||||
background: #020F32;
|
background: #020F32;
|
||||||
//background: url("./imgs/back.png") no-repeat;
|
//background: url("./imgs/back.png") no-repeat;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
}
|
}
|
||||||
.top_{
|
|
||||||
|
.top_ {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 86px;
|
height: 86px;
|
||||||
background: url("./imgs/top.png") no-repeat;
|
background: url("./imgs/top.png") no-repeat;
|
||||||
@ -221,19 +469,23 @@ export default {
|
|||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
}
|
}
|
||||||
.content_{
|
|
||||||
|
.content_ {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
//align-items: center;
|
//align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.c_left{
|
|
||||||
|
.c_left {
|
||||||
width: 25%;
|
width: 25%;
|
||||||
}
|
}
|
||||||
.c_cont{
|
|
||||||
|
.c_cont {
|
||||||
width: 50%;
|
width: 50%;
|
||||||
}
|
}
|
||||||
.tab_{
|
|
||||||
|
.tab_ {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@ -242,13 +494,15 @@ export default {
|
|||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
margin: 15px auto;
|
margin: 15px auto;
|
||||||
}
|
}
|
||||||
.yb_title{
|
|
||||||
|
.yb_title {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
margin: 15px auto;
|
margin: 15px auto;
|
||||||
}
|
}
|
||||||
.tab_bt{
|
|
||||||
|
.tab_bt {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@ -257,7 +511,8 @@ export default {
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding-bottom: 20px;
|
padding-bottom: 20px;
|
||||||
}
|
}
|
||||||
.tab_buttom{
|
|
||||||
|
.tab_buttom {
|
||||||
width: 120px;
|
width: 120px;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
|
|
||||||
@ -266,18 +521,21 @@ export default {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
yb_title{
|
|
||||||
|
yb_title {
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
.numlist{
|
|
||||||
|
.numlist {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
.num_box{
|
|
||||||
|
.num_box {
|
||||||
width: 38px;
|
width: 38px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
border-radius: 0px 0px 0px 0px;
|
border-radius: 0px 0px 0px 0px;
|
||||||
@ -288,40 +546,48 @@ yb_title{
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
background: url("./imgs/numbcak.png") no-repeat;
|
background: url("./imgs/numbcak.png") no-repeat;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
margin: 0px 10px;
|
margin: 0px 10px;
|
||||||
}
|
}
|
||||||
.yb_{
|
|
||||||
|
.yb_ {
|
||||||
width: 50%;
|
width: 50%;
|
||||||
}
|
}
|
||||||
.tab_acvit{
|
|
||||||
|
.tab_acvit {
|
||||||
background: #0174F6 !important;
|
background: #0174F6 !important;
|
||||||
}
|
}
|
||||||
.five_box{
|
|
||||||
|
.five_box {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-around;
|
justify-content: space-around;
|
||||||
margin: 30px auto;
|
margin: 30px auto;
|
||||||
}
|
}
|
||||||
.f_size{
|
|
||||||
|
.f_size {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
}
|
}
|
||||||
.f_num{
|
|
||||||
|
.f_num {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 24px;
|
font-size: 24px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
}
|
}
|
||||||
.img_left{
|
|
||||||
|
.img_left {
|
||||||
width: 60px;
|
width: 60px;
|
||||||
height: 60px;
|
height: 60px;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
}
|
}
|
||||||
.f_box{
|
|
||||||
|
.f_box {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
.co_title{
|
|
||||||
|
.co_title {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
background: url("./imgs/c_title.png") no-repeat;
|
background: url("./imgs/c_title.png") no-repeat;
|
||||||
@ -332,7 +598,8 @@ yb_title{
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding-left: 40px;
|
padding-left: 40px;
|
||||||
}
|
}
|
||||||
.s_title{
|
|
||||||
|
.s_title {
|
||||||
width: 90%;
|
width: 90%;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
background: url("./imgs/title.png") no-repeat;
|
background: url("./imgs/title.png") no-repeat;
|
||||||
@ -344,53 +611,60 @@ yb_title{
|
|||||||
padding-left: 40px;
|
padding-left: 40px;
|
||||||
margin: 0px auto;
|
margin: 0px auto;
|
||||||
}
|
}
|
||||||
.echaets_box{
|
|
||||||
|
.echaets_box {
|
||||||
width: 90%;
|
width: 90%;
|
||||||
height: 267px;
|
height: 267px;
|
||||||
margin: 0px auto;
|
margin: 0px auto;
|
||||||
border-bottom: 1px solid #0174F6;
|
border-bottom: 1px solid #0174F6;
|
||||||
}
|
}
|
||||||
.list_long{
|
|
||||||
|
.list_long {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 563px;
|
height: 563px;
|
||||||
|
|
||||||
}
|
}
|
||||||
.l_one{
|
|
||||||
|
.l_one {
|
||||||
width: 30%;
|
width: 30%;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: rgba(255,255,255,0.7);
|
color: rgba(255, 255, 255, 0.7);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding-left: 35px;
|
padding-left: 35px;
|
||||||
}
|
}
|
||||||
.l_two{
|
|
||||||
|
.l_two {
|
||||||
width: 20%;
|
width: 20%;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: rgba(255,255,255,0.7);
|
color: rgba(255, 255, 255, 0.7);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
.l_three{
|
|
||||||
|
.l_three {
|
||||||
width: 20%;
|
width: 20%;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: rgba(255,255,255,0.7);
|
color: rgba(255, 255, 255, 0.7);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
.l_four{
|
|
||||||
|
.l_four {
|
||||||
width: 30%;
|
width: 30%;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: rgba(255,255,255,0.7);
|
color: rgba(255, 255, 255, 0.7);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding-right: 35px;
|
padding-right: 35px;
|
||||||
}
|
}
|
||||||
.long_title{
|
|
||||||
|
.long_title {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 58px;
|
height: 58px;
|
||||||
background: rgba(1,116,246,0.1);
|
background: rgba(1, 116, 246, 0.1);
|
||||||
background: url("./imgs/c_list.png") no-repeat;
|
background: url("./imgs/c_list.png") no-repeat;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -398,25 +672,29 @@ yb_title{
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin: 10px auto;
|
margin: 10px auto;
|
||||||
}
|
}
|
||||||
.ot_vox{
|
|
||||||
|
.ot_vox {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 500px;
|
height: 500px;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
scrollbar-width: none;
|
scrollbar-width: none;
|
||||||
}
|
}
|
||||||
.long_box{
|
|
||||||
|
.long_box {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 58px;
|
height: 58px;
|
||||||
background: rgba(1,116,246,0.1);
|
background: rgba(1, 116, 246, 0.1);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin: 10px auto;
|
margin: 10px auto;
|
||||||
}
|
}
|
||||||
.six_box{
|
|
||||||
|
.six_box {
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
}
|
}
|
||||||
.c_right{
|
|
||||||
|
.c_right {
|
||||||
width: 25%;
|
width: 25%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -419,6 +419,12 @@ export default {
|
|||||||
// 提交
|
// 提交
|
||||||
async handleSubmit() {
|
async handleSubmit() {
|
||||||
try {
|
try {
|
||||||
|
const isNull = this.validateNull();
|
||||||
|
if (!isNull) return;
|
||||||
|
const names = this.validateZero()
|
||||||
|
if (names){
|
||||||
|
await this.$modal.confirm("确认配件:" + names + "的采购价格为0吗?")
|
||||||
|
}
|
||||||
await this.createInit()
|
await this.createInit()
|
||||||
await createRepairSo(this.formData)
|
await createRepairSo(this.formData)
|
||||||
this.inStockDialog = false
|
this.inStockDialog = false
|
||||||
@ -457,6 +463,35 @@ export default {
|
|||||||
}
|
}
|
||||||
})]
|
})]
|
||||||
},
|
},
|
||||||
|
validateNull(){
|
||||||
|
const flag = this.partList.map(item => {
|
||||||
|
const price = item.newPrice
|
||||||
|
if (price === null || price === ""){
|
||||||
|
this.$modal.msgError("配件:" + item.name + "采购价格为空")
|
||||||
|
return false
|
||||||
|
}else {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
let count = 0
|
||||||
|
flag.forEach(item => {
|
||||||
|
if (!item){
|
||||||
|
count++
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return count === 0
|
||||||
|
},
|
||||||
|
validateZero(){
|
||||||
|
const flag = this.partList.map(item => {
|
||||||
|
const price = parseFloat(item.newPrice)
|
||||||
|
if (price === 0){
|
||||||
|
return item.name
|
||||||
|
}else {
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return flag.filter(item => item !== "").join(",")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -44,6 +44,12 @@
|
|||||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
|
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
|
||||||
>查看
|
>查看
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button v-hasPermi="['repair:tkm:edit']" size="mini" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">
|
||||||
|
编辑工单
|
||||||
|
</el-button>
|
||||||
|
<el-button v-hasPermi="['repair:tkm:remove']" size="mini" type="text" icon="el-icon-remove" @click="handleRemove(scope.row)">
|
||||||
|
删除
|
||||||
|
</el-button>
|
||||||
<el-button v-if="userRole === 'service_advisor' && isFinish" size="mini" type="text" icon="el-icon-refresh" @click="handleEditRecord(scope.row)">
|
<el-button v-if="userRole === 'service_advisor' && isFinish" size="mini" type="text" icon="el-icon-refresh" @click="handleEditRecord(scope.row)">
|
||||||
维修记录设置
|
维修记录设置
|
||||||
</el-button>
|
</el-button>
|
||||||
@ -77,6 +83,9 @@
|
|||||||
v-if="(userRole === 'repair_staff' ? (leader ? !isFinish : false) : false) && !(scope.row.ticketsWorkStatus !== '01' && userRole === 'repair_staff' && !isFinish)">
|
v-if="(userRole === 'repair_staff' ? (leader ? !isFinish : false) : false) && !(scope.row.ticketsWorkStatus !== '01' && userRole === 'repair_staff' && !isFinish)">
|
||||||
重新指派
|
重新指派
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button v-if="userRole === 'repair_staff' && !isFinish && scope.row.ticketsWorkStatus === '01' && !(nowUser.id === scope.row.nowRepairId)" @click="handleGet(scope.row)" size="mini" type="text" icon="el-icon-document-add">
|
||||||
|
申请配件
|
||||||
|
</el-button>
|
||||||
<el-dropdown
|
<el-dropdown
|
||||||
v-if="(scope.row.ticketsWorkStatus !== '01' && ((userRole === 'service_advisor' || userRole === 'general_inspection') && !isFinish)) || (userRole === 'repair_staff' && !isFinish && scope.row.ticketsWorkStatus !== '01')"
|
v-if="(scope.row.ticketsWorkStatus !== '01' && ((userRole === 'service_advisor' || userRole === 'general_inspection') && !isFinish)) || (userRole === 'repair_staff' && !isFinish && scope.row.ticketsWorkStatus !== '01')"
|
||||||
@command="(command) => handleCommand(command, scope.$index, scope.row)">
|
@command="(command) => handleCommand(command, scope.$index, scope.row)">
|
||||||
@ -148,11 +157,12 @@
|
|||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
<RecordSetting ref="recordSet" />
|
<RecordSetting ref="recordSet" />
|
||||||
|
<EditTickets ref="editTickets" @success="listTickets"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {getPageType, updateTake, getTicketsById} from "@/api/repair/tickets/Tickets";
|
import {getPageType, updateTake, getTicketsById, removeTicketById} from "@/api/repair/tickets/Tickets";
|
||||||
import TicketsShow from "@/views/repair/tickets/Components/TicketsShow.vue";
|
import TicketsShow from "@/views/repair/tickets/Components/TicketsShow.vue";
|
||||||
import UpdateRepair from "@/views/repair/tickets/form/UpdateRepair.vue";
|
import UpdateRepair from "@/views/repair/tickets/form/UpdateRepair.vue";
|
||||||
import TWOperate from "@/views/repair/tickets/form/TWOperate.vue";
|
import TWOperate from "@/views/repair/tickets/form/TWOperate.vue";
|
||||||
@ -162,10 +172,11 @@ import {getIfLeader} from "@/api/repair/repairworker";
|
|||||||
import UpdateRecord from "@/views/repair/tickets/form/UpdateRecord.vue";
|
import UpdateRecord from "@/views/repair/tickets/form/UpdateRecord.vue";
|
||||||
import {getUserProfile} from "@/api/system/user";
|
import {getUserProfile} from "@/api/system/user";
|
||||||
import RecordSetting from "@/views/repair/tickets/form/RecordSetting.vue";
|
import RecordSetting from "@/views/repair/tickets/form/RecordSetting.vue";
|
||||||
|
import EditTickets from "@/views/repair/tickets/form/EditTickets.vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "TicketManagerItem",
|
name: "TicketManagerItem",
|
||||||
components: {RecordSetting, UpdateRecord, TWOperate, UpdateRepair, TicketsShow},
|
components: {EditTickets, RecordSetting, UpdateRecord, TWOperate, UpdateRepair, TicketsShow},
|
||||||
props: {
|
props: {
|
||||||
isFinish: {
|
isFinish: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
@ -398,6 +409,20 @@ export default {
|
|||||||
handleEditRecord(row){
|
handleEditRecord(row){
|
||||||
this.$refs.recordSet.open(row.id)
|
this.$refs.recordSet.open(row.id)
|
||||||
},
|
},
|
||||||
|
handleEditTicket(row){
|
||||||
|
this.$refs.editTickets.open(row)
|
||||||
|
},
|
||||||
|
async handleRemove(row){
|
||||||
|
try {
|
||||||
|
const id = row.id
|
||||||
|
if (id){
|
||||||
|
await this.$modal.confirm("确认删除工单" + row.ticketNo + "吗?")
|
||||||
|
await removeTicketById(id)
|
||||||
|
await this.listTickets()
|
||||||
|
this.$modal.msgSuccess("删除成功")
|
||||||
|
}
|
||||||
|
}catch{}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -104,7 +104,7 @@
|
|||||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
|
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
|
||||||
>查看
|
>查看
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button v-if="TicketType === 'tu' && isWXCW && scope.row.isFinish === '1'" size="mini" type="text" icon="el-icon-finished"
|
<el-button v-if="scope.row.isFinish === '1'" v-hasPermi="['repair:tk:paid']" size="mini" type="text" icon="el-icon-finished"
|
||||||
@click="handlePaid(scope.row)"
|
@click="handlePaid(scope.row)"
|
||||||
>结算
|
>结算
|
||||||
</el-button>
|
</el-button>
|
||||||
@ -117,11 +117,14 @@
|
|||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="mini" type="text" icon="el-icon-printer"
|
<el-button size="mini" type="text" icon="el-icon-printer"
|
||||||
@click="handlePrint(scope.row)"
|
@click="handlePrint(scope.row)"
|
||||||
>打印
|
>下载打印
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="mini" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">
|
<el-button size="mini" v-hasPermi="['repair:tk:edit']" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">
|
||||||
编辑工单
|
编辑工单
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button size="mini" v-hasPermi="['repair:tk:remove']" type="text" icon="el-icon-remove" @click="handleRemove(scope.row)">
|
||||||
|
删除
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
@ -178,7 +181,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {setTicketsVoid, setTicketsPaid, setTicketsPrint} from '@/api/repair/tickets/Tickets'
|
import {setTicketsVoid, setTicketsPaid, setTicketsPrint, removeTicketById} from '@/api/repair/tickets/Tickets'
|
||||||
import TicketsShow from "@/views/repair/tickets/Components/TicketsShow.vue";
|
import TicketsShow from "@/views/repair/tickets/Components/TicketsShow.vue";
|
||||||
import {getByNameAndMobile} from "@/api/base/customer";
|
import {getByNameAndMobile} from "@/api/base/customer";
|
||||||
import EditTickets from "@/views/repair/tickets/form/EditTickets.vue";
|
import EditTickets from "@/views/repair/tickets/form/EditTickets.vue";
|
||||||
@ -206,7 +209,7 @@ export default {
|
|||||||
formData: {
|
formData: {
|
||||||
id: null,
|
id: null,
|
||||||
ticketsStatus: null,
|
ticketsStatus: null,
|
||||||
remark: null,
|
billingRemark: null,
|
||||||
payType: null
|
payType: null
|
||||||
},
|
},
|
||||||
formRules:{
|
formRules:{
|
||||||
@ -226,7 +229,7 @@ export default {
|
|||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
}).then(({value}) => {
|
}).then(({value}) => {
|
||||||
this.formData.id = row.id
|
this.formData.id = row.id
|
||||||
this.formData.remark = value
|
this.formData['remark'] = value
|
||||||
this.formData.ticketsStatus = "03"
|
this.formData.ticketsStatus = "03"
|
||||||
this.doVoid()
|
this.doVoid()
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
@ -260,7 +263,7 @@ export default {
|
|||||||
this.formData = {
|
this.formData = {
|
||||||
id: null,
|
id: null,
|
||||||
ticketsStatus: null,
|
ticketsStatus: null,
|
||||||
remark: null,
|
billingRemark: null,
|
||||||
payType: null
|
payType: null
|
||||||
}
|
}
|
||||||
this.formData['id'] = row.id
|
this.formData['id'] = row.id
|
||||||
@ -297,6 +300,17 @@ export default {
|
|||||||
},
|
},
|
||||||
returnSuccess(){
|
returnSuccess(){
|
||||||
this.$emit("success")
|
this.$emit("success")
|
||||||
|
},
|
||||||
|
async handleRemove(row){
|
||||||
|
try {
|
||||||
|
const id = row.id
|
||||||
|
if (id){
|
||||||
|
await this.$modal.confirm("确认删除工单" + row.ticketNo + "吗?")
|
||||||
|
await removeTicketById(id)
|
||||||
|
await this.listTickets()
|
||||||
|
this.$modal.msgSuccess("删除成功")
|
||||||
|
}
|
||||||
|
}catch{}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -123,13 +123,16 @@
|
|||||||
</div>
|
</div>
|
||||||
<!-- 卡片内容 -->
|
<!-- 卡片内容 -->
|
||||||
<div>
|
<div>
|
||||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px">
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"
|
||||||
|
label-width="90px">
|
||||||
<el-form-item label="关键字" prop="query">
|
<el-form-item label="关键字" prop="query">
|
||||||
<el-input style="width: 20rem" type="text" placeholder="工单号、车牌号、联系电话" v-model="queryParams.query"/>
|
<el-input style="width: 20rem" type="text" placeholder="工单号、车牌号、联系电话"
|
||||||
|
v-model="queryParams.query"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="状态" prop="waresStatus">
|
<el-form-item label="状态" prop="waresStatus">
|
||||||
<el-select v-model="queryParams.waresStatus">
|
<el-select v-model="queryParams.waresStatus">
|
||||||
<el-option v-for="item in this.getDictDatas(DICT_TYPE.TW_ITEM_STATUS)" :key="item.value" :label="item.label" :value="item.value" />
|
<el-option v-for="item in this.getDictDatas(DICT_TYPE.TW_ITEM_STATUS)" :key="item.value"
|
||||||
|
:label="item.label" :value="item.value"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
@ -151,42 +154,53 @@
|
|||||||
<span>{{ scope.$index + 1 }}</span>
|
<span>{{ scope.$index + 1 }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column align="center" label="客户可见" prop="isShow" v-if="userRole === 'service_advisor' && type" width="180">-->
|
<!-- <el-table-column align="center" label="客户可见" prop="isShow" v-if="userRole === 'service_advisor' && type" width="180">-->
|
||||||
<!-- <template slot-scope="scope">-->
|
<!-- <template slot-scope="scope">-->
|
||||||
<!-- <el-switch-->
|
<!-- <el-switch-->
|
||||||
<!-- v-model="scope.row.isShow"-->
|
<!-- v-model="scope.row.isShow"-->
|
||||||
<!-- active-text="是"-->
|
<!-- active-text="是"-->
|
||||||
<!-- inactive-text="否"-->
|
<!-- inactive-text="否"-->
|
||||||
<!-- active-value="1"-->
|
<!-- active-value="1"-->
|
||||||
<!-- inactive-value="0"-->
|
<!-- inactive-value="0"-->
|
||||||
<!-- @change="changeIsShow(scope.row)"-->
|
<!-- @change="changeIsShow(scope.row)"-->
|
||||||
<!-- >-->
|
<!-- >-->
|
||||||
<!-- </el-switch>-->
|
<!-- </el-switch>-->
|
||||||
<!-- </template>-->
|
<!-- </template>-->
|
||||||
<!-- </el-table-column>-->
|
<!-- </el-table-column>-->
|
||||||
<el-table-column label="名称" align="center" prop="waresName" :show-overflow-tooltip="true"/>
|
<el-table-column label="名称" align="center" prop="waresName" :show-overflow-tooltip="true"/>
|
||||||
<el-table-column label="规格" align="center" prop="wares.model" width="180"/>
|
<el-table-column label="规格" align="center" prop="wares.model" width="180"/>
|
||||||
<el-table-column label="数量" align="center" prop="waresCount" width="180"/>
|
<el-table-column label="数量" align="center" prop="waresCount" width="180"/>
|
||||||
<el-table-column v-if="userRole === 'service_advisor' && type" label="折扣" align="center" prop="itemDiscount" width="180">
|
<el-table-column v-if="userRole === 'service_advisor' && type" label="销售价格" align="center" prop="wares.price" width="180">
|
||||||
<!-- <div v-if="formData.status === '01'" class="item" slot-scope="scope">-->
|
<div v-if="formData.status === '01'" class="item" slot-scope="scope">
|
||||||
<!--<!– <el-input @blur="save(scope.row)" class="item__input" v-model="scope.row.itemDiscount"/>–>-->
|
<el-input @blur="save(scope.row)" class="item__input" v-model="scope.row.wares.price"/>
|
||||||
<!-- <DiscountInput @input-blur="save(scope.row)" class="item__input" v-model="scope.row.itemDiscount" />-->
|
<span class="item__txt">{{ scope.row.wares.price }}</span>
|
||||||
<!-- <span class="item__txt">{{ scope.row.itemDiscount === 1 ? "无折扣" : scope.row.itemDiscount }}</span>-->
|
</div>
|
||||||
<!-- </div>-->
|
<div v-else slot-scope="scope">
|
||||||
|
<span>{{ scope.row.wares.price }}</span>
|
||||||
|
</div>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column v-if="userRole === 'service_advisor' && type" label="折扣" align="center"
|
||||||
|
prop="itemDiscount" width="180">
|
||||||
|
<!-- <div v-if="formData.status === '01'" class="item" slot-scope="scope">-->
|
||||||
|
<!--<!– <el-input @blur="save(scope.row)" class="item__input" v-model="scope.row.itemDiscount"/>–>-->
|
||||||
|
<!-- <DiscountInput @input-blur="save(scope.row)" class="item__input" v-model="scope.row.itemDiscount" />-->
|
||||||
|
<!-- <span class="item__txt">{{ scope.row.itemDiscount === 1 ? "无折扣" : scope.row.itemDiscount }}</span>-->
|
||||||
|
<!-- </div>-->
|
||||||
<div slot-scope="scope">
|
<div slot-scope="scope">
|
||||||
<span>{{ scope.row.itemDiscount === 1 ? "无折扣" : scope.row.itemDiscount }}</span>
|
<span>{{ scope.row.itemDiscount === 1 ? "无折扣" : scope.row.itemDiscount }}</span>
|
||||||
</div>
|
</div>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="状态" align="center" prop="waresStatus" width="180">
|
<el-table-column label="状态" align="center" prop="waresStatus" width="180">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<dict-tag :type="DICT_TYPE.TW_ITEM_STATUS" :value="scope.row.waresStatus" />
|
<dict-tag :type="DICT_TYPE.TW_ITEM_STATUS" :value="scope.row.waresStatus"/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="备注" prop="remark" width="180" :show-overflow-tooltip="true"/>
|
<el-table-column align="center" label="备注" prop="remark" width="180" :show-overflow-tooltip="true"/>
|
||||||
</el-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
<div slot="footer" class="dialog-footer" v-if="info.status === '01' && (userRole === 'service_advisor' || userRole === 'general_inspection')">
|
<div slot="footer" class="dialog-footer"
|
||||||
|
v-if="info.status === '01' && (userRole === 'service_advisor' || userRole === 'general_inspection')">
|
||||||
<el-button type="primary" @click="handleAudit(true)">通 过</el-button>
|
<el-button type="primary" @click="handleAudit(true)">通 过</el-button>
|
||||||
<el-button @click="handleAudit(false)">驳 回</el-button>
|
<el-button @click="handleAudit(false)">驳 回</el-button>
|
||||||
</div>
|
</div>
|
||||||
@ -199,18 +213,19 @@ import {getTicketsById} from "@/api/repair/tickets/Tickets";
|
|||||||
import {auditTicketWares} from "@/api/repair/tickets/TicketWares";
|
import {auditTicketWares} from "@/api/repair/tickets/TicketWares";
|
||||||
import {listTwItem, updateIsShow} from "@/api/repair/tickets/TWItem";
|
import {listTwItem, updateIsShow} from "@/api/repair/tickets/TWItem";
|
||||||
import DiscountInput from "@/views/repair/tickets/Components/DiscountInput.vue";
|
import DiscountInput from "@/views/repair/tickets/Components/DiscountInput.vue";
|
||||||
|
import item from "@/layout/components/Sidebar/Item.vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "TicketWaresShow",
|
name: "TicketWaresShow",
|
||||||
components: {DiscountInput},
|
components: {DiscountInput},
|
||||||
props:{
|
props: {
|
||||||
userRole: String,
|
userRole: String,
|
||||||
type: Boolean
|
type: Boolean
|
||||||
},
|
},
|
||||||
data(){
|
data() {
|
||||||
return{
|
return {
|
||||||
info:{},
|
info: {},
|
||||||
items:[],
|
items: [],
|
||||||
dialogVisible: false,
|
dialogVisible: false,
|
||||||
queryParams: {
|
queryParams: {
|
||||||
twId: null,
|
twId: null,
|
||||||
@ -221,12 +236,12 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
formData: {},
|
formData: {},
|
||||||
clickCellMap: {},
|
clickCellMap: {},
|
||||||
editProp: [],
|
editProp: ['wares.price'],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods:{
|
methods: {
|
||||||
async open(row){
|
async open(row) {
|
||||||
if (row){
|
if (row) {
|
||||||
this.formData = row
|
this.formData = row
|
||||||
const res = await getTicketsById(row.ticketId)
|
const res = await getTicketsById(row.ticketId)
|
||||||
this.info = res.data
|
this.info = res.data
|
||||||
@ -236,7 +251,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.dialogVisible = true
|
this.dialogVisible = true
|
||||||
},
|
},
|
||||||
async getTwItem(){
|
async getTwItem() {
|
||||||
try {
|
try {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
const res = await listTwItem(this.queryParams)
|
const res = await listTwItem(this.queryParams)
|
||||||
@ -247,29 +262,35 @@ export default {
|
|||||||
itemDiscount: 1,
|
itemDiscount: 1,
|
||||||
}
|
}
|
||||||
})]
|
})]
|
||||||
}finally {
|
} finally {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleQuery(){
|
handleQuery() {
|
||||||
this.getTwItem()
|
this.getTwItem()
|
||||||
},
|
},
|
||||||
resetQuery(){
|
resetQuery() {
|
||||||
this.resetForm('queryForm')
|
this.resetForm('queryForm')
|
||||||
this.handleQuery()
|
this.handleQuery()
|
||||||
},
|
},
|
||||||
async changeIsShow(row){
|
async changeIsShow(row) {
|
||||||
try {
|
try {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
await updateIsShow({id: row.id, isShow: row.isShow})
|
await updateIsShow({id: row.id, isShow: row.isShow})
|
||||||
await this.getTwItem()
|
await this.getTwItem()
|
||||||
}finally {
|
} finally {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 审核
|
// 审核
|
||||||
async handleAudit(flag){
|
async handleAudit(flag) {
|
||||||
try {
|
try {
|
||||||
|
const isNull = this.validateNull();
|
||||||
|
if (!isNull) return;
|
||||||
|
const names = this.validateZero()
|
||||||
|
if (names){
|
||||||
|
await this.$modal.confirm("确认配件:" + names + "的销售价格为0吗?")
|
||||||
|
}
|
||||||
this.formData['status'] = flag ? "02" : '05'
|
this.formData['status'] = flag ? "02" : '05'
|
||||||
// 处理配件信息
|
// 处理配件信息
|
||||||
this.formData.wares = [...this.items.map(item => {
|
this.formData.wares = [...this.items.map(item => {
|
||||||
@ -292,7 +313,7 @@ export default {
|
|||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
this.$modal.msgSuccess("审核成功")
|
this.$modal.msgSuccess("审核成功")
|
||||||
this.$emit('success')
|
this.$emit('success')
|
||||||
}catch {
|
} catch {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -342,7 +363,7 @@ export default {
|
|||||||
},
|
},
|
||||||
/** 保存数据 */
|
/** 保存数据 */
|
||||||
save(row) {
|
save(row) {
|
||||||
if (row.itemDiscount <= 0 || row.itemDiscount > 10){
|
if (row.itemDiscount <= 0 || row.itemDiscount > 10) {
|
||||||
row.itemDiscount = 10
|
row.itemDiscount = 10
|
||||||
this.$modal.msgError("折扣只能是1-10")
|
this.$modal.msgError("折扣只能是1-10")
|
||||||
}
|
}
|
||||||
@ -353,6 +374,35 @@ export default {
|
|||||||
})
|
})
|
||||||
this.clickCellMap[id] = []
|
this.clickCellMap[id] = []
|
||||||
},
|
},
|
||||||
|
validateNull(){
|
||||||
|
const flag = this.items.map(item => {
|
||||||
|
const price = item.wares.price
|
||||||
|
if (price === null || price === ""){
|
||||||
|
this.$modal.msgError("配件:" + item.waresName + "销售价格为空")
|
||||||
|
return false
|
||||||
|
}else {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
let count = 0
|
||||||
|
flag.forEach(item => {
|
||||||
|
if (!item){
|
||||||
|
count++
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return count === 0
|
||||||
|
},
|
||||||
|
validateZero(){
|
||||||
|
const flag = this.items.map(item => {
|
||||||
|
const price = parseFloat(item.wares.price)
|
||||||
|
if (price === 0){
|
||||||
|
return item.waresName
|
||||||
|
}else {
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return flag.filter(item => item !== "").join(",")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@ -361,6 +411,7 @@ export default {
|
|||||||
.box-card {
|
.box-card {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item {
|
.item {
|
||||||
.item__input {
|
.item__input {
|
||||||
display: none;
|
display: none;
|
||||||
|
@ -58,6 +58,48 @@
|
|||||||
</template>
|
</template>
|
||||||
{{ parseTime(info.createTime, '{y}-{m}-{d}') }}
|
{{ parseTime(info.createTime, '{y}-{m}-{d}') }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
已行里程
|
||||||
|
</template>
|
||||||
|
{{ info.mileageTraveled }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
三包单位
|
||||||
|
</template>
|
||||||
|
{{ info.threePackUnits }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
保险名称
|
||||||
|
</template>
|
||||||
|
{{ info.insuranceName }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
管理费
|
||||||
|
</template>
|
||||||
|
{{ info.managerMoney }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
救援费
|
||||||
|
</template>
|
||||||
|
{{ info.rescueMoney }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
三包费
|
||||||
|
</template>
|
||||||
|
{{ info.threePackMoney }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">
|
||||||
|
定损费
|
||||||
|
</template>
|
||||||
|
{{ info.confirmFaultMoney }}
|
||||||
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">
|
<template slot="label">
|
||||||
预计完工
|
预计完工
|
||||||
|
@ -393,10 +393,10 @@ export default {
|
|||||||
mileageTraveled: null,
|
mileageTraveled: null,
|
||||||
threePackUnits: null,
|
threePackUnits: null,
|
||||||
insuranceName: null,
|
insuranceName: null,
|
||||||
managerMoney: null,
|
managerMoney: 0,
|
||||||
rescueMoney: null,
|
rescueMoney: 0,
|
||||||
threePackMoney: null,
|
threePackMoney: 0,
|
||||||
confirmFaultMoney: null,
|
confirmFaultMoney: 0,
|
||||||
},
|
},
|
||||||
selectUser: {},
|
selectUser: {},
|
||||||
selectCar: {},
|
selectCar: {},
|
||||||
@ -535,10 +535,10 @@ export default {
|
|||||||
mileageTraveled: null,
|
mileageTraveled: null,
|
||||||
threePackUnits: null,
|
threePackUnits: null,
|
||||||
insuranceName: null,
|
insuranceName: null,
|
||||||
managerMoney: null,
|
managerMoney: 0,
|
||||||
rescueMoney: null,
|
rescueMoney: 0,
|
||||||
threePackMoney: null,
|
threePackMoney: 0,
|
||||||
confirmFaultMoney: null,
|
confirmFaultMoney: 0,
|
||||||
}
|
}
|
||||||
this.selectUser = {}
|
this.selectUser = {}
|
||||||
this.selectCar = {}
|
this.selectCar = {}
|
||||||
|
@ -234,11 +234,63 @@
|
|||||||
<el-button @click="addDialog = false">取 消</el-button>
|
<el-button @click="addDialog = false">取 消</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog title="信息修改" :visible.sync="infoDialog" width="60%" v-dialogDrag append-to-body ref="infoDialog">
|
||||||
|
<el-form :model="infoFormData" :inline="true" ref="infoForm" label-width="10rem">
|
||||||
|
<el-row :gutter="2">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="已行里程" prop="mileageTraveled">
|
||||||
|
<el-input v-model="infoFormData.mileageTraveled" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="三包单位" prop="threePackUnits">
|
||||||
|
<el-input v-model="infoFormData.threePackUnits" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="2">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="保险名称" prop="insuranceName">
|
||||||
|
<el-input v-model="infoFormData.insuranceName" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="管理费" prop="managerMoney">
|
||||||
|
<el-input v-model="infoFormData.managerMoney" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="2">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="救援费" prop="rescueMoney">
|
||||||
|
<el-input v-model="infoFormData.rescueMoney" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="三包费" prop="threePackMoney">
|
||||||
|
<el-input v-model="infoFormData.threePackMoney" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="2">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="定损费" prop="confirmFaultMoney">
|
||||||
|
<el-input v-model="infoFormData.confirmFaultMoney" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="handleUpdate">确 定</el-button>
|
||||||
|
<el-button @click="infoDialog = false">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {getTicketsById, updateShow, addItems} from "@/api/repair/tickets/Tickets";
|
import {getTicketsById, updateShow, addItems, updateTicket} from "@/api/repair/tickets/Tickets";
|
||||||
import {removeItemById} from "@/api/repair/tickets/TicketsItem";
|
import {removeItemById} from "@/api/repair/tickets/TicketsItem";
|
||||||
import TicketItemShow from "@/views/repair/tickets/Components/TicketItemShow.vue";
|
import TicketItemShow from "@/views/repair/tickets/Components/TicketItemShow.vue";
|
||||||
import other from "@/views/repair/other/index.vue";
|
import other from "@/views/repair/other/index.vue";
|
||||||
@ -270,6 +322,17 @@ export default {
|
|||||||
projectList: [],
|
projectList: [],
|
||||||
waresList: [],
|
waresList: [],
|
||||||
otherList: [],
|
otherList: [],
|
||||||
|
infoDialog: false,
|
||||||
|
infoFormData: {
|
||||||
|
id: null,
|
||||||
|
mileageTraveled: null,
|
||||||
|
threePackUnits: null,
|
||||||
|
insuranceName: null,
|
||||||
|
managerMoney: 0,
|
||||||
|
rescueMoney: 0,
|
||||||
|
threePackMoney: 0,
|
||||||
|
confirmFaultMoney: 0,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
@ -395,7 +458,28 @@ export default {
|
|||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
},
|
},
|
||||||
handleEditInfo(){
|
handleEditInfo(){
|
||||||
// todo
|
this.infoFormData = {
|
||||||
|
id: this.info.id,
|
||||||
|
mileageTraveled: this.info.mileageTraveled,
|
||||||
|
threePackUnits: this.info.threePackUnits,
|
||||||
|
insuranceName: this.info.insuranceName,
|
||||||
|
managerMoney: this.info.managerMoney | 0,
|
||||||
|
rescueMoney: this.info.rescueMoney | 0,
|
||||||
|
threePackMoney: this.info.threePackMoney | 0,
|
||||||
|
confirmFaultMoney: this.info.confirmFaultMoney | 0,
|
||||||
|
}
|
||||||
|
this.infoDialog = true
|
||||||
|
},
|
||||||
|
async handleUpdate(){
|
||||||
|
try{
|
||||||
|
this.loadingInstance.$loading({
|
||||||
|
target: this.$refs.infoDialog.$el
|
||||||
|
})
|
||||||
|
await updateTicket(this.infoFormData)
|
||||||
|
this.infoDialog = false
|
||||||
|
this.$modal.msgSuccess("修改成功")
|
||||||
|
await this.open(this.infoFormData.id)
|
||||||
|
}catch{}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -308,7 +308,10 @@ export default {
|
|||||||
formRules: {
|
formRules: {
|
||||||
'userInfo.cusName':[{required: true, message: "客户名称不能为空", trigger: 'blur'}],
|
'userInfo.cusName':[{required: true, message: "客户名称不能为空", trigger: 'blur'}],
|
||||||
'userInfo.phoneNumber': [{required: true, message: "联系方式不能为空", trigger: 'blur'}],
|
'userInfo.phoneNumber': [{required: true, message: "联系方式不能为空", trigger: 'blur'}],
|
||||||
'carInfo.licenseNumber': [{required: true, message: "车牌号不能为空", trigger: 'blur'}]
|
'carInfo.licenseNumber': [{required: true, message: "车牌号不能为空", trigger: 'blur'}],
|
||||||
|
'carInfo.brandAndModel': [{required: true, message: "品牌型号不能为空", trigger: 'blur'}],
|
||||||
|
'carInfo.carCategory': [{required: true, message: '车辆类别不能为空', trigger: 'blur'}],
|
||||||
|
'carInfo.carNature': [{required: true, message: '车辆性质不能为空', trigger: 'blur'}]
|
||||||
},
|
},
|
||||||
formLoading: false,
|
formLoading: false,
|
||||||
//折叠面板默认展开
|
//折叠面板默认展开
|
||||||
@ -369,9 +372,11 @@ export default {
|
|||||||
await updateCustomerAndCar(this.formData)
|
await updateCustomerAndCar(this.formData)
|
||||||
this.$modal.msgSuccess(this.formData?.userInfo?.id ? "修改成功" : "新增成功")
|
this.$modal.msgSuccess(this.formData?.userInfo?.id ? "修改成功" : "新增成功")
|
||||||
this.$emit("success", this.formData)
|
this.$emit("success", this.formData)
|
||||||
}finally {
|
|
||||||
this.formLoading = false
|
this.formLoading = false
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
|
}catch {}
|
||||||
|
finally {
|
||||||
|
this.formLoading = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
reset(){
|
reset(){
|
||||||
|
Loading…
Reference in New Issue
Block a user