feat: setup globals (Footer), sqlite migration, seed update and access rules
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { postgresAdapter } from '@payloadcms/db-postgres'
|
||||
import { sqliteAdapter } from '@payloadcms/db-sqlite'
|
||||
import { mcpPlugin } from '@payloadcms/plugin-mcp'
|
||||
import { ipalKit } from '@intecion/ipal-kit'
|
||||
import { lexicalEditor } from '@payloadcms/richtext-lexical'
|
||||
@@ -11,6 +11,8 @@ import { Users } from './collections/Users'
|
||||
import { Media } from './collections/Media'
|
||||
import { Pages } from './collections/Pages'
|
||||
import { Company } from './globals/Company'
|
||||
import { Header } from './globals/Header'
|
||||
import { Footer } from './globals/Footer'
|
||||
import { i18n } from './i18n.config'
|
||||
|
||||
const filename = fileURLToPath(import.meta.url)
|
||||
@@ -24,15 +26,15 @@ export default buildConfig({
|
||||
},
|
||||
},
|
||||
collections: [Users, Media, Pages],
|
||||
globals: [Company],
|
||||
globals: [Company, Header, Footer],
|
||||
editor: lexicalEditor(),
|
||||
secret: process.env.PAYLOAD_SECRET || '',
|
||||
typescript: {
|
||||
outputFile: path.resolve(dirname, 'payload-types.ts'),
|
||||
},
|
||||
db: postgresAdapter({
|
||||
pool: {
|
||||
connectionString: process.env.DATABASE_URL || '',
|
||||
db: sqliteAdapter({
|
||||
client: {
|
||||
url: process.env.DATABASE_URI || '',
|
||||
},
|
||||
}),
|
||||
sharp,
|
||||
@@ -41,5 +43,5 @@ export default buildConfig({
|
||||
fallback: true,
|
||||
defaultLocale: i18n.defaultLocale,
|
||||
},
|
||||
plugins: [mcpPlugin({}), ipalKit({ i18n })],
|
||||
plugins: [mcpPlugin({}), ipalKit({ i18n, pages: { slug: 'pages' } })],
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user