Files
anouma/lib/payload/globals.ts
T
maro 45261a0461 Initial commit: ANOUMA website with Payload CMS, WebRTC meetings, and booking system
- Next.js 16 App Router site with the ANOUMA design system
- Payload CMS (PostgreSQL) for offers, events, posts and page content
- WebRTC video-call system with custom signaling server
- SMTP email reminders and booking-request notifications
- Customer accounts, calendar-based availability, and booking workflow
2026-08-25 16:40:51 +02:00

34 lines
1.1 KiB
TypeScript

import { cache } from "react";
import { getCMS } from "@/lib/payload/getPayload";
import type { About, AktuellesIntro, AngeboteIntro, Booking, Contact, Home } from "@/payload-types";
export const getHomeGlobal = cache(async (): Promise<Home> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "home" });
});
export const getAboutGlobal = cache(async (): Promise<About> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "about" });
});
export const getAngeboteIntroGlobal = cache(async (): Promise<AngeboteIntro> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "angebote-intro" });
});
export const getAktuellesIntroGlobal = cache(async (): Promise<AktuellesIntro> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "aktuelles-intro" });
});
export const getContactGlobal = cache(async (): Promise<Contact> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "contact" });
});
export const getBookingGlobal = cache(async (): Promise<Booking> => {
const payload = await getCMS();
return payload.findGlobal({ slug: "booking" });
});