feat(dashboard): add professor user selection, loading overlays on all edit/detail views, and SMS bypass management
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
<!-- /src/views/classes/ClassDetailView.vue -->
|
||||
<template>
|
||||
<div class="class-detail-view" v-if="classData">
|
||||
<div class="class-detail-view relative">
|
||||
<LoadingOverlay :loading="isFetching || !classData" message="در حال دریافت مشخصات کلاس..." />
|
||||
<div v-if="classData">
|
||||
<PageHeader :title="classData.name" :subtitle="`دوره: ${classData.course?.title || '-'}`">
|
||||
<PermissionGate permission="financial_reports:read">
|
||||
<Button
|
||||
@@ -241,6 +242,7 @@
|
||||
/>
|
||||
</template>
|
||||
</Dialog>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -256,6 +258,7 @@ import { useToast } from '@/composables/useToast';
|
||||
import { usePermission } from '@/composables/usePermission';
|
||||
import { getPayableAmount } from '@/utils/paymentAmount';
|
||||
import PageHeader from '@/components/common/PageHeader.vue';
|
||||
import LoadingOverlay from '@/components/common/LoadingOverlay.vue';
|
||||
import StatusTag from '@/components/common/StatusTag.vue';
|
||||
import TableSkeleton from '@/components/common/TableSkeleton.vue';
|
||||
import ConfirmDeleteDialog from '@/components/common/ConfirmDeleteDialog.vue';
|
||||
@@ -402,12 +405,17 @@ const removeDialogMessage = computed(() => {
|
||||
: 'آیا این دانشجو از کلاس حذف شود؟';
|
||||
});
|
||||
|
||||
const isFetching = ref(true);
|
||||
|
||||
const fetchClass = async () => {
|
||||
isFetching.value = true;
|
||||
try {
|
||||
const res = await classApi.getOne(classId);
|
||||
classData.value = res.data || res;
|
||||
} catch (err) {
|
||||
showError(err);
|
||||
} finally {
|
||||
isFetching.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user