fix: 班级学生列表搜索时刷新合并申请状态,可直接应用和退回操作

This commit is contained in:
TsMask
2024-07-22 11:45:15 +08:00
parent f977b6ea53
commit b2510c0eb3
2 changed files with 55 additions and 16 deletions

View File

@@ -21,7 +21,7 @@ import useConfigArray from './hooks/useConfigArray';
import useConfigArrayChild from './hooks/useConfigArrayChild';
import { getAllNeConfig } from '@/api/ne/neConfig';
import { getPtNeConfigData } from '@/api/pt/neConfig';
import { hasRoles } from '@/plugins/auth-user';
import { isSystemAdmin, hasRoles } from '@/plugins/auth-user';
const neInfoStore = useNeInfoStore();
const { t } = useI18n();
const { ruleVerification, getConfigSMFByUPFIds, SMFByUPFIdOptions } =
@@ -343,6 +343,7 @@ const {
classState,
studentStatus,
studentSearch,
studentChange,
} = usePtOptions({ t, fnActiveConfigNode });
const { tablePagination, listState, listEdit, listEditClose, listEditOk } =
@@ -438,6 +439,7 @@ onMounted(() => {
<template>
<PageContainer>
<a-card
v-if="!isSystemAdmin()"
:bordered="false"
:body-style="{ marginBottom: '24px', paddingBottom: 0 }"
>
@@ -455,7 +457,7 @@ onMounted(() => {
:not-found-content="null"
:options="classState.studentOptions"
@search="studentSearch"
@change="fnActiveConfigNode('#')"
@change="studentChange"
>
<template #option="{ value, label, applyStatus }">
<span>{{ label }} </span>
@@ -681,7 +683,12 @@ onMounted(() => {
v-model:value="listState.editRecord['value']"
:disabled="listState.confirmLoading"
></a-input>
<a-space :size="16" align="center" direction="horizontal">
<a-space
:size="8"
align="center"
direction="horizontal"
style="margin-left: 18px"
>
<a-tooltip placement="bottomRight">
<template #title> {{ t('common.ok') }} </template>
<a-popconfirm
@@ -700,26 +707,32 @@ onMounted(() => {
class="editable-cell__icon-edit"
:disabled="listState.confirmLoading"
>
<template #icon><CheckOutlined /></template>
<template #icon>
<CheckOutlined style="color: #52c41a" />
</template>
</a-button>
</a-popconfirm>
</a-tooltip>
<a-tooltip placement="bottomRight">
<template #title>
{{ t('common.cancel') }}
</template>
<template #title> {{ t('common.cancel') }} </template>
<a-button
type="text"
class="editable-cell__icon-edit"
:disabled="listState.confirmLoading"
@click.prevent="listEditClose()"
>
<template #icon><CloseOutlined /></template>
<template #icon>
<CloseOutlined style="color: #eb2f96" />
</template>
</a-button>
</a-tooltip>
</a-space>
</div>
<div v-else class="editable-cell__text-wrapper">
<div
v-else
class="editable-cell__text-wrapper"
@dblclick="listEdit(record)"
>
<template v-if="record['type'] === 'enum'">
{{ JSON.parse(record['filter'])[text] }}
</template>
@@ -727,6 +740,7 @@ onMounted(() => {
<EditOutlined
class="editable-cell__icon"
@click="listEdit(record)"
style="margin-left: 18px"
v-if="
!['read-only', 'read', 'ro'].includes(
record.access