diff --git a/src/components/classes/ClassSessionsSection.vue b/src/components/classes/ClassSessionsSection.vue index a386504..e0a9031 100644 --- a/src/components/classes/ClassSessionsSection.vue +++ b/src/components/classes/ClassSessionsSection.vue @@ -232,7 +232,7 @@
#{{ toPersianDigits(index + 1) }}
- +
@@ -261,7 +261,7 @@ label="افزودن ردیف" icon="pi pi-plus" text - @click="manualSessions.push({ date: todayJalali(), startTime: '19:00', endTime: '20:30', topic: '' })" + @click="manualSessions.push({ date: getTodayJalali(), startTime: '19:00', endTime: '20:30', topic: '' })" />
diff --git a/src/views/sessions/SessionListView.vue b/src/views/sessions/SessionListView.vue index 079efcf..d421f74 100644 --- a/src/views/sessions/SessionListView.vue +++ b/src/views/sessions/SessionListView.vue @@ -131,19 +131,6 @@ /> - -
@@ -211,7 +170,6 @@ import Column from 'primevue/column'; import Tag from 'primevue/tag'; import Select from 'primevue/select'; import Dropdown from 'primevue/select'; -import Dialog from 'primevue/dialog'; const { formatJalali, toPersianDigits } = usePersianDate(); const { showSuccess, showError } = useToast(); @@ -242,35 +200,6 @@ const selectedSession = ref(null); const bulkDeleteMode = ref(false); const isDeleting = ref(false); -const notifyDialogVisible = ref(false); -const selectedSessionForNotify = ref(null); -const notifyingSessionId = ref(null); -const isNotifying = ref(false); - -const openNotifyHoldingDialog = (session) => { - selectedSessionForNotify.value = session; - notifyDialogVisible.value = true; -}; - -const handleSendSessionHolding = async () => { - if (!selectedSessionForNotify.value) return; - const id = selectedSessionForNotify.value._id || selectedSessionForNotify.value.id; - notifyingSessionId.value = id; - isNotifying.value = true; - try { - const res = await sessionApi.notifyHolding(id); - const count = res.data?.sentCount || res.data?.totalStudents || ''; - showSuccess(`پیامک برگزاری جلسه با موفقیت به ${count ? toPersianDigits(count) + ' نفر از ' : ''}دانشجویان ارسال شد`); - notifyDialogVisible.value = false; - selectedSessionForNotify.value = null; - } catch (err) { - showError(err); - } finally { - notifyingSessionId.value = null; - isNotifying.value = false; - } -}; - const statusOptions = [ { label: 'طبق برنامه', value: 'scheduled' }, { label: 'برگزار شده', value: 'held' },