mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-12 12:26:47 +08:00
--fix 添加归属权
This commit is contained in:
@@ -27,7 +27,7 @@
|
||||
<a-form-item title="姓名:">
|
||||
<a-input
|
||||
class="cus-input"
|
||||
v-model:value="searchParams.studentName"
|
||||
v-model:value="searchName"
|
||||
placeholder="请输入姓名"
|
||||
/>
|
||||
</a-form-item>
|
||||
@@ -36,7 +36,7 @@
|
||||
<a-button
|
||||
class="cus-btn"
|
||||
style="background: #4ea6ff; color: #fff; width: 100px"
|
||||
@click="searchStu"
|
||||
@click="search"
|
||||
>
|
||||
<template #icon><img style="margin-right: 10px" src="../../assets/images/courseManage/search0.png"/>
|
||||
</template>
|
||||
@@ -104,7 +104,7 @@ const visiable = ref(false);
|
||||
|
||||
const initParams = {
|
||||
studentName: "",
|
||||
page: 1,
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
type: props.type || '',
|
||||
types: props.types,
|
||||
@@ -112,6 +112,7 @@ const initParams = {
|
||||
}
|
||||
|
||||
const searchParams = ref(initParams)
|
||||
const searchName = ref('')
|
||||
|
||||
const columns = ref([
|
||||
{
|
||||
@@ -144,7 +145,7 @@ const columns = ref([
|
||||
key: "type",
|
||||
width: 30,
|
||||
align: "center",
|
||||
customRender: ({record: {type}}) => ({4: "查看权", 5: "管理权", 6: "归属权"}[type]),
|
||||
customRender: ({record: {type}}) => ({4: "查看权", 5: "管理权", 6: "归属权",7: "查看权", 8: "管理权", 9: "归属权",10: "查看权", 11: "管理权", 12: "归属权"}[type])
|
||||
},
|
||||
{
|
||||
title: "操作",
|
||||
@@ -156,24 +157,28 @@ const columns = ref([
|
||||
},
|
||||
])
|
||||
|
||||
const {data: studentList, fetch: searchStu, total, loading} = usePage(STUDENT_LIST, searchParams.value)
|
||||
const {data: studentList, fetch: searchStu, total, loading} = usePage(STUDENT_LIST, searchParams)
|
||||
|
||||
const stuPagination = computed(() => ({
|
||||
total: total,
|
||||
total:total.value,
|
||||
showSizeChanger: false,
|
||||
current: searchParams.value.page,
|
||||
current: searchParams.value.pageNo,
|
||||
pageSize: searchParams.value.pageSize,
|
||||
onChange: changePagination,
|
||||
onChange: changePagination
|
||||
}));
|
||||
|
||||
const openDrawer = () => {
|
||||
visiable.value = true;
|
||||
};
|
||||
|
||||
const changePagination = (page) => {
|
||||
searchParams.value.page = page;
|
||||
searchStu();
|
||||
searchParams.value.pageNo = page;
|
||||
};
|
||||
|
||||
function search(){
|
||||
searchParams.value.studentName = searchName.value
|
||||
searchParams.value.pageNo = 1
|
||||
}
|
||||
function del(id) {
|
||||
Modal.confirm({
|
||||
title: () => '确定删除?',
|
||||
@@ -194,7 +199,7 @@ const closeDrawer = () => {
|
||||
|
||||
function reset(){
|
||||
searchParams.value = initParams
|
||||
searchStu()
|
||||
searchName.value=''
|
||||
}
|
||||
|
||||
watch(visiable, () => {
|
||||
|
||||
Reference in New Issue
Block a user