PAMapp/shared/services/appointment.service.ts
@@ -16,8 +16,17 @@ } // 顧問瀏覽自己所有的預約單紀錄觸發API private viewAllAppointment(): void { http.post('/consultant/record/allAppointmentsView').then(); private async viewAllAppointment(): Promise<void> { try { const response = await http.post('/consultant/record/allAppointmentsView'); if (response !== null) { } else { throw new Error('http.post returned null-like value.'); } } catch (error) { console.error('An error occurred while viewing all appointments:', error); throw error; } } // 讀取預約單時觸發,紀錄讀取預約單時間