Commit 818f9de9 by 前端

Merge branch 'v1.0.1' of http://192.168.3.233:8090/glsx/gl_tape into v1.0.1

2 parents 802eb7d4 1f07588e
......@@ -139,13 +139,7 @@ export default {
popKey: 'employeeBoxVisible'
}
],
customerInfo: {
customerName: '',
carModel: '',
phoneNumber: '',
salesUuid: '',
staffName: ''
}
customerInfo: this.$store.state.user.customerInfo
}
},
mounted () {
......
......@@ -60,7 +60,7 @@
<media_6 :views="media[id]" />
</view>
<pay-pop ref="pay"></pay-pop>
<template v-if="type != 'preview'">
<template v-if="type != 'preview'">
<view
class="pen-box"
@click="drawStatus = !drawStatus"
......@@ -150,6 +150,7 @@ export default {
},
// 完成接待
done () {
this.$store.dispatch('clearCustomerInfo')
this.stopAudio();
uni.navigateBack();
},
......
......@@ -60,7 +60,7 @@
<template v-for="(i, index) in formObject">
<view class="form-item" :key="index">
<view class="label">{{ i.label }}</view>
<view class="value">
<view :class="['value', { error: i.error }]">
<template v-if="i.type == 'input'">
<input
:type="i.inputType"
......@@ -260,6 +260,15 @@ export default {
console.log(this.formData);
this.messageBoxVisible = false;
this.stopAudio(this.infoList);
// this.messageBoxVisible = false;
try {
for (let i in this.formData) {
if (!this.formData[i]) throw i;
}
} catch (error) {
this.formData[i].error = true;
}
this.stopAudio();
},
// 选择车型与销售
showPop(key) {
......
......@@ -3,14 +3,20 @@
* @Author: huyue
* @Date: 2024-04-07 18:15:11
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-04-09 19:23:10
* @LastEditTime: 2024-04-09 19:49:48
*/
// import { setToken, getToken, removeToken } from '@/utils/token';;
export default {
state() {
return {
customerInfo: {},
customerInfo: {
customerName: "",
carModel: "",
phoneNumber: "",
salesUuid: "",
staffName: "",
},
};
},
mutations: {
......@@ -20,14 +26,26 @@ export default {
setCustomerInfo(state, data) {
state.customerInfo = data;
},
clearCustomerInfo(state) {
state.customerInfo = {
customerName: "",
carModel: "",
phoneNumber: "",
salesUuid: "",
staffName: "",
};
},
},
actions: {
// 获取用户详情
async getCustomerInfo({ commit }) {
return commit("getCustomerInfo");
getCustomerInfo({ state }) {
return state.customerInfo;
},
async setCustomerInfo({ commit }, value) {
setCustomerInfo({ commit }, value) {
commit("setCustomerInfo", value);
},
clearCustomerInfo({ commit }) {
commit("clearCustomerInfo");
},
},
};
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!