Initial release of Moniki paid services site and CMS (v1.0.0).
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
import type { CollectionConfig } from 'payload'
|
||||
import { ADMIN_GROUP } from '../admin/groups'
|
||||
|
||||
export const Gallery: CollectionConfig = {
|
||||
slug: 'gallery',
|
||||
labels: { singular: 'Фото', plural: 'Галерея' },
|
||||
admin: { group: ADMIN_GROUP.content, useAsTitle: 'title' },
|
||||
access: { read: () => true },
|
||||
fields: [
|
||||
{ name: 'title', type: 'text', required: true, localized: true },
|
||||
{ name: 'image', type: 'upload', relationTo: 'media', required: true },
|
||||
{
|
||||
name: 'category',
|
||||
type: 'select',
|
||||
options: [
|
||||
{ label: 'Клиника', value: 'clinic' },
|
||||
{ label: 'Оборудование', value: 'equipment' },
|
||||
{ label: 'События', value: 'events' },
|
||||
],
|
||||
defaultValue: 'clinic',
|
||||
},
|
||||
{ name: 'branch', type: 'relationship', relationTo: 'branches' },
|
||||
{ name: 'sortOrder', type: 'number', defaultValue: 0 },
|
||||
],
|
||||
}
|
||||
Reference in New Issue
Block a user