【发布时间】:2019-08-28 08:49:48
【问题描述】:
我使用 axios 从 DB 获取信息。我从数组中的服务器得到响应:
我的html标签:
js代码如下:
data() {
return {
departments: {
id: 0,
name: "name of company",
nameZod: "name of company dif"
},
};
},
created() {
axios
.get('/SomeController/Departments')
.then(response => {
this.departments = response.data;
console.log(this.departments);
})
}
我收到一个错误:无法读取未定义的属性“_wrapper”。这很奇怪,因为我在其他模块中使用了类似的代码并且它工作正常。
【问题讨论】:
-
您能否发布完整的错误消息,包括显示文件和行号的堆栈跟踪?