This commit is contained in:
Dominic Ferrando
2026-09-26 18:27:33 -04:00
parent b66980c0fb
commit 930bd61e62
4 changed files with 87 additions and 81 deletions
+3 -3
View File
@@ -14,7 +14,7 @@ export const VerificationStatusSchema = t.Union([
]);
export type VerificationStatus = Static<typeof VerificationStatusSchema>;
export const REQUIRED_MEDIA_ACTIVITIES = Object.values(Activity);
const REQUIRED_MEDIA_ACTIVITIES = Object.values(Activity);
const MEDIA_KEY_COLUMN = {
[Activity.BackSquat]: "media_key_back_squat",
@@ -80,9 +80,10 @@ export class VerificationsService {
.executeTakeFirst();
}
async get(id: string) {
async get(id: string, accountId?: string) {
return await VerificationsService.baseQuery()
.where("verifications.id", "=", id)
.$if(accountId !== undefined, (qb) => qb.where("assessments.account_id", "=", accountId!))
.executeTakeFirst();
}
@@ -173,7 +174,6 @@ export class VerificationsService {
"verifications.verf_broad_jump",
"verifications.verf_run",
"verifications.verf_cone_drill",
"assessments.account_id",
"assessments.name",
"assessments.gender",
"assessments.age",