import { httpGetInterceptor, httpPostInterceptor, } from "../http-config/http-interceptor-service"; import { httpGet } from "../http-config/http-base-service"; import { any } from "zod"; export async function paginationSchedule( size: number, page: number, type: any, title: string = "" ) { return await httpGetInterceptor( `schedule/pagination?enablePage=1&scheduleTypeId=${type}&page=${page}&size=${size}&title=${title}` ); } export async function postSchedule(data: any) { const url = "schedule"; return httpPostInterceptor(url, data); } export async function detailSchedule(id: any) { const url = `public/schedule?id=${id}`; return httpGetInterceptor(url); } export async function listScheduleTodayPublic(group = null) { const url = `public/schedule/today?group=${group}`; return httpGet(url, null); } export async function listScheduleNextPublic(group = null) { const url = `public/schedule/next-activity?group=${group}`; return httpGet(url, null); } export async function listSchedulePrevPublic(group = null) { const url = `public/schedule/prev-activity?group=${group}`; return httpGet(url, null); } export async function listSchedule(group = null) { const url = `public/schedule/list?group=${group}`; return httpGet(url, null); } export async function searchSchedules(search = null) { const url = `public/schedule/list?search=${search}`; return httpGet(url, null); } export async function listScheduleToday() { const url = "schedule/today"; return httpGetInterceptor(url); } export async function getListScheduleAttachment(scheduleId: any) { const url = `media/list?&enablePage=0&scheduleId=${scheduleId}`; return httpGetInterceptor(url); } export async function listScheduleNext() { const url = "schedule/next-activity"; return httpGetInterceptor(url); }