2 Commits

4 changed files with 15 additions and 23 deletions

View File

@ -111,6 +111,7 @@ export function getOrCodeInfo(data){
return request({ return request({
url:'/agg-api/wxcp/createContactQrCode', url:'/agg-api/wxcp/createContactQrCode',
method:'POST', method:'POST',
contentType:'application/json',
data data
}) })
} }

View File

@ -111,7 +111,7 @@
<script> <script>
import {leftCopy} from "@/utils/common" import {leftCopy} from "@/utils/common"
import QRCode from 'qrcode' import QRCode from 'qrcode'
import { uploadImage, ocrHandler, unifiedOCRWithCompress, getArea, saveSupplier, getSupplierInfo, getOrCodeInfo, getContactQrCodeResult } from "@/api/mine" import { uploadImage, supplierServicePartTree, ocrHandler, unifiedOCRWithCompress, getArea, saveSupplier, getSupplierInfo, getOrCodeInfo, getContactQrCodeResult } from "@/api/mine"
import {myMixins} from "@/utils/myMixins" import {myMixins} from "@/utils/myMixins"
import {Dialog} from "vant"; import {Dialog} from "vant";
export default { export default {
@ -144,23 +144,14 @@
areaShow: false, areaShow: false,
areaList: [], areaList: [],
supplierServiceList: [], supplierServiceList: [],
bigServiceList: [{ bigServiceList: [],
id: 1002,
title: '拖车服务'
}, {
id: 1003,
title: '抢修服务'
}, {
id: 1004,
title: '困境救援'
}],
defaultProps: { defaultProps: {
children: 'children', children: 'children',
label: 'title', label: 'title',
}, },
areaProps: { multiple: true, checkStrictly: true, value: 'id',label: 'title', emitPath: false, }, areaProps: { multiple: true, checkStrictly: true, value: 'id',label: 'title', emitPath: false, },
configId: '', configId: '',
wechatId: '', wechatId: 'test',
} }
}, },
async mounted() { async mounted() {
@ -171,7 +162,7 @@
await this.getInfoHandler(); await this.getInfoHandler();
} }
// await this.getSupplierServiceTree(); await this.getSupplierServiceTree();
}, },
methods: { methods: {
async QrCodeHandler() { async QrCodeHandler() {
@ -205,8 +196,8 @@
if(this.companyPhoto) { if(this.companyPhoto) {
this.companyPhotoList = [{ url : this.companyPhoto }]; this.companyPhotoList = [{ url : this.companyPhoto }];
} }
if( _data.service ) { if( _data.serviceType ) {
this.$refs.tree.setCheckedKeys(_data.service.split(',')) this.$refs.tree.setCheckedKeys(_data.serviceType.split(','))
} }
if(_data?.serviceAreaCode) { if(_data?.serviceAreaCode) {
this.$set(this.form, 'serviceAreaCode', _data?.serviceAreaCode.split(',').map(item => Number(item))); this.$set(this.form, 'serviceAreaCode', _data?.serviceAreaCode.split(',').map(item => Number(item)));
@ -262,7 +253,7 @@
checkArr.push(item.data.id) checkArr.push(item.data.id)
}) })
/* let treeArr = this.$refs.tree.getCheckedKeys(); let treeArr = this.$refs.tree.getCheckedKeys();
let childrenTreeArr = []; let childrenTreeArr = [];
treeArr.map(item => { treeArr.map(item => {
let _arr = this.supplierServiceList.filter(_item => _item.id == item) || [] // 获取对应的大类 let _arr = this.supplierServiceList.filter(_item => _item.id == item) || [] // 获取对应的大类
@ -270,14 +261,14 @@
childrenTreeArr?.push(childItem?.id) childrenTreeArr?.push(childItem?.id)
}) })
}) })
let allArr = [...treeArr, ...childrenTreeArr]*/ let allArr = [...treeArr, ...childrenTreeArr]
let res = await saveSupplier({ let res = await saveSupplier({
id: this.id, id: this.id,
...this.form, ...this.form,
idCardFrontUrl: this.idFrontPhoto, idCardFrontUrl: this.idFrontPhoto,
idCardBackUrl: this.idBackPhoto, idCardBackUrl: this.idBackPhoto,
businessLicense: this.companyPhoto, businessLicense: this.companyPhoto,
service: this.$refs.tree.getCheckedKeys().join(',') , serviceType: allArr.join(',') ,
serviceAreaCode: checkArr.join(','), serviceAreaCode: checkArr.join(','),
wechatId: this.wechatId, wechatId: this.wechatId,
}); });
@ -297,9 +288,9 @@
let res = await getArea(); let res = await getArea();
this.areaList = res?.data; this.areaList = res?.data;
}, },
/*async getSupplierServiceTree(){ async getSupplierServiceTree(){
let res = await supplierServicePartTree({ let res = await supplierServicePartTree({
serviceTypes: '1002,1003,1004', serviceTypes: '1002,1003',
treeType: 2 treeType: 2
}); });
this.supplierServiceList=res.data this.supplierServiceList=res.data
@ -308,7 +299,7 @@
let obj = {...item, children: null} let obj = {...item, children: null}
this.bigServiceList.push(obj) this.bigServiceList.push(obj)
}) })
},*/ },
confirmHandle(val){ confirmHandle(val){
this.region=[] this.region=[]
val?.forEach(item => this.region.push(item.name)) val?.forEach(item => this.region.push(item.name))

View File

@ -74,7 +74,7 @@
</div> </div>
<div class="info_item"> <div class="info_item">
<div class="label">服务能力</div> <div class="label">服务能力</div>
<div class="content service_color">{{supplierInfo?.serviceCategoryName}}</div> <div class="content service_color">{{supplierInfo?.serviceName}}</div>
</div> </div>
<div class="info_item"> <div class="info_item">
<div class="label">拖车数量</div> <div class="label">拖车数量</div>

View File

@ -46,7 +46,7 @@
<div class="item"> <div class="item">
<span class="leftTitle fontColor">服务类型:</span><span class="rightContent">{{ orderDetailInfo.taskServiceName }}</span> <span class="leftTitle fontColor">服务类型:</span><span class="rightContent">{{ orderDetailInfo.taskServiceName }}</span>
</div> </div>
<div class="item" v-if="orderDetailInfo?.userVehicleTypeString"> <div class="item">
<span class="leftTitle fontColor">车辆类型:</span><span class="rightContent">{{ orderDetailInfo.userVehicleTypeString }}<van-icon class="icon" name="question" @click="showCarTypeShow = true" /></span> <span class="leftTitle fontColor">车辆类型:</span><span class="rightContent">{{ orderDetailInfo.userVehicleTypeString }}<van-icon class="icon" name="question" @click="showCarTypeShow = true" /></span>
</div> </div>
<div class="item"> <div class="item">