4 Commits

42 changed files with 199 additions and 1821 deletions

View File

@ -316,20 +316,4 @@ export function unifiedOCRWithCompress(data){
contentType:'application/json', contentType:'application/json',
data data
}) })
}
// 服务商是否培训
export function jumpPage(data){
return request({
url:'/supplierAppV2/dispatchApp/user/jumpPage',
method:'POST',
data
})
}
//
export function sendInsuranceEmail(){
return request({
url:'/supplierAppV2/dispatchApp/user/sendInsuranceEmail',
method:'POST',
})
} }

View File

@ -112,43 +112,3 @@ export function correctionHandle(data) {
data data
}) })
} }
// 获取报警列表
export function getAlarmList(data) {
return request({
url: '/supplierAppV2/dispatchApp/alarm/alarmList',
method:'POST',
contentType: 'application/json',
data
})
}
// 获取报警数目
export function getAlarmCount(data) {
return request({
url: '/supplierAppV2/dispatchApp/alarm/alarmCount',
method:'POST',
data
})
}
// 获取报警详情
export function getAlarmByCode(data) {
return request({
url: '/supplierAppV2/dispatchApp/alarm/getAlarmByCode',
method:'POST',
data
})
}
// 处理报警
export function dealWithAlarm(data) {
return request({
url: '/supplierAppV2/dispatchApp/alarm/handAlarm',
method:'POST',
data
})
}

View File

@ -93,23 +93,4 @@ export function saveRecord(data){
contentType: 'application/json', contentType: 'application/json',
data data
}) })
} }
// 审核不通过再次提交
export function auditCarInfoAgain(data){
return request({
url: '/toc-user/car-app/auditCarInfoAgain',
method:'POST',
contentType: 'application/json',
data
})
}
// 我的发布列表
export function getAddressForService(data){
return request({
url: '/base/gaodeMap/getPlaceByAddress',
method:'GET',
params: data,
})
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 785 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 770 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

View File

@ -251,22 +251,6 @@ const routes = [
title:'车辆维保' title:'车辆维保'
} }
}, },
{
path: '/vehicleAlarmList',
name: 'vehicleAlarmList',
component:()=>import('@/views/vehicle-maintenance/vehicle-alarm-list.vue'),
meta: {
title:'车辆报警'
}
},
{
path: '/vehicleAlarmDetail',
name: 'vehicleAlarmDetail',
component:()=>import('@/views/vehicle-maintenance/vehicle-alarm-detail.vue'),
meta: {
title:'报警详情'
}
},
{ {
path: '/maintenanceApplication', path: '/maintenanceApplication',
name: 'maintenanceApplication', name: 'maintenanceApplication',

View File

@ -17,13 +17,5 @@ const reportRouter = [
title: '道路救援', title: '道路救援',
} }
}, },
{
path: '/insuredPage',
name: 'insuredPage',
component: () => import('@/views/liabilityInsurance/insuredPage'),
meta:{
title: '参保救援职业责任险',
}
},
] ]
export default reportRouter export default reportRouter

View File

@ -55,13 +55,5 @@ const secondHandCar = [
title: '免责声明', title: '免责声明',
} }
}, },
{
path: '/sellingInfo',
name: 'sellingInfo',
component: () => import('@/views/secondHandCar/sellingInfo.vue'),
meta:{
title: '售出信息',
}
},
] ]
export default secondHandCar export default secondHandCar

View File

@ -25,7 +25,7 @@ service.interceptors.request.use(
} }
config.headers['Content-Type'] = config.contentType || 'application/x-www-form-urlencoded' config.headers['Content-Type'] = config.contentType || 'application/x-www-form-urlencoded'
let token = localStorage.getItem('token'); let token = localStorage.getItem('token');
// let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJBTkNIQU5HIiwidXNlcklkIjo0NTY3MSwibmFtZSI6IuWuieeVhSIsInVzZXJOYW1lIjoiQU5DSEFORyIsInN1cHBsaWVySWQiOjExMjgsImlzWmQiOjAsImV4cCI6MTc1NTQyMjUyNX0.xzDZhaANJFnbeViIHJA0SEtOyTv7Ja3rKmXqRKRuFkc' // let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJBTkNIQU5HIiwidXNlcklkIjo0NTY3MSwibmFtZSI6IuWuieeVhSIsInVzZXJOYW1lIjoiQU5DSEFORyIsInN1cHBsaWVySWQiOjExMjgsImlzWmQiOjAsImV4cCI6MTc1MjEzNDc2M30.q1O7C8thZzEMVKYDhBQ-N_14Fh9Bqejj7j11EKLF5Aw'
// let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJTSEhQWEIiLCJ1c2VySWQiOjU0NzI2LCJuYW1lIjoiI-a1i-ivleWwj-eZveeZvSIsInVzZXJOYW1lIjoiU0hIUFhCIiwic3VwcGxpZXJJZCI6MTAwMDE2NSwiZXhwIjoxNzQ0NTEwNzkwfQ.JPk0OA7slYJN3FIi_uhW4Y0CiWRvl6R1dK8MRTbyhD8' // let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJTSEhQWEIiLCJ1c2VySWQiOjU0NzI2LCJuYW1lIjoiI-a1i-ivleWwj-eZveeZvSIsInVzZXJOYW1lIjoiU0hIUFhCIiwic3VwcGxpZXJJZCI6MTAwMDE2NSwiZXhwIjoxNzQ0NTEwNzkwfQ.JPk0OA7slYJN3FIi_uhW4Y0CiWRvl6R1dK8MRTbyhD8'
if(!(reqUrl=='/supplier/supplierTraining/trainingTask' || reqUrl=='/supplier/supplierTraining/normalList' || reqUrl=='/supplier/supplierTraining/trainingList')){ if(!(reqUrl=='/supplier/supplierTraining/trainingTask' || reqUrl=='/supplier/supplierTraining/normalList' || reqUrl=='/supplier/supplierTraining/trainingList')){
if(token) { if(token) {

View File

@ -1,4 +1,3 @@
import { getAddressForService } from "@/api/secondHandCar"
// 获取定位, 返回 经纬度 // 获取定位, 返回 经纬度
export function getLocal(mapContext) { export function getLocal(mapContext) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
@ -47,19 +46,7 @@ export function getAddress(mapContext, lnglat) {
// 输入提示 // 输入提示
export function searchFun(mapContext, cityCode, keyword) { export function searchFun(mapContext, cityCode, keyword) {
return new Promise((resolve) => { return new Promise((resolve) => {
getAddressForService({ mapContext.plugin('AMap.AutoComplete', function(){
city: '',
address: keyword
}).then((res) => {
if(res.code == 200) {
resolve(res?.data?.pois || [])
} else {
resolve([])
}
}).catch(() => {
resolve([])
})
/*mapContext.plugin('AMap.AutoComplete', function(){
var autoOptions = { var autoOptions = {
city: cityCode || '全国', city: cityCode || '全国',
}; };
@ -74,7 +61,7 @@ export function searchFun(mapContext, cityCode, keyword) {
resolve([]) resolve([])
} }
}) })
})*/ })
}) })
} }

View File

@ -76,7 +76,7 @@
import { Decimal } from 'decimal.js'; import { Decimal } from 'decimal.js';
import { Dialog } from "vant"; import { Dialog } from "vant";
import { myMixins } from "@/utils/myMixins" import { myMixins } from "@/utils/myMixins"
import { uploadInvoice, getBillingInfo, deleteInvoice, createBatch, jumpPage} from "@/api/mine" import { uploadInvoice, getBillingInfo, deleteInvoice, createBatch } from "@/api/mine"
export default { export default {
name: "uploadInvoice", name: "uploadInvoice",
mixins:[ myMixins ], mixins:[ myMixins ],
@ -132,10 +132,6 @@
} }
}, },
methods: { methods: {
async getJumpHandler() {
let res = await jumpPage();
return res
},
async initData() { async initData() {
this.list = JSON.parse(localStorage.getItem('list')); this.list = JSON.parse(localStorage.getItem('list'));
this.batchIds = []; this.batchIds = [];
@ -234,12 +230,7 @@
}).catch(() => { }).catch(() => {
}); });
}, },
async beforeRead (file) { beforeRead (file) {
let res = await this.getJumpHandler();
if(res?.data?.jump) {
this.$message.warning("您有没有完成的培训请在中道调度APP上完成培训再进行发票上传")
return false
}
const FileExt = file.name.replace(/.+\./, ""); const FileExt = file.name.replace(/.+\./, "");
if (['jpg', 'png', 'jpeg', 'pdf', 'ofd'].indexOf(FileExt.toLowerCase()) === -1) { if (['jpg', 'png', 'jpeg', 'pdf', 'ofd'].indexOf(FileExt.toLowerCase()) === -1) {
this.$toast('请上传后缀名为jpg、jpeg、png、pdf、ofd的文件') this.$toast('请上传后缀名为jpg、jpeg、png、pdf、ofd的文件')

View File

@ -308,7 +308,7 @@ export default {
}else{ }else{
this.supplierServiceList = this.oldSupplierServiceList this.supplierServiceList = this.oldSupplierServiceList
} }
this.setDefault();
}, },
}, },
@ -321,23 +321,6 @@ export default {
} }
}, },
methods:{ methods:{
setDefault() {
if( this.vehicleLicenseInfo?.vehicleType?.includes('小型') || this.vehicleLicenseInfo?.vehicleType?.includes('微型') || this.vehicleLicenseInfo?.vehicleType?.includes('普通') || this.vehicleLicenseInfo?.vehicleType?.includes('摩托') ) {
this.vehicleTypes.map(item => {
if( item.value == 1 || item.value == 9 ) {
item.disabled = false;
} else {
item.disabled = true;
}
})
this.$forceUpdate();
} else {
this.vehicleTypes.map(item => {
item.disabled = false;
})
this.$forceUpdate();
}
},
getVehicleLicense(color) { getVehicleLicense(color) {
if( color == '蓝' ) { if( color == '蓝' ) {
this.vehicleLicense = 1 this.vehicleLicense = 1
@ -419,7 +402,6 @@ export default {
this.vehicleLicenseInfo.registrationDate = frontInfo?.registerDate; this.vehicleLicenseInfo.registrationDate = frontInfo?.registerDate;
this.vehicleLicenseInfo.issueDate = frontInfo?.issueDate; this.vehicleLicenseInfo.issueDate = frontInfo?.issueDate;
this.vehicleLicenseInfo.issueAuthority = frontInfo?.seal; this.vehicleLicenseInfo.issueAuthority = frontInfo?.seal;
this.setDefault();
} }
}, },
async vehicleBackOcrHandler() { // 行驶证副页 ocr 识别 async vehicleBackOcrHandler() { // 行驶证副页 ocr 识别

View File

@ -84,7 +84,7 @@ export default {
color:'rgba(4, 4, 21,0.45)' color:'rgba(4, 4, 21,0.45)'
}, },
detail: { detail: {
color:this.isStore ? this.bgColor : (this.bgColor || '#040415'), color:this.isStore ? this.bgColor : '#040415',
fontSize: this.isStore ? 43 :19, fontSize: this.isStore ? 43 :19,
formatter: this.isStore ? '{value}' : '{value}%' formatter: this.isStore ? '{value}' : '{value}%'
} }
@ -110,4 +110,4 @@ export default {
width: 100%; width: 100%;
height: 125px; height: 125px;
} }
</style> </style>

View File

@ -39,7 +39,7 @@
<van-tabs v-model="active" sticky @click="tabClickHandle"> <van-tabs v-model="active" sticky @click="tabClickHandle">
<van-tab v-for="(item,index) in tabArr" :key="index" :title="item.name"></van-tab> <van-tab v-for="(item,index) in tabArr" :key="index" :title="item.name"></van-tab>
<div v-if="isMobile && !([0,1,2,3].includes(active))" class="tipArrow left">{{ leftArr }}</div> <div v-if="isMobile && !([0,1,2,3].includes(active))" class="tipArrow left">{{ leftArr }}</div>
<div v-if="isMobile && !([9,10, 11].includes(active))" class="tipArrow right">>>></div> <div v-if="isMobile && !([9,10].includes(active))" class="tipArrow right">>>></div>
</van-tabs> </van-tabs>
<div v-loading="loadingData" :class="{'contentWrap':true,'webcontentWrap':!isMobile}" v-if="active===0"> <div v-loading="loadingData" :class="{'contentWrap':true,'webcontentWrap':!isMobile}" v-if="active===0">
<div :class="{'reciceOrder':true,'webCom':!isMobile}"> <div :class="{'reciceOrder':true,'webCom':!isMobile}">
@ -51,11 +51,11 @@
<div class="itemTitle">承接案件量</div> <div class="itemTitle">承接案件量</div>
</div> </div>
<div class="center common" @click="clickJumpHandle(5)"> <div class="center common" @click="clickJumpHandle(5)">
<div class="num" :class="{'numRed': Number(indexData?.refuseOrderRate) >= 5, 'numGreen': Number(indexData?.refuseOrderRate) < 5 }">{{ indexData && indexData.refuseOrderRate }}%</div> <div class="num">{{ indexData && indexData.refuseOrderRate }}%</div>
<div class="itemTitle" style="cursor: pointer">拒单率 ></div> <div class="itemTitle" style="cursor: pointer">拒单率 ></div>
</div> </div>
<div class="right common" @click="clickJumpHandle(6)"> <div class="right common" @click="clickJumpHandle(6)">
<div class="num" :class="{'numRed': Number(indexData?.timeoutOrderRate) >= 5, 'numGreen': Number(indexData?.timeoutOrderRate) < 5 }">{{ indexData && indexData.timeoutOrderRate }}%</div> <div class="num">{{ indexData && indexData.timeoutOrderRate }}%</div>
<div class="itemTitle" style="cursor: pointer">超时率 ></div> <div class="itemTitle" style="cursor: pointer">超时率 ></div>
</div> </div>
</div> </div>
@ -63,39 +63,41 @@
<div :class="{'reciceOrder':true,'webCom':!isMobile,'evaluate':isMobile}"> <div :class="{'reciceOrder':true,'webCom':!isMobile,'evaluate':isMobile}">
<div class="title">客户评价</div> <div class="title">客户评价</div>
<div class="reciceOrderIWrap" v-if="indexData"> <div class="reciceOrderIWrap" v-if="indexData">
<circle-char ref="Doughnut1" :data="indexData && indexData.complainOrderRate" :title-text="'投诉率'" :bg-color="Number(indexData?.complainOrderRate || 0) <= 0.01 ? 'green' : 'red'" <circle-char ref="Doughnut1" :data="indexData && indexData.complainOrderRate" :title-text="'投诉率'" :bg-color="'#9485ED'"
:is-store="false" @clickComplain="clickJumpHandle(7)"></circle-char> :is-store="false" @clickComplain="clickJumpHandle(7)"></circle-char>
<circle-char ref="Doughnut2" :data="indexData && indexData.customerSatisfaction" :title-text="'平安好评率'" <circle-char ref="Doughnut2" :data="indexData && indexData.customerSatisfaction" :title-text="'客户满意度'"
:bg-color="Number(indexData?.customerSatisfaction || 0) >= 99.4 ? 'green' : 'red'"></circle-char> :bg-color="'#5DDECF'"></circle-char>
<circle-char ref="Doughnut3" :data="indexData && indexData.urgeRate" :title-text="'催促率'" <circle-char ref="Doughnut3" :data="indexData && indexData.urgeRate" :title-text="'催促率'"
:bg-color="Number(indexData?.urgeRate || 0) >= 3 ? 'red' : 'green'"></circle-char> :bg-color="'#FFADAD'"></circle-char>
</div> </div>
</div> </div>
<div :class="{'reciceOrder':true,'webCom':!isMobile,'appUse':isMobile}"> <div :class="{'reciceOrder':true,'webCom':!isMobile,'appUse':isMobile}">
<div class="title">APP使用</div> <div class="title">APP使用</div>
<div class="reciceOrderIWrap" v-if="indexData"> <div class="reciceOrderIWrap" v-if="indexData">
<circle-char ref="Doughnut4" :data="indexData && indexData.appRate" :title-text="'APP使用率'" :bg-color="Number(indexData?.appRate || 0) >= 95 ? 'green' : 'red'" <circle-char ref="Doughnut4" :data="indexData && indexData.appRate" :title-text="'使用率'" :bg-color="'#3AA1FF'"
:is-store="false" :is-store="false"
@clickUse="clickJumpHandle(8)"></circle-char> @clickUse="clickJumpHandle(8)"></circle-char>
<circle-char ref="Doughnut5" :data="indexData && indexData.threeMinutesContactRate" :title-text="'3联系客户率'" :bg-color="Number(indexData?.threeMinutesContactRate || 0) >= 90 ? 'green' : 'red'"></circle-char> <circle-char ref="Doughnut5" :data="indexData && indexData.threeMinutesContactRate" :title-text="'3联系客户率'"
<circle-char ref="Doughnut6" :data="indexData && indexData.polymerizationSuccessRate" :title-text="'总聚合成功率'" :bg-color="Number(indexData?.polymerizationSuccessRate || 0) >= 80 ? 'green' : 'red'"></circle-char> :bg-color="'#5D7FD7'"></circle-char>
<circle-char ref="Doughnut6" :data="indexData && indexData.polymerizationSuccessRate" :title-text="'总聚合成功率'"
:bg-color="'#4ECB73'"></circle-char>
</div> </div>
</div> </div>
<div :class="{'reciceOrder':true,'webCom':!isMobile}"> <div :class="{'reciceOrder':true,'webCom':!isMobile}">
<div :class="{'title':true,'webTitle':!isMobile}">时效</div> <div :class="{'title':true,'webTitle':!isMobile}">时效</div>
<div class="reciceOrderIWrap"> <div class="reciceOrderIWrap">
<div class="left common"> <div class="left common">
<div class="num" :class="{'numRed': Number(indexData?.receiving) > 5, 'numGreen': Number(indexData?.receiving) <= 5 }">{{ indexData && indexData.receiving }}</div> <div class="num">{{ indexData && indexData.receiving }}</div>
<div class="itemTitle">接单时效()</div> <div class="itemTitle">接单时效()</div>
</div> </div>
<div class="line"></div> <div class="line"></div>
<div class="center common"> <div class="center common">
<div class="num" :class="{'numRed': Number(indexData?.polymerizationSuccessArriving) > 22, 'numGreen': Number(indexData?.polymerizationSuccessArriving) <= 22 }">{{ indexData && indexData.polymerizationSuccessArriving }}</div> <div class="num">{{ indexData && indexData.polymerizationSuccessArriving }}</div>
<div class="itemTitle">集合成功到达时效()</div> <div class="itemTitle">集合成功到达时效()</div>
</div> </div>
<div class="line"></div> <div class="line"></div>
<div class="right common"> <div class="right common">
<div class="num" :class="{'numRed': Number(indexData?.arriving) > 40, 'numGreen': Number(indexData?.arriving) <= 40 }">{{ indexData && indexData.arriving }}</div> <div class="num">{{ indexData && indexData.arriving }}</div>
<div class="itemTitle">到达时效()</div> <div class="itemTitle">到达时效()</div>
</div> </div>
</div> </div>
@ -109,7 +111,7 @@
<i class="el-icon-question" @click.prevent="showScoreChart = !showScoreChart"></i> <i class="el-icon-question" @click.prevent="showScoreChart = !showScoreChart"></i>
</div> </div>
<div class="storeWrap" v-if="indexData"> <div class="storeWrap" v-if="indexData">
<circle-char v-show="showScoreChart" ref="Doughnut7" :data="indexData && indexData.score" :bg-color="Number(indexData?.score || 0) >= 60 ? 'green' : 'red'" :is-store="true"></circle-char> <circle-char v-show="showScoreChart" ref="Doughnut7" :data="indexData && indexData.score" :bg-color="'#00D273'" :is-store="true"></circle-char>
<div v-show="!showScoreChart" class="detailScore"> <div v-show="!showScoreChart" class="detailScore">
<div class="left"> <div class="left">
<div> <div>
@ -243,7 +245,7 @@
:total="total"> :total="total">
</el-pagination> </el-pagination>
</div> </div>
<div v-loading="loadingData" class="contentWrap monthTotal" v-if="[3,6,7,8,9,10, 11].includes(active)"> <div v-loading="loadingData" class="contentWrap monthTotal" v-if="[3,6,7,8,9,10].includes(active)">
<div :class="{'comTab':true,'detailTable':isMobile}"> <div :class="{'comTab':true,'detailTable':isMobile}">
<noFit-table :active='active' :is-mobile='isMobile' :table-data="detailList" :label-list="labelList" <noFit-table :active='active' :is-mobile='isMobile' :table-data="detailList" :label-list="labelList"
></noFit-table> ></noFit-table>
@ -290,7 +292,7 @@ export default {
// //
tabArr: [ tabArr: [
{name: '总览'}, {name: '月/总'}, {name: '日/总'},{name: '师傅满意度'},{name: '月/师傅'}, {name: '日/师傅'}, {name: '拒单明细'}, {name: '总览'}, {name: '月/总'}, {name: '日/总'},{name: '师傅满意度'},{name: '月/师傅'}, {name: '日/师傅'}, {name: '拒单明细'},
{name: '超时明细'}, {name: '投诉明细'}, {name: '不使用APP案件明细'}, {name: '车辆在线情况'} , {name: '聚合失败案件明细'} {name: '超时明细'}, {name: '投诉明细'}, {name: '不使用APP案件明细'}, {name: '车辆在线情况'}
], ],
list: [{name: '接单指标'}, {name: '客户评价'}, {name: 'APP使用'}, {name: ' 时效 '}], list: [{name: '接单指标'}, {name: '客户评价'}, {name: 'APP使用'}, {name: ' 时效 '}],
driverList: [{name: '得分总览'},{name: '接单情况'}, {name: '服务评价'}, {name: 'APP使用情况'}, {name: '时效 '}], driverList: [{name: '得分总览'},{name: '接单情况'}, {name: '服务评价'}, {name: 'APP使用情况'}, {name: '时效 '}],
@ -310,12 +312,10 @@ export default {
v4: [], v4: [],
v5: [], v5: [],
v6: [], v6: [],
v7: [],
v8: [],
xAxisArr: [], xAxisArr: [],
isMobile: false, isMobile: false,
isZd: '', isZd: '',
current:'2024-10', current:'',
// current: dayjs(new Date()).format('M'), // current: dayjs(new Date()).format('M'),
supplierName:'', supplierName:'',
value: '1', value: '1',
@ -370,19 +370,14 @@ export default {
} }
}, },
monthChangeHandle(value){ monthChangeHandle(value){
console.log('valuevaluevalue', dayjs(new Date(value)).format('YYYY-MM-DD'))
if (value) { if (value) {
this.current = dayjs(new Date(value)).format('YYYY-MM') const year = value.getFullYear();
const _tempDate = dayjs(new Date(value)).format('YYYY-MM-DD')
const lastDay = dayjs(_tempDate).endOf('month');
/*const year = value.getFullYear();
const month = value.getMonth() + 1; // 月份从 0 开始,需要加 1 const month = value.getMonth() + 1; // 月份从 0 开始,需要加 1
const yearAndMonth = year + '-' + (month > 9 ? month : '0' + month); const yearAndMonth = year + '-' + (month > 9 ? month : '0' + month);
this.current = dayjs(new Date(yearAndMonth)).format('YYYY-MM')*/ this.current = dayjs(new Date(yearAndMonth)).format('YYYY-MM')
this.startTime = `${this.current}-01 00:00:00`; this.startTime = `${year}-${this.padZero(month)}-01 00:00:00`;
// const lastDay = new Date(year, month, 0).getDate(); // 获取该月的最后一天 const lastDay = new Date(year, month, 0).getDate(); // 获取该月的最后一天
this.endTime = `${this.current}-${this.padZero(lastDay.date())} 23:59:59`; this.endTime = `${year}-${this.padZero(month)}-${this.padZero(lastDay)} 23:59:59`;
this.startMonthTime=this.getStartTimeFromEndTime(this.endTime) this.startMonthTime=this.getStartTimeFromEndTime(this.endTime)
console.log(" this.startMonthTime", this.startMonthTime) console.log(" this.startMonthTime", this.startMonthTime)
this.selectSupplierNameHandle(); this.selectSupplierNameHandle();
@ -460,8 +455,6 @@ export default {
this.v4 = [] this.v4 = []
this.v5 = [] this.v5 = []
this.v6 = [] this.v6 = []
this.v7 = []
this.v8 = []
this.xAxisArr = [] this.xAxisArr = []
this.etlDetailList=[] this.etlDetailList=[]
this.etlLabelList=[] this.etlLabelList=[]
@ -552,7 +545,7 @@ export default {
formatter: '{c}%' formatter: '{c}%'
}, },
}, },
/* { {
name: '客户取消率', name: '客户取消率',
type: "line", type: "line",
data: this.v4, data: this.v4,
@ -563,13 +556,24 @@ export default {
position: 'top', position: 'top',
formatter: '{c}%' formatter: '{c}%'
}, },
},*/ },
] ]
let series2 = [ let series2 = [{
name: '客户评价率',
type: 'line',
data: this.v1,
smooth: true,
yAxisIndex: 0,
label: {
show: true, // 显示标签
position: 'top', // 标签位置在柱形顶部
formatter: '{c}%'
}
},
{ {
name: '投诉率', name: '投诉率',
type: "line", type: "line",
data: this.v2, data: this.v3,
smooth: true, smooth: true,
yAxisIndex: 0, yAxisIndex: 0,
label: { label: {
@ -579,10 +583,10 @@ export default {
}, },
}, },
{ {
name: '好评率', name: '客户满意度',
type: 'line', type: 'line',
smooth: true, smooth: true,
data: this.v4, data: this.v2,
yAxisIndex: 0, yAxisIndex: 0,
label: { label: {
show: true, show: true,
@ -591,7 +595,7 @@ export default {
}, },
}, },
] ]
/*let series3 = [ let series3 = [
{ {
name: 'APP使用率', name: 'APP使用率',
type: 'line', type: 'line',
@ -664,8 +668,8 @@ export default {
formatter: '{c}%' formatter: '{c}%'
}, },
}, },
]*/ ]
/*let series4 = [{ let series4 = [{
name: '接单时效(分)', name: '接单时效(分)',
type: 'bar', type: 'bar',
data: this.v1, data: this.v1,
@ -689,19 +693,6 @@ export default {
formatter: '{c}%' formatter: '{c}%'
}, },
}, },
]*/
let series4 = [
{
name: '接单时效(分)',
type: 'line',
smooth: true,
data: this.v1,
yAxisIndex: 0,
label: {
show: true,
position: 'top',
},
},
] ]
let series5 = [{ let series5 = [{
name: '到达时效(分)', name: '到达时效(分)',
@ -756,15 +747,21 @@ export default {
formatter: '{value}%' formatter: '{value}%'
} }
} ] } ]
/*let yAxis3 = [ let yAxis3 = [
{ {
type: 'value', type: 'value',
axisLabel: { axisLabel: {
formatter: '{value}%' formatter: '{value}%'
} }
}, },
]*/ ]
let yAxis4 = [ let yAxis4 = [
{
type: 'value',
axisLabel: {
formatter: '{value}%'
}
},
{type: 'value'}, {type: 'value'},
] ]
let yAxis5 = [ let yAxis5 = [
@ -786,8 +783,8 @@ export default {
series = series2 series = series2
yAxis = yAxis2 yAxis = yAxis2
} else if (this.activeIndex === 2) { } else if (this.activeIndex === 2) {
series = [] series = series3
yAxis = [] yAxis = yAxis3
} else if (this.activeIndex === 3) { } else if (this.activeIndex === 3) {
if (this.value == 1) { if (this.value == 1) {
series = series4 series = series4
@ -800,7 +797,7 @@ export default {
} }
option = { option = {
title: { title: {
text: this.isMobile ? this.getTitle(this.activeIndex) : (this.active === 1 && this.activeIndex === 2) ? '' : '师傅接单时效', text: this.isMobile ? this.getTitle(this.activeIndex) : '师傅接单时效',
textStyle: { textStyle: {
fontSize: 12 fontSize: 12
}, },
@ -855,32 +852,41 @@ export default {
containLabel: true containLabel: true
}, },
yAxis: [ yAxis: [
{
type: 'value',
axisLabel: {
formatter: '{value}%'
}
},
{type: 'value'}, {type: 'value'},
], ],
series: [{ series: [{
name: '到达时效', name: '到达时效(分)',
type: 'line', type: 'bar',
data: this.v3, data: this.v3,
yAxisIndex: 0, yAxisIndex: 1,
smooth: true, smooth: true,
barWidth: 45,
barGap: '0%', // 设置柱子之间的间隔
label: { label: {
show: true, // 显示标签 show: true, // 显示标签
position: 'top', // 标签位置在柱形顶部 position: 'top', // 标签位置在柱形顶部
} }
}, },
{ {
name: '平安聚合成功到达时效', name: '聚合成功到达时效',
type: 'line', type: 'bar',
data: this.v4, data: this.v4,
yAxisIndex: 1,
smooth: true, smooth: true,
yAxisIndex: 0,
barWidth: 45, barWidth: 45,
barGap: '0%', // 设置柱子之间的间隔
label: { label: {
show: true, // 显示标签 show: true, // 显示标签
position: 'top', // 标签位置在柱形顶部 position: 'top', // 标签位置在柱形顶部
} }
}, },
/*{ {
name: '40分钟到达率', name: '40分钟到达率',
type: 'line', type: 'line',
smooth: true, smooth: true,
@ -891,7 +897,7 @@ export default {
position: 'top', position: 'top',
formatter: '{c}%' formatter: '{c}%'
}, },
},*/ },
] ]
}; };
option && myChart.setOption(option, true); option && myChart.setOption(option, true);
@ -1026,16 +1032,12 @@ export default {
item.timeoutOrderRate=this.formatPercentage(item.timeoutOrderRate) ; item.timeoutOrderRate=this.formatPercentage(item.timeoutOrderRate) ;
item.cancelRate=this.formatPercentage(item.cancelRate) ; item.cancelRate=this.formatPercentage(item.cancelRate) ;
item.urgeRate=this.formatPercentage(item.urgeRate) ; item.urgeRate=this.formatPercentage(item.urgeRate) ;
item.favorableRate=this.formatPercentage(item.favorableRate) ;
item.pinganEvaluateRate = this.formatPercentage(item.pinganEvaluateRate) ;
item.complainOrderRate=this.formatPercentage(item.complainOrderRate) ; item.complainOrderRate=this.formatPercentage(item.complainOrderRate) ;
item.pinganFavorableRate=this.formatPercentage(item.pinganFavorableRate) ;
item.customerEvaluateRate=this.formatPercentage(item.customerEvaluateRate) ; item.customerEvaluateRate=this.formatPercentage(item.customerEvaluateRate) ;
item.appRate=this.formatPercentage(item.appRate) ; item.appRate=this.formatPercentage(item.appRate) ;
item.threeMinutesContactRate=this.formatPercentage(item.threeMinutesContactRate) ; item.threeMinutesContactRate=this.formatPercentage(item.threeMinutesContactRate) ;
item.pinganPolymerizationSuccessRate=this.formatPercentage(item.pinganPolymerizationSuccessRate) ; item.pinganPolymerizationSuccessRate=this.formatPercentage(item.pinganPolymerizationSuccessRate) ;
item.zhonghuaPolymerizationSuccessRate=this.formatPercentage(item.zhonghuaPolymerizationSuccessRate) ; item.zhonghuaPolymerizationSuccessRate=this.formatPercentage(item.zhonghuaPolymerizationSuccessRate) ;
item.wholeJuheSuccessRate = this.formatPercentage(item.wholeJuheSuccessRate) ;
item.zdPolymerizationSuccessRate=this.formatPercentage(item.zdPolymerizationSuccessRate) ; item.zdPolymerizationSuccessRate=this.formatPercentage(item.zdPolymerizationSuccessRate) ;
item.polymerizationSuccessRate=this.formatPercentage(item.polymerizationSuccessRate) ; item.polymerizationSuccessRate=this.formatPercentage(item.polymerizationSuccessRate) ;
item.threeMinutesReceivingRate=this.formatPercentage(item.threeMinutesReceivingRate) ; item.threeMinutesReceivingRate=this.formatPercentage(item.threeMinutesReceivingRate) ;
@ -1117,7 +1119,7 @@ export default {
} }
await this.twoTabHanldeData(); await this.twoTabHanldeData();
} }
else if ([ 6, 7, 8,9,10, 11].includes(this.active)) { else if ([ 6, 7, 8,9,10].includes(this.active)) {
this.detailList = [] this.detailList = []
this.labelList = [] this.labelList = []
let result = await getKpiDetailsData({ let result = await getKpiDetailsData({
@ -1138,38 +1140,38 @@ export default {
this.labelList = [ this.labelList = [
{label: '案件编号', prop: 'orderCode'}, {label: '案件编号', prop: 'orderCode'},
{label: '服务内容', prop: 'serviceName'}, {label: '服务内容', prop: 'serviceName'},
{label: '拒单供应商', prop: 'supplierName'}, {label: '拒单师傅车号', prop: 'plateNumber'},
{label: '拒单车辆名称', prop: 'vehicleName'}, {label: '拒单师傅名称', prop: 'driverName'},
{label: '拒单师傅', prop: 'driverName'}, {label: '手机号', prop: 'driverPhone'},
{label: '拒绝时间', prop: 'time'}, {label: '上游接单来源', prop: 'workSource'},
{label: '拒单原因', prop: 'reason'}, {label: '中道派单时间', prop: 'dispatchTime'},
{label: '拒绝原因', prop: 'reason'},
] ]
} else if (this.active === 7) {//超时明细 } else if (this.active === 7) {//超时明细
this.labelList = [ this.labelList = [
{label: '案件编号', prop: 'orderCode'}, {label: '案件编号', prop: 'orderCode'},
{label: '服务内容', prop: 'serviceName'}, {label: '服务内容', prop: 'serviceName'},
{label: '超时供应商', prop: 'supplierName'}, {label: '超时师傅车号', prop: 'plateNumber'},
{label: '超时车辆名称', prop: 'vehicleName'}, {label: '超时师傅名称', prop: 'driverName'},
{label: '超时师傅', prop: 'driverName'}, {label: '手机号', prop: 'driverPhone'},
{label: '超时时间', prop: 'time'}, {label: '上游接单来源', prop: 'workSource'},
{label: '超时原因', prop: 'reason'}, {label: '中道派单时间', prop: 'dispatchTime'},
] ]
} else if (this.active === 8) {//投诉明细 } else if (this.active === 8) {//投诉明细
this.labelList = [ this.labelList = [
{label: '案件编号', prop: 'orderCode'}, {label: '案件编号', prop: 'orderCode'},
{label: '服务内容', prop: 'serviceName'}, {label: '服务内容', prop: 'serviceName'},
{label: '责任供应商', prop: 'supplierName'}, {label: '接单车号', prop: 'plateNumber'},
{label: '接单师傅', prop: 'driverName'},
{label: '投诉时间', prop: 'complainCreateTime'}, {label: '投诉时间', prop: 'complainCreateTime'},
{label: '投诉类型', prop: 'complainTypeString'}, {label: '投诉类型', prop: 'complainTypeString'},
{label: '责任供应商扣罚金额', prop: 'compensateFee'},
] ]
} else if (this.active === 9) {//不使用App案件明细 } else if (this.active === 9) {//不使用App案件明细
this.labelList = [ this.labelList = [
{label: '案件编号', prop: 'orderCode'}, {label: '案件编号', prop: 'orderCode'},
{label: '服务内容', prop: 'serviceName'}, {label: '服务内容', prop: 'serviceName'},
{label: '供应商', prop: 'supplierName'}, {label: '接单师傅手机号', prop: 'driverPhone'},
{label: '车辆', prop: 'driverName'}, {label: '工单创建时间', prop: 'orderCreateTime'},
{label: '案件创建时间', prop: 'orderCreateTime'},
{label: '事发地', prop: 'vehiclePointAddress'}, {label: '事发地', prop: 'vehiclePointAddress'},
] ]
} else if (this.active === 10) {//车辆在线情况 } else if (this.active === 10) {//车辆在线情况
@ -1182,17 +1184,6 @@ export default {
{label: '20点在线车辆数量', prop: 'twentyClockVehicleCount'}, {label: '20点在线车辆数量', prop: 'twentyClockVehicleCount'},
{label: '22点在线车辆数量', prop: 'twentyTwoClockVehicleCount'}, {label: '22点在线车辆数量', prop: 'twentyTwoClockVehicleCount'},
] ]
} else if (this.active === 11) {//车辆在线情况
this.labelList = [
{label: '日期', prop: 'date'},
{label: '案件编号', prop: 'orderCode'},
{label: '服务内容', prop: 'serviceName'},
{label: '聚合分类', prop: 'workOrderTypeString'},
{label: '聚合供应商', prop: 'supplierName'},
{label: '聚合车辆', prop: 'driverName'},
{label: '聚合师傅手机号', prop: 'driverPhone'},
{label: '创建时间', prop: 'orderCreateTime'},
]
} }
} }
} finally { } finally {
@ -1209,7 +1200,7 @@ export default {
}, },
// 初始化获取当月日期 // 初始化获取当月日期
initDate() { initDate() {
/*let year='' let year=''
let month='' let month=''
if( this.current ) { if( this.current ) {
year = new Date(this.current).getFullYear(); year = new Date(this.current).getFullYear();
@ -1221,25 +1212,7 @@ export default {
let yearAndMonth = year + '-' + (month > 9 ? month : '0' + month); let yearAndMonth = year + '-' + (month > 9 ? month : '0' + month);
this.current = dayjs(new Date(yearAndMonth)).format('YYYY-MM') this.current = dayjs(new Date(yearAndMonth)).format('YYYY-MM')
this.startTime = dayjs(new Date()).format('YYYY-MM') + '-01 00:00:00' this.startTime = dayjs(new Date()).format('YYYY-MM') + '-01 00:00:00'
this.endTime = dayjs(new Date()).format('YYYY-MM') + '-' + this.getDayLen()+' 23:59:59'*/ this.endTime = dayjs(new Date()).format('YYYY-MM') + '-' + this.getDayLen()+' 23:59:59'
// test
let _testDate = new Date('2024-11-01 00:00:01')
const today = dayjs(_testDate); // 获取当前日期
const currentDay = today.date(); // 获取今天是几号1-31
let targetMonth = today; // 默认目标月份是当前月
if (currentDay === 1) {
targetMonth = today.subtract(1, 'month'); // 上个月
}
this.current = targetMonth.format('YYYY-MM');
this.startTime = targetMonth.startOf('month').format('YYYY-MM-DD HH:mm:ss');
let endTime;
if (targetMonth.isSame(today, 'month')) {
endTime = today.subtract(1, 'day').endOf('day');
} else {
endTime = targetMonth.endOf('month');
}
this.endTime = endTime.format('YYYY-MM-DD HH:mm:ss');
this.startMonthTime=this.getStartTimeFromEndTime(this.endTime) this.startMonthTime=this.getStartTimeFromEndTime(this.endTime)
console.log(" this.startMonthTime", this.startMonthTime,this.startTime) console.log(" this.startMonthTime", this.startMonthTime,this.startTime)
}, },
@ -1257,15 +1230,13 @@ export default {
}, },
//获取近五个月的开始时间 //获取近五个月的开始时间
getStartTimeFromEndTime(endTimeStr) { getStartTimeFromEndTime(endTimeStr) {
/* const endTime = new Date(endTimeStr); const endTime = new Date(endTimeStr);
endTime.setMonth(endTime.getMonth() - 5); // 减去5个月 endTime.setMonth(endTime.getMonth() - 5); // 减去5个月
const year = endTime.getFullYear(); const year = endTime.getFullYear();
let month = String(endTime.getMonth() + 1).padStart(2, '0'); // 月份+1并确保为两位数 let month = String(endTime.getMonth() + 1).padStart(2, '0'); // 月份+1并确保为两位数
let day = '01'; // 因为我们要的是那个月的第一天 let day = '01'; // 因为我们要的是那个月的第一天
const startTimeStr = `${year}-${month}-${day} `+'00:00:00'; const startTimeStr = `${year}-${month}-${day} `+'00:00:00';
return startTimeStr;*/ return startTimeStr;
const startTime = dayjs(endTimeStr).subtract(4, 'month').startOf('month');
return startTime.format('YYYY-MM-DD HH:mm:ss');
}, },
async changeTab(index) { async changeTab(index) {
try { try {
@ -1278,8 +1249,6 @@ export default {
this.v4 = [] this.v4 = []
this.v5 = [] this.v5 = []
this.v6 = [] this.v6 = []
this.v7 = []
this.v8 = []
await this.twoTabHanldeData() await this.twoTabHanldeData()
this.loadingData = false this.loadingData = false
if (this.active === 1) { if (this.active === 1) {
@ -1338,43 +1307,39 @@ export default {
{label: '取消率(%)', prop: 'cancelRate'}, {label: '取消率(%)', prop: 'cancelRate'},
] ]
} else if (this.activeIndex === 1) { } else if (this.activeIndex === 1) {
this.etlDetailList=[{ 'month': '投诉量' },{ 'month': '投诉率(%)' },{ 'month': '平安好评量' }, { 'month': '平安好评率' }] this.etlDetailList=[{ 'month': '投诉量' },{ 'month': '投诉率(%)' },{ 'month': '客户满意度(%)' }, { 'month': '客户评价率(%)' }]
console.log('detailList', this.detailList)
let props = 'prop' //自定义字段名称 let props = 'prop' //自定义字段名称
this.detailList?.map((item,index) => { this.detailList?.map((item,index) => {
this.v1.push(item.complainOrderCount) this.v1.push(item.customerEvaluateRate.replace('%', ''))
this.v2.push(item.complainOrderRate?.replace('%', '')) this.v2.push(item.customerSatisfaction.replace('%', ''))
this.v3.push(item?.pinganFavorableCount) this.v3.push(item.complainOrderRate.replace('%', ''))
this.v4.push(item.pinganFavorableRate?.replace('%', ''))
const columnObj = {} const columnObj = {}
columnObj.label = item.month // 每一列的标题的名称 columnObj.label = item.month // 每一列的标题的名称
columnObj.prop = props + index //自定义每一列标题字段名称 columnObj.prop = props + index //自定义每一列标题字段名称
this.etlLabelList.push(columnObj) this.etlLabelList.push(columnObj)
let mappings = [ 'complainOrderCount', 'complainOrderRate', 'pinganFavorableCount','pinganFavorableRate' ]; let mappings = [ 'complainOrderCount', 'complainOrderRate', 'customerSatisfaction','customerEvaluateRate' ];
for (let i = 0; i < mappings.length; i++) { for (let i = 0; i < mappings.length; i++) {
this.$set(this.etlDetailList[i], columnObj.prop, item[mappings[i]]); this.$set(this.etlDetailList[i], columnObj.prop, item[mappings[i]]);
} }
}) })
this.labelList = [ this.labelList = [
{label: '月份', prop: 'month'}, {label: '月', prop: 'month'},
{label: '投诉量', prop: 'complainOrderCount'}, {label: '投诉量', prop: 'complainOrderCount'},
{label: '投诉率', prop: 'complainOrderRate'}, {label: '投诉率(%)', prop: 'complainOrderRate'},
{label: '平安好评量', prop: 'pinganFavorableCount'}, {label: '客户满意度(%)', prop: 'customerSatisfaction'},
{label: '平安好评率', prop: 'pinganFavorableRate'}, {label: '客户评价率(%)', prop: 'customerEvaluateRate'},
] ]
} else if (this.activeIndex === 2) { } else if (this.activeIndex === 2) {
this.etlDetailList=[{ 'month': 'APP使用量' }, { 'month': 'APP使用率' }, { 'month': '平安聚合成功量' },{ 'month': '平安聚合成功率' }, this.etlDetailList=[{ 'month': '使用率(%)' },{ 'month': '3联系客户率(%)' },{ 'month': '平安聚合成功率(%)' }, { 'month': '中华聚合成功率(%)' }
{ 'month': '中华联合聚合成功量' }, { 'month': '中华联合聚合成功率' }, { 'month': '整体聚合成功量' }, { 'month': '整体聚合成功率' }] ,{ 'month': '中道聚合成功率(%' }, { 'month': '总聚合成功率(%)' }]
let props = 'prop' //自定义字段名称 let props = 'prop' //自定义字段名称
this.detailList?.map((item,index) => { this.detailList?.map((item,index) => {
this.v1.push(item.appUseCount) this.v1.push(item.appRate.replace('%', ''))
this.v2.push(item.appRate.replace('%', '')) this.v2.push(item.threeMinutesContactRate.replace('%', ''))
this.v3.push(item.pinganJuheSuccessCount) this.v3.push(item.pinganPolymerizationSuccessRate.replace('%', ''))
this.v4.push(item.pinganPolymerizationSuccessRate.replace('%', '')) this.v4.push(item.zhonghuaPolymerizationSuccessRate.replace('%', ''))
this.v5.push(item.zhonghuaPolymerizationSuccessCount) this.v5.push(item.zdPolymerizationSuccessRate.replace('%', ''))
this.v6.push(item.zhonghuaPolymerizationSuccessRate.replace('%', '')) this.v6.push(item.polymerizationSuccessRate.replace('%', ''))
this.v7.push(item.wholeJuheSuccessCount)
this.v7.push(item.wholeJuheSuccessRate.replace('%', ''))
const columnObj = {} const columnObj = {}
columnObj.label = item.month // 每一列的标题的名称 columnObj.label = item.month // 每一列的标题的名称
columnObj.prop = props + index //自定义每一列标题字段名称 columnObj.prop = props + index //自定义每一列标题字段名称
@ -1385,18 +1350,16 @@ export default {
} }
}) })
this.labelList = [ this.labelList = [
{label: '月份', prop: 'month'}, {label: '月', prop: 'month'},
{label: 'APP使用量', prop: 'appUseCount'}, {label: '使用率(%)', prop: 'appRate'},
{label: 'APP使用率', prop: 'appRate'}, {label: '3联系客户率(%)', prop: 'threeMinutesContactRate'},
{label: '平安聚合成功量', prop: 'pinganJuheSuccessCount'}, {label: '平安聚合成功率(%)', prop: 'pinganPolymerizationSuccessRate'},
{label: '平安聚合成功率', prop: 'pinganPolymerizationSuccessRate'}, {label: '中华聚合成功率(%)', prop: 'zhonghuaPolymerizationSuccessRate'},
{label: '中华联合聚合成功量', prop: 'zhonghuaPolymerizationSuccessCount'}, {label: '中道聚合成功率(%)', prop: 'zdPolymerizationSuccessRate'},
{label: '中华联合聚合成功率', prop: 'zhonghuaPolymerizationSuccessRate'}, {label: '总聚合成功率(%)', prop: 'polymerizationSuccessRate'},
{label: '整体聚合成功量', prop: 'wholeJuheSuccessCount'},
{label: '整体聚合成功率', prop: 'wholeJuheSuccessRate'},
] ]
} else if (this.activeIndex === 3) { } else if (this.activeIndex === 3) {
this.etlDetailList=[{ 'month': '接单时效' },{ 'month': '3分钟联系客户率' },{ 'month': '到达时效' },{'month':'平安聚合成功到达时效'}] this.etlDetailList=[{ 'month': '接单时效(分)' },{ 'month': '3接单率(%)' },{ 'month': '到达时效(分)' }, { 'month': '40到达率(%)' },{'month':'聚合成功到达时效(分)'}]
let props = 'prop' //自定义字段名称 let props = 'prop' //自定义字段名称
if (this.isMobile) { if (this.isMobile) {
if (this.value == 1) { if (this.value == 1) {
@ -1429,67 +1392,70 @@ export default {
if (this.swithVal) { if (this.swithVal) {
this.detailList?.map(item => { this.detailList?.map(item => {
this.v3.push(item.trailArriving) this.v3.push(item.trailArriving)
this.v4.push(item.pinganJuheSuccessArriving) this.v4.push(item.trailPolymerizationSuccessArsriving)
// this.v5.push(item.trailFortyMinutesArrivalRate ? item.trailFortyMinutesArrivalRate.replace('%', '') : item.trailFortyMinutesArrivalRate) this.v5.push(item.trailFortyMinutesArrivalRate ? item.trailFortyMinutesArrivalRate.replace('%', '') : item.trailFortyMinutesArrivalRate)
}) })
} else { } else {
this.detailList?.map(item => { this.detailList?.map(item => {
this.v3.push(item.minorArriving) this.v3.push(item.minorArriving)
this.v4.push(item.pinganJuheSuccessArriving) this.v4.push(item.minorPolymerizationSuccessArriving)
// this.v5.push(item.minorFortyMinutesArrivalRate ? item.minorFortyMinutesArrivalRate.replace('%', '') : item.minorFortyMinutesArrivalRate) this.v5.push(item.minorFortyMinutesArrivalRate ? item.minorFortyMinutesArrivalRate.replace('%', '') : item.minorFortyMinutesArrivalRate)
}) })
} }
} }
this.labelList = [ this.labelList = [
{label: '月份', prop: 'month'}, {label: '月', prop: 'month'},
{label: '接单时效', prop: 'receiving'}, {label: '接单时效(分)', prop: 'receiving'},
{label: '3分钟联系客户率', prop: 'threeMinutesReceivingRate'}, {label: '3接单率(%)', prop: 'threeMinutesReceivingRate'},
{label: '到达时效', prop: 'arriving'}, {label: '到达时效(分)', prop: 'arriving'},
{label: '平安聚合成功到达时效', prop: 'pinganJuheSuccessArriving'}, {label: '40到达率(%)', prop: 'fortyMinutesArrivalRate'},
{label: '聚合成功到达时效(分)', prop: 'polymerizationSuccessArriving'},
] ]
} }
} else if (this.active === 2) { } else if (this.active === 2) {
if (this.activeIndex === 0) {//接单指标 if (this.activeIndex === 0) {//接单指标
this.labelList = [ this.labelList = [
{label: '日', prop: 'date'}, {label: '日', prop: 'date'},
{label: '派单量', prop: 'dispatchOrderCount'}, {label: '派遣案件量', prop: 'dispatchOrderCount'},
{label: '接单量', prop: 'receiveOrderCount'}, {label: '承接案件量', prop: 'receiveOrderCount'},
// {label: '完成量', prop: 'finishOrderCount'}, {label: '完成量', prop: 'finishOrderCount'},
{label: '拒单量', prop: 'refuseOrderCount'}, {label: '拒单量', prop: 'refuseOrderCount'},
{label: '拒单率', prop: 'refuseOrderRate'}, {label: '拒单率(%)', prop: 'refuseOrderRate'},
{label: '超时量', prop: 'timeoutOrderCount'}, {label: '超时接单量', prop: 'timeoutOrderCount'},
{label: '超时率', prop: 'timeoutOrderRate'}, {label: '超时率(%)', prop: 'timeoutOrderRate'},
// {label: '客户取消率(%)', prop: 'cancelRate'}, {label: '客户取消率(%)', prop: 'cancelRate'},
] ]
} else if (this.activeIndex === 1) { } else if (this.activeIndex === 1) {
this.labelList = [ this.labelList = [
{label: '日', prop: 'date'}, {label: '日', prop: 'date'},
{label: '投诉量', prop: 'complainOrderCount'}, {label: '投诉量', prop: 'complainOrderCount'},
{label: '投诉率', prop: 'complainOrderRate'}, {label: '投诉率(%)', prop: 'complainOrderRate'},
{label: '好评量', prop: 'favorableCount'}, {label: '客户评价率(%)', prop: 'customerEvaluateRate'},
{label: '好评率', prop: 'favorableRate'}, {label: '催促率(%)', prop: 'urgeRate'},
{label: '平安评价率', prop: 'pinganEvaluateRate'},
{label: '平安好评率', prop: 'pinganFavorableRate'},
] ]
} else if (this.activeIndex === 2) { } else if (this.activeIndex === 2) {
this.labelList = [ this.labelList = [
{label: '日', prop: 'date'}, {label: '日', prop: 'date'},
{label: 'APP使用量', prop: 'appUseCount'}, {label: '使用率(%)', prop: 'appRate'},
{label: 'APP使用率', prop: 'appRate'}, {label: '3联系客户率(%)', prop: 'threeMinutesContactRate'},
{label: '平安聚合成功量', prop: 'pinganJuheSuccessCount'}, {label: '平安聚合成功率(%)', prop: 'pinganPolymerizationSuccessRate'},
{label: '平安聚合成功率', prop: 'pinganPolymerizationSuccessRate'}, {label: '中华聚合成功率(%)', prop: 'zhonghuaPolymerizationSuccessRate'},
{label: '中华联合聚合成功量', prop: 'zhonghuaPolymerizationSuccessCount'}, {label: '中道聚合成功率(%)', prop: 'zdPolymerizationSuccessRate'},
{label: '中华联合聚合成功率', prop: 'zhonghuaPolymerizationSuccessRate'}, {label: '总聚合成功率(%)', prop: 'polymerizationSuccessRate'},
{label: '整体聚合成功量', prop: 'wholeJuheSuccessCount'},
{label: '整体聚合成功率', prop: 'wholeJuheSuccessRate'},
] ]
} else if (this.activeIndex === 3) { } else if (this.activeIndex === 3) {
this.labelList = [ this.labelList = [
{label: '日', prop: 'date'}, {label: '日', prop: 'date'},
{label: '接单时效(分)', prop: 'receiving'}, {label: '接单时效(分)', prop: 'receiving'},
{label: '3分钟联系客户率', prop: 'threeMinutesReceivingRate'}, {label: '3接单率(%)', prop: 'threeMinutesReceivingRate'},
{label: '小修到达时效(分)', prop: 'minorArriving'},
{label: '拖车到达时效(分)', prop: 'trailArriving'},
{label: '困境到达时效(分)', prop: 'dilemmaArriving'},
{label: '到达时效(分)', prop: 'arriving'}, {label: '到达时效(分)', prop: 'arriving'},
{label: '平安聚合成功到达时效(分)', prop: 'pinganJuheSuccessArriving'}, {label: '40到达率(%)', prop: 'fortyMinutesArrivalRate'},
{label: '小修聚合成功到达时效(分)', prop: 'minorPolymerizationSuccessArriving'},
{label: '拖车聚合成功到达时效(分)', prop: 'trailPolymerizationSuccessArriving'},
{label: '聚合成功到达时效(分)', prop: 'polymerizationSuccessArriving'},
] ]
} }
} }
@ -1618,7 +1584,6 @@ export default {
checkMobile() { checkMobile() {
const userAgent = navigator.userAgent || navigator.vendor || window.opera; const userAgent = navigator.userAgent || navigator.vendor || window.opera;
this.isMobile = /android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(userAgent); this.isMobile = /android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(userAgent);
// this.isMobile = true
}, },
setType(type) { setType(type) {
switch (type) { switch (type) {
@ -1632,8 +1597,6 @@ export default {
return 4; return 4;
case 10: case 10:
return 5; return 5;
case 11:
return 6;
} }
}, },
getTitle(type) { getTitle(type) {
@ -2086,10 +2049,4 @@ export default {
line-height: 1 !important; line-height: 1 !important;
} }
} }
.numRed {
color: red !important;
}
.numGreen {
color: green !important;
}
</style> </style>

View File

@ -1,199 +0,0 @@
<template>
<div class="wrap">
<div class="navBar">
<van-nav-bar
title="参保救援职业责任险"
left-arrow
left-arrow-color="#FFFFFF"
:border="false"
:fixed="true"
:safe-area-inset-top="true"
@click-left="goBack"
/>
</div>
<div class="contentWrap">
<div>
为降低日常救援工作中的不可预期的车损赔付带来的运营风险和资金压力减少由此衍生而来的可能投诉顺应行业服务标准不断增长的局势中道救援自有车辆已全部投保了救援职业责任险
</div>
<div>
通过日常的交流了解此险种对于服务商而言投保相对较难很多服务商在无投保渠道的情况下选择了对于我们救援场景保障能力稍弱不太匹配的货物险从而从形成了现在很多救援车无保障或者特殊场景货物险理赔难的局面
</div>
<div>
为此中道救援经过与保司沟通协调特为与中道救援合作紧密的服务商提供救援职业责任险参保渠道提升服务商服务能力降低运营风险实现共同进步
</div>
<div>救援职业责任险简介</div>
<div>1综合保额50万元可全方位覆盖我们日常的经营活动</div>
<div> 2保费支付可采用救援服务费抵扣的方式降低资金压力</div>
<div> 3详细保险条款保费和其他问题如需了解请与辖区区域经理联系</div>
<div> 其他意见建议如需交流请与18621558505曲仁杰联系</div>
<div> 如确认参保请点击下方参保按钮会有专人与贵司联系</div>
</div>
<div class="upload_btn_wrap">
<div class="btn_save" @click="showPoup = true">参保</div>
</div>
<div class="poupCommon" v-if="showPoup">
<div class="showPoupContainer">
<img class="insured" src="@/assets/insured-jianbian.png">
<img class="insure" src="@/assets/insured.png">
<div class="con">
<div class="title">请确认</div>
<div class="title">是否参保救援职业责任险</div>
<div class="btnWrap">
<div class="btn confirmBtn" @click="saveHandle">确认</div>
<div class="btn closeBtn" @click="showPoup = false">取消</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import {myMixins} from "@/utils/myMixins"
import {sendInsuranceEmail} from "@/api/mine"
export default {
name: "insuredPage",
mixins: [myMixins],
data() {
return {
showPoup: false,
}
},
async mounted() {
},
methods: {
async saveHandle() {
await sendInsuranceEmail();
this.$toast('操作成功');
this.showPoup=false
setTimeout(()=>{
this.goBack()
},1500)
},
}
}
</script>
<style scoped lang="scss">
@import "@/styles/mixin.scss";
@import "@/styles/common.scss";
.wrap {
@include wh(100%, 100%);
background-color: #F4F5F7;
overflow-y: auto;
position: relative;
}
.navBar {
height: 46px;
}
.contentWrap {
padding-top: 15px;
div {
padding: 0 18px;
line-height: 22px;
}
}
.upload_btn_wrap {
position: fixed;
width: 100%;
box-sizing: border-box;
bottom: 10px;
left: 0;
padding: 15px 30px;
display: flex;
color: #fff;
font-weight: bold;
font-size: 14px;
line-height: 40px;
div {
height: 40px;
line-height: 40px;
border-radius: 5px;
text-align: center;
flex: 1;
}
.btn_save {
background: #354D93;
margin-right: 4px;
}
}
.poupCommon {
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, .7);
position: absolute;
top: 0;
left: 0;
.showPoupContainer {
width: 290px;
height: 242px;
background-color: #FFFFFF;
border-radius: 12px;
position: absolute;
z-index: 11;
top: 0;
bottom: 0;
left: 0;
right: 0;
margin: auto;
.con {
top: 80px !important;
display: flex;
flex-direction: column;
align-items: center;
margin-top: 60px;
}
.title {
font-weight: 500;
font-size: 16px;
color: #040404;
line-height: 28px;
}
.insure {
width: 78px;
height: 78px;
position: absolute;
z-index: 11;
top: -34px;
left: 50%;
transform: translateX(-50%);
}
.insured {
width: 100%;
position: absolute;
z-index: -1;
}
.btnWrap {
margin-top: 36px;
text-align: center;
.btn{
width: 174px;
height: 42px;
line-height: 42px;
border-radius: 23px;
}
.closeBtn {
font-weight: 400;
font-size: 14px;
color: #2C4155;
opacity: .6;
}
.confirmBtn {
font-weight: 500;
font-size: 15px;
background: #F1BA63;
color: #FFFFFF;
}
}
}
}
</style>

View File

@ -90,7 +90,7 @@
} }
let activeObj = this.addressList[this.activeIndex]; let activeObj = this.addressList[this.activeIndex];
let _tempObj = { let _tempObj = {
startPoiAddress: activeObj?.address + activeObj?.name, startPoiAddress: activeObj?.district + activeObj?.address + activeObj?.name,
startLat: activeObj?.location?.lat, startLat: activeObj?.location?.lat,
startLng: activeObj?.location?.lng, startLng: activeObj?.location?.lng,
adCode: activeObj?.adcode, adCode: activeObj?.adcode,

View File

@ -268,6 +268,7 @@ export default {
if( this.form.vehicleRearPhoto ) { if( this.form.vehicleRearPhoto ) {
this.vehicleRearPhotoList = [{url: this.form.vehicleRearPhoto}] this.vehicleRearPhotoList = [{url: this.form.vehicleRearPhoto}]
} }
// console.log("carSourceFormInfo",carSourceFormInfo)
if(carSourceFormInfo.otherImgSrc0){ if(carSourceFormInfo.otherImgSrc0){
this.otherImgSrc.push(carSourceFormInfo.otherImgSrc0) this.otherImgSrc.push(carSourceFormInfo.otherImgSrc0)
this.otherImgSrcList.push({url:carSourceFormInfo.otherImgSrc0}) this.otherImgSrcList.push({url:carSourceFormInfo.otherImgSrc0})
@ -292,6 +293,7 @@ export default {
this.otherImgSrc.push(carSourceFormInfo.otherImgSrc5) this.otherImgSrc.push(carSourceFormInfo.otherImgSrc5)
this.otherImgSrcList.push({url:carSourceFormInfo.otherImgSrc5}) this.otherImgSrcList.push({url:carSourceFormInfo.otherImgSrc5})
} }
// console.log("--",this.vehicleLicensePhotoList,this.vehicleAnglePhotoList,this.otherImgSrcList)
}, },
methods:{ methods:{
validatePrice(value) { validatePrice(value) {
@ -478,6 +480,21 @@ export default {
otherPhoto:this.otherImgSrc?.join(',') otherPhoto:this.otherImgSrc?.join(',')
}) })
this.clearStorageFormInfo() this.clearStorageFormInfo()
if(res.code == 200 && !res.msg){
this.$toast('发布成功')
if(this.isWebFunc()){
setTimeout(()=>{
this.closeParentDialog()
},1000)
}else{
setTimeout(()=>{
this.$router.push({ name: "mineRelease"})
sessionStorage.setItem('mineActiveTab',String(1) )
},1000)
}
}else{
this.$toast(res.msg)
}
console.log("车源发布publishCarInfo",res) console.log("车源发布publishCarInfo",res)
} catch (e){ } catch (e){
console.log('e',e) console.log('e',e)
@ -588,6 +605,7 @@ export default {
} }
.navBar{ .navBar{
margin-bottom: 46px; margin-bottom: 46px;
} }
.noContentAudit{ .noContentAudit{
height: calc(100% - 42px); height: calc(100% - 42px);

View File

@ -8,11 +8,10 @@
:preview-full-image="false" :preview-full-image="false"
:max-count="multiple ? 6 : 1" :max-count="multiple ? 6 : 1"
@click-preview="handlePreviewClick" @click-preview="handlePreviewClick"
:deletable="showDel"
> >
<div class="upload"> <div class="upload">
<img class="icon" src="@/assets/secondHandCar/upload.png"/> <img class="icon" src="@/assets/secondHandCar/upload.png"/>
<span class="text" v-show="!['交易合同','回收证明'].includes(displayText)">{{ displayText }}</span> <span class="text">{{ displayText }}</span>
</div> </div>
<template v-if="text.includes('其他照片')" #preview-cover="{ index }"> <template v-if="text.includes('其他照片')" #preview-cover="{ index }">
<div class="preview-cover van-ellipsis">{{ index + 1 }}/6</div> <div class="preview-cover van-ellipsis">{{ index + 1 }}/6</div>
@ -37,10 +36,6 @@ export default {
files: { files: {
type: Array, type: Array,
default: () => [] default: () => []
},
showDel:{
type: Boolean,
default: true
} }
}, },
data() { data() {

View File

@ -16,6 +16,7 @@
:preview-src-list="[item]" :preview-src-list="[item]"
class="swipeImg" class="swipeImg"
/> />
<!-- <img v-if="item" class="swipeImg" :src="item" />-->
</el-carousel-item> </el-carousel-item>
</el-carousel> </el-carousel>
<van-swipe v-else @change="onChange" :autoplay="3000"> <van-swipe v-else @change="onChange" :autoplay="3000">
@ -33,9 +34,8 @@
<span>{{ detailInfo.boardType?.label }}</span> <span>{{ detailInfo.boardType?.label }}</span>
<span>{{ detailInfo.licenseType?.label }}</span> <span>{{ detailInfo.licenseType?.label }}</span>
<span>{{detailInfo.brandModel?.match(/^[\u4e00-\u9fa5]+/)?.[0]?.replace(/牌$/, '')}}</span> <span>{{detailInfo.brandModel?.match(/^[\u4e00-\u9fa5]+/)?.[0]?.replace(/牌$/, '')}}</span>
<span>{{ detailInfo.emissionStandard?.label }}</span>
<span>{{ detailInfo.underpanBrand }}</span>
<span>{{ formatToWan(detailInfo.mileage) }}公里</span> <span>{{ formatToWan(detailInfo.mileage) }}公里</span>
<span>{{ detailInfo.emissionStandard?.label }}</span>
</div> </div>
<div class="time"> <div class="time">
<span>{{ detailInfo.createTime?.substring(0,10) }}</span><span>{{ detailInfo.areaName }}</span><span>发布</span> <span>{{ detailInfo.createTime?.substring(0,10) }}</span><span>{{ detailInfo.areaName }}</span><span>发布</span>
@ -48,10 +48,6 @@
</div> </div>
<div class="viewNum">{{detailInfo.attentionCount}}人想要<span>{{detailInfo.browseCount}}人浏览</span></div> <div class="viewNum">{{detailInfo.attentionCount}}人想要<span>{{detailInfo.browseCount}}人浏览</span></div>
</div> </div>
<div class="price commonColor">
车源ID: &nbsp;&nbsp;&nbsp;&nbsp;{{ detailInfo.code }}
<img class="copyIcon" @click="copyHandler(detailInfo.code)" src="@/assets/copy.png" />
</div>
</div> </div>
<div class="detailInfoWrap wrapCommon"> <div class="detailInfoWrap wrapCommon">
<div> <div>
@ -182,16 +178,6 @@ export default {
this.getDuration(1) this.getDuration(1)
}, },
methods:{ methods:{
copyHandler(copyText){
let inputNode = document.createElement('input') // 创建input
inputNode.value = copyText // 赋值给 input 值
document.body.appendChild(inputNode) // 插入进去
inputNode.select() // 选择对象
document.execCommand('Copy') // 原生调用执行浏览器复制命令
inputNode.className = 'oInput'
inputNode.style.display = 'none' // 隐藏
this.$toast('复制成功')
},
showImagePreview(index) { showImagePreview(index) {
ImagePreview({ ImagePreview({
images: this.imgSrcList.map(item => item), images: this.imgSrcList.map(item => item),
@ -288,7 +274,7 @@ export default {
margin-bottom: 12px; margin-bottom: 12px;
} }
.titleWrap{ .titleWrap{
height: 120px; height: 108px;
padding: 18px 0 15px 21px; padding: 18px 0 15px 21px;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
@ -451,14 +437,4 @@ export default {
object-fit: cover; object-fit: cover;
object-position: center; object-position: center;
} }
.copyIcon {
width: 35px;
height: 15px;
margin-left: 10px
}
.commonColor {
color: #999999 !important;
display: flex;
align-items: center;
}
</style> </style>

View File

@ -119,7 +119,7 @@
<div class="right"> <div class="right">
<div class="title">{{item.vehicleType}}</div> <div class="title">{{item.vehicleType}}</div>
<div v-if="activeTab==0" class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{ item.licenseType?.label }} | <div v-if="activeTab==0" class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{ item.licenseType?.label }} |
{{ item.brandModel?.match(/^[\u4e00-\u9fa5]+/)?.[0]?.replace(/$/, '') }} | {{item.emissionStandard?.label}} | {{item.underpanBrand}} | {{ formatToWan(item.mileage) }}公里</div> {{ item.brandModel?.match(/^[\u4e00-\u9fa5]+/)?.[0]?.replace(/$/, '') }} | {{item.emissionStandard?.label}} | {{ formatToWan(item.mileage) }}公里</div>
<div v-else class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{item.emissionStandard?.label}}</div> <div v-else class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{item.emissionStandard?.label}}</div>
<div class="date" v-show="activeTab==0 && item.registerDate">注册日期 {{item.registerDate?.substring(0,10)}}</div> <div class="date" v-show="activeTab==0 && item.registerDate">注册日期 {{item.registerDate?.substring(0,10)}}</div>
<div class="priceWrap" v-if="activeTab==0" > <div class="priceWrap" v-if="activeTab==0" >
@ -354,8 +354,6 @@ export default {
sessionStorage.setItem('areaCode',String(this.areaCode)); sessionStorage.setItem('areaCode',String(this.areaCode));
sessionStorage.setItem('areaName',this.areaName); sessionStorage.setItem('areaName',this.areaName);
sessionStorage.setItem('dateVal',this.dateVal); sessionStorage.setItem('dateVal',this.dateVal);
sessionStorage.setItem('brandModel',this.brandModel);
sessionStorage.setItem('underpanBrand',this.underpanBrand);
}, },
getSearchVal(){ getSearchVal(){
this.activeTab = Number(sessionStorage.getItem('indexActiveTab')) || 0; this.activeTab = Number(sessionStorage.getItem('indexActiveTab')) || 0;
@ -369,8 +367,6 @@ export default {
this.areaCode=Number(sessionStorage.getItem('areaCode')) || ''; this.areaCode=Number(sessionStorage.getItem('areaCode')) || '';
this.areaName=sessionStorage.getItem('areaName') || ''; this.areaName=sessionStorage.getItem('areaName') || '';
this.dateVal=sessionStorage.getItem('dateVal') || ''; this.dateVal=sessionStorage.getItem('dateVal') || '';
this.brandModel=sessionStorage.getItem('brandModel') || '';
this.underpanBrand=sessionStorage.getItem('underpanBrand') || '';
}, },
goMine(){//我的发布 goMine(){//我的发布
this.$router.push({ name: "mineRelease"}) this.$router.push({ name: "mineRelease"})
@ -432,8 +428,6 @@ export default {
areaCode:this.areaCode, areaCode:this.areaCode,
startTime:this.startTime, startTime:this.startTime,
endTime:this.endTime, endTime:this.endTime,
brandModel:this.brandModel,
underpanBrand:this.underpanBrand,
}) })
this.total=res.total this.total=res.total
if(this.pageNum == 1){// 第一页直接赋值 if(this.pageNum == 1){// 第一页直接赋值
@ -692,9 +686,9 @@ export default {
color: #282828; color: #282828;
line-height: 23px; line-height: 23px;
width: 200px; width: 200px;
/* white-space: nowrap; !* 强制文本在一行显示 *! white-space: nowrap; /* 强制文本在一行显示 */
overflow: hidden; !* 隐藏超出部分 *! overflow: hidden; /* 隐藏超出部分 */
text-overflow: ellipsis; !* 超出部分显示省略号 *!*/ text-overflow: ellipsis; /* 超出部分显示省略号 */
} }
.date{ .date{
font-weight: 400; font-weight: 400;

View File

@ -32,7 +32,7 @@
<div class="right"> <div class="right">
<div class="title"> <div class="title">
<span>{{item.vehicleType}}</span> <span>{{item.vehicleType}}</span>
<img :class="{'titleImg':true,bigImg:[8,9].includes(item.status?.code)}" :src="getStatus(item.status?.code)" /> <img class="titleImg" :src="getStatus(item.status?.code)" />
</div> </div>
<div v-if="activeTab==0" class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{ item.licenseType?.label }} | <div v-if="activeTab==0" class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{ item.licenseType?.label }} |
@ -50,10 +50,8 @@
<div class="btnWrap"> <div class="btnWrap">
<img v-if="(activeTab==1 && item.status?.code==3) || activeTab==2" @click.stop="noMultipleClicks(reviseHandle,item)" class="revise" src="@/assets/secondHandCar/revise.png" /> <img v-if="(activeTab==1 && item.status?.code==3) || activeTab==2" @click.stop="noMultipleClicks(reviseHandle,item)" class="revise" src="@/assets/secondHandCar/revise.png" />
<img v-if="(activeTab==1 && (item.status?.code==1 || item.status?.code==3)) || activeTab==2" @click.stop="noMultipleClicks(xiajiaHandle,item)" class="xiajia" src="@/assets/secondHandCar/xiajia.png" /> <img v-if="(activeTab==1 && (item.status?.code==1 || item.status?.code==3)) || activeTab==2" @click.stop="noMultipleClicks(xiajiaHandle,item)" class="xiajia" src="@/assets/secondHandCar/xiajia.png" />
<img v-if="(activeTab==1 && item.status?.code==9)" @click.stop="noMultipleClicks(reviseXiajiaHandle,item)" class="reshangjia" src="@/assets/secondHandCar/reviseXiajia.png" />
<img v-if="((activeTab==3 && item.status?.code==7) || activeTab==2) && !isToday(item.wapTime)" @click.stop="noMultipleClicks(polishHandle,item)" class="polish" src="@/assets/secondHandCar/polish.png" /> <img v-if="((activeTab==3 && item.status?.code==7) || activeTab==2) && !isToday(item.wapTime)" @click.stop="noMultipleClicks(polishHandle,item)" class="polish" src="@/assets/secondHandCar/polish.png" />
<img v-if="activeTab==3 && item.type==1 && item.downReason=='不卖了' " @click.stop="noMultipleClicks(reShangJiaHandle,item)" class="reshangjia" src="@/assets/secondHandCar/reshangjia.png" /> <img v-if="activeTab==3 && item.type==1 && item.downReason=='不卖了' " @click.stop="noMultipleClicks(reShangJiaHandle,item)" class="reshangjia" src="@/assets/secondHandCar/reshangjia.png" />
<img v-if="(activeTab==3 && [10,11].includes(item.status?.code)) || (activeTab==1 && [8,9].includes(item.status?.code))" @click.stop="noMultipleClicks(viewXiajiaHandle,item)" class="reshangjia" src="@/assets/secondHandCar/viewXiajia.png" />
</div> </div>
<div class="line"></div> <div class="line"></div>
</div> </div>
@ -65,14 +63,13 @@
<div class="empty" v-show="show"> <div class="empty" v-show="show">
<img src="@/assets/empty.png" /> <img src="@/assets/empty.png" />
</div> </div>
<van-popup v-model="poupShow" closeable round :style="{ width: '70%',height:xiajiaInfo.proprietary==1 && xiajiaInfo?.type==1 && radio==1 ? '20%' : '18%' }" class="poupWrap"> <van-popup v-model="poupShow" closeable round :style="{ width: '70%',height:'18%' }" class="poupWrap">
<span class="title">下架原因</span> <span class="title">下架原因</span>
<div class="poupContent"> <div class="poupContent">
<van-radio-group v-model="radio" class="radioWrap"> <van-radio-group v-model="radio" class="radioWrap">
<van-radio name="1">{{xiajiaInfo?.type==1 ? '已售出' : '已买到'}}</van-radio> <van-radio name="1">{{xiajiaInfo?.type==1 ? '已售出' : '已买到'}}</van-radio>
<van-radio name="2">{{xiajiaInfo?.type==1 ? '不卖了' : '不买了'}}</van-radio> <van-radio name="2">{{xiajiaInfo?.type==1 ? '不卖了' : '不买了'}}</van-radio>
</van-radio-group> </van-radio-group>
<div v-show="xiajiaInfo.proprietary==1 && xiajiaInfo?.type==1 && radio==1" class="tip">已售出需前往完善售出信息</div>
<div class="btnWrap"> <div class="btnWrap">
<div class="btn" @click="noMultipleClicks(submitHandle)">确认</div> <div class="btn" @click="noMultipleClicks(submitHandle)">确认</div>
</div> </div>
@ -124,9 +121,7 @@ export default {
}, },
onRefresh() { onRefresh() {
this.pageNum=1 this.pageNum=1
setTimeout(async () => { setTimeout(() => {
// this.pageList=[]
await this.getList()
this.$toast('刷新成功'); this.$toast('刷新成功');
this.isLoading = false; this.isLoading = false;
}, 1000); }, 1000);
@ -163,19 +158,13 @@ export default {
this.$toast('下架原因不能为空') this.$toast('下架原因不能为空')
return return
} }
if(this.xiajiaInfo.proprietary==1 && this.xiajiaInfo?.type==1 && this.radio==1){ await usedCarRemove({
this.poupShow=false id:this.xiajiaInfo.id,
this.radio = '' downReason:this.radio==1 ? (this.xiajiaInfo?.type==1 ? '已售出' : '已买到') : (this.xiajiaInfo?.type==1 ? '不卖了' : '不买了')
this.$router.push({ name: "sellingInfo", query: {id:this.xiajiaInfo.id,type:'revise'}}) })
}else{ this.poupShow=false
await usedCarRemove({ this.radio = ''
id:this.xiajiaInfo.id, await this.getList()
downReason:this.radio==1 ? (this.xiajiaInfo?.type==1 ? '已售出' : '已买到') : (this.xiajiaInfo?.type==1 ? '不卖了' : '不买了')
})
this.poupShow=false
this.radio = ''
await this.getList()
}
}, },
reviseHandle(item){//修改 reviseHandle(item){//修改
this.$router.push({ this.$router.push({
@ -202,17 +191,8 @@ export default {
console.log('reShangJiaHandle',e) console.log('reShangJiaHandle',e)
} }
}, },
reviseXiajiaHandle(item){//修改下架
console.log("修改下架",item)
this.$router.push({ name: "sellingInfo", query: {id:item.id,type:'revise'}})
},
viewXiajiaHandle(item){//查看下架
console.log("查看下架",item)
this.$router.push({ name: "sellingInfo", query: {id:item.id,type:'view'}})
},
xiajiaHandle(item){//下架 xiajiaHandle(item){//下架
this.poupShow=true this.poupShow=true
this.radio = ''
this.xiajiaInfo=item this.xiajiaInfo=item
}, },
isToday(time) { isToday(time) {
@ -234,24 +214,14 @@ export default {
}, },
getStatus(i){ getStatus(i){
switch (i){ switch (i){
case 1://待审核
return require('@/assets/secondHandCar/wait_verify.png')
case 3://审核不通过
return require('@/assets/secondHandCar/nopass.png')
case 5://已发布 case 5://已发布
return require('@/assets/secondHandCar/fabuing.png') return require('@/assets/secondHandCar/fabuing.png')
case 6://已下架 case 6://已下架
return require('@/assets/secondHandCar/alreayXiajia.png') return require('@/assets/secondHandCar/alreayXiajia.png')
case 7://信息过期 case 7://信息过期
return require('@/assets/secondHandCar/expire.png') return require('@/assets/secondHandCar/expire.png')
case 8://下架待审核 case 1://待审核
return require('@/assets/secondHandCar/xiajia_warting.png') return require('@/assets/secondHandCar/wait_verify.png')
case 9://下架不通过
return require('@/assets/secondHandCar/xiajia_nopass.png')
case 10://下架售出
return require('@/assets/secondHandCar/xiajia_saled.png')
case 11://下架报废
return require('@/assets/secondHandCar/xiajia_scrap.png')
default://未通过 default://未通过
return require('@/assets/secondHandCar/nopass.png') return require('@/assets/secondHandCar/nopass.png')
} }
@ -394,10 +364,6 @@ export default {
width: 43px; width: 43px;
height: 14px; height: 14px;
} }
.bigImg{
width: 60px;
height: 16px;
}
} }
.type{ .type{
font-weight: 400; font-weight: 400;
@ -511,11 +477,6 @@ export default {
} }
} }
} }
.tip{
color: red;
margin-left: 25px;
margin-bottom: 6px;
}
} }
.empty{ .empty{
@include flexTwoCenter; @include flexTwoCenter;

View File

@ -1,489 +0,0 @@
<template>
<div class="wrap" >
<div class="headerWrap">
<img class="bg" src="@/assets/secondHandCar/bg.png" />
<div class="navWrap">
<div v-if="isWebFunc()" style="opacity: 0;" class="back"></div>
<img v-else class="back" @click="h5GoBack" src="@/assets/secondHandCar/back.png" />
<img class="navIcon" src="@/assets/secondHandCar/sellingInfo.png" />
<!-- <span class="title">售出信息</span>-->
<div style="opacity: 0;" class="back"></div>
</div>
<div class="audit" v-if="type=='revise' && status==9 && auditRemark">
<span><img class="noAudit" src="@/assets/secondHandCar/noAudit.png" />审核不通过</span>
<span>{{auditRemark }}</span>
</div>
</div>
<div class="contentWrap" :class="[!(status==9 && auditRemark) ? 'noReasonWrap': 'hasReasonWrap']">
<div class="content">
<div class="item" style="align-items: center">
<span> <span class="star">*</span>售出渠道 </span>
<van-radio-group v-model="form.salesChannel" direction="horizontal" class="radioWrap" :disabled="type !== 'revise'">
<van-radio name="1" :class="{'checked':form.salesChannel==1,'salesChannelRadio':true,'radio':true}">中道二手拖车</van-radio>
<van-radio name="2" :class="{'checked':form.salesChannel==2,'salesChannelRadio':true}">本地线下</van-radio>
<van-radio name="3" :class="{'checked':form.salesChannel==3,'salesChannelRadio':true}">报废</van-radio>
</van-radio-group>
</div>
<template v-if="form.salesChannel==3">
<div class="item" style="margin-top: 8px">
<span style="line-height: 0.5rem"> <span class="star">*</span>报废机动车回收证明 </span>
<upload-common @success3="getRecyclePhoto" @delete3="deleteImgRecycle" :show-del="type == 'revise'"
:text="'回收证明'" :multiple="false" :files.sync="recyclePathList"/>
</div>
<div class="item">
<span> <span class="star">*</span>报废年月</span>
<van-field
:disabled="type !== 'revise'"
@focus="showDatetime = true"
class="radioWrap"
readonly
v-model="scrapTimeFormatShow"
input-align="right"
>
</van-field>
</div>
</template>
<template v-else>
<div class="item">
<span> <span class="star">*</span>购买方 </span>
<van-field
:disabled="type !== 'revise'"
class="radioWrap"
v-model="form.purchaser"
input-align="right"
> </van-field>
</div>
<div class="item">
<span> <span class="star">*</span>售出价格 </span>
<van-field
:disabled="type !== 'revise'"
type="number"
class="radioWrap"
v-model="form.sellPrice"
input-align="right"
>
<template slot="right-icon" >
<span style="white-space: nowrap; margin-left: 8px;"> </span>
</template>
</van-field>
</div>
<div class="item" style="margin-top: 8px">
<span> <span class="star">*</span>交易合同 </span>
<upload-common @success3="getTradePhoto" @delete3="deleteImgTrade" :show-del="type == 'revise'"
:text="'交易合同'" :multiple="false" :files.sync="tradeContractPathList"/>
</div>
<div class="item">
<span> <span class="star">*</span>交易年月</span>
<van-field
:disabled="type !== 'revise'"
@focus="showDatetime = true"
class="radioWrap"
readonly
v-model="tradeTimeFormatShow"
input-align="right"
> </van-field>
</div>
</template>
</div>
<div class="btnWrap" v-if="type !== 'view'">
<div v-if="type == 'revise'" class="btn commonBtn" @click="noMultipleClicks(submitHandle)">确认售出</div>
<template v-else-if="type=='audit'">
<div style="margin: 10px">不通过原因</div>
<el-input style="margin-bottom: 10px;margin-left: 10px" class="ipt" v-model.trim="auditReason" type="textarea" :autosize="{ minRows: 2, maxRows: 6 }"
maxlength="200" show-word-limit placeholder="请填写不通过原因"></el-input>
<div class="auditBtn">
<div class="commonBtn" @click="noMultipleClicks(auditHandle,0)">审核不通过</div>
<div class="commonBtn" @click="noMultipleClicks(auditHandle,1)"><span style="margin-right: 6px"></span>审核通过</div>
</div>
</template>
</div>
</div>
<van-popup v-model="showDatetime" round position="bottom">
<van-datetime-picker
class="dataTime"
v-if="showDatetime"
v-model="time"
type="date"
:min-date="minDate"
@confirm="onConfirm"
@cancel="showDatetime = false"
/>
</van-popup>
</div>
</template>
<script>
import {myMixins} from "@/utils/myMixins"
import {auditCarInfo, usedCarRemove,carInfoDetail,auditCarInfoAgain} from "@/api/secondHandCar"
import uploadCommon from "@/views/secondHandCar/components/upload-common.vue";
import {timeFormat} from "@/utils/common";
export default {
name: "sellingInfo",
mixins:[myMixins],
data(){
return{
noClick:true,
form:{
id:'',
downReason: '已售出',
salesChannel:'',
purchaser:'',
sellPrice:'',
tradeContractPath:'',
tradeTime:'',
recyclePath:'',
scrapTime:'',
},
tradeContractPathList:[],
recyclePathList:[],
otherImgSrc:[],
otherImgSrcList:[],
type:'',
auditRemark:'',
auditReason:'',
status:'' ,
time:'',
showDatetime:false,
minDate: new Date(),
}
},
async mounted() {
const urlParams = new URLSearchParams(window.location.search);
this.form.id=this.$route.query.id || urlParams.get('id');
this.type=this.$route.query.type || urlParams.get('type');
if( this.form.id){
let res = await carInfoDetail({
id:this.form.id,
queryType:4,
})
this.form={...res.data}
this.form.downReason='已售出'
this.auditRemark=res.data?.auditRemark
this.status=res.data?.status?.code
if(res.data?.tradeContractPath){
this.tradeContractPathList=[{url:res.data?.tradeContractPath}]
}
if(res.data?.recyclePath){
this.recyclePathList=[{url:res.data?.recyclePath}]
}
}
},
methods:{
onConfirm(data) {
this.time = timeFormat(new Date(data))
if(this.form.salesChannel==3){
this.form.scrapTime = timeFormat(new Date(data))
}else {
this.form.tradeTime = timeFormat(new Date(data))
}
this.showDatetime = false;
},
// 审核操作
async auditHandle(type){
if (!type && !this.auditReason){
this.$toast('请填写不通过原因')
return
}
try {
await auditCarInfo({
id: this.form.id,
auditResult: type ? 1 : 0 ,
auditReason: this.auditReason,
...this.form,
licenseType:this.form?.licenseType?.code,
boardType:this.form?.boardType?.code,
emissionStandard:this.form?.emissionStandard?.code,
})
setTimeout(()=>{
this.closeParentDialog()
},1000)
} finally {
console.log(type)
}
},
async submitHandle(){
let rule = this.validationRules.find(item =>
item.required && (item.value === null || item.value === undefined || item.value === ''))
if(rule){
this.$toast(rule.name)
return
}
try {
// 清除原本选择的信息
if(this.form.salesChannel==3){
this.form.purchaser=''
this.form.sellPrice=''
this.form.tradeContractPath=''
this.form.tradeTime=''
}else{
this.form.recyclePath=''
this.form.scrapTime=''
}
let res=''
if(this.status == 9){
res=await auditCarInfoAgain({// 审核不通过再次提交
...this.form,
salesChannel:Number(this.form.salesChannel)
})
}else {
res=await usedCarRemove({
...this.form,
salesChannel:Number(this.form.salesChannel)
})
}
if(res.code == 200 && !res.msg){
this.$toast('操作成功')
if(this.isWebFunc()){
setTimeout(()=>{
this.closeParentDialog()
},1000)
}else{
setTimeout(()=>{
this.h5GoBack()
},1000)
}
}else{
this.$toast(res.msg)
}
} catch (e) {
console.log(e)
}
},
getTradePhoto(data) {
this.form.tradeContractPath = data.url
},
deleteImgTrade() {
this.form.tradeContractPath = '';
},
getRecyclePhoto(data) {
this.form.recyclePath = data.url
},
deleteImgRecycle() {
this.form.recyclePath = '';
},
},
computed: {
tradeTimeFormatShow(){
return this.form.tradeTime ? this.form.tradeTime?.substring(0,10) : '';
},
scrapTimeFormatShow(){
return this.form.scrapTime ? this.form.scrapTime?.substring(0,10) : '';
},
validationRules() {
return [
{required:true, value: this.form.salesChannel, name: '售出渠道不能为空' },
{required:this.form.salesChannel==3 ? false : true, value: this.form.purchaser, name: '购买方不能为空' },
{required:this.form.salesChannel==3 ? false : true, value: this.form.sellPrice, name: '售出价格不能为空' },
{required:this.form.salesChannel==3 ? false : true, value: this.form.tradeContractPath, name: '交易合同文件不能为空' },
{required:this.form.salesChannel==3 ? false : true, value: this.form.tradeTime, name: '交易年月不能为空' },
{required:this.form.salesChannel==3 ? true : false, value: this.form.recyclePath, name: '报废机动车回收证明不能为空' },
{required:this.form.salesChannel==3 ? true : false, value: this.form.scrapTime, name: '报废年月不能为空' },
];
},
},
components:{uploadCommon}
}
</script>
<style scoped lang="scss">
@import '@/styles/mixin.scss';
.wrap {
@include wh(100%, 100%);
position: relative;
}
.headerWrap{
width: 100%;
box-sizing: border-box;
padding-top: 15px;
padding-bottom: 15px;
position: relative;
.navWrap{
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
box-sizing: border-box;
padding: 0 16px 10px;
}
.bg {
position: absolute;
width: 100%;
height: 120px;
line-height: 120px;
top: 0;
left: 0;
opacity: 0.5;
z-index: -1;
}
.back{
@include wh(15px,15px);
}
.title{
font-weight: bold;
font-size: 16px;
color: #203152;
}
.navIcon{
@include wh(84px,21px);
}
.audit{
@include wh(100%,43px);
background: #FFF7F4;
display: flex;
align-items: center;
justify-content: center;
font-size: 11px;
color: #FF6B3B;
.noAudit{
@include wh(13px,12px);
margin-right: 5px;
vertical-align: bottom;
}
span:first-child{
font-weight: 600;
}
}
}
.navBar{
margin-bottom: 46px;
}
.noReasonWrap{
height: calc(100% - 42px);
}
.hasReasonWrap{
height: calc(100% - 85px);
}
.contentWrap{
width: 100%;
overflow-y: auto;
@include sizingPadding(15px,15px);
@include flexBetween;
.btnWrap{
padding-bottom: 20px;
padding-top: 15px;
}
.commonBtn{
height: 46px;
line-height: 46px;
text-align: center;
font-weight: bold;
border-radius: 5px;
color: #FFFFFF;
cursor: pointer;
}
.btn{
width: 296px;
background: #4A7FEB;
margin: 0 auto;
font-size: 15px;
}
.auditBtn{
display: flex;
justify-content: space-between;
font-size: 14px;
box-sizing: border-box;
padding: 0 6px;
div:first-child{
width: 100px;
opacity: 0.79;
background: #1C2C49;
}
div:last-child{
width: 200px;
background: #4A7FEB;
}
}
}
.content{
width: 100%;
.item{
display: flex;
font-weight: 400;
font-size: 13px;
color: #2C3D54;
line-height: 44px;
width: 100%;
box-sizing: border-box;
padding-left: 21px;
padding-right: 9px;
span:first-child{
display: inline-block;
width:70px;
font-size: 13px;
color: rgba(44, 61, 84, 0.59);
}
span:last-child{
display: inline-block;
width:calc(100% - 70px);
border-bottom: 1px solid #E9E9EA;
}
.orc{
box-sizing: border-box;
padding-left: 6px;
}
}
.star{
color: #FF4B4B !important;
opacity: 1 !important;
font-weight: bold;
font-size: 12px;
margin-right: 6px;
margin-left: -6px;
}
.radioWrap{
width:calc(100% - 70px);
border-bottom: 1px solid #E9E9EA;
}
}
.lastLine{
margin-top: 3px !important;
}
::v-deep .van-icon-success{
display: none !important;
}
::v-deep .van-radio__label{
margin-left: 0;
width: 54px;
height: 23px;
border-radius: 13px;
border: 1px solid #9F9F9F;
opacity: 0.5;
text-align: center;
line-height: 23px;
font-size: 12px;
color: #323233;
opacity: 1;
}
::v-deep .van-radio--horizontal{
margin-right: 4px;
}
::v-deep .van-radio--horizontal:last-child{
margin-right: 0;
}
::v-deep .checked .van-radio__label{
background: #FFF1EC !important;
border: 1px solid #FF5C26 !important;
color: #FE5006 !important;
border-radius: 13px !important;
}
::v-deep .van-field__right-icon{
margin-right: 0;
padding: 0;
}
::v-deep .ipt .el-textarea__inner{
background: #F5F7F9;
border-radius: 4px;
font-size: 12px;
border: none;
}
::v-deep .van-popup__close-icon--top-right{
display: none;
}
::v-deep .salesChannelRadio .van-radio__label{
margin-bottom: 8px !important;
}
::v-deep .radio .van-radio__label{
width: 80px !important;
}
</style>

View File

@ -23,12 +23,6 @@
</div> </div>
<div class="viewNum">{{detailInfo.attentionCount}}人想卖<span>{{detailInfo.browseCount}}人浏览</span></div> <div class="viewNum">{{detailInfo.attentionCount}}人想卖<span>{{detailInfo.browseCount}}人浏览</span></div>
</div> </div>
<div class="priceWrap">
<div class="commonColor" style="margin-top: 5px">
车源ID: &nbsp;&nbsp;&nbsp;&nbsp;{{ detailInfo.code }}
<img class="copyIcon" @click="copyHandler(detailInfo.code)" src="@/assets/copy.png" />
</div>
</div>
</div> </div>
<div class="detailInfoWrap wrapCommon"> <div class="detailInfoWrap wrapCommon">
<div> <div>
@ -107,16 +101,6 @@ export default {
this.getDuration(1) this.getDuration(1)
}, },
methods:{ methods:{
copyHandler(copyText){
let inputNode = document.createElement('input') // 创建input
inputNode.value = copyText // 赋值给 input 值
document.body.appendChild(inputNode) // 插入进去
inputNode.select() // 选择对象
document.execCommand('Copy') // 原生调用执行浏览器复制命令
inputNode.className = 'oInput'
inputNode.style.display = 'none' // 隐藏
this.$toast('复制成功')
},
getDuration(type){ getDuration(type){
const endTime = new Date(); const endTime = new Date();
const duration = (endTime - this.startTime) / 1000; // 计算时长(秒) const duration = (endTime - this.startTime) / 1000; // 计算时长(秒)
@ -306,14 +290,4 @@ export default {
cursor: pointer; cursor: pointer;
} }
} }
.commonColor {
color: #999999 !important;
display: flex;
align-items: center;
}
.copyIcon {
width: 35px;
height: 15px;
margin-left: 10px
}
</style> </style>

View File

@ -1,415 +0,0 @@
<template>
<div class="wrap">
<div class="alarm_info">
<div class="alarm_title">
<div class="title_left">
<span class="car_title">{{info.alarmTypeString}}</span>
<img class="alarm_level" v-if="info.level == 1" src="@/assets/alarm_one.png" alt="">
<img class="alarm_level" v-if="info.level == 2" src="@/assets/alarm_two.png" alt="">
<img class="alarm_level" v-if="info.level == 3" src="@/assets/alarm_three.png" alt="">
</div>
<div class="status">{{info.handStatusString}}</div>
</div>
<div class="content_list">
<div class="alarm_content">
<div class="label">报警时间:</div>
<div class="content">{{info.startTime}}</div>
</div>
<div class="alarm_content">
<div class="label">报警详情:</div>
<div class="content">{{info.alarmRemark}}</div>
</div>
<div class="alarm_content">
<div class="label">报警照片:</div>
<div class="content">
<img class="photo" v-if="info.url" :src="info.url" alt="">
</div>
</div>
<div class="alarm_content">
<div class="label">报警通道:</div>
<div class="content content_flex">
<span>{{ info.plateNumber + '_' + (info?.channel || '') }} <!--浙A7H1M2_1--></span>
<span class="btn" @click="goAlarmMonitoring">查看监控</span>
</div>
</div>
</div>
</div>
<div class="alarm_info car_info">
<div class="car_title title">
车辆位置
</div>
<div class="car_map">
<div class="map_title">
<span class="driver_name">{{info.vehicleName}} / {{info.plateNumber}}</span>
<span class="driver_name">司机{{info.onlineDriverName}} <a :href="'tel:' + info.onlinePhone">{{info.onlinePhone}}</a></span>
</div>
<div class="map_cover" id="container"></div>
</div>
</div>
<div class="deal_btn" v-if="[0, 3].includes(info.handStatus)" @click="dealWithShow = true">处理</div>
<van-popup v-model="dealWithShow" v-if="dealWithShow" round position="center">
<div class="dialog_wrap">
<div class="dialog_title">报警处理</div>
<div>
<van-radio-group v-model="radio" @change="change" class="horizontal-radio-group">
<van-radio v-for="item in radioList" :key="item.value" :name="item.value" :disabled="item.disabled" class="item">
<span :style="{ color: radio === item.value ? '#393230' : 'rgba(0, 0, 0, 0.5)' }">
{{ item.name }}
</span>
<img
slot="icon"
class="icon"
slot-scope="props"
:src="props.checked ? activeIcon : inactiveIcon"
>
</van-radio>
</van-radio-group>
<div class="alarm_tip" v-if="['1', '2', '3'].includes(String(info.alarmType))">
开始处理后将流转至技术支持进行处理
</div>
<div class="alarm_text" v-if="radio == 5">
<textarea class="alarm_textarea" id="text-input" rows="6" placeholder="处理结果:" v-model.trim="remark"></textarea>
</div>
<div class="btn_wrap">
<div class="btn_confirm" @click="noMultipleClicks(operatorHandle)">确认</div>
<div class="btn_close" @click="dealWithShow = false">关闭</div>
</div>
</div>
</div>
</van-popup>
</div>
</template>
<script>
import {myMixins} from "@/utils/myMixins"
import { getAlarmByCode, dealWithAlarm } from "@/api/order"
import trailerPosition from "@/assets/alarm_trailer.png";
import repairPosition from "@/assets/alarm_repair.png";
export default {
name: "vehicleAlarmDetail",
mixins: [ myMixins ],
data() {
return {
noClick: true,
map: null,
lng: 121.553376,
lat: 31.247998,
radio: '',
activeIcon: require('@/assets/alarm_check.png'),
inactiveIcon: require('@/assets/alarm_unCheck.png'),
dealWithShow: false,
radioList: [{ name: '开始处理', value: 3, disabled: false }, { name: '处理完成', value: 5, disabled: false }],
remark: '',
code: '',
info: {}
}
},
mounted() {
this.code = this.$route.query.code;
this.getAlarmDetail();
this.initMap();
},
methods: {
// 新增方法:重置弹窗状态
resetPopupState() {
this.radio = '';
this.remark = '';
// 重置radioList状态
this.radioList = [
{ name: '开始处理', value: 3, disabled: false },
{ name: '处理完成', value: 5, disabled: false }
];
},
goAlarmMonitoring() {
let data = {
"action":"goMonitoring",
"params": {
"code": this.code
}
};
let u = navigator.userAgent;
let isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
if(isiOS){
window.webkit.messageHandlers.nativeObject.postMessage(data);
}else {
window.android.sendMessage("code=" + this.code);
}
},
async operatorHandle() {
try {
await dealWithAlarm({
alarmId: this.info.id,
handleStatus: this.radio,
remark: this.remark
})
this.$toast('操作成功')
this.resetPopupState();
} finally {
this.dealWithShow = false;
await this.getAlarmDetail();
}
},
change(e) {
this.radio = e
},
async getAlarmDetail() {
let res = await getAlarmByCode({
code: this.code
});
if(!res.data) {
this.$router.push({
name: 'vehicleAlarmList',
params: {
token: localStorage.getItem('token')
},
replace: true // 关键:替换当前路由,而不是新增历史记录
});
return
}
this.info = res?.data;
// 每次获取详情时重置radioList
this.radioList = [
{ name: '开始处理', value: 3, disabled: false },
{ name: '处理完成', value: 5, disabled: false }
];
if( this.info.handStatus == 0 && ['1', '2', '3'].includes(String(this.info.alarmType))) { // 未处理,且需要技术处理
this.radio = this.radioList[0].value
this.radioList[1].disabled = true
}
if(this.info.handStatus == 3) {
this.radioList[0].disabled = true
}
},
initMap() {
this.map = new AMap.Map('container',{
zoom:14,//级别(缩放比例 3-20 )
center: [this.lng, this.lat],//中心点坐标
viewMode:'2D',//使用3D视图
})
this.map.on('complete', () => {
this.mapMarkers();
});
},
mapMarkers() {
let url = String(this.info.vehicleType) == '5' ? repairPosition : trailerPosition
let marker = new AMap.Marker({
position: [this.lng, this.lat],
icon: new AMap.Icon({
image: url, // 图片的相对路径
size: new AMap.Size(42, 50), // 图标的尺寸
imageSize: new AMap.Size(42, 50) // 图片的实际尺寸
}),
});
this.map.add(marker);
}
}
}
</script>
<style scoped lang="scss">
.wrap {
width: 100%;
height: 100%;
background-color: #F4F5F7 !important;
box-sizing: border-box;
overflow-y: auto;
padding: 0 12px;
box-sizing: border-box;
}
.alarm_info {
padding-top: 12px;
padding-bottom: 16px;
background: #FFFFFF;
box-shadow: 0px 1px 4px 0px rgba(39,52,125,0.05);
border-radius: 6px;
backdrop-filter: blur(5.602678571428572px);
margin-top: 10px;
.alarm_title {
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1px solid rgba(233, 233, 234, 0.6);
padding: 3px 20px 10px 18px;
.title_left {
display: flex;
align-items: center;
.alarm_level {
width: 32px;
height: 14px;
margin-left: 7px;
}
}
.status {
font-size: 11px;
color: #FA8D14;
font-weight: bold;
}
}
.content_list {
padding: 12px 18px 0px;
}
.alarm_content {
display: flex;
margin-bottom: 6px;
.content {
margin-left: 10px;
font-size: 12px;
color: rgba(0, 0, 0, 0.75);
flex: 1;
.btn {
/*display: inline-block;*/
padding: 5px 12px;
background: #FA8236;
border-radius: 3px;
color: #fff;
font-size: 12px;
}
.photo {
width: 75px;
height: 55px;
margin-right: 6px;
margin-bottom: 6px;
}
}
}
}
.label {
color: rgba(0, 0, 0, 0.5);
}
.content_flex {
display: flex;
justify-content: space-between;
}
.car_title {
font-size: 14px;
font-weight: bold;
color: rgba(0, 0, 0, 0.85);
}
.title {
padding-left: 18px;
margin-bottom: 8px;
}
.car_info {
padding: 12px 4px 5px 4px;
}
.car_map {
width: 100%;
/*height: 204px;*/
border-radius: 4px;
border: 1px solid #F0F0F0;
background-color: #F9FCFF;
box-sizing: border-box;
.map_title {
display: flex;
align-items: center;
justify-content: space-between;
padding: 10px 8px 10px 15px;
.driver_name {
font-size: 12px;
color: #000000;
a {
color: #377BE6;
}
}
}
.map_cover {
width: 100%;
height: 174px;
background-color: #fff;
}
}
.deal_btn {
width: calc(100% - 38px);
height: 48px;
text-align: center;
line-height: 48px;
position: fixed;
bottom: 10px;
left: 19px;
font-size: 15px;
color: #fff;
background: #354D93;
border-radius: 5px;
}
.dialog_wrap {
width: 325px;
border-radius: 13px;
.dialog_title {
height: 68px;
line-height: 82px;
background: linear-gradient( 180deg, #FFE8DA 0%, rgba(255,233,233,0) 100%);
font-size: 18px;
color: #E0481E;
text-align: center;
font-weight: bold;
}
.horizontal-radio-group {
display: flex;
flex-direction: row;
justify-content: space-around;
margin-bottom: 15px;
.icon {
width: 16px;
height: 16px;
}
.item {
font-size: 14px;
margin-bottom: 8px;
display: flex;
align-items: center;
}
}
.alarm_tip {
font-size: 14px;
color: #FF5D3B;
margin: 10px 0 20px;
text-align: center;
}
.alarm_text {
width: 100%;
padding: 0 25px 15px;
box-sizing: border-box;
.alarm_textarea {
width: 100%;
background: #FFFBFB;
border-radius: 3px;
border: 1px solid #F97C64;
backdrop-filter: blur(10px);
padding: 10px;
color: #FF5D3B;
box-sizing: border-box;
}
.alarm_textarea::placeholder {
color: rgba(255, 93, 59, 0.8);
}
}
.btn_wrap {
.btn_confirm {
width: 173px;
height: 42px;
line-height: 42px;
color: #FFFFFF;
font-size: 15px;
font-weight: bold;
text-align: center;
background: #F16363;
border-radius: 23px;
margin: 0 auto;
}
.btn_close {
margin-top: 12px;
margin-bottom: 22px;
font-size: 14px;
color: rgba(44, 65, 85, 0.6);
text-align: center;
}
}
}
::v-deep .van-radio__icon {
display: flex;
align-items: center;
}
::v-deep .van-radio__label--disabled {
opacity: 0.5;
}
</style>

View File

@ -1,247 +0,0 @@
<template>
<div class="wrap">
<div class="tab_wrap">
<div class="item_wrap" v-for="(item, index) in tabArr" :key="index" @click="changeTab(index)">
<span class="alpha" :class="{'active' : activeIndex == index }"> {{ item.name }}</span>
<span class="numTip" style="opacity: 1 !important;" v-if="item.num > 0">{{item.num}}</span>
</div>
</div>
<van-pull-refresh class="refresh" v-model="isLoading" @refresh="onRefresh" v-show="!show">
<van-list
v-model="loading"
:finished="finished"
finished-text="没有更多了"
@load="onLoad"
>
<div class="content_wrap">
<div class="alarm_wrap" v-for="(item, index) in pageList" :key="index" @click="goDetail(item)">
<div class="alarm_title">
<div class="title_left">
<span>{{item.alarmTypeString}}</span>
<img class="alarm_level" v-if="item.level == 1" src="@/assets/alarm_one.png" alt="">
<img class="alarm_level" v-if="item.level == 2" src="@/assets/alarm_two.png" alt="">
<img class="alarm_level" v-if="item.level == 3" src="@/assets/alarm_three.png" alt="">
</div>
<div class="label">{{item.startTime}}</div>
</div>
<div class="alarm_content">
<div class="label flexLabel">车辆名称:</div>
<div class="content flexContent">{{item.vehicleName}}</div>
</div>
<div class="alarm_content">
<div class="label flexLabel">报警详情:</div>
<div class="content flexContent">{{item.alarmRemark}}</div>
</div>
</div>
</div>
</van-list>
</van-pull-refresh>
<div class="bgEmptyImg" v-show="show" >
<img src="@/assets/emptyData.png" />
</div>
</div>
</template>
<script>
import {myMixins} from "@/utils/myMixins"
import { getAlarmList, getAlarmCount } from "@/api/order"
export default {
name: "vehicleAlarmList",
data() {
return {
tabArr: [{ name: '未处理', num: 0 }, { name: '技术处理中', num: 0 }, {name: '处理中', num: 1 }],
activeIndex: 0,
pageNum:1,
pageSize:10,
total:'',
pageList: [],
isLoading: '',
loading: false,
finished: false,
}
},
mixins: [ myMixins ],
computed:{
show() {
return (this.pageList.length < 0 || this.pageList.length == 0); // 判断数组长度是否大于 0
},
},
async mounted() {
await this.getList()
},
methods: {
goDetail(item) {
this.goPage('vehicleAlarmDetail', { code: item.code })
},
async getCount() {
let res = await getAlarmCount();
this.tabArr[0].num = res?.data?.alarmCount || 0
this.tabArr[1].num = res?.data?.jxCount || 0
this.tabArr[2].num = res?.data?.yyCount || 0
},
async changeTab(index) {
this.activeIndex = index
this.pageNum = 1
this.pageList = [];
this.total= 0
await this.getList()
},
async getList() {
let handleStatus;
if( this.activeIndex == 2 ) {
handleStatus = 3
} else {
handleStatus = this.activeIndex
}
let res = await getAlarmList({
pageNum:this.pageNum,
pageSize:this.pageSize,
handStatus: handleStatus
})
this.total = res.total
if(this.pageNum == 1){// 第一页直接赋值
this.pageList=res.data
}else{// 第二页数据拼接
let preList = this.pageList;
let arr = res.data;
this.pageList = preList.concat(arr)
}
await this.getCount();
},
async onLoad(){
this.pageNum++;
await this.getList()
this.loading = false;
if (this.pageList.length >= this.total) {
this.finished = true;
}
},
async onRefresh() {
this.pageNum=1
await this.getList()
setTimeout(() => {
this.$toast('刷新成功');
this.isLoading = false;
}, 1000);
},
}
}
</script>
<style scoped lang="scss">
.wrap{
width: 100%;
height: 100%;
background-color: #F4F5F7 !important;
box-sizing: border-box;
overflow-y: auto;
}
.tab_wrap {
display: flex;
justify-content: space-around;
padding-top: 15px;
padding-bottom: 10px;
position: fixed;
width: 100%;
top: 0;
left: 0;
background-color: #F4F5F7;
z-index: 100;
.item_wrap {
display: flex;
align-items: center;
}
.alpha {
color: rgba(115, 115, 115, 0.7);
font-size: 13px;
line-height: 13px;
}
.active {
font-size: 14px;
color: #3678FF;
position: relative;
}
.active:after {
content: '';
display: block;
width: 18px;
height: 3px;
background: linear-gradient( 270deg, #33A3FF 0%, #176AFE 100%);
border-radius: 2px;
position: absolute;
margin-top: 3px;
left: 50%;
transform: translateX(-50%);
}
.numTip {
border-radius: 4px;
background: #F95B45;
display: inline-block;
padding: 2px 4px;
font-weight: 600;
font-size: 11px;
color: #FFFFFF;
margin-left: 5px;
}
}
.content_wrap {
padding: 50px 12px 0;
.alarm_wrap {
margin-top: 10px;
background: #FFFFFF;
box-shadow: 0px 2px 10px 0px rgba(216,216,216,0.5);
border-radius: 6px;
padding: 13px 13px 17px 18px;
box-sizing: border-box;
.alarm_title {
display: flex;
justify-content: space-between;
align-items: center;
}
.label {
color: rgba(0, 0, 0, 0.5);
}
.flexLabel {
min-width: 50px;
flex-shrink: 0;
}
.flexContent {
flex: 1;
word-break: break-all;
}
.title_left {
display: flex;
align-items: center;
span {
font-size: 14px;
font-weight: bold;
color: rgba(0, 0, 0, 0.85);
}
.alarm_level {
width: 32px;
height: 14px;
margin-left: 7px;
}
}
.alarm_content {
display: flex;
margin-top: 10px;
.content {
margin-left: 10px;
font-size: 13px;
color: rgba(0, 0, 0, 0.75);
}
}
}
}
.bgEmptyImg{
display: flex;
align-items: center;
justify-content: center;
height: 90% ;
background-color: #F4F5F7;
img{
width: 100%;
}
}
</style>