|
@ -229,6 +229,10 @@ const getSelectionRows = (currentPage,currentPageSelectionRows) => { |
|
|
const readHandle = (row,isAll)=>{ |
|
|
const readHandle = (row,isAll)=>{ |
|
|
let rows:any = [] |
|
|
let rows:any = [] |
|
|
if(isAll){ |
|
|
if(isAll){ |
|
|
|
|
|
//全部已读 |
|
|
|
|
|
if(selectionRows.value==0){ |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
selectionRows.value.forEach(item=>{ |
|
|
selectionRows.value.forEach(item=>{ |
|
|
let itemSelectionRows = item.selectionRows.filter(item1=>item1.isRead==0) |
|
|
let itemSelectionRows = item.selectionRows.filter(item1=>item1.isRead==0) |
|
|
console.log('itemSelectionRows',itemSelectionRows) |
|
|
console.log('itemSelectionRows',itemSelectionRows) |
|
@ -237,17 +241,19 @@ const readHandle = (row,isAll)=>{ |
|
|
console.log('selectionRows',selectionRows) |
|
|
console.log('selectionRows',selectionRows) |
|
|
console.log('全部已读',rows.join(',')) |
|
|
console.log('全部已读',rows.join(',')) |
|
|
}else{ |
|
|
}else{ |
|
|
|
|
|
//单行 |
|
|
|
|
|
if(row.isRead==1){ |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
rows = [row.mainId] |
|
|
rows = [row.mainId] |
|
|
console.log('已读',rows.join(',')) |
|
|
console.log('已读',rows.join(',')) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
let getLoading = ElLoading.service({ |
|
|
let getLoading = ElLoading.service({ |
|
|
lock: true, |
|
|
lock: true, |
|
|
text: 'loading...', |
|
|
text: 'loading...', |
|
|
background: 'rgba(0, 0, 0, 0.7)' |
|
|
background: 'rgba(0, 0, 0, 0.7)' |
|
|
}) |
|
|
}) |
|
|
if(selectionRows.value==0){ |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
DemandforecastingMainApi.updateIsRead({isReadMainIds:rows.join(',')}).then(res => { |
|
|
DemandforecastingMainApi.updateIsRead({isReadMainIds:rows.join(',')}).then(res => { |
|
|
console.log('res',res); |
|
|
console.log('res',res); |
|
|
getLoading?.close() |
|
|
getLoading?.close() |
|
|