53 lines
1.2 KiB
JavaScript
53 lines
1.2 KiB
JavaScript
"use strict";
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
exports.desc = void 0;
|
|
const action_1 = require("oak-domain/lib/actions/action");
|
|
exports.desc = {
|
|
attributes: {
|
|
userId: {
|
|
notNull: true,
|
|
type: "ref",
|
|
ref: "user"
|
|
},
|
|
providerConfigId: {
|
|
notNull: true,
|
|
type: "ref",
|
|
ref: "oauthProviderConfigs"
|
|
},
|
|
providerUserId: {
|
|
notNull: true,
|
|
type: "varchar",
|
|
params: {
|
|
length: 128
|
|
}
|
|
},
|
|
rawUserInfo: {
|
|
notNull: true,
|
|
type: "object"
|
|
},
|
|
// 令牌
|
|
accessToken: {
|
|
notNull: true,
|
|
type: "varchar",
|
|
params: {
|
|
length: 256
|
|
}
|
|
},
|
|
refreshToken: {
|
|
type: "varchar",
|
|
params: {
|
|
length: 256
|
|
}
|
|
},
|
|
accessExpiresAt: {
|
|
notNull: true,
|
|
type: "datetime"
|
|
},
|
|
refreshExpiresAt: {
|
|
type: "datetime"
|
|
}
|
|
},
|
|
actionType: "crud",
|
|
actions: action_1.genericActions
|
|
};
|