import urlAlias from '../url'; import request from '../request'; const { mylovelist } = urlAlias; const state = { loveList: [], }; const mutations = { INIT: (state, data) => { state.loveList = data; }, }; const actions = { getLoveList({ commit }, param) { request({ url: mylovelist, data: param, success: (res) => { // console.log(res.data); commit("INIT", res.data.data); }, }) } } export default { namespaced: true, state, mutations, actions, }