@compfest-18/oppenheimer-schema 0.0.6-staging.df88d67 → 0.0.7-develop.77f855e
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +102 -0
- package/dist/index.mjs +87 -77
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -115,6 +115,23 @@ declare const users: drizzle_orm_pg_core.PgTableWithColumns<{
|
|
|
115
115
|
identity: undefined;
|
|
116
116
|
generated: undefined;
|
|
117
117
|
}, {}, {}>;
|
|
118
|
+
isNameCustom: drizzle_orm_pg_core.PgColumn<{
|
|
119
|
+
name: "is_name_custom";
|
|
120
|
+
tableName: "users";
|
|
121
|
+
dataType: "boolean";
|
|
122
|
+
columnType: "PgBoolean";
|
|
123
|
+
data: boolean;
|
|
124
|
+
driverParam: boolean;
|
|
125
|
+
notNull: true;
|
|
126
|
+
hasDefault: true;
|
|
127
|
+
isPrimaryKey: false;
|
|
128
|
+
isAutoincrement: false;
|
|
129
|
+
hasRuntimeDefault: false;
|
|
130
|
+
enumValues: undefined;
|
|
131
|
+
baseColumn: never;
|
|
132
|
+
identity: undefined;
|
|
133
|
+
generated: undefined;
|
|
134
|
+
}, {}, {}>;
|
|
118
135
|
createdAt: drizzle_orm_pg_core.PgColumn<{
|
|
119
136
|
name: "createdAt";
|
|
120
137
|
tableName: "users";
|
|
@@ -1354,6 +1371,40 @@ declare const xcelerateRegistrations: drizzle_orm_pg_core.PgTableWithColumns<{
|
|
|
1354
1371
|
identity: undefined;
|
|
1355
1372
|
generated: undefined;
|
|
1356
1373
|
}, {}, {}>;
|
|
1374
|
+
cvUrl: drizzle_orm_pg_core.PgColumn<{
|
|
1375
|
+
name: "cv_url";
|
|
1376
|
+
tableName: "xcelerate_registrations";
|
|
1377
|
+
dataType: "string";
|
|
1378
|
+
columnType: "PgText";
|
|
1379
|
+
data: string;
|
|
1380
|
+
driverParam: string;
|
|
1381
|
+
notNull: false;
|
|
1382
|
+
hasDefault: false;
|
|
1383
|
+
isPrimaryKey: false;
|
|
1384
|
+
isAutoincrement: false;
|
|
1385
|
+
hasRuntimeDefault: false;
|
|
1386
|
+
enumValues: [string, ...string[]];
|
|
1387
|
+
baseColumn: never;
|
|
1388
|
+
identity: undefined;
|
|
1389
|
+
generated: undefined;
|
|
1390
|
+
}, {}, {}>;
|
|
1391
|
+
cvFileName: drizzle_orm_pg_core.PgColumn<{
|
|
1392
|
+
name: "cv_file_name";
|
|
1393
|
+
tableName: "xcelerate_registrations";
|
|
1394
|
+
dataType: "string";
|
|
1395
|
+
columnType: "PgText";
|
|
1396
|
+
data: string;
|
|
1397
|
+
driverParam: string;
|
|
1398
|
+
notNull: false;
|
|
1399
|
+
hasDefault: false;
|
|
1400
|
+
isPrimaryKey: false;
|
|
1401
|
+
isAutoincrement: false;
|
|
1402
|
+
hasRuntimeDefault: false;
|
|
1403
|
+
enumValues: [string, ...string[]];
|
|
1404
|
+
baseColumn: never;
|
|
1405
|
+
identity: undefined;
|
|
1406
|
+
generated: undefined;
|
|
1407
|
+
}, {}, {}>;
|
|
1357
1408
|
deletedAt: drizzle_orm_pg_core.PgColumn<{
|
|
1358
1409
|
name: "deleted_at";
|
|
1359
1410
|
tableName: "xcelerate_registrations";
|
|
@@ -2854,6 +2905,23 @@ declare const teams: drizzle_orm_pg_core.PgTableWithColumns<{
|
|
|
2854
2905
|
identity: undefined;
|
|
2855
2906
|
generated: undefined;
|
|
2856
2907
|
}, {}, {}>;
|
|
2908
|
+
batch: drizzle_orm_pg_core.PgColumn<{
|
|
2909
|
+
name: "batch";
|
|
2910
|
+
tableName: "teams";
|
|
2911
|
+
dataType: "number";
|
|
2912
|
+
columnType: "PgInteger";
|
|
2913
|
+
data: number;
|
|
2914
|
+
driverParam: string | number;
|
|
2915
|
+
notNull: true;
|
|
2916
|
+
hasDefault: true;
|
|
2917
|
+
isPrimaryKey: false;
|
|
2918
|
+
isAutoincrement: false;
|
|
2919
|
+
hasRuntimeDefault: false;
|
|
2920
|
+
enumValues: undefined;
|
|
2921
|
+
baseColumn: never;
|
|
2922
|
+
identity: undefined;
|
|
2923
|
+
generated: undefined;
|
|
2924
|
+
}, {}, {}>;
|
|
2857
2925
|
deletedAt: drizzle_orm_pg_core.PgColumn<{
|
|
2858
2926
|
name: "deleted_at";
|
|
2859
2927
|
tableName: "teams";
|
|
@@ -3381,6 +3449,40 @@ declare const programTasks: drizzle_orm_pg_core.PgTableWithColumns<{
|
|
|
3381
3449
|
}, {}, {}, drizzle_orm.ColumnBuilderExtraConfig>;
|
|
3382
3450
|
size: undefined;
|
|
3383
3451
|
}>;
|
|
3452
|
+
isOptional: drizzle_orm_pg_core.PgColumn<{
|
|
3453
|
+
name: "is_optional";
|
|
3454
|
+
tableName: "program_tasks";
|
|
3455
|
+
dataType: "boolean";
|
|
3456
|
+
columnType: "PgBoolean";
|
|
3457
|
+
data: boolean;
|
|
3458
|
+
driverParam: boolean;
|
|
3459
|
+
notNull: true;
|
|
3460
|
+
hasDefault: true;
|
|
3461
|
+
isPrimaryKey: false;
|
|
3462
|
+
isAutoincrement: false;
|
|
3463
|
+
hasRuntimeDefault: false;
|
|
3464
|
+
enumValues: undefined;
|
|
3465
|
+
baseColumn: never;
|
|
3466
|
+
identity: undefined;
|
|
3467
|
+
generated: undefined;
|
|
3468
|
+
}, {}, {}>;
|
|
3469
|
+
isRegistrationTask: drizzle_orm_pg_core.PgColumn<{
|
|
3470
|
+
name: "is_registration_task";
|
|
3471
|
+
tableName: "program_tasks";
|
|
3472
|
+
dataType: "boolean";
|
|
3473
|
+
columnType: "PgBoolean";
|
|
3474
|
+
data: boolean;
|
|
3475
|
+
driverParam: boolean;
|
|
3476
|
+
notNull: true;
|
|
3477
|
+
hasDefault: true;
|
|
3478
|
+
isPrimaryKey: false;
|
|
3479
|
+
isAutoincrement: false;
|
|
3480
|
+
hasRuntimeDefault: false;
|
|
3481
|
+
enumValues: undefined;
|
|
3482
|
+
baseColumn: never;
|
|
3483
|
+
identity: undefined;
|
|
3484
|
+
generated: undefined;
|
|
3485
|
+
}, {}, {}>;
|
|
3384
3486
|
deletedAt: drizzle_orm_pg_core.PgColumn<{
|
|
3385
3487
|
name: "deleted_at";
|
|
3386
3488
|
tableName: "program_tasks";
|
package/dist/index.mjs
CHANGED
|
@@ -92,13 +92,16 @@ var cartStatusEnum = pgEnum("cart_status", [
|
|
|
92
92
|
|
|
93
93
|
// auth/user.schema.ts
|
|
94
94
|
import { sql } from "drizzle-orm";
|
|
95
|
-
import { pgTable, text, timestamp } from "drizzle-orm/pg-core";
|
|
95
|
+
import { boolean, pgTable, text, timestamp } from "drizzle-orm/pg-core";
|
|
96
96
|
var users = pgTable("users", {
|
|
97
97
|
id: text("id").primaryKey(),
|
|
98
98
|
email: text("email").notNull().unique(),
|
|
99
99
|
name: text("name").notNull(),
|
|
100
100
|
image: text("image"),
|
|
101
101
|
referralCode: text("referral_code").notNull().unique().default(sql`substring(replace(gen_random_uuid()::text, '-', ''), 1, 8)`),
|
|
102
|
+
// Once true, SSO sync (login-time) no longer overwrites `name` with the
|
|
103
|
+
// SSO-provided value — the user has set a COMPFEST-local display name.
|
|
104
|
+
isNameCustom: boolean("is_name_custom").notNull().default(false),
|
|
102
105
|
createdAt: timestamp("createdAt").notNull().defaultNow(),
|
|
103
106
|
updatedAt: timestamp("updatedAt").notNull().defaultNow()
|
|
104
107
|
});
|
|
@@ -236,6 +239,8 @@ var xcelerateRegistrations = pgTable6(
|
|
|
236
239
|
jobCategory: text6("job_category"),
|
|
237
240
|
knowEventSource: knowEventSourceEnum("know_event_source"),
|
|
238
241
|
batch: text6("batch"),
|
|
242
|
+
cvUrl: text6("cv_url"),
|
|
243
|
+
cvFileName: text6("cv_file_name"),
|
|
239
244
|
deletedAt: timestamp6("deleted_at"),
|
|
240
245
|
createdAt: timestamp6("created_at").notNull().defaultNow(),
|
|
241
246
|
updatedAt: timestamp6("updated_at").notNull().defaultNow()
|
|
@@ -306,7 +311,7 @@ var eventsRelations = relations7(events, ({ many }) => ({
|
|
|
306
311
|
|
|
307
312
|
// feedback/feedback.schema.ts
|
|
308
313
|
import { relations as relations11 } from "drizzle-orm";
|
|
309
|
-
import { boolean, index as index10, pgTable as pgTable12, text as text12, timestamp as timestamp12 } from "drizzle-orm/pg-core";
|
|
314
|
+
import { boolean as boolean2, index as index10, pgTable as pgTable12, text as text12, timestamp as timestamp12 } from "drizzle-orm/pg-core";
|
|
310
315
|
|
|
311
316
|
// feedback/feedback-question.schema.ts
|
|
312
317
|
import { relations as relations9 } from "drizzle-orm";
|
|
@@ -388,7 +393,7 @@ var feedbacks = pgTable12(
|
|
|
388
393
|
{
|
|
389
394
|
id: text12("id").primaryKey(),
|
|
390
395
|
eventId: text12("event_id").notNull().unique().references(() => events.id, { onDelete: "cascade" }),
|
|
391
|
-
isOpen:
|
|
396
|
+
isOpen: boolean2("is_open").notNull().default(true),
|
|
392
397
|
deletedAt: timestamp12("deleted_at"),
|
|
393
398
|
createdAt: timestamp12("created_at").notNull().defaultNow(),
|
|
394
399
|
updatedAt: timestamp12("updated_at").notNull().defaultNow()
|
|
@@ -402,15 +407,15 @@ var feedbacksRelations = relations11(feedbacks, ({ many }) => ({
|
|
|
402
407
|
|
|
403
408
|
// programs/member.schema.ts
|
|
404
409
|
import { relations as relations16 } from "drizzle-orm";
|
|
405
|
-
import { boolean as
|
|
410
|
+
import { boolean as boolean5, index as index15, pgTable as pgTable17, text as text17, timestamp as timestamp17 } from "drizzle-orm/pg-core";
|
|
406
411
|
|
|
407
412
|
// programs/team.schema.ts
|
|
408
413
|
import { relations as relations15 } from "drizzle-orm";
|
|
409
|
-
import { boolean as
|
|
414
|
+
import { boolean as boolean4, index as index14, integer as integer2, pgTable as pgTable16, text as text16, timestamp as timestamp16 } from "drizzle-orm/pg-core";
|
|
410
415
|
|
|
411
416
|
// programs/program.schema.ts
|
|
412
417
|
import { relations as relations14 } from "drizzle-orm";
|
|
413
|
-
import { boolean as
|
|
418
|
+
import { boolean as boolean3, index as index13, integer, jsonb, pgTable as pgTable15, text as text15, timestamp as timestamp15 } from "drizzle-orm/pg-core";
|
|
414
419
|
|
|
415
420
|
// programs/program-registration.schema.ts
|
|
416
421
|
import { relations as relations12 } from "drizzle-orm";
|
|
@@ -485,7 +490,7 @@ var programs = pgTable15(
|
|
|
485
490
|
allowedEducationLevel: text15("allowed_education_level"),
|
|
486
491
|
minMember: integer("min_member"),
|
|
487
492
|
maxMember: integer("max_member"),
|
|
488
|
-
isAbleToRegisterAsTeam:
|
|
493
|
+
isAbleToRegisterAsTeam: boolean3("is_able_to_register_as_team").notNull().default(false),
|
|
489
494
|
paymentBills: jsonb("payment_bills"),
|
|
490
495
|
startDate: timestamp15("start_date"),
|
|
491
496
|
extendStartDate: timestamp15("extend_start_date"),
|
|
@@ -523,7 +528,8 @@ var teams = pgTable16(
|
|
|
523
528
|
code: text16("code").notNull().unique(),
|
|
524
529
|
status: teamStatusEnum("status").notNull().default("WAITING_FOR_VERIFICATION"),
|
|
525
530
|
notes: text16("notes"),
|
|
526
|
-
isPublic:
|
|
531
|
+
isPublic: boolean4("is_public").notNull().default(false),
|
|
532
|
+
batch: integer2("batch").notNull().default(1),
|
|
527
533
|
deletedAt: timestamp16("deleted_at"),
|
|
528
534
|
createdAt: timestamp16("created_at").notNull().defaultNow(),
|
|
529
535
|
updatedAt: timestamp16("updated_at").notNull().defaultNow()
|
|
@@ -549,7 +555,7 @@ var members = pgTable17(
|
|
|
549
555
|
id: text17("id").primaryKey(),
|
|
550
556
|
userId: text17("user_id").notNull().references(() => users.id, { onDelete: "cascade" }),
|
|
551
557
|
teamId: text17("team_id").notNull().references(() => teams.id, { onDelete: "cascade" }),
|
|
552
|
-
isLeader:
|
|
558
|
+
isLeader: boolean5("is_leader").notNull().default(false),
|
|
553
559
|
deletedAt: timestamp17("deleted_at"),
|
|
554
560
|
createdAt: timestamp17("created_at").notNull().defaultNow(),
|
|
555
561
|
updatedAt: timestamp17("updated_at").notNull().defaultNow()
|
|
@@ -601,8 +607,8 @@ var teamJoinRequestsRelations = relations17(teamJoinRequests, ({ one }) => ({
|
|
|
601
607
|
}));
|
|
602
608
|
|
|
603
609
|
// tasks/competition-payment-proof.schema.ts
|
|
604
|
-
import { relations as relations18 } from "drizzle-orm";
|
|
605
|
-
import { index as index17, pgTable as pgTable19, text as text19, timestamp as timestamp19 } from "drizzle-orm/pg-core";
|
|
610
|
+
import { relations as relations18, sql as sql2 } from "drizzle-orm";
|
|
611
|
+
import { index as index17, pgTable as pgTable19, text as text19, timestamp as timestamp19, uniqueIndex } from "drizzle-orm/pg-core";
|
|
606
612
|
var competitionPaymentProofs = pgTable19(
|
|
607
613
|
"competition_payment_proofs",
|
|
608
614
|
{
|
|
@@ -619,7 +625,9 @@ var competitionPaymentProofs = pgTable19(
|
|
|
619
625
|
(table) => [
|
|
620
626
|
index17("competition_payment_proofs_program_id_idx").on(table.programId),
|
|
621
627
|
index17("competition_payment_proofs_team_id_idx").on(table.teamId),
|
|
622
|
-
index17("competition_payment_proofs_user_id_idx").on(table.userId)
|
|
628
|
+
index17("competition_payment_proofs_user_id_idx").on(table.userId),
|
|
629
|
+
uniqueIndex("competition_payment_proofs_program_team_uniq").on(table.programId, table.teamId).where(sql2`${table.teamId} IS NOT NULL`),
|
|
630
|
+
uniqueIndex("competition_payment_proofs_program_user_uniq").on(table.programId, table.userId).where(sql2`${table.userId} IS NOT NULL`)
|
|
623
631
|
]
|
|
624
632
|
);
|
|
625
633
|
var competitionPaymentProofsRelations = relations18(competitionPaymentProofs, ({ one }) => ({
|
|
@@ -639,7 +647,7 @@ var competitionPaymentProofsRelations = relations18(competitionPaymentProofs, ({
|
|
|
639
647
|
|
|
640
648
|
// tasks/program-task.schema.ts
|
|
641
649
|
import { relations as relations19 } from "drizzle-orm";
|
|
642
|
-
import { index as index18, pgTable as pgTable20, text as text20, timestamp as timestamp20 } from "drizzle-orm/pg-core";
|
|
650
|
+
import { boolean as boolean6, index as index18, pgTable as pgTable20, text as text20, timestamp as timestamp20 } from "drizzle-orm/pg-core";
|
|
643
651
|
var programTasks = pgTable20(
|
|
644
652
|
"program_tasks",
|
|
645
653
|
{
|
|
@@ -651,6 +659,8 @@ var programTasks = pgTable20(
|
|
|
651
659
|
guideBookUrl: text20("guide_book_url"),
|
|
652
660
|
type: programTaskTypeEnum("type").notNull(),
|
|
653
661
|
acceptedFileTypes: fileTypeEnum("accepted_file_types").array(),
|
|
662
|
+
isOptional: boolean6("is_optional").notNull().default(false),
|
|
663
|
+
isRegistrationTask: boolean6("is_registration_task").notNull().default(false),
|
|
654
664
|
deletedAt: timestamp20("deleted_at"),
|
|
655
665
|
createdAt: timestamp20("created_at").notNull().defaultNow(),
|
|
656
666
|
updatedAt: timestamp20("updated_at").notNull().defaultNow()
|
|
@@ -666,14 +676,14 @@ var programTasksRelations = relations19(programTasks, ({ one }) => ({
|
|
|
666
676
|
|
|
667
677
|
// tasks/program-task-extra-description.schema.ts
|
|
668
678
|
import { relations as relations20 } from "drizzle-orm";
|
|
669
|
-
import { boolean as
|
|
679
|
+
import { boolean as boolean7, index as index19, pgTable as pgTable21, text as text21, timestamp as timestamp21 } from "drizzle-orm/pg-core";
|
|
670
680
|
var programTaskExtraDescriptions = pgTable21(
|
|
671
681
|
"program_task_extra_descriptions",
|
|
672
682
|
{
|
|
673
683
|
id: text21("id").primaryKey(),
|
|
674
684
|
taskId: text21("task_id").notNull().references(() => programTasks.id, { onDelete: "cascade" }),
|
|
675
685
|
description: text21("description").notNull(),
|
|
676
|
-
forProgram:
|
|
686
|
+
forProgram: boolean7("for_program").notNull().default(true),
|
|
677
687
|
deletedAt: timestamp21("deleted_at"),
|
|
678
688
|
createdAt: timestamp21("created_at").notNull().defaultNow(),
|
|
679
689
|
updatedAt: timestamp21("updated_at").notNull().defaultNow()
|
|
@@ -751,7 +761,7 @@ var programTaskSubmissionsRelations = relations21(programTaskSubmissions, ({ one
|
|
|
751
761
|
}));
|
|
752
762
|
|
|
753
763
|
// tasks/xcelerate-workshop-task.schema.ts
|
|
754
|
-
import { index as index21, integer as
|
|
764
|
+
import { index as index21, integer as integer3, pgTable as pgTable23, text as text23, timestamp as timestamp23 } from "drizzle-orm/pg-core";
|
|
755
765
|
var xcelerateWorkshopTasks = pgTable23(
|
|
756
766
|
"xcelerateWorkshopTasks",
|
|
757
767
|
{
|
|
@@ -759,7 +769,7 @@ var xcelerateWorkshopTasks = pgTable23(
|
|
|
759
769
|
title: text23("title").notNull(),
|
|
760
770
|
description: text23("description"),
|
|
761
771
|
deadline: timestamp23("deadline"),
|
|
762
|
-
batch:
|
|
772
|
+
batch: integer3("batch"),
|
|
763
773
|
taskUrl: text23("taskUrl"),
|
|
764
774
|
createdAt: timestamp23("createdAt").notNull().defaultNow(),
|
|
765
775
|
updatedAt: timestamp23("updatedAt").notNull().defaultNow()
|
|
@@ -772,7 +782,7 @@ var xcelerateWorkshopTasks = pgTable23(
|
|
|
772
782
|
|
|
773
783
|
// tasks/xcelerate-workshop-task-submission.schema.ts
|
|
774
784
|
import { relations as relations22 } from "drizzle-orm";
|
|
775
|
-
import { index as index22, pgTable as pgTable24, text as text24, timestamp as timestamp24, uniqueIndex } from "drizzle-orm/pg-core";
|
|
785
|
+
import { index as index22, pgTable as pgTable24, text as text24, timestamp as timestamp24, uniqueIndex as uniqueIndex2 } from "drizzle-orm/pg-core";
|
|
776
786
|
var xcelerateWorkshopTaskSubmissions = pgTable24(
|
|
777
787
|
"xcelerateWorkshopTaskSubmissions",
|
|
778
788
|
{
|
|
@@ -792,7 +802,7 @@ var xcelerateWorkshopTaskSubmissions = pgTable24(
|
|
|
792
802
|
(table) => [
|
|
793
803
|
index22("xcelerate_workshop_task_submissions_task_id_idx").on(table.taskId),
|
|
794
804
|
index22("xcelerate_workshop_task_submissions_user_id_idx").on(table.userId),
|
|
795
|
-
|
|
805
|
+
uniqueIndex2("xcelerate_workshop_task_submissions_task_user_idx").on(
|
|
796
806
|
table.taskId,
|
|
797
807
|
table.userId
|
|
798
808
|
)
|
|
@@ -814,7 +824,7 @@ var xcelerateWorkshopTaskSubmissionsRelations = relations22(
|
|
|
814
824
|
|
|
815
825
|
// announcements/announcement.schema.ts
|
|
816
826
|
import { relations as relations23 } from "drizzle-orm";
|
|
817
|
-
import { boolean as
|
|
827
|
+
import { boolean as boolean8, index as index23, pgTable as pgTable25, text as text25, timestamp as timestamp25 } from "drizzle-orm/pg-core";
|
|
818
828
|
var announcements = pgTable25(
|
|
819
829
|
"announcements",
|
|
820
830
|
{
|
|
@@ -824,11 +834,11 @@ var announcements = pgTable25(
|
|
|
824
834
|
message: text25("message"),
|
|
825
835
|
status: text25("status").notNull().default("published"),
|
|
826
836
|
programId: text25("program_id").references(() => programs.id, { onDelete: "cascade" }),
|
|
827
|
-
isAdmin:
|
|
828
|
-
audienceAcademy:
|
|
829
|
-
audienceCompetition:
|
|
830
|
-
emailEnabled:
|
|
831
|
-
emailSent:
|
|
837
|
+
isAdmin: boolean8("is_admin").notNull().default(false),
|
|
838
|
+
audienceAcademy: boolean8("audience_academy").notNull().default(false),
|
|
839
|
+
audienceCompetition: boolean8("audience_competition").notNull().default(false),
|
|
840
|
+
emailEnabled: boolean8("email_enabled").notNull().default(false),
|
|
841
|
+
emailSent: boolean8("email_sent").notNull().default(false),
|
|
832
842
|
emailSentAt: timestamp25("email_sent_at"),
|
|
833
843
|
emailError: text25("email_error"),
|
|
834
844
|
deletedAt: timestamp25("deleted_at"),
|
|
@@ -876,7 +886,7 @@ var userPlaygrounds = pgTable27(
|
|
|
876
886
|
);
|
|
877
887
|
|
|
878
888
|
// playground/user-playground-detention.schema.ts
|
|
879
|
-
import { boolean as
|
|
889
|
+
import { boolean as boolean9, index as index25, pgTable as pgTable28, text as text27, timestamp as timestamp28, uuid as uuid3 } from "drizzle-orm/pg-core";
|
|
880
890
|
var userPlaygroundDetentions = pgTable28(
|
|
881
891
|
"userPlaygroundDetentions",
|
|
882
892
|
{
|
|
@@ -885,7 +895,7 @@ var userPlaygroundDetentions = pgTable28(
|
|
|
885
895
|
description: text27("description").notNull(),
|
|
886
896
|
penaltyPoint: text27("penalty_point").notNull(),
|
|
887
897
|
state: detentionStateEnum("state").notNull(),
|
|
888
|
-
isRead:
|
|
898
|
+
isRead: boolean9("is_read").notNull().default(false),
|
|
889
899
|
deletedAt: timestamp28("deleted_at"),
|
|
890
900
|
createdAt: timestamp28("created_at").notNull().defaultNow(),
|
|
891
901
|
updatedAt: timestamp28("updated_at").notNull().defaultNow()
|
|
@@ -895,7 +905,7 @@ var userPlaygroundDetentions = pgTable28(
|
|
|
895
905
|
|
|
896
906
|
// games/game.schema.ts
|
|
897
907
|
import { relations as relations28 } from "drizzle-orm";
|
|
898
|
-
import { boolean as
|
|
908
|
+
import { boolean as boolean12, pgTable as pgTable33, text as text31, timestamp as timestamp33 } from "drizzle-orm/pg-core";
|
|
899
909
|
|
|
900
910
|
// games/game-developer.schema.ts
|
|
901
911
|
import { relations as relations24 } from "drizzle-orm";
|
|
@@ -938,17 +948,17 @@ var gameRulesRelations = relations25(gameRules, ({ one }) => ({
|
|
|
938
948
|
|
|
939
949
|
// games/user-play-game-history.schema.ts
|
|
940
950
|
import { relations as relations27 } from "drizzle-orm";
|
|
941
|
-
import { boolean as
|
|
951
|
+
import { boolean as boolean11, pgTable as pgTable32, text as text30, timestamp as timestamp32, uuid as uuid5 } from "drizzle-orm/pg-core";
|
|
942
952
|
|
|
943
953
|
// tokens/playground-token.schema.ts
|
|
944
954
|
import { relations as relations26 } from "drizzle-orm";
|
|
945
|
-
import { boolean as
|
|
955
|
+
import { boolean as boolean10, pgTable as pgTable31, timestamp as timestamp31, uuid as uuid4, varchar } from "drizzle-orm/pg-core";
|
|
946
956
|
var playgroundTokens = pgTable31("playgroundTokens", {
|
|
947
957
|
id: uuid4("id").primaryKey().defaultRandom(),
|
|
948
958
|
userPlaygroundId: uuid4("userPlaygroundId").references(() => userPlaygrounds.id, { onDelete: "cascade" }).notNull(),
|
|
949
959
|
code: varchar("code", { length: 6 }).notNull().unique(),
|
|
950
960
|
tokenType: tokenTypeEnum("tokenType").notNull(),
|
|
951
|
-
isUsed:
|
|
961
|
+
isUsed: boolean10("isUsed").notNull().default(false),
|
|
952
962
|
usedAt: timestamp31("usedAt"),
|
|
953
963
|
deletedAt: timestamp31("deletedAt"),
|
|
954
964
|
createdAt: timestamp31("createdAt").notNull().defaultNow(),
|
|
@@ -969,7 +979,7 @@ var userPlayGameHistories = pgTable32("userPlayGameHistories", {
|
|
|
969
979
|
tokenUsedId: uuid5("tokenUsedId").references(() => playgroundTokens.id, {
|
|
970
980
|
onDelete: "set null"
|
|
971
981
|
}),
|
|
972
|
-
isFinished:
|
|
982
|
+
isFinished: boolean11("isFinished").notNull().default(false),
|
|
973
983
|
finishedAt: timestamp32("finishedAt"),
|
|
974
984
|
createdAt: timestamp32("createdAt").notNull().defaultNow(),
|
|
975
985
|
updatedAt: timestamp32("updatedAt").notNull().defaultNow()
|
|
@@ -997,7 +1007,7 @@ var games = pgTable33("games", {
|
|
|
997
1007
|
arcadeUrl: text31("arcadeUrl"),
|
|
998
1008
|
description: text31("description"),
|
|
999
1009
|
rules: text31("rules").array(),
|
|
1000
|
-
isGetPoint:
|
|
1010
|
+
isGetPoint: boolean12("isGetPoint").notNull().default(false),
|
|
1001
1011
|
orientation: gameOrientationEnum("orientation").notNull().default("VERTICAL"),
|
|
1002
1012
|
createdAt: timestamp33("createdAt").notNull().defaultNow(),
|
|
1003
1013
|
updatedAt: timestamp33("updatedAt").notNull().defaultNow()
|
|
@@ -1010,7 +1020,7 @@ var gamesRelations = relations28(games, ({ many }) => ({
|
|
|
1010
1020
|
|
|
1011
1021
|
// tokens/playground-expense-history.schema.ts
|
|
1012
1022
|
import { relations as relations29 } from "drizzle-orm";
|
|
1013
|
-
import { index as index26, integer as
|
|
1023
|
+
import { index as index26, integer as integer4, pgTable as pgTable34, text as text32, timestamp as timestamp34, uuid as uuid6 } from "drizzle-orm/pg-core";
|
|
1014
1024
|
var playgroundExpenseHistories = pgTable34(
|
|
1015
1025
|
"playgroundExpenseHistories",
|
|
1016
1026
|
{
|
|
@@ -1019,7 +1029,7 @@ var playgroundExpenseHistories = pgTable34(
|
|
|
1019
1029
|
onDelete: "cascade"
|
|
1020
1030
|
}),
|
|
1021
1031
|
description: text32("description"),
|
|
1022
|
-
amount:
|
|
1032
|
+
amount: integer4("amount").notNull(),
|
|
1023
1033
|
createdAt: timestamp34("createdAt").notNull().defaultNow(),
|
|
1024
1034
|
updatedAt: timestamp34("updatedAt").notNull().defaultNow()
|
|
1025
1035
|
},
|
|
@@ -1039,7 +1049,7 @@ var playgroundExpenseHistoriesRelations = relations29(
|
|
|
1039
1049
|
|
|
1040
1050
|
// tokens/playground-reward-history.schema.ts
|
|
1041
1051
|
import { relations as relations30 } from "drizzle-orm";
|
|
1042
|
-
import { index as index27, integer as
|
|
1052
|
+
import { index as index27, integer as integer5, pgTable as pgTable35, text as text33, timestamp as timestamp35, uuid as uuid7 } from "drizzle-orm/pg-core";
|
|
1043
1053
|
var playgroundRewardHistories = pgTable35(
|
|
1044
1054
|
"playgroundRewardHistories",
|
|
1045
1055
|
{
|
|
@@ -1049,7 +1059,7 @@ var playgroundRewardHistories = pgTable35(
|
|
|
1049
1059
|
}),
|
|
1050
1060
|
description: text33("description"),
|
|
1051
1061
|
rewardType: rewardTypeEnum("rewardType").notNull(),
|
|
1052
|
-
amount:
|
|
1062
|
+
amount: integer5("amount").notNull(),
|
|
1053
1063
|
createdAt: timestamp35("createdAt").notNull().defaultNow(),
|
|
1054
1064
|
updatedAt: timestamp35("updatedAt").notNull().defaultNow()
|
|
1055
1065
|
},
|
|
@@ -1070,12 +1080,12 @@ import { relations as relations31 } from "drizzle-orm";
|
|
|
1070
1080
|
import { pgTable as pgTable37, text as text35, timestamp as timestamp37, uuid as uuid8 } from "drizzle-orm/pg-core";
|
|
1071
1081
|
|
|
1072
1082
|
// ads/advertisement.schema.ts
|
|
1073
|
-
import { boolean as
|
|
1083
|
+
import { boolean as boolean13, integer as integer6, pgTable as pgTable36, text as text34, timestamp as timestamp36 } from "drizzle-orm/pg-core";
|
|
1074
1084
|
var advertisements = pgTable36("advertisements", {
|
|
1075
1085
|
id: text34("id").primaryKey(),
|
|
1076
1086
|
contentUrl: text34("contentUrl").notNull(),
|
|
1077
|
-
isVideo:
|
|
1078
|
-
contentLength:
|
|
1087
|
+
isVideo: boolean13("isVideo").notNull().default(false),
|
|
1088
|
+
contentLength: integer6("contentLength"),
|
|
1079
1089
|
createdAt: timestamp36("createdAt").notNull().defaultNow(),
|
|
1080
1090
|
updatedAt: timestamp36("updatedAt").notNull().defaultNow()
|
|
1081
1091
|
});
|
|
@@ -1105,16 +1115,16 @@ var adWatchHistoriesRelations = relations31(adWatchHistories, ({ one }) => ({
|
|
|
1105
1115
|
|
|
1106
1116
|
// ads/ad-watch-session.schema.ts
|
|
1107
1117
|
import { relations as relations32 } from "drizzle-orm";
|
|
1108
|
-
import { integer as
|
|
1118
|
+
import { integer as integer7, pgTable as pgTable38, text as text36, timestamp as timestamp38, uuid as uuid9 } from "drizzle-orm/pg-core";
|
|
1109
1119
|
var adWatchSessions = pgTable38("adWatchSessions", {
|
|
1110
1120
|
id: text36("id").primaryKey(),
|
|
1111
1121
|
userPlaygroundId: uuid9("userPlaygroundId").references(() => userPlaygrounds.id, {
|
|
1112
1122
|
onDelete: "cascade"
|
|
1113
1123
|
}),
|
|
1114
1124
|
adId: text36("adId").references(() => advertisements.id, { onDelete: "cascade" }),
|
|
1115
|
-
adLength:
|
|
1116
|
-
startTimeUnix:
|
|
1117
|
-
lockUntil:
|
|
1125
|
+
adLength: integer7("adLength"),
|
|
1126
|
+
startTimeUnix: integer7("startTimeUnix").notNull(),
|
|
1127
|
+
lockUntil: integer7("lockUntil"),
|
|
1118
1128
|
finishedAt: timestamp38("finishedAt"),
|
|
1119
1129
|
createdAt: timestamp38("createdAt").notNull().defaultNow(),
|
|
1120
1130
|
updatedAt: timestamp38("updatedAt").notNull().defaultNow()
|
|
@@ -1173,7 +1183,7 @@ import { index as index30, pgTable as pgTable41, text as text39, timestamp as ti
|
|
|
1173
1183
|
|
|
1174
1184
|
// quiz/main-event-mini-quiz-question-option.schema.ts
|
|
1175
1185
|
import { relations as relations34 } from "drizzle-orm";
|
|
1176
|
-
import { boolean as
|
|
1186
|
+
import { boolean as boolean14, index as index29, pgTable as pgTable40, text as text38, timestamp as timestamp40 } from "drizzle-orm/pg-core";
|
|
1177
1187
|
var mainEventMiniQuizQuestionOptions = pgTable40(
|
|
1178
1188
|
"mainEventMiniQuizQuestionOptions",
|
|
1179
1189
|
{
|
|
@@ -1182,7 +1192,7 @@ var mainEventMiniQuizQuestionOptions = pgTable40(
|
|
|
1182
1192
|
onDelete: "cascade"
|
|
1183
1193
|
}),
|
|
1184
1194
|
option: text38("option").notNull(),
|
|
1185
|
-
isAnswer:
|
|
1195
|
+
isAnswer: boolean14("isAnswer").notNull().default(false),
|
|
1186
1196
|
createdAt: timestamp40("createdAt").notNull().defaultNow(),
|
|
1187
1197
|
updatedAt: timestamp40("updatedAt").notNull().defaultNow()
|
|
1188
1198
|
},
|
|
@@ -1273,14 +1283,14 @@ var miniQuizAttemptsRelations = relations37(miniQuizAttempts, ({ one }) => ({
|
|
|
1273
1283
|
|
|
1274
1284
|
// quiz/mini-quiz-question.schema.ts
|
|
1275
1285
|
import { relations as relations38 } from "drizzle-orm";
|
|
1276
|
-
import { boolean as
|
|
1286
|
+
import { boolean as boolean15, index as index33, pgTable as pgTable44, text as text42, timestamp as timestamp44 } from "drizzle-orm/pg-core";
|
|
1277
1287
|
var miniQuizQuestions = pgTable44(
|
|
1278
1288
|
"miniQuizQuestions",
|
|
1279
1289
|
{
|
|
1280
1290
|
id: text42("id").primaryKey(),
|
|
1281
1291
|
quizId: text42("quizId").references(() => miniQuizzes.id, { onDelete: "cascade" }),
|
|
1282
1292
|
question: text42("question").notNull(),
|
|
1283
|
-
isTrue:
|
|
1293
|
+
isTrue: boolean15("isTrue"),
|
|
1284
1294
|
createdAt: timestamp44("createdAt").notNull().defaultNow(),
|
|
1285
1295
|
updatedAt: timestamp44("updatedAt").notNull().defaultNow()
|
|
1286
1296
|
},
|
|
@@ -1329,7 +1339,7 @@ var companyExhibitions = pgTable46("companyExhibitions", {
|
|
|
1329
1339
|
|
|
1330
1340
|
// exhibition/company-exhibition-vacancies.schema.ts
|
|
1331
1341
|
import { relations as relations40 } from "drizzle-orm";
|
|
1332
|
-
import { boolean as
|
|
1342
|
+
import { boolean as boolean16, index as index35, pgTable as pgTable47, text as text45, timestamp as timestamp47 } from "drizzle-orm/pg-core";
|
|
1333
1343
|
var companyExhibitionVacancies = pgTable47(
|
|
1334
1344
|
"companyExhibitionVacancies",
|
|
1335
1345
|
{
|
|
@@ -1347,7 +1357,7 @@ var companyExhibitionVacancies = pgTable47(
|
|
|
1347
1357
|
responsibilities: text45("responsibilities"),
|
|
1348
1358
|
requirements: text45("requirements"),
|
|
1349
1359
|
vacancyUrl: text45("vacancyUrl"),
|
|
1350
|
-
isOpen:
|
|
1360
|
+
isOpen: boolean16("isOpen").notNull().default(true),
|
|
1351
1361
|
createdAt: timestamp47("createdAt").notNull().defaultNow(),
|
|
1352
1362
|
updatedAt: timestamp47("updatedAt").notNull().defaultNow()
|
|
1353
1363
|
},
|
|
@@ -1368,27 +1378,27 @@ var companyExhibitionVacanciesRelations = relations40(
|
|
|
1368
1378
|
|
|
1369
1379
|
// jobfair/walk-in-interview-applicant.schema.ts
|
|
1370
1380
|
import { relations as relations43 } from "drizzle-orm";
|
|
1371
|
-
import { index as index37, pgTable as pgTable50, text as text48, timestamp as timestamp50, uniqueIndex as
|
|
1381
|
+
import { index as index37, pgTable as pgTable50, text as text48, timestamp as timestamp50, uniqueIndex as uniqueIndex3 } from "drizzle-orm/pg-core";
|
|
1372
1382
|
|
|
1373
1383
|
// jobfair/walk-in-interview-company-slot.schema.ts
|
|
1374
1384
|
import { relations as relations42 } from "drizzle-orm";
|
|
1375
|
-
import { boolean as
|
|
1385
|
+
import { boolean as boolean17, index as index36, pgTable as pgTable49, text as text47, timestamp as timestamp49 } from "drizzle-orm/pg-core";
|
|
1376
1386
|
|
|
1377
1387
|
// jobfair/walk-in-interview-company.schema.ts
|
|
1378
1388
|
import { relations as relations41 } from "drizzle-orm";
|
|
1379
|
-
import { integer as
|
|
1389
|
+
import { integer as integer8, pgTable as pgTable48, text as text46, timestamp as timestamp48 } from "drizzle-orm/pg-core";
|
|
1380
1390
|
var walkInInterviewCompanies = pgTable48("walkInInterviewCompanies", {
|
|
1381
1391
|
id: text46("id").primaryKey(),
|
|
1382
1392
|
name: text46("name").notNull(),
|
|
1383
1393
|
description: text46("description"),
|
|
1384
1394
|
iconUrl: text46("iconUrl"),
|
|
1385
|
-
slots:
|
|
1395
|
+
slots: integer8("slots"),
|
|
1386
1396
|
session: text46("session"),
|
|
1387
1397
|
roles: text46("roles"),
|
|
1388
1398
|
tags: text46("tags"),
|
|
1389
1399
|
benefits: text46("benefits"),
|
|
1390
1400
|
criteria: text46("criteria"),
|
|
1391
|
-
currentApplicants:
|
|
1401
|
+
currentApplicants: integer8("currentApplicants"),
|
|
1392
1402
|
boothLocation: text46("boothLocation"),
|
|
1393
1403
|
createdAt: timestamp48("createdAt").notNull().defaultNow(),
|
|
1394
1404
|
updatedAt: timestamp48("updatedAt").notNull().defaultNow()
|
|
@@ -1410,7 +1420,7 @@ var walkInInterviewCompanySlots = pgTable49(
|
|
|
1410
1420
|
}),
|
|
1411
1421
|
startTime: timestamp49("startTime").notNull(),
|
|
1412
1422
|
endTime: timestamp49("endTime").notNull(),
|
|
1413
|
-
isAvailable:
|
|
1423
|
+
isAvailable: boolean17("isAvailable").notNull().default(true),
|
|
1414
1424
|
createdAt: timestamp49("createdAt").notNull().defaultNow(),
|
|
1415
1425
|
updatedAt: timestamp49("updatedAt").notNull().defaultNow()
|
|
1416
1426
|
},
|
|
@@ -1446,7 +1456,7 @@ var walkInInterviewApplicants = pgTable50(
|
|
|
1446
1456
|
},
|
|
1447
1457
|
(table) => [
|
|
1448
1458
|
index37("walkInInterviewApplicants_userId_idx").on(table.userId),
|
|
1449
|
-
|
|
1459
|
+
uniqueIndex3("walkInInterviewApplicants_appliedSessionId_unique_idx").on(
|
|
1450
1460
|
table.appliedSessionId
|
|
1451
1461
|
)
|
|
1452
1462
|
]
|
|
@@ -1489,7 +1499,7 @@ var cvClinicClaims = pgTable52("cv_clinic_claims", {
|
|
|
1489
1499
|
});
|
|
1490
1500
|
|
|
1491
1501
|
// voting/competition-showcase.schema.ts
|
|
1492
|
-
import { pgTable as pgTable53, text as text51, timestamp as timestamp52, uniqueIndex as
|
|
1502
|
+
import { pgTable as pgTable53, text as text51, timestamp as timestamp52, uniqueIndex as uniqueIndex4 } from "drizzle-orm/pg-core";
|
|
1493
1503
|
var competitionShowcases = pgTable53(
|
|
1494
1504
|
"competition_showcases",
|
|
1495
1505
|
{
|
|
@@ -1499,11 +1509,11 @@ var competitionShowcases = pgTable53(
|
|
|
1499
1509
|
createdAt: timestamp52("created_at").notNull().defaultNow(),
|
|
1500
1510
|
updatedAt: timestamp52("updated_at").notNull().defaultNow()
|
|
1501
1511
|
},
|
|
1502
|
-
(table) => [
|
|
1512
|
+
(table) => [uniqueIndex4("competition_showcases_name_unique").on(table.name)]
|
|
1503
1513
|
);
|
|
1504
1514
|
|
|
1505
1515
|
// voting/nominee.schema.ts
|
|
1506
|
-
import { boolean as
|
|
1516
|
+
import { boolean as boolean18, integer as integer9, pgTable as pgTable54, text as text52, timestamp as timestamp53 } from "drizzle-orm/pg-core";
|
|
1507
1517
|
var nominees = pgTable54("nominees", {
|
|
1508
1518
|
id: text52("id").primaryKey(),
|
|
1509
1519
|
type: nomineeTypeEnum("type").notNull(),
|
|
@@ -1512,8 +1522,8 @@ var nominees = pgTable54("nominees", {
|
|
|
1512
1522
|
description: text52("description"),
|
|
1513
1523
|
thumbnailUrl: text52("thumbnail_url"),
|
|
1514
1524
|
url: text52("url"),
|
|
1515
|
-
isActive:
|
|
1516
|
-
point:
|
|
1525
|
+
isActive: boolean18("is_active").notNull().default(true),
|
|
1526
|
+
point: integer9("point").notNull().default(0),
|
|
1517
1527
|
deletedAt: timestamp53("deleted_at"),
|
|
1518
1528
|
createdAt: timestamp53("created_at").notNull().defaultNow(),
|
|
1519
1529
|
updatedAt: timestamp53("updated_at").notNull().defaultNow()
|
|
@@ -1533,7 +1543,7 @@ var nomineeVotes = pgTable55("nominee_votes", {
|
|
|
1533
1543
|
});
|
|
1534
1544
|
|
|
1535
1545
|
// voting/project.schema.ts
|
|
1536
|
-
import { integer as
|
|
1546
|
+
import { integer as integer10, pgTable as pgTable56, text as text54, timestamp as timestamp55, uniqueIndex as uniqueIndex5 } from "drizzle-orm/pg-core";
|
|
1537
1547
|
var projects = pgTable56(
|
|
1538
1548
|
"projects",
|
|
1539
1549
|
{
|
|
@@ -1546,16 +1556,16 @@ var projects = pgTable56(
|
|
|
1546
1556
|
youtubeUrl: text54("youtube_url"),
|
|
1547
1557
|
externalUrl: text54("external_url"),
|
|
1548
1558
|
teamName: text54("team_name").notNull(),
|
|
1549
|
-
votes:
|
|
1559
|
+
votes: integer10("votes").notNull().default(0),
|
|
1550
1560
|
deletedAt: timestamp55("deleted_at"),
|
|
1551
1561
|
createdAt: timestamp55("created_at").notNull().defaultNow(),
|
|
1552
1562
|
updatedAt: timestamp55("updated_at").notNull().defaultNow()
|
|
1553
1563
|
},
|
|
1554
|
-
(table) => [
|
|
1564
|
+
(table) => [uniqueIndex5("projects_type_name_unique").on(table.type, table.name)]
|
|
1555
1565
|
);
|
|
1556
1566
|
|
|
1557
1567
|
// voting/project-vote.schema.ts
|
|
1558
|
-
import { index as index38, pgTable as pgTable57, text as text55, timestamp as timestamp56, uniqueIndex as
|
|
1568
|
+
import { index as index38, pgTable as pgTable57, text as text55, timestamp as timestamp56, uniqueIndex as uniqueIndex6 } from "drizzle-orm/pg-core";
|
|
1559
1569
|
var projectVotes = pgTable57(
|
|
1560
1570
|
"project_votes",
|
|
1561
1571
|
{
|
|
@@ -1566,7 +1576,7 @@ var projectVotes = pgTable57(
|
|
|
1566
1576
|
createdAt: timestamp56("created_at").notNull().defaultNow()
|
|
1567
1577
|
},
|
|
1568
1578
|
(table) => [
|
|
1569
|
-
|
|
1579
|
+
uniqueIndex6("project_votes_user_project_unique").on(table.userId, table.projectId),
|
|
1570
1580
|
index38("project_votes_user_type_idx").on(table.userId, table.type),
|
|
1571
1581
|
index38("project_votes_project_idx").on(table.projectId)
|
|
1572
1582
|
]
|
|
@@ -1593,14 +1603,14 @@ var exhibitors = pgTable58(
|
|
|
1593
1603
|
);
|
|
1594
1604
|
|
|
1595
1605
|
// booth/main-event-booth-reward.schema.ts
|
|
1596
|
-
import { index as index40, integer as
|
|
1606
|
+
import { index as index40, integer as integer11, pgTable as pgTable59, text as text57, timestamp as timestamp58 } from "drizzle-orm/pg-core";
|
|
1597
1607
|
var mainEventBoothRewards = pgTable59(
|
|
1598
1608
|
"main_event_booth_rewards",
|
|
1599
1609
|
{
|
|
1600
1610
|
id: text57("id").primaryKey(),
|
|
1601
1611
|
companyName: text57("company_name").notNull(),
|
|
1602
1612
|
description: text57("description").notNull(),
|
|
1603
|
-
points:
|
|
1613
|
+
points: integer11("points").notNull(),
|
|
1604
1614
|
type: boothRewardTypeEnum("type").notNull(),
|
|
1605
1615
|
createdAt: timestamp58("created_at").notNull().defaultNow(),
|
|
1606
1616
|
updatedAt: timestamp58("updated_at").notNull().defaultNow()
|
|
@@ -1612,13 +1622,13 @@ var mainEventBoothRewards = pgTable59(
|
|
|
1612
1622
|
);
|
|
1613
1623
|
|
|
1614
1624
|
// supermarket/supermarket-item.schema.ts
|
|
1615
|
-
import { decimal, integer as
|
|
1625
|
+
import { decimal, integer as integer12, pgTable as pgTable60, text as text58, timestamp as timestamp59 } from "drizzle-orm/pg-core";
|
|
1616
1626
|
var supermarketItems = pgTable60("supermarket_items", {
|
|
1617
1627
|
id: text58("id").primaryKey(),
|
|
1618
1628
|
name: text58("name").notNull(),
|
|
1619
1629
|
description: text58("description"),
|
|
1620
1630
|
price: decimal("price", { precision: 10, scale: 2 }).notNull(),
|
|
1621
|
-
stock:
|
|
1631
|
+
stock: integer12("stock").notNull().default(0),
|
|
1622
1632
|
category: text58("category").notNull(),
|
|
1623
1633
|
imageUrl: text58("image_url"),
|
|
1624
1634
|
deletedAt: timestamp59("deleted_at"),
|
|
@@ -1653,12 +1663,12 @@ import { decimal as decimal2, pgTable as pgTable63, text as text61, timestamp as
|
|
|
1653
1663
|
|
|
1654
1664
|
// supermarket/supermarket-user-cart-item.schema.ts
|
|
1655
1665
|
import { relations as relations45 } from "drizzle-orm";
|
|
1656
|
-
import { integer as
|
|
1666
|
+
import { integer as integer13, json as json3, pgTable as pgTable62, text as text60, timestamp as timestamp61 } from "drizzle-orm/pg-core";
|
|
1657
1667
|
var supermarketUserCartItems = pgTable62("supermarket_user_cart_items", {
|
|
1658
1668
|
id: text60("id").primaryKey(),
|
|
1659
1669
|
cartId: text60("cart_id").notNull().references(() => supermarketUserCarts.id, { onDelete: "cascade" }),
|
|
1660
1670
|
itemId: text60("item_id").notNull().references(() => supermarketItems.id, { onDelete: "cascade" }),
|
|
1661
|
-
quantity:
|
|
1671
|
+
quantity: integer13("quantity").notNull().default(1),
|
|
1662
1672
|
selectedOptions: json3("selected_options"),
|
|
1663
1673
|
// JSON to store selected option key-value pairs
|
|
1664
1674
|
deletedAt: timestamp61("deleted_at"),
|
|
@@ -1718,14 +1728,14 @@ var exploreITFunfacts = pgTable65("explore_it_funfacts", {
|
|
|
1718
1728
|
});
|
|
1719
1729
|
|
|
1720
1730
|
// notifications/dashboard-notification.schema.ts
|
|
1721
|
-
import { boolean as
|
|
1731
|
+
import { boolean as boolean19, index as index41, pgTable as pgTable66, text as text64, timestamp as timestamp65 } from "drizzle-orm/pg-core";
|
|
1722
1732
|
var dashboardNotifications = pgTable66(
|
|
1723
1733
|
"dashboard_notifications",
|
|
1724
1734
|
{
|
|
1725
1735
|
id: text64("id").primaryKey(),
|
|
1726
1736
|
title: text64("title").notNull(),
|
|
1727
1737
|
content: text64("content").notNull(),
|
|
1728
|
-
isPrivate:
|
|
1738
|
+
isPrivate: boolean19("is_private").notNull().default(false),
|
|
1729
1739
|
type: text64("type").notNull(),
|
|
1730
1740
|
programCode: programCodeEnum("program_code"),
|
|
1731
1741
|
deletedAt: timestamp65("deleted_at"),
|
|
@@ -1737,14 +1747,14 @@ var dashboardNotifications = pgTable66(
|
|
|
1737
1747
|
|
|
1738
1748
|
// notifications/dashboard-notification-user-read.schema.ts
|
|
1739
1749
|
import { relations as relations47 } from "drizzle-orm";
|
|
1740
|
-
import { boolean as
|
|
1750
|
+
import { boolean as boolean20, index as index42, pgTable as pgTable67, text as text65, timestamp as timestamp66 } from "drizzle-orm/pg-core";
|
|
1741
1751
|
var dashboardNotificationUserReads = pgTable67(
|
|
1742
1752
|
"dashboard_notification_user_reads",
|
|
1743
1753
|
{
|
|
1744
1754
|
id: text65("id").primaryKey(),
|
|
1745
1755
|
userId: text65("user_id").notNull().references(() => users.id, { onDelete: "cascade" }),
|
|
1746
1756
|
notificationId: text65("notification_id").notNull().references(() => dashboardNotifications.id, { onDelete: "cascade" }),
|
|
1747
|
-
isOpened:
|
|
1757
|
+
isOpened: boolean20("is_opened").notNull().default(false),
|
|
1748
1758
|
createdAt: timestamp66("created_at").notNull().defaultNow(),
|
|
1749
1759
|
updatedAt: timestamp66("updated_at").notNull().defaultNow()
|
|
1750
1760
|
},
|