Commit dc82b26f by 赖慧粮

feat(state): 状态数据出发错误修复

parent d9081658
/* eslint-disable no-param-reassign */ /* eslint-disable no-param-reassign */
import { getLotteryInfos, getLotterySessionList } from '@/api/modules/lottery' import { getLotteryInfos, getLotterySessionList } from '@/api/modules/lottery'
import { Toast } from 'vant' import { Toast } from 'vant'
import { cloneDeep } from 'lodash' // import { cloneDeep } from 'lodash'
export const state = () => ({ export const state = () => ({
sessionList: [], // 抽奖场次列表 sessionList: [], // 抽奖场次列表
...@@ -71,8 +71,8 @@ export const actions = { ...@@ -71,8 +71,8 @@ export const actions = {
}) })
}, },
updateInfo({ state }, val) { updateInfo({ state }, val) {
const lotteryInfo = cloneDeep(state.lotteryInfo) // const lotteryInfo = cloneDeep(state.lotteryInfo)
state.lotteryInfo = { ...lotteryInfo, ...val } state.lotteryInfo = { ...state.lotteryInfo, ...val }
}, },
} }
export const getters = { export const getters = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment