chore: adds users collection
This commit is contained in:
7
test/_community/collections/Users/index.ts
Normal file
7
test/_community/collections/Users/index.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import type { CollectionConfig } from 'payload'
|
||||
|
||||
export const UsersCollection: CollectionConfig = {
|
||||
slug: 'users',
|
||||
auth: true,
|
||||
fields: [],
|
||||
}
|
||||
@@ -6,13 +6,16 @@ import { buildConfigWithDefaults } from '../buildConfigWithDefaults.js'
|
||||
import { devUser } from '../credentials.js'
|
||||
import { MediaCollection } from './collections/Media/index.js'
|
||||
import { PostsCollection, postsSlug } from './collections/Posts/index.js'
|
||||
import { UsersCollection } from './collections/Users/index.js'
|
||||
import { MenuGlobal } from './globals/Menu/index.js'
|
||||
|
||||
const filename = fileURLToPath(import.meta.url)
|
||||
const dirname = path.dirname(filename)
|
||||
|
||||
export default buildConfigWithDefaults({
|
||||
// ...extend config here
|
||||
collections: [
|
||||
UsersCollection,
|
||||
PostsCollection,
|
||||
{
|
||||
slug: 'simple',
|
||||
@@ -26,6 +29,7 @@ export default buildConfigWithDefaults({
|
||||
MediaCollection,
|
||||
],
|
||||
admin: {
|
||||
user: 'users',
|
||||
importMap: {
|
||||
baseDir: path.resolve(dirname),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user