@platform-modules/foreign-ministry 1.3.199 → 1.3.200
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 +10 -5
- package/dist/data-source.js +4 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/models/DocumentationFileModel.d.ts +9 -0
- package/dist/models/DocumentationFileModel.js +49 -0
- package/dist/models/DocumentationFolderModel.d.ts +8 -0
- package/dist/models/DocumentationFolderModel.js +44 -0
- package/dist/models/MissionTravelClassConfigModel.d.ts +10 -0
- package/dist/models/MissionTravelClassConfigModel.js +50 -0
- package/dist/models/MissionTravelPerdiemModel.d.ts +10 -0
- package/dist/models/MissionTravelPerdiemModel.js +54 -0
- package/package.json +1 -1
- package/src/data-source.ts +4 -0
- package/src/index.ts +2 -0
- package/src/models/DiplomaticAcademyRequestModel.ts +80 -80
- package/src/models/DocumentationFileModel.ts +35 -0
- package/src/models/DocumentationFolderModel.ts +25 -0
- 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/ProjectMilestoneDocumentsModel.ts +40 -40
- package/src/models/ProjectMilestonesModel.ts +65 -65
- package/src/models/ProjectModel.ts +65 -65
- package/src/models/ProjectTaskActivityModel.ts +35 -35
- package/src/models/ProjectTaskCommentsModel.ts +17 -17
- package/src/models/ProjectTasksModel.ts +80 -80
- package/src/models/SectionModel.ts +35 -35
- package/src/models/ServicesNotificationConfigsModel.ts +55 -55
- package/src/models/TelephoneDirectoryModel.ts +20 -20
- package/dist/models/EmbassyMasterModel.d.ts +0 -16
- package/dist/models/EmbassyMasterModel.js +0 -75
- package/dist/models/UserDependentsModel.d.ts +0 -18
- package/dist/models/UserDependentsModel.js +0 -94
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'project_milestone_documents' })
|
|
5
|
-
export class ProjectMilestoneDocuments extends BaseModel {
|
|
6
|
-
@Column({ type: 'int' })
|
|
7
|
-
project_id: number;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'int' })
|
|
10
|
-
milestone_id: number;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'text', nullable: true })
|
|
13
|
-
document_link: 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,
|
|
26
|
-
milestone_id?: number,
|
|
27
|
-
document_link?: string,
|
|
28
|
-
filename?: string,
|
|
29
|
-
filesize?: number,
|
|
30
|
-
filetype?: string
|
|
31
|
-
) {
|
|
32
|
-
super();
|
|
33
|
-
this.project_id = project_id ?? 0;
|
|
34
|
-
this.milestone_id = milestone_id ?? 0;
|
|
35
|
-
this.document_link = document_link ?? '';
|
|
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: 'project_milestone_documents' })
|
|
5
|
+
export class ProjectMilestoneDocuments extends BaseModel {
|
|
6
|
+
@Column({ type: 'int' })
|
|
7
|
+
project_id: number;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'int' })
|
|
10
|
+
milestone_id: number;
|
|
11
|
+
|
|
12
|
+
@Column({ type: 'text', nullable: true })
|
|
13
|
+
document_link: 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,
|
|
26
|
+
milestone_id?: number,
|
|
27
|
+
document_link?: string,
|
|
28
|
+
filename?: string,
|
|
29
|
+
filesize?: number,
|
|
30
|
+
filetype?: string
|
|
31
|
+
) {
|
|
32
|
+
super();
|
|
33
|
+
this.project_id = project_id ?? 0;
|
|
34
|
+
this.milestone_id = milestone_id ?? 0;
|
|
35
|
+
this.document_link = document_link ?? '';
|
|
36
|
+
this.filename = filename ?? '';
|
|
37
|
+
this.filesize = filesize ?? 0;
|
|
38
|
+
this.filetype = filetype ?? '';
|
|
39
|
+
}
|
|
40
|
+
}
|
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'project_milestones' })
|
|
5
|
-
export class ProjectMilestones extends BaseModel {
|
|
6
|
-
@Column({ type: 'int' })
|
|
7
|
-
project_id: number;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'varchar', length: 255 })
|
|
10
|
-
milestone_name: string;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'jsonb', nullable: true })
|
|
13
|
-
vendor_names: string[] | null;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'text', nullable: true })
|
|
16
|
-
milestone_description: string;
|
|
17
|
-
|
|
18
|
-
@Column({ type: 'date', nullable: true })
|
|
19
|
-
estimated_startdate: Date | null;
|
|
20
|
-
|
|
21
|
-
@Column({ type: 'date', nullable: true })
|
|
22
|
-
estimated_enddate: Date | null;
|
|
23
|
-
|
|
24
|
-
@Column({ type: 'date', nullable: true })
|
|
25
|
-
actual_startdate: Date | null;
|
|
26
|
-
|
|
27
|
-
@Column({ type: 'date', nullable: true })
|
|
28
|
-
actual_enddate: Date | null;
|
|
29
|
-
|
|
30
|
-
@Column({ type: 'jsonb', nullable: true })
|
|
31
|
-
checklist: string[] | null;
|
|
32
|
-
|
|
33
|
-
@Column({ type: 'varchar', length: 50, default: 'Not Started' })
|
|
34
|
-
status: string;
|
|
35
|
-
|
|
36
|
-
@Column({ type: 'int', default: 1, nullable: true })
|
|
37
|
-
phase: number;
|
|
38
|
-
|
|
39
|
-
constructor(
|
|
40
|
-
project_id?: number,
|
|
41
|
-
milestone_name?: string,
|
|
42
|
-
vendor_names?: string[] | null,
|
|
43
|
-
milestone_description?: string,
|
|
44
|
-
estimated_startdate?: Date | null,
|
|
45
|
-
estimated_enddate?: Date | null,
|
|
46
|
-
actual_startdate?: Date | null,
|
|
47
|
-
actual_enddate?: Date | null,
|
|
48
|
-
checklist?: string[] | null,
|
|
49
|
-
status?: string,
|
|
50
|
-
phase?: number
|
|
51
|
-
) {
|
|
52
|
-
super();
|
|
53
|
-
this.project_id = project_id ?? 0;
|
|
54
|
-
this.milestone_name = milestone_name ?? '';
|
|
55
|
-
this.vendor_names = vendor_names ?? null;
|
|
56
|
-
this.milestone_description = milestone_description ?? '';
|
|
57
|
-
this.estimated_startdate = estimated_startdate ?? null;
|
|
58
|
-
this.estimated_enddate = estimated_enddate ?? null;
|
|
59
|
-
this.actual_startdate = actual_startdate ?? null;
|
|
60
|
-
this.actual_enddate = actual_enddate ?? null;
|
|
61
|
-
this.checklist = checklist ?? null;
|
|
62
|
-
this.status = status ?? 'Not Started';
|
|
63
|
-
this.phase = phase ?? 1;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'project_milestones' })
|
|
5
|
+
export class ProjectMilestones extends BaseModel {
|
|
6
|
+
@Column({ type: 'int' })
|
|
7
|
+
project_id: number;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'varchar', length: 255 })
|
|
10
|
+
milestone_name: string;
|
|
11
|
+
|
|
12
|
+
@Column({ type: 'jsonb', nullable: true })
|
|
13
|
+
vendor_names: string[] | null;
|
|
14
|
+
|
|
15
|
+
@Column({ type: 'text', nullable: true })
|
|
16
|
+
milestone_description: string;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'date', nullable: true })
|
|
19
|
+
estimated_startdate: Date | null;
|
|
20
|
+
|
|
21
|
+
@Column({ type: 'date', nullable: true })
|
|
22
|
+
estimated_enddate: Date | null;
|
|
23
|
+
|
|
24
|
+
@Column({ type: 'date', nullable: true })
|
|
25
|
+
actual_startdate: Date | null;
|
|
26
|
+
|
|
27
|
+
@Column({ type: 'date', nullable: true })
|
|
28
|
+
actual_enddate: Date | null;
|
|
29
|
+
|
|
30
|
+
@Column({ type: 'jsonb', nullable: true })
|
|
31
|
+
checklist: string[] | null;
|
|
32
|
+
|
|
33
|
+
@Column({ type: 'varchar', length: 50, default: 'Not Started' })
|
|
34
|
+
status: string;
|
|
35
|
+
|
|
36
|
+
@Column({ type: 'int', default: 1, nullable: true })
|
|
37
|
+
phase: number;
|
|
38
|
+
|
|
39
|
+
constructor(
|
|
40
|
+
project_id?: number,
|
|
41
|
+
milestone_name?: string,
|
|
42
|
+
vendor_names?: string[] | null,
|
|
43
|
+
milestone_description?: string,
|
|
44
|
+
estimated_startdate?: Date | null,
|
|
45
|
+
estimated_enddate?: Date | null,
|
|
46
|
+
actual_startdate?: Date | null,
|
|
47
|
+
actual_enddate?: Date | null,
|
|
48
|
+
checklist?: string[] | null,
|
|
49
|
+
status?: string,
|
|
50
|
+
phase?: number
|
|
51
|
+
) {
|
|
52
|
+
super();
|
|
53
|
+
this.project_id = project_id ?? 0;
|
|
54
|
+
this.milestone_name = milestone_name ?? '';
|
|
55
|
+
this.vendor_names = vendor_names ?? null;
|
|
56
|
+
this.milestone_description = milestone_description ?? '';
|
|
57
|
+
this.estimated_startdate = estimated_startdate ?? null;
|
|
58
|
+
this.estimated_enddate = estimated_enddate ?? null;
|
|
59
|
+
this.actual_startdate = actual_startdate ?? null;
|
|
60
|
+
this.actual_enddate = actual_enddate ?? null;
|
|
61
|
+
this.checklist = checklist ?? null;
|
|
62
|
+
this.status = status ?? 'Not Started';
|
|
63
|
+
this.phase = phase ?? 1;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'projects' })
|
|
5
|
-
export class Projects extends BaseModel {
|
|
6
|
-
@Column({ type: 'varchar', length: 255 })
|
|
7
|
-
project_name: string;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'text' , nullable: true})
|
|
10
|
-
project_objective: string;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'text' , nullable: true})
|
|
13
|
-
project_benefits: string;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'text' , nullable: true})
|
|
16
|
-
project_risks: string;
|
|
17
|
-
|
|
18
|
-
@Column({ type: 'text' , nullable: true})
|
|
19
|
-
project_challenges: string;
|
|
20
|
-
|
|
21
|
-
@Column({ type: 'text' , nullable: true})
|
|
22
|
-
project_description: string;
|
|
23
|
-
|
|
24
|
-
@Column({ type: 'text' , nullable: true})
|
|
25
|
-
project_status: string;
|
|
26
|
-
|
|
27
|
-
@Column({ type: 'text' , nullable: true})
|
|
28
|
-
roadmap_link: string;
|
|
29
|
-
|
|
30
|
-
@Column({ type: 'jsonb' , nullable: true})
|
|
31
|
-
template_ids: number[] | null;
|
|
32
|
-
|
|
33
|
-
@Column({ type: 'varchar', length: 100, nullable: true})
|
|
34
|
-
project_version: string;
|
|
35
|
-
|
|
36
|
-
@Column({ type: 'int', default: 0, nullable: true })
|
|
37
|
-
no_of_phases: number;
|
|
38
|
-
|
|
39
|
-
constructor(
|
|
40
|
-
project_name?: string,
|
|
41
|
-
project_objective?: string,
|
|
42
|
-
project_benefits?: string,
|
|
43
|
-
project_risks?: string,
|
|
44
|
-
project_challenges?: string,
|
|
45
|
-
project_description?: string,
|
|
46
|
-
project_status?: string,
|
|
47
|
-
roadmap_link?: string | null,
|
|
48
|
-
template_ids?: number[] | null,
|
|
49
|
-
project_version?: string,
|
|
50
|
-
no_of_phases?: number
|
|
51
|
-
) {
|
|
52
|
-
super();
|
|
53
|
-
this.project_name = project_name || '';
|
|
54
|
-
this.project_objective = project_objective || '';
|
|
55
|
-
this.project_benefits = project_benefits || '';
|
|
56
|
-
this.project_risks = project_risks || '';
|
|
57
|
-
this.project_challenges = project_challenges || '';
|
|
58
|
-
this.project_description = project_description || '';
|
|
59
|
-
this.project_status = project_status || '';
|
|
60
|
-
this.roadmap_link = roadmap_link || '';
|
|
61
|
-
this.template_ids = template_ids || [];
|
|
62
|
-
this.project_version = project_version || '';
|
|
63
|
-
this.no_of_phases = no_of_phases ?? 0;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'projects' })
|
|
5
|
+
export class Projects extends BaseModel {
|
|
6
|
+
@Column({ type: 'varchar', length: 255 })
|
|
7
|
+
project_name: string;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'text' , nullable: true})
|
|
10
|
+
project_objective: string;
|
|
11
|
+
|
|
12
|
+
@Column({ type: 'text' , nullable: true})
|
|
13
|
+
project_benefits: string;
|
|
14
|
+
|
|
15
|
+
@Column({ type: 'text' , nullable: true})
|
|
16
|
+
project_risks: string;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'text' , nullable: true})
|
|
19
|
+
project_challenges: string;
|
|
20
|
+
|
|
21
|
+
@Column({ type: 'text' , nullable: true})
|
|
22
|
+
project_description: string;
|
|
23
|
+
|
|
24
|
+
@Column({ type: 'text' , nullable: true})
|
|
25
|
+
project_status: string;
|
|
26
|
+
|
|
27
|
+
@Column({ type: 'text' , nullable: true})
|
|
28
|
+
roadmap_link: string;
|
|
29
|
+
|
|
30
|
+
@Column({ type: 'jsonb' , nullable: true})
|
|
31
|
+
template_ids: number[] | null;
|
|
32
|
+
|
|
33
|
+
@Column({ type: 'varchar', length: 100, nullable: true})
|
|
34
|
+
project_version: string;
|
|
35
|
+
|
|
36
|
+
@Column({ type: 'int', default: 0, nullable: true })
|
|
37
|
+
no_of_phases: number;
|
|
38
|
+
|
|
39
|
+
constructor(
|
|
40
|
+
project_name?: string,
|
|
41
|
+
project_objective?: string,
|
|
42
|
+
project_benefits?: string,
|
|
43
|
+
project_risks?: string,
|
|
44
|
+
project_challenges?: string,
|
|
45
|
+
project_description?: string,
|
|
46
|
+
project_status?: string,
|
|
47
|
+
roadmap_link?: string | null,
|
|
48
|
+
template_ids?: number[] | null,
|
|
49
|
+
project_version?: string,
|
|
50
|
+
no_of_phases?: number
|
|
51
|
+
) {
|
|
52
|
+
super();
|
|
53
|
+
this.project_name = project_name || '';
|
|
54
|
+
this.project_objective = project_objective || '';
|
|
55
|
+
this.project_benefits = project_benefits || '';
|
|
56
|
+
this.project_risks = project_risks || '';
|
|
57
|
+
this.project_challenges = project_challenges || '';
|
|
58
|
+
this.project_description = project_description || '';
|
|
59
|
+
this.project_status = project_status || '';
|
|
60
|
+
this.roadmap_link = roadmap_link || '';
|
|
61
|
+
this.template_ids = template_ids || [];
|
|
62
|
+
this.project_version = project_version || '';
|
|
63
|
+
this.no_of_phases = no_of_phases ?? 0;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'project_task_activity' })
|
|
5
|
-
export class ProjectTaskActivity extends BaseModel {
|
|
6
|
-
@Column({ type: 'int' })
|
|
7
|
-
task_id: number;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
10
|
-
activity_type: string;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'text', nullable: true })
|
|
13
|
-
description: string;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'text', nullable: true })
|
|
16
|
-
old_value: string | null;
|
|
17
|
-
|
|
18
|
-
@Column({ type: 'text', nullable: true })
|
|
19
|
-
new_value: string | null;
|
|
20
|
-
|
|
21
|
-
constructor(
|
|
22
|
-
task_id?: number,
|
|
23
|
-
activity_type?: string,
|
|
24
|
-
description?: string,
|
|
25
|
-
old_value?: string | null,
|
|
26
|
-
new_value?: string | null
|
|
27
|
-
) {
|
|
28
|
-
super();
|
|
29
|
-
this.task_id = task_id ?? 0;
|
|
30
|
-
this.activity_type = activity_type ?? '';
|
|
31
|
-
this.description = description ?? '';
|
|
32
|
-
this.old_value = old_value ?? null;
|
|
33
|
-
this.new_value = new_value ?? null;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'project_task_activity' })
|
|
5
|
+
export class ProjectTaskActivity extends BaseModel {
|
|
6
|
+
@Column({ type: 'int' })
|
|
7
|
+
task_id: number;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
10
|
+
activity_type: string;
|
|
11
|
+
|
|
12
|
+
@Column({ type: 'text', nullable: true })
|
|
13
|
+
description: string;
|
|
14
|
+
|
|
15
|
+
@Column({ type: 'text', nullable: true })
|
|
16
|
+
old_value: string | null;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'text', nullable: true })
|
|
19
|
+
new_value: string | null;
|
|
20
|
+
|
|
21
|
+
constructor(
|
|
22
|
+
task_id?: number,
|
|
23
|
+
activity_type?: string,
|
|
24
|
+
description?: string,
|
|
25
|
+
old_value?: string | null,
|
|
26
|
+
new_value?: string | null
|
|
27
|
+
) {
|
|
28
|
+
super();
|
|
29
|
+
this.task_id = task_id ?? 0;
|
|
30
|
+
this.activity_type = activity_type ?? '';
|
|
31
|
+
this.description = description ?? '';
|
|
32
|
+
this.old_value = old_value ?? null;
|
|
33
|
+
this.new_value = new_value ?? null;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'project_task_comments' })
|
|
5
|
-
export class ProjectTaskComments extends BaseModel {
|
|
6
|
-
@Column({ type: 'int' })
|
|
7
|
-
task_id: number;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'text' })
|
|
10
|
-
comment: string;
|
|
11
|
-
|
|
12
|
-
constructor(task_id?: number, comment?: string) {
|
|
13
|
-
super();
|
|
14
|
-
this.task_id = task_id ?? 0;
|
|
15
|
-
this.comment = comment ?? '';
|
|
16
|
-
}
|
|
17
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'project_task_comments' })
|
|
5
|
+
export class ProjectTaskComments extends BaseModel {
|
|
6
|
+
@Column({ type: 'int' })
|
|
7
|
+
task_id: number;
|
|
8
|
+
|
|
9
|
+
@Column({ type: 'text' })
|
|
10
|
+
comment: string;
|
|
11
|
+
|
|
12
|
+
constructor(task_id?: number, comment?: string) {
|
|
13
|
+
super();
|
|
14
|
+
this.task_id = task_id ?? 0;
|
|
15
|
+
this.comment = comment ?? '';
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
import { Column, Entity } from 'typeorm';
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
export interface TaskAttachmentItem {
|
|
5
|
-
link?: string;
|
|
6
|
-
filename?: string;
|
|
7
|
-
filesize?: number;
|
|
8
|
-
filetype?: string;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export const TASK_PRIORITY = ['low', 'medium', 'high'] as const;
|
|
12
|
-
export const TASK_STATUS = ['Not started', 'Pending', 'In Progress', 'Completed'] as const;
|
|
13
|
-
|
|
14
|
-
@Entity({ name: 'project_tasks' })
|
|
15
|
-
export class ProjectTasks extends BaseModel {
|
|
16
|
-
@Column({ type: 'int' })
|
|
17
|
-
project_id: number;
|
|
18
|
-
|
|
19
|
-
@Column({ type: 'varchar', length: 500 })
|
|
20
|
-
task_title: string;
|
|
21
|
-
|
|
22
|
-
@Column({ type: 'text', nullable: true })
|
|
23
|
-
task_description: string;
|
|
24
|
-
|
|
25
|
-
@Column({ type: 'jsonb', nullable: true })
|
|
26
|
-
attachments: TaskAttachmentItem[] | null;
|
|
27
|
-
|
|
28
|
-
@Column({ type: 'varchar', length: 20, default: 'medium' })
|
|
29
|
-
priority: string;
|
|
30
|
-
|
|
31
|
-
@Column({ type: 'varchar', length: 50, default: 'Not started' })
|
|
32
|
-
status: string;
|
|
33
|
-
|
|
34
|
-
@Column({ type: 'int', nullable: true })
|
|
35
|
-
milestone_id: number | null;
|
|
36
|
-
|
|
37
|
-
@Column({ type: 'int', default: 1, nullable: true })
|
|
38
|
-
phase: number;
|
|
39
|
-
|
|
40
|
-
@Column({ type: 'int', nullable: true })
|
|
41
|
-
assign_to: number | null;
|
|
42
|
-
|
|
43
|
-
@Column({ type: 'int', nullable: true })
|
|
44
|
-
manager_id: number | null;
|
|
45
|
-
|
|
46
|
-
@Column({ type: 'date', nullable: true })
|
|
47
|
-
start_date: Date | null;
|
|
48
|
-
|
|
49
|
-
@Column({ type: 'date', nullable: true })
|
|
50
|
-
end_date: Date | null;
|
|
51
|
-
|
|
52
|
-
constructor(
|
|
53
|
-
project_id?: number,
|
|
54
|
-
task_title?: string,
|
|
55
|
-
task_description?: string,
|
|
56
|
-
attachments?: TaskAttachmentItem[] | null,
|
|
57
|
-
priority?: string,
|
|
58
|
-
status?: string,
|
|
59
|
-
milestone_id?: number | null,
|
|
60
|
-
phase?: number,
|
|
61
|
-
assign_to?: number | null,
|
|
62
|
-
manager_id?: number | null,
|
|
63
|
-
start_date?: Date | null,
|
|
64
|
-
end_date?: Date | null
|
|
65
|
-
) {
|
|
66
|
-
super();
|
|
67
|
-
this.project_id = project_id ?? 0;
|
|
68
|
-
this.task_title = task_title ?? '';
|
|
69
|
-
this.task_description = task_description ?? '';
|
|
70
|
-
this.attachments = attachments ?? null;
|
|
71
|
-
this.priority = priority ?? 'medium';
|
|
72
|
-
this.status = status ?? 'Not started';
|
|
73
|
-
this.milestone_id = milestone_id ?? null;
|
|
74
|
-
this.phase = phase ?? 1;
|
|
75
|
-
this.assign_to = assign_to ?? null;
|
|
76
|
-
this.manager_id = manager_id ?? null;
|
|
77
|
-
this.start_date = start_date ?? null;
|
|
78
|
-
this.end_date = end_date ?? null;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
1
|
+
import { Column, Entity } from 'typeorm';
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
export interface TaskAttachmentItem {
|
|
5
|
+
link?: string;
|
|
6
|
+
filename?: string;
|
|
7
|
+
filesize?: number;
|
|
8
|
+
filetype?: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export const TASK_PRIORITY = ['low', 'medium', 'high'] as const;
|
|
12
|
+
export const TASK_STATUS = ['Not started', 'Pending', 'In Progress', 'Completed'] as const;
|
|
13
|
+
|
|
14
|
+
@Entity({ name: 'project_tasks' })
|
|
15
|
+
export class ProjectTasks extends BaseModel {
|
|
16
|
+
@Column({ type: 'int' })
|
|
17
|
+
project_id: number;
|
|
18
|
+
|
|
19
|
+
@Column({ type: 'varchar', length: 500 })
|
|
20
|
+
task_title: string;
|
|
21
|
+
|
|
22
|
+
@Column({ type: 'text', nullable: true })
|
|
23
|
+
task_description: string;
|
|
24
|
+
|
|
25
|
+
@Column({ type: 'jsonb', nullable: true })
|
|
26
|
+
attachments: TaskAttachmentItem[] | null;
|
|
27
|
+
|
|
28
|
+
@Column({ type: 'varchar', length: 20, default: 'medium' })
|
|
29
|
+
priority: string;
|
|
30
|
+
|
|
31
|
+
@Column({ type: 'varchar', length: 50, default: 'Not started' })
|
|
32
|
+
status: string;
|
|
33
|
+
|
|
34
|
+
@Column({ type: 'int', nullable: true })
|
|
35
|
+
milestone_id: number | null;
|
|
36
|
+
|
|
37
|
+
@Column({ type: 'int', default: 1, nullable: true })
|
|
38
|
+
phase: number;
|
|
39
|
+
|
|
40
|
+
@Column({ type: 'int', nullable: true })
|
|
41
|
+
assign_to: number | null;
|
|
42
|
+
|
|
43
|
+
@Column({ type: 'int', nullable: true })
|
|
44
|
+
manager_id: number | null;
|
|
45
|
+
|
|
46
|
+
@Column({ type: 'date', nullable: true })
|
|
47
|
+
start_date: Date | null;
|
|
48
|
+
|
|
49
|
+
@Column({ type: 'date', nullable: true })
|
|
50
|
+
end_date: Date | null;
|
|
51
|
+
|
|
52
|
+
constructor(
|
|
53
|
+
project_id?: number,
|
|
54
|
+
task_title?: string,
|
|
55
|
+
task_description?: string,
|
|
56
|
+
attachments?: TaskAttachmentItem[] | null,
|
|
57
|
+
priority?: string,
|
|
58
|
+
status?: string,
|
|
59
|
+
milestone_id?: number | null,
|
|
60
|
+
phase?: number,
|
|
61
|
+
assign_to?: number | null,
|
|
62
|
+
manager_id?: number | null,
|
|
63
|
+
start_date?: Date | null,
|
|
64
|
+
end_date?: Date | null
|
|
65
|
+
) {
|
|
66
|
+
super();
|
|
67
|
+
this.project_id = project_id ?? 0;
|
|
68
|
+
this.task_title = task_title ?? '';
|
|
69
|
+
this.task_description = task_description ?? '';
|
|
70
|
+
this.attachments = attachments ?? null;
|
|
71
|
+
this.priority = priority ?? 'medium';
|
|
72
|
+
this.status = status ?? 'Not started';
|
|
73
|
+
this.milestone_id = milestone_id ?? null;
|
|
74
|
+
this.phase = phase ?? 1;
|
|
75
|
+
this.assign_to = assign_to ?? null;
|
|
76
|
+
this.manager_id = manager_id ?? null;
|
|
77
|
+
this.start_date = start_date ?? null;
|
|
78
|
+
this.end_date = end_date ?? null;
|
|
79
|
+
}
|
|
80
|
+
}
|