This repository has been archived on 2024-12-15. You can view files and clone it, but cannot push or open issues or pull requests.
seepur/database/migrations/1503248427885_user.js
Sagi Dayan d7c9359ef2 Basic logic
- DB migrations
 - Login/Register flows
 - Dockerfile
 - Layouts, Partials, Components
 - Sass
 - Bulma.io
 - sqlite
2020-01-18 15:46:06 -05:00

23 lines
485 B
JavaScript

'use strict'
/** @type {import('@adonisjs/lucid/src/Schema')} */
const Schema = use('Schema')
class UserSchema extends Schema {
up () {
this.create('users', (table) => {
table.increments()
table.string('email', 254).notNullable().unique()
table.string('name').notNullable()
table.string('password', 60).notNullable()
table.string('avatar')
table.timestamps()
})
}
down () {
this.drop('users')
}
}
module.exports = UserSchema