@platform-modules/foreign-ministry 1.3.275 → 1.3.276
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/.env +5 -10
- package/dist/data-source.js +5 -22
- package/dist/index.d.ts +2 -10
- package/dist/index.js +3 -30
- package/dist/models/AnnualTravelTicketEmployeeAllocationFamilyModel.d.ts +20 -0
- package/dist/models/AnnualTravelTicketEmployeeAllocationFamilyModel.js +44 -0
- package/dist/models/AnnualTravelTicketEmployeeAllocationModel.d.ts +20 -0
- package/dist/models/AnnualTravelTicketEmployeeAllocationModel.js +53 -0
- package/dist/models/EmbassyMasterModel.d.ts +16 -0
- package/dist/models/EmbassyMasterModel.js +75 -0
- package/dist/models/UserDependentsModel.d.ts +18 -0
- package/dist/models/UserDependentsModel.js +94 -0
- package/package.json +1 -1
- package/src/data-source.ts +584 -606
- package/src/index.ts +2 -27
- package/src/models/AnnualTravelTicketEmployeeAllocationFamilyModel.ts +33 -0
- package/src/models/AnnualTravelTicketEmployeeAllocationModel.ts +32 -0
- package/src/models/AnnualTravelTicketPriceConfigurationItemModel.ts +36 -36
- package/src/models/AnnualTravelTicketPriceConfigurationModel.ts +35 -35
- package/src/models/AnnualTravelTicketRequestModel.ts +42 -42
- package/src/models/DiplomaticAcademyRequestModel.ts +80 -80
- package/src/models/DocumentationFileModel.ts +40 -40
- package/src/models/FinancialWorkFlowModel.ts +15 -15
- package/src/models/GatePassVisitorsModel.ts +7 -7
- package/src/models/LMSExternalEntityTrainedPersonModel.ts +45 -45
- package/src/models/LanguageCourseRequestModel.ts +67 -67
- package/src/models/LeaveConfigModel.ts +71 -71
- package/src/models/MissionTravelApprovalModel.ts +101 -101
- package/src/models/MissionTravelAttachmentModel.ts +56 -56
- package/src/models/MissionTravelChatModel.ts +52 -52
- package/src/models/MissionTravelPersonModel.ts +105 -105
- package/src/models/MissionTravelWorkflowModel.ts +54 -54
- package/src/models/PollOptionsModel.ts +26 -26
- package/src/models/PollVotesModel.ts +37 -37
- package/src/models/PollsModel.ts +49 -49
- package/src/models/ProjectContactsModel.ts +51 -51
- package/src/models/ProjectFaqModel.ts +36 -36
- package/src/models/ProjectInvoicesModel.ts +41 -41
- package/src/models/ProjectModel.ts +75 -75
- package/src/models/ProjectTasksModel.ts +75 -75
- package/src/models/ResignationTerminationApprovalModel.ts +9 -9
- package/src/models/ResignationTerminationRequestModel.ts +17 -17
- package/src/models/SectionModel.ts +35 -35
- package/src/models/ServicesNotificationConfigsModel.ts +55 -55
- package/src/models/TelephoneDirectoryModel.ts +20 -20
- package/dist/models/EmployeeEvaluationAnswerModel.d.ts +0 -11
- package/dist/models/EmployeeEvaluationAnswerModel.js +0 -46
- package/dist/models/EmployeeEvaluationApprovalModel.d.ts +0 -22
- package/dist/models/EmployeeEvaluationApprovalModel.js +0 -84
- package/dist/models/EmployeeEvaluationAttachmentModel.d.ts +0 -11
- package/dist/models/EmployeeEvaluationAttachmentModel.js +0 -52
- package/dist/models/EmployeeEvaluationChatModel.d.ts +0 -18
- package/dist/models/EmployeeEvaluationChatModel.js +0 -65
- package/dist/models/EmployeeEvaluationModel.d.ts +0 -16
- package/dist/models/EmployeeEvaluationModel.js +0 -59
- package/dist/models/EmployeeEvaluationRequestModel.d.ts +0 -34
- package/dist/models/EmployeeEvaluationRequestModel.js +0 -104
- package/dist/models/EmployeeEvaluationWorkflowModel.d.ts +0 -17
- package/dist/models/EmployeeEvaluationWorkflowModel.js +0 -67
- package/dist/models/EvaluationEligibilitySettingModel.d.ts +0 -20
- package/dist/models/EvaluationEligibilitySettingModel.js +0 -67
- package/dist/models/EvaluationMastersModel.d.ts +0 -16
- package/dist/models/EvaluationMastersModel.js +0 -67
- package/dist/models/EvaluationQuestionMasterModel.d.ts +0 -10
- package/dist/models/EvaluationQuestionMasterModel.js +0 -42
- package/dist/models/EvaluationSectionMasterModel.d.ts +0 -7
- package/dist/models/EvaluationSectionMasterModel.js +0 -36
- package/dist/models/EvaluationWorkflowModel.d.ts +0 -60
- package/dist/models/EvaluationWorkflowModel.js +0 -215
- package/dist/models/IneligibleForEvaluationModel.d.ts +0 -8
- package/dist/models/IneligibleForEvaluationModel.js +0 -44
- package/dist/models/MissionTravelClassConfigModel.d.ts +0 -10
- package/dist/models/MissionTravelClassConfigModel.js +0 -50
- package/dist/models/MissionTravelPerdiemModel.d.ts +0 -10
- package/dist/models/MissionTravelPerdiemModel.js +0 -54
- package/src/models/EmployeeEvaluationAnswerModel.ts +0 -26
- package/src/models/EmployeeEvaluationApprovalModel.ts +0 -56
- package/src/models/EmployeeEvaluationAttachmentModel.ts +0 -29
- package/src/models/EmployeeEvaluationChatModel.ts +0 -42
- package/src/models/EmployeeEvaluationModel.ts +0 -38
- package/src/models/EmployeeEvaluationRequestModel.ts +0 -77
- package/src/models/EmployeeEvaluationWorkflowModel.ts +0 -43
- package/src/models/EvaluationEligibilitySettingModel.ts +0 -42
- package/src/models/EvaluationQuestionMasterModel.ts +0 -23
- package/src/models/EvaluationSectionMasterModel.ts +0 -17
package/src/index.ts
CHANGED
|
@@ -83,6 +83,8 @@ export * from './models/MissionBankAccountWorkflowModel';
|
|
|
83
83
|
export * from './models/AnnualTravelTicketRequestModel';
|
|
84
84
|
export * from './models/AnnualTravelTicketPriceConfigurationModel';
|
|
85
85
|
export * from './models/AnnualTravelTicketPriceConfigurationItemModel';
|
|
86
|
+
export * from './models/AnnualTravelTicketEmployeeAllocationModel';
|
|
87
|
+
export * from './models/AnnualTravelTicketEmployeeAllocationFamilyModel';
|
|
86
88
|
export * from './models/AmbassadorSpecialAccountAmountRequestModel';
|
|
87
89
|
export * from './models/StayAfterHoursRequestModel';
|
|
88
90
|
export * from './models/StayAfterHoursApprovalModel';
|
|
@@ -425,30 +427,3 @@ export * from './models/ServicesNotificationConfigsModel';
|
|
|
425
427
|
export { ServicesNotificationTriggerType } from './models/ServicesNotificationConfigsModel';
|
|
426
428
|
// Moodle Users Model
|
|
427
429
|
export * from './models/MoodleUsersModel';
|
|
428
|
-
// Evaluation
|
|
429
|
-
export {
|
|
430
|
-
EvaluationEligibilitySetting,
|
|
431
|
-
EvaluationEligibilitySettingEmployee,
|
|
432
|
-
} from './models/EvaluationEligibilitySettingModel';
|
|
433
|
-
export { EvaluationSectionMaster } from './models/EvaluationSectionMasterModel';
|
|
434
|
-
export { EvaluationQuestionMaster } from './models/EvaluationQuestionMasterModel';
|
|
435
|
-
export {
|
|
436
|
-
EmployeeEvaluationRequests,
|
|
437
|
-
EmployeeEvaluationRequestStatus,
|
|
438
|
-
EmployeeEvaluationRoutingBucket,
|
|
439
|
-
} from './models/EmployeeEvaluationRequestModel';
|
|
440
|
-
export { EmployeeEvaluation, EmployeeEvaluationUsFeedback } from './models/EmployeeEvaluationModel';
|
|
441
|
-
export { EmployeeEvaluationAnswers } from './models/EmployeeEvaluationAnswerModel';
|
|
442
|
-
export {
|
|
443
|
-
EmployeeEvaluationApprovalDetails,
|
|
444
|
-
EmployeeEvaluationApprovalStatus,
|
|
445
|
-
} from './models/EmployeeEvaluationApprovalModel';
|
|
446
|
-
export {
|
|
447
|
-
EmployeeEvaluationWorkFlow,
|
|
448
|
-
EmployeeEvaluationWorkFlowStatus,
|
|
449
|
-
} from './models/EmployeeEvaluationWorkflowModel';
|
|
450
|
-
export {
|
|
451
|
-
EmployeeEvaluationRequestChat,
|
|
452
|
-
EmployeeEvaluationMessageType,
|
|
453
|
-
} from './models/EmployeeEvaluationChatModel';
|
|
454
|
-
export { EmployeeEvaluationRequestAttachment } from './models/EmployeeEvaluationAttachmentModel';
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
/** One JSON row per child age band / pool (carry, allocated total, used). */
|
|
5
|
+
export interface AnnualTravelTicketChildTicketPool {
|
|
6
|
+
age_category: string;
|
|
7
|
+
relation?: string;
|
|
8
|
+
carry_forward: number;
|
|
9
|
+
total_allocated: number;
|
|
10
|
+
used: number;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Spouse: real columns. Children: JSON array column `children_pools` (age_category buckets only).
|
|
15
|
+
* Linked to annual_travel_ticket_employee_allocations by allocation_id only (no ORM relation).
|
|
16
|
+
*/
|
|
17
|
+
@Entity({ name: 'annual_travel_ticket_employee_allocation_family' })
|
|
18
|
+
export class AnnualTravelTicketEmployeeAllocationFamily extends BaseModel {
|
|
19
|
+
@Column({ type: 'int', nullable: false, unique: true })
|
|
20
|
+
allocation_id: number;
|
|
21
|
+
|
|
22
|
+
@Column({ type: 'int', default: 0 })
|
|
23
|
+
spouse_carry_forward: number;
|
|
24
|
+
|
|
25
|
+
@Column({ type: 'int', default: 0 })
|
|
26
|
+
spouse_total_allocated: number;
|
|
27
|
+
|
|
28
|
+
@Column({ type: 'int', default: 0 })
|
|
29
|
+
spouse_used: number;
|
|
30
|
+
|
|
31
|
+
@Column({ type: 'jsonb', nullable: false, default: () => "'[]'::jsonb" })
|
|
32
|
+
children_pools: AnnualTravelTicketChildTicketPool[];
|
|
33
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Column, Entity, Index } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Per employee + year: employee self pool (columns) + history_log.
|
|
6
|
+
* Spouse / children live on annual_travel_ticket_employee_allocation_family (allocation_id FK only).
|
|
7
|
+
*/
|
|
8
|
+
@Entity({ name: 'annual_travel_ticket_employee_allocations' })
|
|
9
|
+
@Index('idx_att_alloc_user_year', ['employee_user_id', 'ticket_year'])
|
|
10
|
+
export class AnnualTravelTicketEmployeeAllocation extends BaseModel {
|
|
11
|
+
@Column({ type: 'int', nullable: false })
|
|
12
|
+
employee_user_id: number;
|
|
13
|
+
|
|
14
|
+
@Column({ type: 'int', nullable: false })
|
|
15
|
+
ticket_year: number;
|
|
16
|
+
|
|
17
|
+
@Column({ type: 'int', default: 0 })
|
|
18
|
+
employee_carry_forward: number;
|
|
19
|
+
|
|
20
|
+
@Column({ type: 'int', default: 0 })
|
|
21
|
+
employee_total_allocated: number;
|
|
22
|
+
|
|
23
|
+
@Column({ type: 'int', default: 0 })
|
|
24
|
+
employee_used: number;
|
|
25
|
+
|
|
26
|
+
/** Append-only change history: { at, by, action, snapshot } */
|
|
27
|
+
@Column({ type: 'jsonb', nullable: false, default: () => "'[]'::jsonb" })
|
|
28
|
+
history_log: Array<{ at: string; by: string; action: string; snapshot?: Record<string, unknown> }>;
|
|
29
|
+
|
|
30
|
+
@Column({ type: 'varchar', length: 2000, nullable: true })
|
|
31
|
+
notes: string | null;
|
|
32
|
+
}
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import { Column, Entity, JoinColumn, ManyToOne, Unique } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
import { AnnualTravelTicketPriceConfiguration } from './AnnualTravelTicketPriceConfigurationModel';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Individual price slab within an annual travel ticket pricing configuration.
|
|
7
|
-
* age_from is inclusive and age_to is exclusive to allow adjacent ranges.
|
|
8
|
-
*/
|
|
9
|
-
@Entity({ name: 'annual_travel_ticket_price_configuration_items' })
|
|
10
|
-
@Unique(['configuration_id', 'ticket_class', 'age_from', 'age_to'])
|
|
11
|
-
export class AnnualTravelTicketPriceConfigurationItem extends BaseModel {
|
|
12
|
-
@Column({ type: 'int', nullable: false })
|
|
13
|
-
configuration_id: number;
|
|
14
|
-
|
|
15
|
-
@ManyToOne(() => AnnualTravelTicketPriceConfiguration, (configuration) => configuration.price_slabs, { onDelete: 'CASCADE' })
|
|
16
|
-
@JoinColumn({ name: 'configuration_id' })
|
|
17
|
-
configuration: AnnualTravelTicketPriceConfiguration;
|
|
18
|
-
|
|
19
|
-
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
20
|
-
ticket_class: string | null;
|
|
21
|
-
|
|
22
|
-
@Column({ type: 'int', nullable: false })
|
|
23
|
-
age_from: number;
|
|
24
|
-
|
|
25
|
-
@Column({ type: 'int', nullable: false })
|
|
26
|
-
age_to: number;
|
|
27
|
-
|
|
28
|
-
@Column({ type: 'decimal', precision: 12, scale: 2, nullable: false })
|
|
29
|
-
price: number | string;
|
|
30
|
-
|
|
31
|
-
@Column({ type: 'varchar', length: 10, nullable: true, default: 'OMR' })
|
|
32
|
-
currency_code: string | null;
|
|
33
|
-
|
|
34
|
-
@Column({ type: 'text', nullable: true })
|
|
35
|
-
notes: string | null;
|
|
36
|
-
}
|
|
1
|
+
import { Column, Entity, JoinColumn, ManyToOne, Unique } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
import { AnnualTravelTicketPriceConfiguration } from './AnnualTravelTicketPriceConfigurationModel';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Individual price slab within an annual travel ticket pricing configuration.
|
|
7
|
+
* age_from is inclusive and age_to is exclusive to allow adjacent ranges.
|
|
8
|
+
*/
|
|
9
|
+
@Entity({ name: 'annual_travel_ticket_price_configuration_items' })
|
|
10
|
+
@Unique(['configuration_id', 'ticket_class', 'age_from', 'age_to'])
|
|
11
|
+
export class AnnualTravelTicketPriceConfigurationItem extends BaseModel {
|
|
12
|
+
@Column({ type: 'int', nullable: false })
|
|
13
|
+
configuration_id: number;
|
|
14
|
+
|
|
15
|
+
@ManyToOne(() => AnnualTravelTicketPriceConfiguration, (configuration) => configuration.price_slabs, { onDelete: 'CASCADE' })
|
|
16
|
+
@JoinColumn({ name: 'configuration_id' })
|
|
17
|
+
configuration: AnnualTravelTicketPriceConfiguration;
|
|
18
|
+
|
|
19
|
+
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
20
|
+
ticket_class: string | null;
|
|
21
|
+
|
|
22
|
+
@Column({ type: 'int', nullable: false })
|
|
23
|
+
age_from: number;
|
|
24
|
+
|
|
25
|
+
@Column({ type: 'int', nullable: false })
|
|
26
|
+
age_to: number;
|
|
27
|
+
|
|
28
|
+
@Column({ type: 'decimal', precision: 12, scale: 2, nullable: false })
|
|
29
|
+
price: number | string;
|
|
30
|
+
|
|
31
|
+
@Column({ type: 'varchar', length: 10, nullable: true, default: 'OMR' })
|
|
32
|
+
currency_code: string | null;
|
|
33
|
+
|
|
34
|
+
@Column({ type: 'text', nullable: true })
|
|
35
|
+
notes: string | null;
|
|
36
|
+
}
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { Column, Entity, OneToMany, Unique } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
import { AnnualTravelTicketPriceConfigurationItem } from './AnnualTravelTicketPriceConfigurationItemModel';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Admin configuration for annual travel ticket pricing.
|
|
7
|
-
* One record per year (and optional service/sub-service pair), with multiple age slabs.
|
|
8
|
-
*/
|
|
9
|
-
@Entity({ name: 'annual_travel_ticket_price_configurations' })
|
|
10
|
-
@Unique(['service_id', 'sub_service_id', 'ticket_year'])
|
|
11
|
-
export class AnnualTravelTicketPriceConfiguration extends BaseModel {
|
|
12
|
-
@Column({ type: 'int', nullable: true })
|
|
13
|
-
service_id: number | null;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'int', nullable: true })
|
|
16
|
-
sub_service_id: number | null;
|
|
17
|
-
|
|
18
|
-
@Column({ type: 'int', nullable: false })
|
|
19
|
-
ticket_year: number;
|
|
20
|
-
|
|
21
|
-
@Column({ type: 'varchar', length: 255, nullable: true })
|
|
22
|
-
configuration_name: string | null;
|
|
23
|
-
|
|
24
|
-
@Column({ type: 'varchar', length: 10, nullable: true, default: 'OMR' })
|
|
25
|
-
currency_code: string | null;
|
|
26
|
-
|
|
27
|
-
@Column({ type: 'text', nullable: true })
|
|
28
|
-
description: string | null;
|
|
29
|
-
|
|
30
|
-
@Column({ type: 'boolean', default: true, nullable: false })
|
|
31
|
-
is_active: boolean;
|
|
32
|
-
|
|
33
|
-
@OneToMany(() => AnnualTravelTicketPriceConfigurationItem, (item) => item.configuration)
|
|
34
|
-
price_slabs?: AnnualTravelTicketPriceConfigurationItem[];
|
|
35
|
-
}
|
|
1
|
+
import { Column, Entity, OneToMany, Unique } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
import { AnnualTravelTicketPriceConfigurationItem } from './AnnualTravelTicketPriceConfigurationItemModel';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Admin configuration for annual travel ticket pricing.
|
|
7
|
+
* One record per year (and optional service/sub-service pair), with multiple age slabs.
|
|
8
|
+
*/
|
|
9
|
+
@Entity({ name: 'annual_travel_ticket_price_configurations' })
|
|
10
|
+
@Unique(['service_id', 'sub_service_id', 'ticket_year'])
|
|
11
|
+
export class AnnualTravelTicketPriceConfiguration extends BaseModel {
|
|
12
|
+
@Column({ type: 'int', nullable: true })
|
|
13
|
+
service_id: number | null;
|
|
14
|
+
|
|
15
|
+
@Column({ type: 'int', nullable: true })
|
|
16
|
+
sub_service_id: number | null;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'int', nullable: false })
|
|
19
|
+
ticket_year: number;
|
|
20
|
+
|
|
21
|
+
@Column({ type: 'varchar', length: 255, nullable: true })
|
|
22
|
+
configuration_name: string | null;
|
|
23
|
+
|
|
24
|
+
@Column({ type: 'varchar', length: 10, nullable: true, default: 'OMR' })
|
|
25
|
+
currency_code: string | null;
|
|
26
|
+
|
|
27
|
+
@Column({ type: 'text', nullable: true })
|
|
28
|
+
description: string | null;
|
|
29
|
+
|
|
30
|
+
@Column({ type: 'boolean', default: true, nullable: false })
|
|
31
|
+
is_active: boolean;
|
|
32
|
+
|
|
33
|
+
@OneToMany(() => AnnualTravelTicketPriceConfigurationItem, (item) => item.configuration)
|
|
34
|
+
price_slabs?: AnnualTravelTicketPriceConfigurationItem[];
|
|
35
|
+
}
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
export enum AnnualTravelTicketPermanentResidence {
|
|
5
|
-
SALALAH = 'Salalah',
|
|
6
|
-
MUSANDAM = 'Musandam',
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
export interface AnnualTravelTicketFamilyDetail {
|
|
10
|
-
person_name: string;
|
|
11
|
-
relation: string;
|
|
12
|
-
age: number;
|
|
13
|
-
age_category: string;
|
|
14
|
-
price: number | string;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/** Aligns with mission bank account request lifecycle for shared workflow UI. */
|
|
18
|
-
export enum AnnualTravelTicketRequestStatus {
|
|
19
|
-
PENDING = 'Pending',
|
|
20
|
-
ASSIGNED = 'Assigned',
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
export enum AnnualTravelTicketPermanentResidence {
|
|
5
|
+
SALALAH = 'Salalah',
|
|
6
|
+
MUSANDAM = 'Musandam',
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface AnnualTravelTicketFamilyDetail {
|
|
10
|
+
person_name: string;
|
|
11
|
+
relation: string;
|
|
12
|
+
age: number;
|
|
13
|
+
age_category: string;
|
|
14
|
+
price: number | string;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/** Aligns with mission bank account request lifecycle for shared workflow UI. */
|
|
18
|
+
export enum AnnualTravelTicketRequestStatus {
|
|
19
|
+
PENDING = 'Pending',
|
|
20
|
+
ASSIGNED = 'Assigned',
|
|
21
21
|
IN_PROGRESS = 'In Progress',
|
|
22
22
|
APPROVED = 'Approved',
|
|
23
23
|
REJECTED = 'Rejected',
|
|
@@ -47,28 +47,28 @@ export class AnnualTravelTicketRequests extends BaseModel {
|
|
|
47
47
|
@Column({ type: 'varchar', length: 120, nullable: false })
|
|
48
48
|
civil_id_or_passport_number: string;
|
|
49
49
|
|
|
50
|
-
@Column({ type: 'enum', enum: AnnualTravelTicketPermanentResidence, nullable: false })
|
|
51
|
-
permanent_residence: AnnualTravelTicketPermanentResidence;
|
|
52
|
-
|
|
53
|
-
/** Traveler list with person name, relation, age, age category, and price. */
|
|
54
|
-
@Column({ type: 'jsonb', nullable: true })
|
|
55
|
-
family_details: AnnualTravelTicketFamilyDetail[] | null;
|
|
56
|
-
|
|
57
|
-
@Column({ type: 'varchar', length: 100, nullable: false })
|
|
58
|
-
bank_account_number: string;
|
|
59
|
-
|
|
60
|
-
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
61
|
-
travel_from: string;
|
|
62
|
-
|
|
63
|
-
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
64
|
-
travel_to: string;
|
|
65
|
-
|
|
66
|
-
@Column({ type: 'date', nullable: false })
|
|
67
|
-
date_of_travel: string;
|
|
68
|
-
|
|
69
|
-
@Column({
|
|
70
|
-
type: 'enum',
|
|
71
|
-
enum: AnnualTravelTicketRequestStatus,
|
|
50
|
+
@Column({ type: 'enum', enum: AnnualTravelTicketPermanentResidence, nullable: false })
|
|
51
|
+
permanent_residence: AnnualTravelTicketPermanentResidence;
|
|
52
|
+
|
|
53
|
+
/** Traveler list with person name, relation, age, age category, and price. */
|
|
54
|
+
@Column({ type: 'jsonb', nullable: true })
|
|
55
|
+
family_details: AnnualTravelTicketFamilyDetail[] | null;
|
|
56
|
+
|
|
57
|
+
@Column({ type: 'varchar', length: 100, nullable: false })
|
|
58
|
+
bank_account_number: string;
|
|
59
|
+
|
|
60
|
+
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
61
|
+
travel_from: string;
|
|
62
|
+
|
|
63
|
+
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
64
|
+
travel_to: string;
|
|
65
|
+
|
|
66
|
+
@Column({ type: 'date', nullable: false })
|
|
67
|
+
date_of_travel: string;
|
|
68
|
+
|
|
69
|
+
@Column({
|
|
70
|
+
type: 'enum',
|
|
71
|
+
enum: AnnualTravelTicketRequestStatus,
|
|
72
72
|
default: AnnualTravelTicketRequestStatus.PENDING,
|
|
73
73
|
nullable: false,
|
|
74
74
|
})
|
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
import { Column, Entity } from "typeorm";
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
export enum DiplomaticAcademyStatus {
|
|
5
|
-
SUBMITTED = "Submitted",
|
|
6
|
-
PENDING = "Pending",
|
|
7
|
-
ASSIGNED = "Assigned",
|
|
8
|
-
IN_PROGRESS = "In Progress",
|
|
9
|
-
APPROVED = "Approved",
|
|
10
|
-
REJECTED = "Rejected"
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
@Entity({ name: 'diplomatic_academy_requests' })
|
|
14
|
-
export class DiplomaticAcademyRequests extends BaseModel {
|
|
15
|
-
|
|
16
|
-
// Common columns
|
|
17
|
-
@Column({ type: 'int', nullable: true })
|
|
18
|
-
req_user_department_id: number | null;
|
|
19
|
-
|
|
20
|
-
@Column({ type: 'int', nullable: true })
|
|
21
|
-
req_user_section_id: number | null;
|
|
22
|
-
|
|
23
|
-
@Column({ type: 'int', nullable: true })
|
|
24
|
-
service_id: number | null;
|
|
25
|
-
|
|
26
|
-
@Column({ type: 'int', nullable: true })
|
|
27
|
-
sub_service_id: number | null;
|
|
28
|
-
|
|
29
|
-
@Column({ type: 'int', nullable: false })
|
|
30
|
-
user_id: number;
|
|
31
|
-
|
|
32
|
-
// Diplomatic Academy specific columns
|
|
33
|
-
@Column({ type: 'varchar', length: 500, nullable: false })
|
|
34
|
-
course_name: string;
|
|
35
|
-
|
|
36
|
-
@Column({ type: 'jsonb', nullable: true })
|
|
37
|
-
cost_details: {
|
|
38
|
-
material_price?: number;
|
|
39
|
-
transportation?: number;
|
|
40
|
-
accommodation?: number;
|
|
41
|
-
allowances?: number;
|
|
42
|
-
food?: number;
|
|
43
|
-
present?: number;
|
|
44
|
-
} | null;
|
|
45
|
-
|
|
46
|
-
@Column({ type: 'int', nullable: false })
|
|
47
|
-
estimated_participants: number;
|
|
48
|
-
|
|
49
|
-
@Column({ type: 'date', nullable: false })
|
|
50
|
-
timeline_date_from: Date;
|
|
51
|
-
|
|
52
|
-
@Column({ type: 'date', nullable: false })
|
|
53
|
-
timeline_date_to: Date;
|
|
54
|
-
|
|
55
|
-
@Column({ type: 'time', nullable: true })
|
|
56
|
-
timeline_time_from: string | null;
|
|
57
|
-
|
|
58
|
-
@Column({ type: 'time', nullable: true })
|
|
59
|
-
timeline_time_to: string | null;
|
|
60
|
-
|
|
61
|
-
@Column({ type: 'jsonb', nullable: false })
|
|
62
|
-
participants_details: Array<{
|
|
63
|
-
full_name: string;
|
|
64
|
-
passport: string;
|
|
65
|
-
age: number;
|
|
66
|
-
qualifications: string;
|
|
67
|
-
experience: string;
|
|
68
|
-
institution: string;
|
|
69
|
-
}>;
|
|
70
|
-
|
|
71
|
-
@Column({ type: 'enum', enum: DiplomaticAcademyStatus, default: DiplomaticAcademyStatus.PENDING, nullable: false })
|
|
72
|
-
status: DiplomaticAcademyStatus;
|
|
73
|
-
|
|
74
|
-
@Column({ type: 'int', nullable: true })
|
|
75
|
-
course_id: number | null;
|
|
76
|
-
|
|
77
|
-
@Column({ type: 'varchar', nullable: true })
|
|
78
|
-
workflow_execution_id: string | null;
|
|
79
|
-
|
|
80
|
-
}
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
export enum DiplomaticAcademyStatus {
|
|
5
|
+
SUBMITTED = "Submitted",
|
|
6
|
+
PENDING = "Pending",
|
|
7
|
+
ASSIGNED = "Assigned",
|
|
8
|
+
IN_PROGRESS = "In Progress",
|
|
9
|
+
APPROVED = "Approved",
|
|
10
|
+
REJECTED = "Rejected"
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
@Entity({ name: 'diplomatic_academy_requests' })
|
|
14
|
+
export class DiplomaticAcademyRequests extends BaseModel {
|
|
15
|
+
|
|
16
|
+
// Common columns
|
|
17
|
+
@Column({ type: 'int', nullable: true })
|
|
18
|
+
req_user_department_id: number | null;
|
|
19
|
+
|
|
20
|
+
@Column({ type: 'int', nullable: true })
|
|
21
|
+
req_user_section_id: number | null;
|
|
22
|
+
|
|
23
|
+
@Column({ type: 'int', nullable: true })
|
|
24
|
+
service_id: number | null;
|
|
25
|
+
|
|
26
|
+
@Column({ type: 'int', nullable: true })
|
|
27
|
+
sub_service_id: number | null;
|
|
28
|
+
|
|
29
|
+
@Column({ type: 'int', nullable: false })
|
|
30
|
+
user_id: number;
|
|
31
|
+
|
|
32
|
+
// Diplomatic Academy specific columns
|
|
33
|
+
@Column({ type: 'varchar', length: 500, nullable: false })
|
|
34
|
+
course_name: string;
|
|
35
|
+
|
|
36
|
+
@Column({ type: 'jsonb', nullable: true })
|
|
37
|
+
cost_details: {
|
|
38
|
+
material_price?: number;
|
|
39
|
+
transportation?: number;
|
|
40
|
+
accommodation?: number;
|
|
41
|
+
allowances?: number;
|
|
42
|
+
food?: number;
|
|
43
|
+
present?: number;
|
|
44
|
+
} | null;
|
|
45
|
+
|
|
46
|
+
@Column({ type: 'int', nullable: false })
|
|
47
|
+
estimated_participants: number;
|
|
48
|
+
|
|
49
|
+
@Column({ type: 'date', nullable: false })
|
|
50
|
+
timeline_date_from: Date;
|
|
51
|
+
|
|
52
|
+
@Column({ type: 'date', nullable: false })
|
|
53
|
+
timeline_date_to: Date;
|
|
54
|
+
|
|
55
|
+
@Column({ type: 'time', nullable: true })
|
|
56
|
+
timeline_time_from: string | null;
|
|
57
|
+
|
|
58
|
+
@Column({ type: 'time', nullable: true })
|
|
59
|
+
timeline_time_to: string | null;
|
|
60
|
+
|
|
61
|
+
@Column({ type: 'jsonb', nullable: false })
|
|
62
|
+
participants_details: Array<{
|
|
63
|
+
full_name: string;
|
|
64
|
+
passport: string;
|
|
65
|
+
age: number;
|
|
66
|
+
qualifications: string;
|
|
67
|
+
experience: string;
|
|
68
|
+
institution: string;
|
|
69
|
+
}>;
|
|
70
|
+
|
|
71
|
+
@Column({ type: 'enum', enum: DiplomaticAcademyStatus, default: DiplomaticAcademyStatus.PENDING, nullable: false })
|
|
72
|
+
status: DiplomaticAcademyStatus;
|
|
73
|
+
|
|
74
|
+
@Column({ type: 'int', nullable: true })
|
|
75
|
+
course_id: number | null;
|
|
76
|
+
|
|
77
|
+
@Column({ type: 'varchar', nullable: true })
|
|
78
|
+
workflow_execution_id: string | null;
|
|
79
|
+
|
|
80
|
+
}
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'documentation_files' })
|
|
5
|
-
export class DocumentationFile extends BaseModel {
|
|
6
|
-
@Column({ type: 'int', nullable: true })
|
|
7
|
-
project_id: number | null;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'int' })
|
|
10
|
-
folder_id: number;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'text', nullable: true })
|
|
13
|
-
file_path: string;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'varchar', length: 500, nullable: true })
|
|
16
|
-
filename: string;
|
|
17
|
-
|
|
18
|
-
@Column({ type: 'bigint', nullable: true })
|
|
19
|
-
filesize: number;
|
|
20
|
-
|
|
21
|
-
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
22
|
-
filetype: string;
|
|
23
|
-
|
|
24
|
-
constructor(
|
|
25
|
-
project_id?: number | null,
|
|
26
|
-
folder_id?: number,
|
|
27
|
-
file_path?: string,
|
|
28
|
-
filename?: string,
|
|
29
|
-
filesize?: number,
|
|
30
|
-
filetype?: string
|
|
31
|
-
) {
|
|
32
|
-
super();
|
|
33
|
-
this.project_id = project_id ?? null;
|
|
34
|
-
this.folder_id = folder_id ?? 0;
|
|
35
|
-
this.file_path = file_path ?? '';
|
|
36
|
-
this.filename = filename ?? '';
|
|
37
|
-
this.filesize = filesize ?? 0;
|
|
38
|
-
this.filetype = filetype ?? '';
|
|
39
|
-
}
|
|
40
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'documentation_files' })
|
|
5
|
+
export class DocumentationFile extends BaseModel {
|
|
6
|
+
@Column({ type: 'int', nullable: true })
|
|
7
|
+
project_id: number | null;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'int' })
|
|
10
|
+
folder_id: number;
|
|
11
|
+
|
|
12
|
+
@Column({ type: 'text', nullable: true })
|
|
13
|
+
file_path: string;
|
|
14
|
+
|
|
15
|
+
@Column({ type: 'varchar', length: 500, nullable: true })
|
|
16
|
+
filename: string;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'bigint', nullable: true })
|
|
19
|
+
filesize: number;
|
|
20
|
+
|
|
21
|
+
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
22
|
+
filetype: string;
|
|
23
|
+
|
|
24
|
+
constructor(
|
|
25
|
+
project_id?: number | null,
|
|
26
|
+
folder_id?: number,
|
|
27
|
+
file_path?: string,
|
|
28
|
+
filename?: string,
|
|
29
|
+
filesize?: number,
|
|
30
|
+
filetype?: string
|
|
31
|
+
) {
|
|
32
|
+
super();
|
|
33
|
+
this.project_id = project_id ?? null;
|
|
34
|
+
this.folder_id = folder_id ?? 0;
|
|
35
|
+
this.file_path = file_path ?? '';
|
|
36
|
+
this.filename = filename ?? '';
|
|
37
|
+
this.filesize = filesize ?? 0;
|
|
38
|
+
this.filetype = filetype ?? '';
|
|
39
|
+
}
|
|
40
|
+
}
|
|
@@ -33,15 +33,15 @@ export class FinancialWorkFlow extends BaseModel {
|
|
|
33
33
|
@Column({ type: 'int', nullable: true })
|
|
34
34
|
approved_by_role_id: number;
|
|
35
35
|
|
|
36
|
-
@Column({ type: 'int', nullable: true })
|
|
37
|
-
step_order: number;
|
|
38
|
-
|
|
39
|
-
@Column({ type: 'varchar', length: 50, nullable: true })
|
|
40
|
-
action: string | null;
|
|
41
|
-
|
|
42
|
-
@ManyToOne(() => FinancialRequests, fr => fr.workflows)
|
|
43
|
-
@JoinColumn({ name: 'financial_request_id' })
|
|
44
|
-
financialRequest?: FinancialRequests;
|
|
36
|
+
@Column({ type: 'int', nullable: true })
|
|
37
|
+
step_order: number;
|
|
38
|
+
|
|
39
|
+
@Column({ type: 'varchar', length: 50, nullable: true })
|
|
40
|
+
action: string | null;
|
|
41
|
+
|
|
42
|
+
@ManyToOne(() => FinancialRequests, fr => fr.workflows)
|
|
43
|
+
@JoinColumn({ name: 'financial_request_id' })
|
|
44
|
+
financialRequest?: FinancialRequests;
|
|
45
45
|
|
|
46
46
|
constructor(
|
|
47
47
|
financial_request_id: number,
|
|
@@ -55,10 +55,10 @@ export class FinancialWorkFlow extends BaseModel {
|
|
|
55
55
|
this.status = status;
|
|
56
56
|
this.approved_by_user_id = approved_by_user_id;
|
|
57
57
|
this.content = content;
|
|
58
|
-
this.financial_approval_id = 0;
|
|
59
|
-
this.activity_date = new Date();
|
|
60
|
-
this.step_order = step_order;
|
|
61
|
-
this.action = null;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
58
|
+
this.financial_approval_id = 0;
|
|
59
|
+
this.activity_date = new Date();
|
|
60
|
+
this.step_order = step_order;
|
|
61
|
+
this.action = null;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
64
|
|
|
@@ -85,10 +85,10 @@ export class GatePassVisitors extends BaseModel {
|
|
|
85
85
|
@Column({ type: 'varchar', length: 255, nullable: true })
|
|
86
86
|
visiting_person_in_department: string | null; // زائر في القسم (Visiting Person in Department)
|
|
87
87
|
|
|
88
|
-
@Column({ type: 'int', nullable: true, unique: true })
|
|
89
|
-
serial_number: number | null;
|
|
90
|
-
|
|
91
|
-
// QR Code for Gate Pass
|
|
88
|
+
@Column({ type: 'int', nullable: true, unique: true })
|
|
89
|
+
serial_number: number | null;
|
|
90
|
+
|
|
91
|
+
// QR Code for Gate Pass
|
|
92
92
|
@Column({ type: 'text', nullable: true })
|
|
93
93
|
qr_code_url: string | null; // QR code URL for this visitor (data URL can be 6000+ characters)
|
|
94
94
|
|
|
@@ -134,9 +134,9 @@ export class GatePassVisitors extends BaseModel {
|
|
|
134
134
|
this.visitor_email_address = visitor_email_address;
|
|
135
135
|
this.visitor_mobile_number = visitor_mobile_number;
|
|
136
136
|
this.visitor_photo_url = visitor_photo_url;
|
|
137
|
-
this.visitor_photo_file_name = visitor_photo_file_name;
|
|
138
|
-
this.serial_number = null;
|
|
139
|
-
this.gate_pass_generated = false;
|
|
137
|
+
this.visitor_photo_file_name = visitor_photo_file_name;
|
|
138
|
+
this.serial_number = null;
|
|
139
|
+
this.gate_pass_generated = false;
|
|
140
140
|
this.email_sent = false;
|
|
141
141
|
}
|
|
142
142
|
}
|