Compare commits

..

No commits in common. "471d73a224cf62dae02e8c93f4d48894b16497b2" and "d4b1e547def236f58cbbe7dbffdb27a17068d9a4" have entirely different histories.

1 changed files with 21 additions and 35 deletions

View File

@ -27,35 +27,24 @@
</div>
</div>
<div class="class-reserv-body">
<!-- loading <el-skeleton :rows="5" animated />-->
<el-skeleton :rows="5" :loading="loading" animated />
<div v-if="classWorkList.length > 0">
<task-item
v-for="(item, index) in activeDataList"
v-show="tabActive === '进行中'"
:key="index"
:item="item"
:tabactive="tabActive"
@click="onClickItem(item)"
@delete-reserv="deleteReserv(item)"
></task-item>
<task-item
v-for="(item, index) in doneDataList"
v-show="tabActive === '已结束'"
:key="index"
:item="item"
:tabactive="tabActive"
@click="onClickItem(item)"
@delete-reserv="deleteReserv(item)"
></task-item>
</div>
<div v-else>
<el-empty
v-show="classWorkList.length == 0 && !loading"
:description="'暂无'+tabActive+'作业数据'"
style="width: 100%; height: 400px"
></el-empty>
</div>
<task-item
v-for="(item, index) in activeDataList"
v-show="tabActive === '进行中'"
:key="index"
:item="item"
:tabactive="tabActive"
@click="onClickItem(item)"
@delete-reserv="deleteReserv(item)"
></task-item>
<task-item
v-for="(item, index) in doneDataList"
v-show="tabActive === '已结束'"
:key="index"
:item="item"
:tabactive="tabActive"
@click="onClickItem(item)"
@delete-reserv="deleteReserv(item)"
></task-item>
</div>
<item-dialog ref="itemDialogRef" @cle-click="closeDialog"></item-dialog>
</el-container>
@ -110,8 +99,6 @@ const changeEndDate = (val) => {
//
const getData = () => {
classWorkList.value = []
loading.value = true
// 1
getClassList()
// 2
@ -194,9 +181,6 @@ const getClassWorkList = () => {
classWorkList.value = response.rows && response.rows.filter((item) => item.workdatacount > 0)
//TODO total
total.value = response.total
}else{
classWorkList.value = []
total.value = 0
}
loading.value = false
})
@ -418,7 +402,9 @@ watch(
)
watch(tabActive, (newVal,oldVal)=>{
console.log('newVal',newVal);
getData() //
setTimeout(() => {
getData() //
}, 300)
})
</script>