feat(birthday): filter featured packages on homepage, add payment link label
This commit is contained in:
parent
a58ce75f66
commit
96c08391e1
2 changed files with 5 additions and 4 deletions
|
|
@ -27,10 +27,10 @@ export const BirthdayPackages: CollectionConfig = {
|
|||
type: 'array',
|
||||
fields: [{ name: 'text', type: 'text', required: true }],
|
||||
},
|
||||
{ name: 'featured', type: 'checkbox', defaultValue: false },
|
||||
{ name: 'badge', type: 'text' },
|
||||
{ name: 'ctaLabel', type: 'text', defaultValue: 'Обрати пакет' },
|
||||
{ name: 'ctaHref', type: 'text' },
|
||||
{ name: 'featured', type: 'checkbox', label: 'Показувати на головній', defaultValue: false },
|
||||
{ name: 'badge', type: 'text', label: 'Бейдж (напр. "Найпопулярніший")' },
|
||||
{ name: 'ctaLabel', type: 'text', label: 'Текст кнопки', defaultValue: 'Обрати пакет' },
|
||||
{ name: 'ctaHref', type: 'text', label: 'Посилання на оплату' },
|
||||
{ name: 'sort', type: 'number', defaultValue: 0 },
|
||||
],
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ export const getHomeData = cache(async (): Promise<HomeData> => {
|
|||
}),
|
||||
payload.find({
|
||||
collection: 'birthday-packages',
|
||||
where: { featured: { equals: true } },
|
||||
sort: 'sort',
|
||||
limit: 10,
|
||||
overrideAccess: true,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue