Commit c641f592 by 李伟康

修复轻改领券页面监听不到输入信息

1 parent 07466c8f
......@@ -28,9 +28,15 @@ export default {
* 监听客户信息是否发生变化
* @param {object} val 监听客户信息
*/
customerInfo: {
handler(val) {
this.handler(val, this.updateCustomerInfo)
// customerInfo: {
// handler(val) {
// this.handler(val, this.updateCustomerInfo)
// },
// deep: true
// },
customerKey:{
handler() {
this.handler(this.customerInfo, this.updateCustomerInfo)
},
deep: true
},
......@@ -52,7 +58,7 @@ export default {
},
computed: {
...mapState(['user.customerInfo']),
...mapGetters(['customerInfo', 'receptionStatus', 'booksList', 'receptionTrack', 'receptionKey'])
...mapGetters(['customerInfo', 'receptionStatus', 'booksList', 'receptionTrack', 'receptionKey','customerKey'])
},
methods: {
...mapMutations('audio', ['setReceptionStatus', 'setBooks', 'setPerRecordNumber']),
......
......@@ -9,4 +9,5 @@ export default {
receptionStatus: (state) => state.audio.receptionStatus,
booksList: (state) => state.audio.booksList,
receptionKey: (state) => state.user.receptionKey,
customerKey: (state) => state.user.customerKey
};
......@@ -32,7 +32,8 @@ export default {
viewKey: Date.now(),
boutiqueCarList:[],
receptionKey:Date.now(), //接待记录埋点KEY
defaultCarId:''
defaultCarId:'',
customerKey:Date.now(), //客户信息KEY
};
},
mutations: {
......@@ -43,6 +44,7 @@ export default {
// state.customerInfo = data;
uni.$storage.set("customerInfo", JSON.stringify(data));
state.customerInfo = data
state.customerKey = Date.now()
},
clearCustomerInfo (state) {
const info = {
......@@ -56,6 +58,7 @@ export default {
};
uni.$storage.set("customerInfo", JSON.stringify(info));
state.customerInfo = info
state.customerKey = Date.now()
},
},
actions: {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!