@appcorp/fusion-storybook 0.2.13 → 0.2.15
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/base-modules/admission/context/use-admission-module.d.ts +88 -0
- package/base-modules/admission/context/use-admission-module.js +771 -0
- package/base-modules/admission/context.d.ts +1 -87
- package/base-modules/admission/context.js +3 -769
- package/base-modules/attendance/more-actions.js +7 -2
- package/base-modules/campus/more-actions.js +0 -1
- package/base-modules/class/more-actions.js +1 -6
- package/base-modules/enrollment/context.d.ts +1 -13
- package/base-modules/enrollment/context.js +0 -3
- package/base-modules/enrollment/form.js +2 -6
- package/base-modules/enrollment/page.d.ts +0 -1
- package/base-modules/enrollment/page.js +5 -13
- package/base-modules/enrollment/validate.d.ts +0 -1
- package/base-modules/enrollment/validate.js +0 -1
- package/base-modules/enrollment/view.js +4 -7
- package/base-modules/expense/more-actions.js +1 -6
- package/base-modules/fee-structure/more-actions.js +1 -6
- package/base-modules/student-fee/context/shared.d.ts +178 -0
- package/base-modules/student-fee/context/shared.js +59 -0
- package/base-modules/student-fee/context/use-student-fee-module.d.ts +64 -0
- package/base-modules/student-fee/context/use-student-fee-module.js +610 -0
- package/base-modules/student-fee/context.d.ts +21 -235
- package/base-modules/student-fee/context.js +2 -674
- package/base-modules/student-fee/more-actions.js +1 -6
- package/base-modules/student-profile/constants.js +7 -3
- package/base-modules/student-profile/context/module-base.d.ts +187 -0
- package/base-modules/student-profile/context/module-base.js +50 -0
- package/base-modules/student-profile/context/use-student-profile-module.d.ts +70 -0
- package/base-modules/student-profile/context/use-student-profile-module.js +506 -0
- package/base-modules/student-profile/context.d.ts +20 -256
- package/base-modules/student-profile/context.js +2 -601
- package/base-modules/teacher/avatar-upload.js +1 -4
- package/base-modules/teacher/more-actions.js +1 -6
- package/base-modules/user/context/use-user-module.d.ts +53 -0
- package/base-modules/user/context/use-user-module.js +546 -0
- package/base-modules/user/context.d.ts +1 -52
- package/base-modules/user/context.js +5 -547
- package/base-modules/workspace-user/more-actions.js +1 -6
- package/components/module-error.d.ts +9 -0
- package/components/module-error.js +3 -0
- package/package.json +5 -4
- package/tsconfig.build.tsbuildinfo +1 -1
- package/type.d.ts +3 -1242
- package/type.js +3 -445
- package/types/academics.d.ts +262 -0
- package/types/academics.js +8 -0
- package/types/admission.d.ts +85 -0
- package/types/admission.js +6 -0
- package/types/communication.d.ts +165 -0
- package/types/communication.js +7 -0
- package/types/enums.d.ts +411 -0
- package/types/enums.js +442 -0
- package/types/finance.d.ts +126 -0
- package/types/finance.js +7 -0
- package/types/index.d.ts +12 -0
- package/types/index.js +12 -0
- package/types/user-management.d.ts +236 -0
- package/types/user-management.js +7 -0
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TypeScript Types Generated from Prisma Schema - Academics
|
|
3
|
+
*
|
|
4
|
+
* This file contains TypeScript interfaces for class, section, subject, course,
|
|
5
|
+
* teacher, enrollment, attendance, grade, schedule, student profile, family,
|
|
6
|
+
* and family member domain models.
|
|
7
|
+
*/
|
|
8
|
+
import { GENDER, FAMILY_MEMBER_ROLE, STUDENT_STATUS, ATTENDANCE_STATUS, GRADE_TYPE, DAY_OF_WEEK } from "./enums";
|
|
9
|
+
import type { SchoolBE, CampusBE, UserBE } from "./user-management";
|
|
10
|
+
import type { FeeStructureBE, StudentFeeBE } from "./finance";
|
|
11
|
+
/**
|
|
12
|
+
* Family represents a household sharing a single user account
|
|
13
|
+
* Contains parents and students using the same login credentials
|
|
14
|
+
*/
|
|
15
|
+
export interface FamilyBE {
|
|
16
|
+
address: string | null;
|
|
17
|
+
city: string | null;
|
|
18
|
+
country: string | null;
|
|
19
|
+
createdAt: string;
|
|
20
|
+
enabled: boolean;
|
|
21
|
+
familyCode: string;
|
|
22
|
+
id: string;
|
|
23
|
+
postalCode: string | null;
|
|
24
|
+
schoolId: string;
|
|
25
|
+
state: string | null;
|
|
26
|
+
updatedAt: string;
|
|
27
|
+
members?: FamilyMemberBE[];
|
|
28
|
+
school?: SchoolBE;
|
|
29
|
+
studentFees?: StudentFeeBE[];
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* FamilyMember represents individuals within a family
|
|
33
|
+
* Multiple members (parents + students) share the family's user account
|
|
34
|
+
*/
|
|
35
|
+
export interface FamilyMemberBE {
|
|
36
|
+
avatar: string | null;
|
|
37
|
+
bloodGroup: string | null;
|
|
38
|
+
createdAt: string;
|
|
39
|
+
dateOfBirth: Date | string | null;
|
|
40
|
+
email: string | null;
|
|
41
|
+
emergencyPhone: string | null;
|
|
42
|
+
enabled: boolean;
|
|
43
|
+
familyId: string;
|
|
44
|
+
firstName: string;
|
|
45
|
+
gender: GENDER;
|
|
46
|
+
id: string;
|
|
47
|
+
idNumber: string;
|
|
48
|
+
isPrimary: boolean;
|
|
49
|
+
lastName: string;
|
|
50
|
+
occupation: string | null;
|
|
51
|
+
organization: string | null;
|
|
52
|
+
phone: string | null;
|
|
53
|
+
relationship: string;
|
|
54
|
+
role: FAMILY_MEMBER_ROLE;
|
|
55
|
+
updatedAt: string;
|
|
56
|
+
family?: FamilyBE;
|
|
57
|
+
studentProfile?: StudentProfileBE;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* StudentProfile extends FamilyMember with student-specific data
|
|
61
|
+
*/
|
|
62
|
+
export interface StudentProfileBE {
|
|
63
|
+
campusId: string | null;
|
|
64
|
+
computerNumber: number;
|
|
65
|
+
createdAt: string;
|
|
66
|
+
discountCode: string | null;
|
|
67
|
+
enabled: boolean;
|
|
68
|
+
familyMemberId: string;
|
|
69
|
+
hafiz: boolean;
|
|
70
|
+
id: string;
|
|
71
|
+
notes: string | null;
|
|
72
|
+
orphan: boolean;
|
|
73
|
+
previousSchool: string | null;
|
|
74
|
+
remarks: string | null;
|
|
75
|
+
status: STUDENT_STATUS;
|
|
76
|
+
studentCode: string;
|
|
77
|
+
updatedAt: string;
|
|
78
|
+
attendances?: AttendanceBE[];
|
|
79
|
+
campus?: CampusBE;
|
|
80
|
+
enrollments?: EnrollmentBE[];
|
|
81
|
+
familyMember?: FamilyMemberBE;
|
|
82
|
+
grades?: GradeBE[];
|
|
83
|
+
studentFees?: StudentFeeBE[];
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* Class represents grade levels (e.g., Grade 1, Grade 2, Grade 10)
|
|
87
|
+
*/
|
|
88
|
+
export interface ClassBE {
|
|
89
|
+
campusId: string | null;
|
|
90
|
+
code: string;
|
|
91
|
+
createdAt: string;
|
|
92
|
+
description: string | null;
|
|
93
|
+
enabled: boolean;
|
|
94
|
+
id: string;
|
|
95
|
+
name: string;
|
|
96
|
+
schoolId: string;
|
|
97
|
+
updatedAt: string;
|
|
98
|
+
campus?: CampusBE;
|
|
99
|
+
feeStructures?: FeeStructureBE[];
|
|
100
|
+
school?: SchoolBE;
|
|
101
|
+
sections?: SectionBE[];
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Section represents class divisions (e.g., Grade 1-A, Grade 1-B)
|
|
105
|
+
*/
|
|
106
|
+
export interface SectionBE {
|
|
107
|
+
capacity: number | null;
|
|
108
|
+
classId: string;
|
|
109
|
+
createdAt: string;
|
|
110
|
+
enabled: boolean;
|
|
111
|
+
id: string;
|
|
112
|
+
name: string;
|
|
113
|
+
schoolId: string;
|
|
114
|
+
updatedAt: string;
|
|
115
|
+
class?: ClassBE;
|
|
116
|
+
courses?: CourseBE[];
|
|
117
|
+
enrollments?: EnrollmentBE[];
|
|
118
|
+
school?: SchoolBE;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Subject represents academic subjects (e.g., Mathematics, English, Science)
|
|
122
|
+
*/
|
|
123
|
+
export interface SubjectBE {
|
|
124
|
+
code: string;
|
|
125
|
+
createdAt: string;
|
|
126
|
+
description: string | null;
|
|
127
|
+
enabled: boolean;
|
|
128
|
+
id: string;
|
|
129
|
+
name: string;
|
|
130
|
+
schoolId: string;
|
|
131
|
+
updatedAt: string;
|
|
132
|
+
courses?: CourseBE[];
|
|
133
|
+
school?: SchoolBE;
|
|
134
|
+
}
|
|
135
|
+
/**
|
|
136
|
+
* Course represents a subject taught in a specific section by a teacher
|
|
137
|
+
*/
|
|
138
|
+
export interface CourseBE {
|
|
139
|
+
code: string;
|
|
140
|
+
createdAt: string;
|
|
141
|
+
enabled: boolean;
|
|
142
|
+
id: string;
|
|
143
|
+
schoolId: string;
|
|
144
|
+
sectionId: string;
|
|
145
|
+
subjectId: string;
|
|
146
|
+
teacherId: string;
|
|
147
|
+
updatedAt: Date;
|
|
148
|
+
grades?: GradeBE[];
|
|
149
|
+
schedules?: ScheduleBE[];
|
|
150
|
+
school?: SchoolBE;
|
|
151
|
+
section?: SectionBE;
|
|
152
|
+
subject?: SubjectBE;
|
|
153
|
+
teacher?: TeacherBE;
|
|
154
|
+
}
|
|
155
|
+
/**
|
|
156
|
+
* Teacher represents teaching staff
|
|
157
|
+
*/
|
|
158
|
+
export interface TeacherBE {
|
|
159
|
+
address: string | null;
|
|
160
|
+
avatar: string | null;
|
|
161
|
+
bio: string | null;
|
|
162
|
+
campusId: string | null;
|
|
163
|
+
city: string | null;
|
|
164
|
+
country: string | null;
|
|
165
|
+
createdAt: string;
|
|
166
|
+
dateOfBirth: Date | string | null;
|
|
167
|
+
emergencyPhone: string | null;
|
|
168
|
+
enabled: boolean;
|
|
169
|
+
experience: number | null;
|
|
170
|
+
firstName: string;
|
|
171
|
+
gender: GENDER | null;
|
|
172
|
+
id: string;
|
|
173
|
+
joiningDate: Date | string;
|
|
174
|
+
lastName: string;
|
|
175
|
+
phone: string | null;
|
|
176
|
+
postalCode: string | null;
|
|
177
|
+
qualification: string | null;
|
|
178
|
+
schoolId: string;
|
|
179
|
+
specialization: string | null;
|
|
180
|
+
state: string | null;
|
|
181
|
+
teacherCode: string;
|
|
182
|
+
updatedAt: Date;
|
|
183
|
+
userId: string | null;
|
|
184
|
+
campus?: CampusBE;
|
|
185
|
+
courses?: CourseBE[];
|
|
186
|
+
school?: SchoolBE;
|
|
187
|
+
user?: UserBE | null;
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Enrollment represents a student enrolled in a section.
|
|
191
|
+
* All courses taught in that section are implied.
|
|
192
|
+
*/
|
|
193
|
+
export interface EnrollmentBE {
|
|
194
|
+
createdAt: string;
|
|
195
|
+
enabled: boolean;
|
|
196
|
+
enrollmentDate: Date | string;
|
|
197
|
+
id: string;
|
|
198
|
+
sectionId: string;
|
|
199
|
+
studentProfileId: string;
|
|
200
|
+
updatedAt: string;
|
|
201
|
+
grades?: GradeBE[];
|
|
202
|
+
section?: SectionBE;
|
|
203
|
+
studentProfile?: StudentProfileBE;
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* Attendance tracks daily student presence in courses
|
|
207
|
+
*/
|
|
208
|
+
export interface AttendanceBE {
|
|
209
|
+
createdAt: string;
|
|
210
|
+
date: Date | string;
|
|
211
|
+
enabled: boolean;
|
|
212
|
+
id: string;
|
|
213
|
+
remarks: string | null;
|
|
214
|
+
schoolId: string;
|
|
215
|
+
status: ATTENDANCE_STATUS;
|
|
216
|
+
studentProfileId: string;
|
|
217
|
+
updatedAt: string;
|
|
218
|
+
school?: SchoolBE;
|
|
219
|
+
studentProfile?: StudentProfileBE;
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* Grade represents student assessment results
|
|
223
|
+
*/
|
|
224
|
+
export interface GradeBE {
|
|
225
|
+
assessmentDate: Date | string;
|
|
226
|
+
courseId: string;
|
|
227
|
+
createdAt: Date;
|
|
228
|
+
enabled: boolean;
|
|
229
|
+
enrollmentId: string;
|
|
230
|
+
grade: string | null;
|
|
231
|
+
gradeType: GRADE_TYPE;
|
|
232
|
+
id: string;
|
|
233
|
+
marksObtained: number;
|
|
234
|
+
maxMarks: number;
|
|
235
|
+
percentage: number | null;
|
|
236
|
+
remarks: string | null;
|
|
237
|
+
schoolId: string;
|
|
238
|
+
studentProfileId: string;
|
|
239
|
+
title: string;
|
|
240
|
+
updatedAt: Date;
|
|
241
|
+
course?: CourseBE;
|
|
242
|
+
enrollment?: EnrollmentBE;
|
|
243
|
+
school?: SchoolBE;
|
|
244
|
+
studentProfile?: StudentProfileBE;
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* Schedule represents class timetable
|
|
248
|
+
*/
|
|
249
|
+
export interface ScheduleBE {
|
|
250
|
+
courseId: string;
|
|
251
|
+
createdAt: string;
|
|
252
|
+
dayOfWeek: DAY_OF_WEEK;
|
|
253
|
+
enabled: boolean;
|
|
254
|
+
endTime: string;
|
|
255
|
+
id: string;
|
|
256
|
+
room: string | null;
|
|
257
|
+
schoolId: string;
|
|
258
|
+
startTime: string;
|
|
259
|
+
updatedAt: string;
|
|
260
|
+
course?: CourseBE;
|
|
261
|
+
school?: SchoolBE;
|
|
262
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TypeScript Types Generated from Prisma Schema - Academics
|
|
3
|
+
*
|
|
4
|
+
* This file contains TypeScript interfaces for class, section, subject, course,
|
|
5
|
+
* teacher, enrollment, attendance, grade, schedule, student profile, family,
|
|
6
|
+
* and family member domain models.
|
|
7
|
+
*/
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TypeScript Types Generated from Prisma Schema - Admission
|
|
3
|
+
*
|
|
4
|
+
* This file contains TypeScript interfaces for the admission domain models.
|
|
5
|
+
*/
|
|
6
|
+
import { GENDER, ADMISSION_STATUS } from "./enums";
|
|
7
|
+
import type { SchoolBE } from "./user-management";
|
|
8
|
+
export interface AdmissionDetails {
|
|
9
|
+
classForAdmission: string;
|
|
10
|
+
previousSchool: string;
|
|
11
|
+
siblings: string;
|
|
12
|
+
}
|
|
13
|
+
export interface FatherDetails {
|
|
14
|
+
fatherIdNumber: string;
|
|
15
|
+
fatherFirstName: string;
|
|
16
|
+
fatherLastName: string;
|
|
17
|
+
fatherMobile: string;
|
|
18
|
+
fatherOccupation: string;
|
|
19
|
+
fatherOrganization: string;
|
|
20
|
+
emergencyContact: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface MotherDetails {
|
|
23
|
+
motherIdNumber: string;
|
|
24
|
+
motherFirstName: string;
|
|
25
|
+
motherLastName: string;
|
|
26
|
+
motherMobile: string;
|
|
27
|
+
emergencyContact: boolean;
|
|
28
|
+
}
|
|
29
|
+
export interface HomeDetails {
|
|
30
|
+
address: string;
|
|
31
|
+
city: string;
|
|
32
|
+
country: string;
|
|
33
|
+
postalCode: string;
|
|
34
|
+
state: string;
|
|
35
|
+
}
|
|
36
|
+
export interface StudentDetails {
|
|
37
|
+
studentIdNumber: string;
|
|
38
|
+
discountCode: string;
|
|
39
|
+
dob: string;
|
|
40
|
+
emergencyContact: string;
|
|
41
|
+
firstName: string;
|
|
42
|
+
gender: GENDER;
|
|
43
|
+
hafiz: boolean;
|
|
44
|
+
lastName: string;
|
|
45
|
+
orphan: boolean;
|
|
46
|
+
registrationCode: string;
|
|
47
|
+
}
|
|
48
|
+
export interface OfficeUse {
|
|
49
|
+
admissionNotes: string;
|
|
50
|
+
notes: string;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* StudentAdmission stores raw application payloads as JSON blobs.
|
|
54
|
+
* This model mirrors the Prisma StudentAdmission model which keeps
|
|
55
|
+
* structured form data in Json columns so the application layer can
|
|
56
|
+
* process/transform it into domain entities on approval.
|
|
57
|
+
*/
|
|
58
|
+
export interface AdmissionAIBE {
|
|
59
|
+
id: string;
|
|
60
|
+
admissionId: string;
|
|
61
|
+
schoolId: string;
|
|
62
|
+
score: number;
|
|
63
|
+
decision: string;
|
|
64
|
+
reasons: string[];
|
|
65
|
+
confidence: number;
|
|
66
|
+
processedAt: string;
|
|
67
|
+
createdAt: string;
|
|
68
|
+
updatedAt: string;
|
|
69
|
+
}
|
|
70
|
+
export interface AdmissionBE {
|
|
71
|
+
admissionDetails: AdmissionDetails | null;
|
|
72
|
+
createdAt: string;
|
|
73
|
+
enabled: boolean;
|
|
74
|
+
fatherDetails: FatherDetails | null;
|
|
75
|
+
homeDetails: HomeDetails | null;
|
|
76
|
+
id: string;
|
|
77
|
+
motherDetails: MotherDetails | null;
|
|
78
|
+
officeUse: OfficeUse | null;
|
|
79
|
+
schoolId: string;
|
|
80
|
+
status: ADMISSION_STATUS;
|
|
81
|
+
studentDetails: StudentDetails | null;
|
|
82
|
+
updatedAt: string;
|
|
83
|
+
school?: SchoolBE;
|
|
84
|
+
aiAnalysis?: AdmissionAIBE | null;
|
|
85
|
+
}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TypeScript Types Generated from Prisma Schema - Communication
|
|
3
|
+
*
|
|
4
|
+
* This file contains TypeScript interfaces for campaigns, blog posts,
|
|
5
|
+
* referrals, push tokens, mobile notifications, and notification preferences.
|
|
6
|
+
*/
|
|
7
|
+
import { CAMPAIGN_STATUS, CAMPAIGN_CONTACT_STATUS, DEVICE_PLATFORM, NOTIFICATION_TYPE, REFERRAL_CHANNEL, REFERRAL_STATUS } from "./enums";
|
|
8
|
+
import type { SchoolBE, UserBE } from "./user-management";
|
|
9
|
+
/**
|
|
10
|
+
* Individual recipient within a broadcast campaign
|
|
11
|
+
*/
|
|
12
|
+
export interface CampaignContactBE {
|
|
13
|
+
campaignId: string;
|
|
14
|
+
createdAt: string;
|
|
15
|
+
errorMessage: string | null;
|
|
16
|
+
id: string;
|
|
17
|
+
name: string;
|
|
18
|
+
phoneNumber: string;
|
|
19
|
+
sentAt: string | null;
|
|
20
|
+
status: CAMPAIGN_CONTACT_STATUS;
|
|
21
|
+
updatedAt: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* WhatsApp broadcast campaign
|
|
25
|
+
*/
|
|
26
|
+
export interface CampaignBE {
|
|
27
|
+
createdAt: string;
|
|
28
|
+
enabled: boolean;
|
|
29
|
+
id: string;
|
|
30
|
+
messageTemplate: string;
|
|
31
|
+
name: string;
|
|
32
|
+
schoolId: string;
|
|
33
|
+
status: CAMPAIGN_STATUS;
|
|
34
|
+
updatedAt: string;
|
|
35
|
+
workerJobId: string | null;
|
|
36
|
+
contacts?: CampaignContactBE[];
|
|
37
|
+
_count?: {
|
|
38
|
+
contacts: number;
|
|
39
|
+
};
|
|
40
|
+
school?: SchoolBE;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* BlogPost metadata and content (MDX/Markdown stored in `content`).
|
|
44
|
+
*/
|
|
45
|
+
export interface BlogPostBE {
|
|
46
|
+
authorId: string | null;
|
|
47
|
+
clapCount: number;
|
|
48
|
+
commentCount: number;
|
|
49
|
+
content: string;
|
|
50
|
+
createdAt: string;
|
|
51
|
+
enabled: boolean;
|
|
52
|
+
excerpt: string | null;
|
|
53
|
+
id: string;
|
|
54
|
+
publishedAt: Date | string | null;
|
|
55
|
+
schoolId: string | null;
|
|
56
|
+
slug: string;
|
|
57
|
+
title: string;
|
|
58
|
+
updatedAt: string;
|
|
59
|
+
author?: UserBE;
|
|
60
|
+
claps?: BlogPostClapBE[];
|
|
61
|
+
comments?: BlogCommentBE[];
|
|
62
|
+
school?: SchoolBE | null;
|
|
63
|
+
}
|
|
64
|
+
export interface BlogCommentBE {
|
|
65
|
+
authorId: string | null;
|
|
66
|
+
clapCount: number;
|
|
67
|
+
content: string;
|
|
68
|
+
createdAt: string;
|
|
69
|
+
enabled: boolean;
|
|
70
|
+
id: string;
|
|
71
|
+
parentId: string | null;
|
|
72
|
+
postId: string;
|
|
73
|
+
updatedAt: string;
|
|
74
|
+
author?: UserBE | null;
|
|
75
|
+
claps?: BlogCommentClapBE[];
|
|
76
|
+
parent?: BlogCommentBE | null;
|
|
77
|
+
post?: BlogPostBE;
|
|
78
|
+
replies?: BlogCommentBE[];
|
|
79
|
+
}
|
|
80
|
+
export interface BlogPostClapBE {
|
|
81
|
+
createdAt: string;
|
|
82
|
+
id: string;
|
|
83
|
+
postId: string;
|
|
84
|
+
sessionId: string | null;
|
|
85
|
+
userId: string | null;
|
|
86
|
+
post?: BlogPostBE;
|
|
87
|
+
user?: UserBE | null;
|
|
88
|
+
}
|
|
89
|
+
export interface BlogCommentClapBE {
|
|
90
|
+
commentId: string;
|
|
91
|
+
createdAt: string;
|
|
92
|
+
id: string;
|
|
93
|
+
sessionId: string | null;
|
|
94
|
+
userId: string | null;
|
|
95
|
+
comment?: BlogCommentBE;
|
|
96
|
+
user?: UserBE | null;
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* A referral invite sent by a school user to encourage another school to join the platform
|
|
100
|
+
*/
|
|
101
|
+
export interface ReferralBE {
|
|
102
|
+
channel: REFERRAL_CHANNEL;
|
|
103
|
+
createdAt: string;
|
|
104
|
+
enabled: boolean;
|
|
105
|
+
errorMessage: string | null;
|
|
106
|
+
id: string;
|
|
107
|
+
inviterUserId: string;
|
|
108
|
+
personalNote: string | null;
|
|
109
|
+
recipientEmail: string | null;
|
|
110
|
+
recipientName: string | null;
|
|
111
|
+
recipientPhone: string | null;
|
|
112
|
+
schoolId: string;
|
|
113
|
+
sentAt: string | null;
|
|
114
|
+
status: REFERRAL_STATUS;
|
|
115
|
+
updatedAt: string;
|
|
116
|
+
workerJobId: string | null;
|
|
117
|
+
school?: SchoolBE;
|
|
118
|
+
}
|
|
119
|
+
/**
|
|
120
|
+
* Expo push token registered by a mobile device for a specific user
|
|
121
|
+
*/
|
|
122
|
+
export interface UserPushTokenBE {
|
|
123
|
+
appVersion: string | null;
|
|
124
|
+
createdAt: string;
|
|
125
|
+
deviceId: string | null;
|
|
126
|
+
id: string;
|
|
127
|
+
platform: DEVICE_PLATFORM;
|
|
128
|
+
pushToken: string;
|
|
129
|
+
updatedAt: string;
|
|
130
|
+
userId: string;
|
|
131
|
+
user?: UserBE;
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Push notification delivered to a mobile user
|
|
135
|
+
*/
|
|
136
|
+
export interface MobileNotificationBE {
|
|
137
|
+
archived: boolean;
|
|
138
|
+
body: string;
|
|
139
|
+
createdAt: string;
|
|
140
|
+
data: Record<string, unknown> | null;
|
|
141
|
+
id: string;
|
|
142
|
+
read: boolean;
|
|
143
|
+
title: string;
|
|
144
|
+
type: NOTIFICATION_TYPE;
|
|
145
|
+
updatedAt: string;
|
|
146
|
+
userId: string;
|
|
147
|
+
user?: UserBE;
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Per-user notification category and channel preferences
|
|
151
|
+
*/
|
|
152
|
+
export interface NotificationPreferenceBE {
|
|
153
|
+
alertEnabled: boolean;
|
|
154
|
+
assignmentEnabled: boolean;
|
|
155
|
+
attendanceEnabled: boolean;
|
|
156
|
+
createdAt: string;
|
|
157
|
+
emailEnabled: boolean;
|
|
158
|
+
generalEnabled: boolean;
|
|
159
|
+
id: string;
|
|
160
|
+
paymentEnabled: boolean;
|
|
161
|
+
pushEnabled: boolean;
|
|
162
|
+
updatedAt: string;
|
|
163
|
+
userId: string;
|
|
164
|
+
user?: UserBE;
|
|
165
|
+
}
|