Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Author table
- Author:
- columns:
- id:
- type: integer(11)
- notnull: true
- autoincrement: true
- primary: true
- firstname:
- type: string(30)
- notnull: false
- lastname:
- type: string(30)
- notnull: false
- username:
- type: string(20)
- notnull: true
- password:
- type: string(32)
- notnull: true
- signature:
- type: string(255)
- notnull: true
- relations:
- Entries:
- class: Entry
- refClass: AuthorEntry
- local: author_id
- foreign: entry_id
- // Entry table
- Entry:
- actAs: [Timestampable]
- columns:
- id:
- type: integer(11)
- notnull: true
- autoincrement: true
- primary: true
- title:
- type: string(255)
- notnull: true
- content:
- type: string
- notnull: true
- is_published:
- type: boolean
- notnull: true
- default: 0
- image:
- type: string(255)
- relations:
- Authors:
- class: Author
- refClass: AuthorEntry
- local: entry_id
- foreign: author_id
- // Author/Entry Linking table
- AuthorEntry:
- columns:
- author_id:
- type: integer
- entry_id:
- type: integer
- relations:
- Entry:
- local: entry_id
- foreign: id
- type: one
- foreignType: many
- Author:
- local: author_id
- foreign: id
- type: one
- foreignType: many
Add Comment
Please, Sign In to add comment