const doLogin = function (username, password, v, callback) {
};
doLogin(localStorage.username, localStorage.password, this, function (res, msg) { if (res) { this.$store.commit({
type: 'login',
username: res.name,
token: res.token,
});
});this.$store這里的this指向不正確怎么把外層this綁定給這個(gè)回調(diào)函
添加回答
舉報(bào)
0/150
提交
取消