You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
592 B

import {Field} from '../../../orm/src/model/Field.ts'
import {Type} from '../../../orm/src/db/types.ts'
import {SessionModel} from '../../../lib/src/module.ts'
export default class Session extends SessionModel {
protected static table = 'sessions'
protected static key = 'session_key'
protected static readonly CREATED_AT = 'start_time'
protected static readonly UPDATED_AT = null // No updated at
@Field(Type.varchar)
protected session_key!: string
@Field(Type.int)
protected user_id?: number
@Field(Type.timestamp)
protected start_time!: Date
}