@universis/accommodation 1.0.0

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.
Files changed (134) hide show
  1. package/.gitlab-ci.yml +23 -0
  2. package/LICENSE +163 -0
  3. package/README.md +3 -0
  4. package/dist/AccommodationSchemaLoader.js +35 -0
  5. package/dist/AccommodationSchemaLoader.js.map +1 -0
  6. package/dist/AccommodationService.js +68 -0
  7. package/dist/AccommodationService.js.map +1 -0
  8. package/dist/DepartmentReplacer.js +54 -0
  9. package/dist/DepartmentReplacer.js.map +1 -0
  10. package/dist/StudentReplacer.js +75 -0
  11. package/dist/StudentReplacer.js.map +1 -0
  12. package/dist/config/models/Accommodation.json +96 -0
  13. package/dist/config/models/AccommodationCardEffectiveStatusType.json +107 -0
  14. package/dist/config/models/AccommodationCardEffectiveStatusTypeLocale.json +85 -0
  15. package/dist/config/models/AccommodationChildFinancialAttribute.json +46 -0
  16. package/dist/config/models/AccommodationGuardianFinancialAttribute.json +46 -0
  17. package/dist/config/models/AccommodationInscriptionModeTag.json +100 -0
  18. package/dist/config/models/AccommodationRequestAction.json +500 -0
  19. package/dist/config/models/AccommodationRequestActionMessage.json +46 -0
  20. package/dist/config/models/AccommodationRequestActionReview.json +31 -0
  21. package/dist/config/models/AccommodationRequestAttachmentConfiguration.json +72 -0
  22. package/dist/config/models/AccommodationRequestCategory.json +50 -0
  23. package/dist/config/models/AccommodationRequestEffectiveStatusType.json +212 -0
  24. package/dist/config/models/AccommodationRequestEffectiveStatusTypeLocale.json +85 -0
  25. package/dist/config/models/AccommodationRequestEvent.json +117 -0
  26. package/dist/config/models/AccommodationRequestFinancialAttribute.json +53 -0
  27. package/dist/config/models/AccommodationRoom.json +151 -0
  28. package/dist/config/models/AccommodationSiblingFinancialAttribute.json +57 -0
  29. package/dist/config/models/CancelAccommodationCardAction.json +32 -0
  30. package/dist/config/models/GuardianType.json +78 -0
  31. package/dist/config/models/Review.json +50 -0
  32. package/dist/config/models/RoomType.json +320 -0
  33. package/dist/config/models/RoomTypeLocale.json +86 -0
  34. package/dist/config/models/StudentAccommodationCard.json +158 -0
  35. package/dist/config/models/TestAction.json +50 -0
  36. package/dist/config/scope.access.js +148 -0
  37. package/dist/config/scope.access.js.map +1 -0
  38. package/dist/index.d.ts +2 -0
  39. package/dist/index.js +3 -0
  40. package/dist/index.js.map +1 -0
  41. package/dist/listeners/AddDefaultAttachmentConfiguration.js +44 -0
  42. package/dist/listeners/AddDefaultAttachmentConfiguration.js.map +1 -0
  43. package/dist/listeners/DefaultAttachmentConfigurations.json +277 -0
  44. package/dist/listeners/DefaultAttachmentTypes.json +523 -0
  45. package/dist/listeners/GenerateRequestNumberListener.js +87 -0
  46. package/dist/listeners/GenerateRequestNumberListener.js.map +1 -0
  47. package/dist/listeners/OnActionCompleteListener.js +96 -0
  48. package/dist/listeners/OnActionCompleteListener.js.map +1 -0
  49. package/dist/listeners/OnCancelAccommodationCardListener.js +87 -0
  50. package/dist/listeners/OnCancelAccommodationCardListener.js.map +1 -0
  51. package/dist/listeners/OnReactivateAccommodationCardListener.js +87 -0
  52. package/dist/listeners/OnReactivateAccommodationCardListener.js.map +1 -0
  53. package/dist/listeners/SendEmailAfterActionStatusChangeListener.js +98 -0
  54. package/dist/listeners/SendEmailAfterActionStatusChangeListener.js.map +1 -0
  55. package/dist/listeners/SendEmailAfterCardStatusChangeListener.js +139 -0
  56. package/dist/listeners/SendEmailAfterCardStatusChangeListener.js.map +1 -0
  57. package/dist/listeners/StudentAccommodationCardSaveListener.js +90 -0
  58. package/dist/listeners/StudentAccommodationCardSaveListener.js.map +1 -0
  59. package/dist/listeners/UpdateStudentAccommodationCardListener.js +70 -0
  60. package/dist/listeners/UpdateStudentAccommodationCardListener.js.map +1 -0
  61. package/dist/listeners/ValidateActionListener.js +348 -0
  62. package/dist/listeners/ValidateActionListener.js.map +1 -0
  63. package/dist/listeners/data-localization.js +209 -0
  64. package/dist/listeners/data-localization.js.map +1 -0
  65. package/dist/listeners/lookup-cache-listener.js +90 -0
  66. package/dist/listeners/lookup-cache-listener.js.map +1 -0
  67. package/dist/models/Accommodation.js +53 -0
  68. package/dist/models/Accommodation.js.map +1 -0
  69. package/dist/models/AccommodationRequestAction.js +214 -0
  70. package/dist/models/AccommodationRequestAction.js.map +1 -0
  71. package/dist/models/AccommodationRequestEvent.js +277 -0
  72. package/dist/models/AccommodationRequestEvent.js.map +1 -0
  73. package/dist/models/EnableAttachmentModel.js +210 -0
  74. package/dist/models/EnableAttachmentModel.js.map +1 -0
  75. package/dist/models/StudentAccommodationCard.js +93 -0
  76. package/dist/models/StudentAccommodationCard.js.map +1 -0
  77. package/dist/models/TestAction.d.ts +5 -0
  78. package/dist/models/TestAction.js +5 -0
  79. package/dist/models/TestAction.js.map +1 -0
  80. package/dist/templates/mail-after-dining-request-status-change/html.ejs +27 -0
  81. package/package.json +57 -0
  82. package/src/AccommodationSchemaLoader.js +35 -0
  83. package/src/AccommodationService.js +67 -0
  84. package/src/DepartmentReplacer.js +53 -0
  85. package/src/StudentReplacer.js +74 -0
  86. package/src/config/models/Accommodation.json +96 -0
  87. package/src/config/models/AccommodationCardEffectiveStatusType.json +107 -0
  88. package/src/config/models/AccommodationCardEffectiveStatusTypeLocale.json +85 -0
  89. package/src/config/models/AccommodationChildFinancialAttribute.json +46 -0
  90. package/src/config/models/AccommodationGuardianFinancialAttribute.json +46 -0
  91. package/src/config/models/AccommodationInscriptionModeTag.json +100 -0
  92. package/src/config/models/AccommodationRequestAction.json +500 -0
  93. package/src/config/models/AccommodationRequestActionMessage.json +46 -0
  94. package/src/config/models/AccommodationRequestActionReview.json +31 -0
  95. package/src/config/models/AccommodationRequestAttachmentConfiguration.json +72 -0
  96. package/src/config/models/AccommodationRequestCategory.json +50 -0
  97. package/src/config/models/AccommodationRequestEffectiveStatusType.json +212 -0
  98. package/src/config/models/AccommodationRequestEffectiveStatusTypeLocale.json +85 -0
  99. package/src/config/models/AccommodationRequestEvent.json +117 -0
  100. package/src/config/models/AccommodationRequestFinancialAttribute.json +53 -0
  101. package/src/config/models/AccommodationRoom.json +151 -0
  102. package/src/config/models/AccommodationSiblingFinancialAttribute.json +57 -0
  103. package/src/config/models/CancelAccommodationCardAction.json +32 -0
  104. package/src/config/models/GuardianType.json +78 -0
  105. package/src/config/models/Review.json +50 -0
  106. package/src/config/models/RoomType.json +320 -0
  107. package/src/config/models/RoomTypeLocale.json +86 -0
  108. package/src/config/models/StudentAccommodationCard.json +158 -0
  109. package/src/config/models/TestAction.json +50 -0
  110. package/src/config/scope.access.js +148 -0
  111. package/src/index.d.ts +2 -0
  112. package/src/index.js +2 -0
  113. package/src/listeners/AddDefaultAttachmentConfiguration.js +43 -0
  114. package/src/listeners/DefaultAttachmentConfigurations.json +277 -0
  115. package/src/listeners/DefaultAttachmentTypes.json +523 -0
  116. package/src/listeners/GenerateRequestNumberListener.js +86 -0
  117. package/src/listeners/OnActionCompleteListener.js +95 -0
  118. package/src/listeners/OnCancelAccommodationCardListener.js +86 -0
  119. package/src/listeners/OnReactivateAccommodationCardListener.js +86 -0
  120. package/src/listeners/SendEmailAfterActionStatusChangeListener.js +97 -0
  121. package/src/listeners/SendEmailAfterCardStatusChangeListener.js +138 -0
  122. package/src/listeners/StudentAccommodationCardSaveListener.js +89 -0
  123. package/src/listeners/UpdateStudentAccommodationCardListener.js +69 -0
  124. package/src/listeners/ValidateActionListener.js +347 -0
  125. package/src/listeners/data-localization.js +214 -0
  126. package/src/listeners/lookup-cache-listener.js +89 -0
  127. package/src/models/Accommodation.js +52 -0
  128. package/src/models/AccommodationRequestAction.js +195 -0
  129. package/src/models/AccommodationRequestEvent.js +276 -0
  130. package/src/models/EnableAttachmentModel.js +209 -0
  131. package/src/models/StudentAccommodationCard.js +92 -0
  132. package/src/models/TestAction.d.ts +5 -0
  133. package/src/models/TestAction.js +10 -0
  134. package/src/templates/mail-after-dining-request-status-change/html.ejs +27 -0
@@ -0,0 +1,500 @@
1
+ {
2
+ "$schema": "https://themost-framework.github.io/themost/models/2018/2/schema.json",
3
+ "@id": "https://universis.io/schemas/AccommodationRequestAction",
4
+ "name": "AccommodationRequestAction",
5
+ "title": "AccommodationRequestAction",
6
+ "hidden": false,
7
+ "sealed": false,
8
+ "abstract": false,
9
+ "inherits": "StudentRequestAction",
10
+ "version": "1.6",
11
+ "classPath": "./models/AccommodationRequestAction",
12
+ "fields": [
13
+ {
14
+ "name": "requestNumber",
15
+ "type": "Text",
16
+ "size": 36
17
+ },
18
+ {
19
+ "name": "studentHouseResident",
20
+ "type": "Boolean",
21
+ "nullable": true,
22
+ "value": "javascript:return false;"
23
+ },
24
+ {
25
+ "name": "sameDegreeHolder",
26
+ "type": "Boolean",
27
+ "nullable": true,
28
+ "value": "javascript:return false;"
29
+ },
30
+ {
31
+ "name": "foreignScholarStudent",
32
+ "type": "Boolean",
33
+ "nullable": false,
34
+ "value": "javascript:return false;"
35
+ },
36
+ {
37
+ "name": "inscriptionModeTag",
38
+ "type": "AccommodationInscriptionModeTag",
39
+ "nullable": true
40
+ },
41
+ {
42
+ "name": "lessThan25yrs",
43
+ "type": "Boolean",
44
+ "nullable": true,
45
+ "value": "javascript:return false;"
46
+ },
47
+ {
48
+ "name": "institutionOrClubLocationSameAsStudentPermanentResidence",
49
+ "type": "Boolean",
50
+ "nullable": true,
51
+ "value": "javascript:return false;"
52
+ },
53
+ {
54
+ "name": "studentDisabledPerson",
55
+ "type": "Boolean",
56
+ "nullable": true,
57
+ "value": "javascript:return false;"
58
+ },
59
+ {
60
+ "name": "studentOrphan",
61
+ "type": "Boolean",
62
+ "nullable": true,
63
+ "value": "javascript:return false;"
64
+ },
65
+ {
66
+ "name": "numberOfStudyingSiblings",
67
+ "type": "Number",
68
+ "nullable": true
69
+ },
70
+ {
71
+ "name": "maritalStatus",
72
+ "title": "Οικογενειακή κατάσταση",
73
+ "description": "Οικογενειακή κατάσταση",
74
+ "type": "FamilyStatus",
75
+ "expandable": true,
76
+ "nullable": true
77
+ },
78
+ {
79
+ "name": "noOfChildren",
80
+ "type": "Number",
81
+ "nullable": true
82
+ },
83
+ {
84
+ "name": "guardianType",
85
+ "title": "Τύπος Κηδεμόνα",
86
+ "description": "Τύπος Κηδεμόνα",
87
+ "type": "GuardianType",
88
+ "expandable": true,
89
+ "nullable": true
90
+ },
91
+ {
92
+ "name": "institutionOrClubLocationSameAsGuardianPermanentResidence",
93
+ "type": "Boolean",
94
+ "nullable": true,
95
+ "value": "javascript:return false;"
96
+ },
97
+ {
98
+ "name": "guardianNoOfChildren",
99
+ "type": "Number",
100
+ "nullable": true
101
+ },
102
+ {
103
+ "name": "studentSubmitsTaxReportInGreece",
104
+ "type": "Boolean",
105
+ "nullable": true,
106
+ "value": "javascript:return false;"
107
+ },
108
+ {
109
+ "name": "studentGuardianSubmitsTaxReportInGreece",
110
+ "type": "Boolean",
111
+ "nullable": true,
112
+ "value": "javascript:return false;"
113
+ },
114
+ {
115
+ "name": "studentAfm",
116
+ "type": "Text",
117
+ "nullable": true
118
+ },
119
+ {
120
+ "name": "studentTotalIncome",
121
+ "type": "Number",
122
+ "nullable": true
123
+ },
124
+ {
125
+ "name": "studentSpouseReceivesUnemploymentBenefit",
126
+ "type": "Boolean",
127
+ "nullable": true,
128
+ "value": "javascript:return false;"
129
+ },
130
+ {
131
+ "name": "studentSpouseAfm",
132
+ "type": "Text",
133
+ "nullable": true
134
+ },
135
+ {
136
+ "name": "studentSpouseTotalIncome",
137
+ "type": "Number",
138
+ "nullable": true
139
+ },
140
+ {
141
+ "name": "studentGuardianReceivesUnemploymentBenefit",
142
+ "type": "Boolean",
143
+ "nullable": true,
144
+ "value": "javascript:return false;"
145
+ },
146
+ {
147
+ "name": "foreignStudentOrChildOfGreekExpatriate",
148
+ "type": "Boolean",
149
+ "nullable": true,
150
+ "value": "javascript:return false;"
151
+ },
152
+ {
153
+ "name": "studentGuardianAfm",
154
+ "type": "Text",
155
+ "nullable": true
156
+ },
157
+ {
158
+ "name": "studentGuardianTotalIncome",
159
+ "type": "Number",
160
+ "nullable": true
161
+ },
162
+ {
163
+ "name": "studentParentsFileJointTaxReport",
164
+ "type": "Boolean",
165
+ "nullable": true,
166
+ "value": "javascript:return false;"
167
+ },
168
+ {
169
+ "name": "specialCategorySelfParticipant",
170
+ "type": "Boolean",
171
+ "nullable": true
172
+ },
173
+ {
174
+ "name": "allInformationSubmittedIsTrueConfirmation",
175
+ "type": "Boolean",
176
+ "nullable": false,
177
+ "value": "javascript:return false;"
178
+ },
179
+ {
180
+ "@id": "http://schema.org/additionalType",
181
+ "name": "additionalType",
182
+ "readonly": true,
183
+ "nullable": false,
184
+ "value": "javascript:return this.model.name;"
185
+ },
186
+ {
187
+ "@id": "http://schema.org/actionStatus",
188
+ "name": "actionStatus",
189
+ "title": "actionStatus",
190
+ "description": "Indicates the current disposition of the Action.",
191
+ "type": "ActionStatusType",
192
+ "value": "javascript:return { alternateName:'PotentialActionStatus' };"
193
+ },
194
+ {
195
+ "name": "effectiveStatus",
196
+ "title": "effectiveStatus",
197
+ "description": "Indicates the effective status of a potential action.",
198
+ "type": "AccommodationRequestEffectiveStatusType",
199
+ "nullable": true
200
+ },
201
+ {
202
+ "@id": "https://universis.io/AccommodationRequestEvent",
203
+ "name": "accommodationRequestEvent",
204
+ "title": "accommodation Request event",
205
+ "description": "accommodation Request event",
206
+ "type": "AccommodationRequestEvent",
207
+ "nullable": true
208
+ },
209
+ {
210
+ "name": "StudentAccommodationCard",
211
+ "title": "student accommodation card",
212
+ "description": "student accommodation card",
213
+ "type": "StudentAccommodationCard",
214
+ "many": true,
215
+ "expandable": true,
216
+ "mapping": {
217
+ "parentModel": "AccommodationRequestAction",
218
+ "parentField": "id",
219
+ "childModel": "StudentAccommodationCard",
220
+ "childField": "action",
221
+ "cascade": "delete",
222
+ "associationType": "association"
223
+ }
224
+ },
225
+ {
226
+ "@id": "https://universis.io/agree",
227
+ "name": "agree",
228
+ "title": "Agreement",
229
+ "description": "Agree with terms and conditions",
230
+ "type": "Boolean",
231
+ "nullable": false,
232
+ "value": "javascript:return 1;"
233
+ },
234
+ {
235
+ "@id": "http://schema.org/agent",
236
+ "name": "agent",
237
+ "title": "agent",
238
+ "description": "The direct performer or driver of the action (animate or inanimate). e.g. <em>John</em> wrote a book.",
239
+ "type": "User"
240
+ },
241
+ {
242
+ "@id": "https://themost.io/schemas/attachments",
243
+ "name": "attachments",
244
+ "type": "Attachment",
245
+ "mapping": {
246
+ "cascade": "delete",
247
+ "associationType": "junction",
248
+ "associationObjectField": "action",
249
+ "associationValueField": "attachment",
250
+ "associationAdapter": "AccommodationRequestActionAttachments",
251
+ "privileges": [
252
+ {
253
+ "mask": 15,
254
+ "type": "global"
255
+ },
256
+ {
257
+ "mask": 15,
258
+ "type": "global",
259
+ "account": "Administrators"
260
+ },
261
+ {
262
+ "mask": 15,
263
+ "type": "global",
264
+ "account": "AccommodationAdministrators"
265
+ },
266
+ {
267
+ "mask": 15,
268
+ "type": "self",
269
+ "filter": "action/student/department eq departments()",
270
+ "account": "AccommodationUsers"
271
+ },
272
+ {
273
+ "mask": 1,
274
+ "type": "self",
275
+ "filter": "action/owner eq me()",
276
+ "account": "Students"
277
+ },
278
+ {
279
+ "mask": 14,
280
+ "type": "self",
281
+ "account": "Students",
282
+ "filter": "action/owner eq me() and action/actionStatus/alternateName eq 'PotentialActionStatus'"
283
+ }
284
+ ]
285
+ }
286
+ },
287
+ {
288
+ "name": "messages",
289
+ "title": "Messages",
290
+ "type": "Message",
291
+ "many": true,
292
+ "mapping": {
293
+ "parentModel": "AccommodationRequestAction",
294
+ "childModel": "AccommodationRequestActionMessage",
295
+ "parentField": "id",
296
+ "childField": "action",
297
+ "cascade": "delete",
298
+ "associationType": "association"
299
+ }
300
+ },
301
+ {
302
+ "name": "studentHasManyChildren",
303
+ "type": "Boolean",
304
+ "value": "javascript:return false;"
305
+ },
306
+ {
307
+ "name": "studentFamilyHasManyChildren",
308
+ "type": "Boolean",
309
+ "value": "javascript:return false;"
310
+ },
311
+ {
312
+ "name": "studyingSiblingsHaveOtherPermanentResidence",
313
+ "type": "Boolean",
314
+ "value": "javascript:return false;"
315
+ },
316
+ {
317
+ "name": "childOfUnmarriedMother",
318
+ "type": "Boolean",
319
+ "value": "javascript:return false;"
320
+ },
321
+ {
322
+ "name": "studentHasDisabledSiblings",
323
+ "type": "Boolean",
324
+ "nullable": true,
325
+ "value": "javascript:return false;"
326
+ },
327
+ {
328
+ "name": "accommodationGuardianFinancialAttributes",
329
+ "title": "accommodationGuardianFinancialAttributes",
330
+ "type": "AccommodationGuardianFinancialAttribute",
331
+ "many": true,
332
+ "nested": true,
333
+ "mapping": {
334
+ "parentModel": "AccommodationRequestAction",
335
+ "childModel": "AccommodationGuardianFinancialAttribute",
336
+ "parentField": "id",
337
+ "childField": "accommodationRequest",
338
+ "cascade": "delete",
339
+ "associationType": "association"
340
+ }
341
+ },
342
+ {
343
+ "name": "accommodationChildFinancialAttributes",
344
+ "title": "accommodationChildFinancialAttributes",
345
+ "type": "AccommodationChildFinancialAttribute",
346
+ "many": true,
347
+ "nested": true,
348
+ "mapping": {
349
+ "parentModel": "AccommodationRequestAction",
350
+ "childModel": "AccommodationChildFinancialAttribute",
351
+ "parentField": "id",
352
+ "childField": "accommodationRequest",
353
+ "cascade": "delete",
354
+ "associationType": "association"
355
+ }
356
+ },
357
+ {
358
+ "name": "mobilityProgramStudent",
359
+ "type": "Boolean",
360
+ "value": "javascript:return false;"
361
+ },
362
+ {
363
+ "name": "accommodationSiblingFinancialAttributes",
364
+ "title": "accommodationSiblingFinancialAttributes",
365
+ "type": "AccommodationSiblingFinancialAttribute",
366
+ "many": true,
367
+ "nested": true,
368
+ "mapping": {
369
+ "parentModel": "AccommodationRequestAction",
370
+ "childModel": "AccommodationSiblingFinancialAttribute",
371
+ "parentField": "id",
372
+ "childField": "accommodationRequest",
373
+ "cascade": "delete",
374
+ "associationType": "association"
375
+ }
376
+ },
377
+ {
378
+ "name": "guardianNoOfChildrenLessThan18yrs",
379
+ "type": "Number",
380
+ "nullable": true
381
+ },
382
+ {
383
+ "@id": "http://schema.org/review",
384
+ "name": "review",
385
+ "title": "A review for this item",
386
+ "type": "Review",
387
+ "multiplicity": "ZeroOrOne",
388
+ "many": true,
389
+ "mapping": {
390
+ "associationType": "association",
391
+ "parentModel": "AccommodationRequestAction",
392
+ "parentField": "id",
393
+ "childModel": "AccommodationRequestActionReview",
394
+ "childField": "itemReviewed",
395
+ "privileges": [
396
+ {
397
+ "mask": 15,
398
+ "type": "global"
399
+ },
400
+ {
401
+ "mask": 15,
402
+ "type": "global",
403
+ "account": "Administrators"
404
+ }
405
+ ]
406
+ }
407
+ },
408
+ {
409
+ "name": "category",
410
+ "title": "Κατηγορία",
411
+ "description": "Κατηγορία ειδικής αίτησης σίτισης",
412
+ "type": "AccommodationRequestCategory",
413
+ "nullable": true
414
+ },
415
+ {
416
+ "name": "studentConsent",
417
+ "type": "Boolean",
418
+ "nullable": true,
419
+ "editable": false
420
+ },
421
+ {
422
+ "name": "numberOfMilitaryActiveSiblings",
423
+ "type": "Number",
424
+ "nullable": true
425
+ },
426
+ {
427
+ "name": "comment",
428
+ "title": "Σημειώσεις",
429
+ "description": "Σημειώσεις",
430
+ "type": "Text",
431
+ "size": 255,
432
+ "many": false,
433
+ "nullable": true
434
+ }
435
+ ],
436
+ "privileges": [
437
+ {
438
+ "mask": 15,
439
+ "type": "global"
440
+ },
441
+ {
442
+ "mask": 15,
443
+ "type": "global",
444
+ "account": "Administrators"
445
+ },
446
+ {
447
+ "mask": 1,
448
+ "type": "self",
449
+ "filter": "owner eq me()",
450
+ "account": "Students"
451
+ },
452
+ {
453
+ "mask": 2,
454
+ "type": "self",
455
+ "filter": "owner eq me() and agent eq null and actionStatus/alternateName eq 'PotentialActionStatus'",
456
+ "account": "Students"
457
+ },
458
+ {
459
+ "mask": 4,
460
+ "type": "self",
461
+ "when": "owner eq me() and agent eq null and actionStatus/alternateName eq 'PotentialActionStatus'",
462
+ "filter": "owner eq me() and agent eq null and (actionStatus/alternateName eq 'PotentialActionStatus' or actionStatus/alternateName eq 'ActiveActionStatus')",
463
+ "account": "Students"
464
+ }
465
+ ],
466
+ "constraints": [
467
+ {
468
+ "type": "unique",
469
+ "description": "Request number must be unique across different records",
470
+ "fields": [
471
+ "requestNumber"
472
+ ]
473
+ },
474
+ {
475
+ "type": "unique",
476
+ "description": "Request must be unique for student and event",
477
+ "fields": [
478
+ "student", "accommodationRequestEvent"
479
+ ]
480
+ }
481
+ ],
482
+ "eventListeners": [
483
+ {
484
+ "type": "@themost/data/previous-state-listener"
485
+ },
486
+ {
487
+ "type": "./listeners/ValidateActionListener"
488
+ },
489
+ {
490
+ "type": "./listeners/GenerateRequestNumberListener"
491
+ },
492
+ {
493
+ "type": "./listeners/OnActionCompleteListener"
494
+ },
495
+ {
496
+ "type": "./listeners/SendEmailAfterActionStatusChangeListener"
497
+ }
498
+ ]
499
+ }
500
+
@@ -0,0 +1,46 @@
1
+ {
2
+ "$schema": "https://themost-framework.github.io/themost/models/2018/2/schema.json",
3
+ "@id": "https://themost.io/schemas/AccommodationRequestActionMessage",
4
+ "name": "AccommodationRequestActionMessage",
5
+ "description": "Message that are being sent between users for a accommodation action",
6
+ "title": "AccommodationRequestActionMessages",
7
+ "abstract": false,
8
+ "sealed": false,
9
+ "hidden": false,
10
+ "inherits": "StudentMessage",
11
+ "version": "1.0",
12
+ "fields": [
13
+ {
14
+ "name": "action",
15
+ "title": "Action",
16
+ "description": "The action associated with this message.",
17
+ "type": "AccommodationRequestAction",
18
+ "nullable": false
19
+ }
20
+ ],
21
+ "eventListeners": [
22
+ ],
23
+ "privileges": [
24
+ {
25
+ "mask": 15,
26
+ "type": "global"
27
+ },
28
+ {
29
+ "mask": 15,
30
+ "type": "global",
31
+ "account": "Administrators"
32
+ },
33
+ {
34
+ "mask": 1,
35
+ "type": "self",
36
+ "filter": "sender eq me() or recipient eq me()",
37
+ "account": "Students"
38
+ },
39
+ {
40
+ "mask": 2,
41
+ "type": "self",
42
+ "filter": "sender eq me() and action/owner eq me()",
43
+ "account": "Students"
44
+ }
45
+ ]
46
+ }
@@ -0,0 +1,31 @@
1
+ {
2
+ "$schema": "https://themost-framework.github.io/themost/models/2018/2/schema.json",
3
+ "@id": "https://themost.io/schemas/AccommodationRequestActionReview",
4
+ "name": "AccommodationRequestActionReview",
5
+ "title": "AccommodationRequestActionReviews",
6
+ "abstract": false,
7
+ "sealed": false,
8
+ "hidden": true,
9
+ "inherits": "Review",
10
+ "version": "1.0",
11
+ "fields": [
12
+ {
13
+ "name": "itemReviewed",
14
+ "title": "Item reviewed",
15
+ "description": "The item that is being reviewed.",
16
+ "type": "AccommodationRequestAction",
17
+ "nullable": true
18
+ }
19
+ ],
20
+ "privileges": [
21
+ {
22
+ "mask": 15,
23
+ "type": "global"
24
+ },
25
+ {
26
+ "mask": 15,
27
+ "type": "global",
28
+ "account": "Administrators"
29
+ }
30
+ ]
31
+ }
@@ -0,0 +1,72 @@
1
+ {
2
+ "$schema": "https://themost-framework.github.io/themost/models/2018/2/schema.json",
3
+ "@id": "https://themost.io/schemas/AccommodationRequestAttachmentConfiguration",
4
+ "name": "AccommodationRequestAttachmentConfiguration",
5
+ "title": "AccommodationRequestAttachmentConfiguration",
6
+ "hidden": false,
7
+ "sealed": false,
8
+ "abstract": false,
9
+ "inherits": "AttachmentConfiguration",
10
+ "version": "1.1",
11
+ "fields": [
12
+ {
13
+ "name": "target",
14
+ "title": "The target model",
15
+ "value": "javascript:return 'AccommodationRequestEvent';"
16
+
17
+ },
18
+ {
19
+ "name": "object",
20
+ "title": "object",
21
+ "description": "The request event.",
22
+ "type": "AccommodationRequestEvent",
23
+ "mapping": {
24
+ "parentModel": "AccommodationRequestEvent",
25
+ "childModel": "AccommodationRequestAttachmentConfiguration",
26
+ "parentField": "identifier",
27
+ "childField": "object",
28
+ "cascade": "none",
29
+ "associationType": "association"
30
+ },
31
+ "nullable": false
32
+ },
33
+ {
34
+ "name": "requiredRule",
35
+ "type": "Text",
36
+ "nullable": true,
37
+ "size": 2048
38
+ },
39
+ {
40
+ "name": "numberOfAttachmentsProperty",
41
+ "type": "Text",
42
+ "nullable": true
43
+ }
44
+ ],
45
+ "eventListeners": [
46
+ ],
47
+ "constraints": [
48
+ {
49
+ "type": "unique",
50
+ "fields": [
51
+ "object",
52
+ "attachmentType"
53
+ ]
54
+ }
55
+ ],
56
+ "privileges": [
57
+ {
58
+ "mask": 15,
59
+ "type": "global"
60
+ },
61
+ {
62
+ "mask": 1,
63
+ "type": "global",
64
+ "account": "*"
65
+ },
66
+ {
67
+ "mask": 15,
68
+ "type": "global",
69
+ "account": "Administrators"
70
+ }
71
+ ]
72
+ }