Ver código fonte

车辆信息接口、样式调整

yxb
zengyuehua 2 anos atrás
pai
commit
5ac89e9d8e

+ 60
- 31
after-sale/rescind-carId/rescind-carId-select.vue Ver arquivo

<image v-else class="icon" :src="state.form.vehNegImgUrl"></image> <image v-else class="icon" :src="state.form.vehNegImgUrl"></image>
</view> </view>
</view> </view>
<view class="picture-wrapper" @click="cardFileImageUpdate()">
<view class="picture-wrapper" @click="cardFileImageUpdate(1)">
<view class="bg"> <view class="bg">
<view class=""> <view class="">
<view class="name"> 人车合影 </view> <view class="name"> 人车合影 </view>
<image v-else class="icon" :src="state.FormData.peopleVehicleImgUrl"></image> <image v-else class="icon" :src="state.FormData.peopleVehicleImgUrl"></image>
</view> </view>
</view> </view>
<view class="picture-wrapper" @click="cardFileImageUpdate(2)">
<view class="bg">
<view class="">
<view class="name"> 承诺书 </view>
<view class="value"> 上传承诺书照片 </view>
<view class="tip">
<view class="tip-value"> 拍摄规范 </view>
</view>
</view>
<image v-if="!state.FormData.commitmentUrl" class="icon" :src="`${$imgUrl}applyCard/weituoshu.png`">
</image>
<image v-else class="icon" :src="state.FormData.commitmentUrl"></image>
</view>
</view>
<view class="shibie-wrapper"> <view class="shibie-wrapper">
<view class="title"> 识别内容如下 </view> <view class="title"> 识别内容如下 </view>
<u-form label-width="200" :model="state.form" ref="uForm"> <u-form label-width="200" :model="state.form" ref="uForm">
pathToBase64 pathToBase64
} from "@/utils/image-tools/index.js"; } from "@/utils/image-tools/index.js";
import { import {
reactive
reactive,
ref
} from "vue"; } from "vue";
import { import {
onLoad, onLoad,
} from "@/utils/network/encryption"; } from "@/utils/network/encryption";
import navBar from "../../components/nav-bar/nav-bar2.vue"; import navBar from "../../components/nav-bar/nav-bar2.vue";


// ##################

import {
ref
} from "vue";
import { import {
navTo navTo
} from "../../utils/utils"; } from "../../utils/utils";
// const list = reactive([{
// name: "A12345",
// },
// {
// name: "B12345",
// },
// {
// name: "C12345",
// },
// ]);
// const flag = ref("0");

// const choose = (i, item) => {
// flag.value = i;
// console.log("选择得数据", item);
// navTo("/after-sale/rescind-carId/base-change-people");
// };

// ######################




// ########
const show1 = ref(false) const show1 = ref(false)
const state = reactive({ const state = reactive({
ocrData: { ocrData: {
}, },
actionSheetList: [{ actionSheetList: [{
label: "蓝色", label: "蓝色",
value: 0,
value: '0',
}, { }, {
label: "黄色", label: "黄色",
value: 1, value: 1,
} }
}); });
const savaHandle = () => { const savaHandle = () => {
let data = JSON.stringify(state.FormData)
navTo(`/after-sale/rescind-carId/verification?fromData=${data}`);
if (state.FormData.idcardFrontImgUrl && state.FormData.idcardBacktImgUrl) {
if (state.FormData.vehPosImgUrl && state.FormData.vehNegImgUrl) {
if (state.FormData.peopleVehicleImgUrl) {
if (state.FormData.vehiclePlate && state.FormData.vehiclePlatecolor) {
state.FormData.vehiclePlatecolor=Number(state.FormData.vehiclePlatecolor)
let data = JSON.stringify(state.FormData)
navTo(`/after-sale/rescind-carId/verification?fromData=${data}`);
} else {
uni.showToast({
title: "请填写车牌号和车牌颜色",
icon: "none"
})
}
} else {
uni.showToast({
title: "请上传人车合影",
icon: "none"
})
}
} else {
uni.showToast({
title: "请上传行驶证正反图片",
icon: "none"
})
}
} else {
uni.showToast({
title: "请上传身份证正反图片",
icon: "none"
})
}







console.log(JSON.stringify(state.FormData)); console.log(JSON.stringify(state.FormData));
state.form.caridCorlor = item[0].label state.form.caridCorlor = item[0].label
}; };


const cardFileImageUpdate = () => {
const cardFileImageUpdate = (val) => {
uni.chooseImage({ uni.chooseImage({
count: 1, //只能选取一张照片 count: 1, //只能选取一张照片
sizeType: ["original", "compressed"], //可以指定是原图还是压缩图,默认二者都有 sizeType: ["original", "compressed"], //可以指定是原图还是压缩图,默认二者都有
request(fileUpload, options).then((res) => { request(fileUpload, options).then((res) => {
const data = stringToJson(res.bizContent); const data = stringToJson(res.bizContent);
console.log(data, "didid"); console.log(data, "didid");
state.FormData.peopleVehicleImgUrl = data.data.url;
if (val == 1) {
state.FormData.peopleVehicleImgUrl = data.data.url;
} else {
state.FormData.commitmentUrl = data.data.url;
}

}); });
}) })
.catch((error) => {}); .catch((error) => {});

+ 10
- 1
personal-center/setting/car-information/car-change.vue Ver arquivo

testRecord: '', //检验记录 testRecord: '', //检验记录
fileNum: '', //档案编号 fileNum: '', //档案编号
useCharacter: '', //车辆使用性质 useCharacter: '', //车辆使用性质
registerDate: '' //注册日期
registerDate: '' ,//注册日期
status:""//车辆信息状态
}, },
orderId: "", orderId: "",
isMyPeopple: true, isMyPeopple: true,
state.form.maintenaceMass=data.maintenaceMass state.form.maintenaceMass=data.maintenaceMass
state.form.vehicleDimensions=data.vehicleDimensions state.form.vehicleDimensions=data.vehicleDimensions
state.form.totalMass=data.totalMass state.form.totalMass=data.totalMass
state.form.status=data.status
if(data.status=='使用'){
state.form.status=1
}else if(data.status=='未使用'){
state.form.status=2
}else{
state.form.status=3
}
}); });
//orc接口调用 //orc接口调用
const cardImageOcr = (val: any) => { const cardImageOcr = (val: any) => {

Carregando…
Cancelar
Salvar