store.state多值怎么获取?
粉丝福利 : 关注VUE中文社区公众号,回复视频领取粉丝福利
现在我想获取/depgroup/list的列表信息 goroupData:[] 要这么改啊 export default { name: ‘userprofileadd’, data() { return { depData: [], goroupData:[]
}
},
created: function () {
this.$store.commit("setNav", "添加新用户");
let self = this;
fetch(self.$store.state.apiBase + '/department/list')
.then(response => response.json())
.then(data => self.depData = data.list)
},