mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-18 07:16:46 +08:00
讲师管理
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
:pagination="false"
|
||||
:scroll="{ x: 'max-content' }"
|
||||
row-key="id"
|
||||
:loading="loading"
|
||||
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
|
||||
>
|
||||
<template #action="{ record }">
|
||||
@@ -59,17 +60,21 @@ const props = defineProps({
|
||||
});
|
||||
watch(()=>props.visible,(val)=>{
|
||||
if(val){
|
||||
loading.value = true
|
||||
api.getListByStatus().then(res=>{
|
||||
if(res.data.code == 200 ){
|
||||
tableData.value = res.data.data
|
||||
}else{
|
||||
message.error(res.data.msg)
|
||||
}
|
||||
loading.value = false
|
||||
}).catch(err=>{
|
||||
message.error(err.data.msg)
|
||||
loading.value = false
|
||||
})
|
||||
}
|
||||
})
|
||||
const loading = ref(false)
|
||||
const selectedRowKeys = ref([])
|
||||
const selectsData = ref([]);
|
||||
const onSelectChange = (e, l) => {
|
||||
@@ -203,6 +208,10 @@ const closeDrawer = () => {
|
||||
selectsData.value = []
|
||||
}
|
||||
const queryDrawer = () => {
|
||||
if(!selectedRowKeys.value.length){
|
||||
message.error('请选择需要审批的数据')
|
||||
return
|
||||
}
|
||||
emit("selectedRowKeys", selectedRowKeys.value)
|
||||
closeDrawer()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user