update notifications,
This commit is contained in:
11
002_source/cms/src/db/Notifications/Update.tsx
Normal file
11
002_source/cms/src/db/Notifications/Update.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
// api method for update notification record
|
||||
// RULES:
|
||||
// TBA
|
||||
import { pb } from '@/lib/pb';
|
||||
import { COL_NOTIFICATIONS } from '@/constants';
|
||||
import type { RecordModel } from 'pocketbase';
|
||||
import type { NotificationFormProps } from '@/components/dashboard/notification/type.d';
|
||||
|
||||
export async function updateNotification(id: string, data: Partial<NotificationFormProps>): Promise<RecordModel> {
|
||||
return pb.collection(COL_NOTIFICATIONS).update(id, data);
|
||||
}
|
Reference in New Issue
Block a user