|
@@ -628,17 +628,20 @@ export default {
|
|
|
this.indexPage.pageSize = this.pageSize
|
|
|
this.indexPage.curIndex = this.curIndex
|
|
|
const res = await bugList(this.indexPage)
|
|
|
- this.$nextTick(() => {
|
|
|
- if (res.code === 200) {
|
|
|
- const data = res.data
|
|
|
- data.map(item1 => {
|
|
|
- this.priorityLevelEnumList.map(item => {
|
|
|
- item1.priorityLevel === item.name ? item1.priorityCode = item.code : ''
|
|
|
- })
|
|
|
+ if (res.code === 200) {
|
|
|
+ const data = res.data
|
|
|
+ this.tableData = await this.setCode(data)
|
|
|
+ this.total = res.total
|
|
|
+ }
|
|
|
+ },
|
|
|
+ setCode(data) {
|
|
|
+ return new Promise((resolve, reject) => {
|
|
|
+ data.map(item1 => {
|
|
|
+ this.priorityLevelEnumList.map(item => {
|
|
|
+ item1.priorityLevel === item.name ? item1.priorityCode = item.code : ''
|
|
|
})
|
|
|
- this.tableData = data
|
|
|
- this.total = res.total
|
|
|
- }
|
|
|
+ })
|
|
|
+ resolve(data)
|
|
|
})
|
|
|
},
|
|
|
getBugSelfList(type, pageSize) {
|