xlb-main-login
Version:
``` yarn install ```
328 lines (318 loc) • 8.39 kB
JavaScript
import * as types from './mutation-types'
import { UPDATE_TOGGLE_VERSION } from './mutation-types'
const mutations = {
[types.SET_REG](state, id) {
state.register = id
},
[types.SET_TOKEN](state, token) {
state.token = token
},
[types.SET_NEWPEO](state, newpeo) {
state.newpeo = newpeo
},
[types.SET_MENUTYPE](state, menuType) {
state.menuType = menuType
},
[types.SETHasSwitchPermission](state, hasSwitchPermission) {
state.hasSwitchPermission = hasSwitchPermission
},
[types.UPDATE_TOGGLE_VERSION](state, toggleVersion) {
state.toggleVersion = toggleVersion
},
[types.SET_NAME](state, name) {
state.name = name
},
[types.SET_MENU](state, menu) {
state.menu = menu
},
[types.SET_FLAG](state, flag) {
state.flag = flag
},
[types.SET_Weinickname](state, weinickname) {
state.weinickname = weinickname
},
[types.SET_Weinickhead](state, weiheadimg) {
state.weiheadimg = weiheadimg
},
[types.SET_DisMoney](state, disearmoney) {
state.disearmoney = disearmoney
},
[types.SET_Discid](state, discid) {
state.discid = discid
},
[types.SET_CONVERLIST](state, converlist) {
state.converlist = converlist
},
[types.SET_CONVERNAMW](state, convertitle) {
state.convertitle = convertitle
},
[types.SET_FORMLIST](state, formlist) {
state.formlist = formlist
},
[types.SET_Disnum](state, disnum) {
state.disnum = disnum
},
[types.SET_Disleft](state, disleft) {
state.disleft = disleft
},
[types.SET_Replyid](state, weireplyid) {
state.weireplyid = weireplyid
},
[types.SET_Weisid](state, weisid) {
state.weisid = weisid
},
[types.SET_Homnum](state, hommun) {
state.hommun = hommun
},
[types.SET_Homleft](state, homleft) {
state.homleft = homleft
},
[types.SET_STAFF](state, workstaff) {
state.workstaff = workstaff
},
[types.SET_GROUP](state, workgroup) {
state.workgroup = workgroup
},
[types.SET_Weinum](state, weimun) {
state.weimun = weimun
},
[types.SET_Weileft](state, weileft) {
state.weileft = weileft
},
[types.SET_Comnum](state, commun) {
state.commun = commun
},
[types.SET_Comleft](state, comleft) {
state.comleft = comleft
},
[types.SET_Pernum](state, permun) {
state.permun = permun
},
[types.SET_Perleft](state, perleft) {
state.perleft = perleft
},
[types.SET_Weinickname](state, weinickname) {
state.weinickname = weinickname
},
[types.SET_FREE](state, free) {
state.free = free
},
[types.SET_GONG](state, gong) {
state.gong = gong
},
[types.SET_KEFU](state, kefu) {
state.kefu = kefu
},
[types.ChoseShowTag](state, showtag) {
state.showtag = showtag
},
[types.NoChoseShowTag](state, noshowtag) {
state.noshowtag = noshowtag
},
[types.SET_MOBAN](state, moban) {
state.moban = moban
},
[types.SET_FENX](state, fenx) {
state.fenx = fenx
},
[types.SET_ZHU](state, zhuce) {
state.zhuce = zhuce
},
// 推广方式3 - 一键群发跳转时保存的参数
[types.SET_CUSTOMERSEND](state, customerSend) {
state.customerSend = customerSend
},
[types.SET_LEFT_TOKEN](state, left_token) {
state.left_token = left_token
},
[types.SET_USER_LINK](state, user_link) {
state.user_link = user_link
},
[types.SET_WEITYPE](state, weitype) {
state.weitype = weitype
},
[types.SET_APPID](state, appid) {
state.appid = appid
},
[types.SET_SELLER](state, seller) {
state.seller = seller
},
[types.StartNum](state, startnum) {
state.startnum = startnum
},
[types.EndNum](state, endnum) {
state.endnum = endnum
},
[types.SET_NEWTENG](state, newteng) {
state.newteng = newteng
},
[types.SET_singleChatRecordArchiving](state, singleChatRecordArchiving) {
state.singleChatRecordArchiving = singleChatRecordArchiving
},
[types.SET_BRAND_INFO](state,BrandInfo) {
state.BrandInfo = BrandInfo
},
[types.wxworkList](state, workchat) {
state.workchat = workchat
},
State(state, content) {
state._state = content
},
stepOnedata(state, onedata) {
state.onedata = onedata
},
stepTwodata(state, twodata) {
state.twodata = twodata
},
stepThreedata(state, threedata) {
state.threedata = threedata
},
stepFourdata(state, fourdata) {
state.fourdata = fourdata
},
stepFivedata(state, fivedata) {
state.fivedata = fivedata
},
activity(state, activitydata) {
state.activitydata = activitydata
},
Deposit(state, num) {
state.deposit = num
},
groupOnedata(state, onedata) {
state.groupOne = onedata
},
groupTwodata(state, twodata) {
state.groupTwo = twodata
},
groupThreedata(state, threedata) {
state.groupThree = threedata
},
groupFourdata(state, fourdata) {
state.groupFour = fourdata
},
groupFivedata(state, fivedata) {
state.groupFive = fivedata
},
GropState(state, content) {
state._groupState = content
},
Gropdata(state, data) {
state.gropdata = data
},
Sharedata(state, data) {
state.shareData = data
},
Sharestate(state, data) {
state.shareState = data
},
/*企业微信*/
wxstepOnedata(state, wxonedata) {
state.wxonedata = wxonedata
},
wxstepOneredpack(state, wxredpack) {
state.wxredpack = wxredpack
},
verify(state, content) {
state.content = content
},
setemploy(state, getemploy) {
state.getemploy = getemploy
},
setwechatlist(state, getwechatlist) {
state.getwechatlist = getwechatlist
},
wechatInformation(state, data) {
state.wechatInformation = data
},
wechatsysid(state, data) {
state.wechatsysid = data
},
dimensional(state, data) {
state.dimensional = data // 支付接口
},
chanel_msg(state, data) {
state.chanel_msg = data // 支付接口
},
chanel_success(state, data) {
state.chanel_success = data // 支付接口
},
checkAppId(state, data) {
state.checkAppId = data // 支付接口
},
// 全局loading 开关
wxSpinning(state, data) {
state.wxSpinning = data
},
nowFullPathDetailName(state, data) {
state.nowFullPathDetailName = data
},
fullPathDetailName(state, data) {
state.fullPathDetailName = data
},
fullPathDetailPath(state, data) {
state.fullPathDetailPath = data
},
showPageList(state, data) {
state.showPageList = data
},
setOptions(state, options) {
state.options = {
...state.options,
...options,
}
},
setSettings(state, settings) {
state.settings = {
...state.settings,
...settings,
}
},
setElements(state, elements) {
state.elements = [...elements]
},
setSelectedElementId(state, id) {
state.selectedElementId = id
},
addElement(state, element) {
state.elements = [...state.elements, element]
},
deleteElement(state, index) {
if (index >= state.elements.length || index < 0) {
throw Error('index out of bounds')
} else {
const auxiliary = [...state.elements]
auxiliary.splice(index, 1)
state.elements = [...auxiliary]
}
},
updateElement(state, { index, element }) {
if (index >= state.elements.length || index < 0) {
throw Error('index out of bounds')
} else {
const newElement = {
...state.elements[index],
...element,
}
const auxiliary = [...state.elements]
auxiliary.splice(index, 1, newElement)
state.elements = auxiliary
}
},
moveElement(state, { fromIndex, toIndex }) {
if (fromIndex < 0 || toIndex < 0 || fromIndex >= state.elements.length || toIndex >= state.elements.length) {
throw Error('index out of bounds')
} else if (fromIndex === toIndex) {
return
}
const auxiliary = [...state.elements]
const [slicedElement] = auxiliary.splice(fromIndex, 1)
auxiliary.splice(toIndex, 0, slicedElement)
state.elements = auxiliary
},
//0元解锁关联h5活动列表
activityList(state, data) {
state.activityList = data
},
}
export default mutations