feat: add POST /api/v1/installation/users to seed user
This commit is contained in:
@@ -13,6 +13,28 @@ class Config extends Base {
|
||||
value: { type: 'object' },
|
||||
},
|
||||
};
|
||||
|
||||
static async isInstallationCompleted() {
|
||||
const installationCompletedEntry = await this
|
||||
.query()
|
||||
.where({
|
||||
key: 'installation.completed'
|
||||
})
|
||||
.first();
|
||||
|
||||
const installationCompleted = installationCompletedEntry?.value?.data === true;
|
||||
|
||||
return installationCompleted;
|
||||
}
|
||||
|
||||
static async markInstallationCompleted() {
|
||||
return await this.query().insert({
|
||||
key: 'installation.completed',
|
||||
value: {
|
||||
data: true,
|
||||
},
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
export default Config;
|
||||
|
Reference in New Issue
Block a user