This repository has been archived on 2022-11-26. You can view files and clone it, but cannot push or open issues or pull requests.
IcyNet.eu/server/api/models.js

110 lines
1.9 KiB
JavaScript
Raw Normal View History

2017-08-02 21:24:01 +00:00
import {Model} from '../../scripts/load-database'
class User extends Model {
static get tableName () {
return 'users'
}
}
class External extends Model {
static get tableName () {
return 'external'
}
}
class Token extends Model {
static get tableName () {
return 'simple_token'
}
}
class OAuth2Client extends Model {
static get tableName () {
return 'oauth2_client'
}
}
class OAuth2AuthorizedClient extends Model {
static get tableName () {
return 'oauth2_client_authorization'
}
}
class OAuth2Code extends Model {
static get tableName () {
2017-08-23 20:13:45 +00:00
return 'oauth2_code'
2017-08-02 21:24:01 +00:00
}
}
class OAuth2AccessToken extends Model {
static get tableName () {
return 'oauth2_access_token'
}
}
class OAuth2RefreshToken extends Model {
static get tableName () {
return 'oauth2_refresh_token'
}
}
class TotpToken extends Model {
static get tableName () {
return 'totp_token'
}
}
class Ban extends Model {
static get tableName () {
return 'network_ban'
}
}
class News extends Model {
static get tableName () {
return 'news'
}
}
class Donation extends Model {
static get tableName () {
return 'donation'
}
}
class Subscription extends Model {
static get tableName () {
return 'subscription'
}
}
2017-10-03 11:20:49 +00:00
class MinecraftMember extends Model {
static get tableName () {
return 'mc_member'
}
}
class MinecraftToken extends Model {
static get tableName () {
return 'mc_verify'
}
}
2017-08-02 21:24:01 +00:00
module.exports = {
User: User,
External: External,
Token: Token,
OAuth2Client: OAuth2Client,
OAuth2AuthorizedClient: OAuth2AuthorizedClient,
OAuth2Code: OAuth2Code,
OAuth2AccessToken: OAuth2AccessToken,
OAuth2RefreshToken: OAuth2RefreshToken,
TotpToken: TotpToken,
Ban: Ban,
News: News,
Donation: Donation,
2017-10-03 11:20:49 +00:00
Subscription: Subscription,
MinecraftMember: MinecraftMember,
MinecraftToken: MinecraftToken
2017-08-02 21:24:01 +00:00
}