d2-crud-plus
d2-crud-plus copied to clipboard
报错 data is undefined
你好我是刚开始用 d2-curd-plus 使用的真实接口后,浏览器报错 data is undefined 能请求到后端的数据 不知道为什么表格不显示数据
先看文档: https://greper.gitee.io/d2-crud-plus/guide/structure.html
我调了返回格式,还是不行
https://greper.gitee.io/d2-crud-plus/guide/quickstart.html#_4-%E4%BF%AE%E6%94%B9http%E5%93%8D%E5%BA%94%E6%8B%A6%E6%88%AA%E7%9A%84%E8%BF%94%E5%9B%9E%E7%BB%93%E6%9E%9C
看这一章节:修改http响应拦截的返回结果
调整了后端返回得数据结构,
现在报错 ret is undefined
#浏览器错误
main中代码
请求代码
返回的数据格式
我添加了return
现在浏览器报[Vue warn]: Invalid prop: type check failed for prop "data". Expected Array, got Undefined
这是我得mian.js
这是浏览器控制台
你页面代码怎么写的?
我的前端框架是dvadmin,
这是index.vue
这是crud.js
api.js 用的原生axios
返回的数据结构
搞忘记了,还需要帮你看吗?你可以加我好友