nocobase/packages/database/examples/tables/bar.js

27 lines
367 B
JavaScript
Raw Normal View History

2020-10-24 07:34:43 +00:00
module.exports = {
name: 'bar',
fields: [
{
type: 'string',
name: 'title',
},
{
type: 'text',
length: 'long',
name: 'content',
},
{
type: 'belongsTo',
name: 'user',
},
{
type: 'belongsToMany',
name: 'tags',
},
{
type: 'hasMany',
name: 'comments'
},
],
};