| | |
| | | label="操作" |
| | | align="center" |
| | | width="120" |
| | | fixed="right" |
| | | class-name="small-padding fixed-width" |
| | | > |
| | | <template slot-scope="scope"> |
| | |
| | | if (Array.isArray(response.data)) { |
| | | // 如果返回的是数组 |
| | | this.confirmationList = response.data; |
| | | this.total = response.data.length; |
| | | this.total = response.total; |
| | | } else if (response.data.rows) { |
| | | // 如果返回的是分页数据结构 |
| | | this.confirmationList = response.data.rows; |
| | | this.total = response.data.total; |
| | | this.total = response.total; |
| | | } else if (Array.isArray(response.data.list)) { |
| | | // 如果返回的是list字段 |
| | | this.confirmationList = response.data.list; |
| | | this.total = response.data.total || response.data.list.length; |
| | | this.total = response.total; |
| | | } else { |
| | | // 其他数据结构,尝试直接使用data |
| | | this.confirmationList = response.data; |