@platform-modules/foreign-ministry 1.3.138 → 1.3.139

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.
@@ -177,6 +177,8 @@ const HallChatModel_1 = require("./models/HallChatModel");
177
177
  const HallWorkflowModel_1 = require("./models/HallWorkflowModel");
178
178
  const HallMasterModel_1 = require("./models/HallMasterModel");
179
179
  const HallHistoryModel_1 = require("./models/HallHistoryModel");
180
+ const GiftsModel_1 = require("./models/GiftsModel");
181
+ const GiftAttachmentModel_1 = require("./models/GiftAttachmentModel");
180
182
  exports.AppDataSource = new typeorm_1.DataSource({
181
183
  type: 'postgres',
182
184
  host: process.env.DB_HOST || 'localhost',
@@ -359,5 +361,7 @@ exports.AppDataSource = new typeorm_1.DataSource({
359
361
  HallWorkflowModel_1.HallWorkFlow,
360
362
  HallMasterModel_1.HallMaster,
361
363
  HallHistoryModel_1.HallHistory,
364
+ GiftsModel_1.Gifts,
365
+ GiftAttachmentModel_1.GiftAttachments,
362
366
  ],
363
367
  });
package/dist/index.d.ts CHANGED
@@ -267,6 +267,8 @@ export * from './models/HallChatModel';
267
267
  export * from './models/HallWorkflowModel';
268
268
  export * from './models/HallMasterModel';
269
269
  export * from './models/HallHistoryModel';
270
+ export * from './models/GiftsModel';
271
+ export * from './models/GiftAttachmentModel';
270
272
  export * from './models/EmployeeMilestonesModel';
271
273
  export * from './models/EmployeeMilestoneDetailsModel';
272
274
  export * from './models/MissionTravelPassportExpiryNotificationConfigModel';
package/dist/index.js CHANGED
@@ -328,6 +328,8 @@ __exportStar(require("./models/HallChatModel"), exports);
328
328
  __exportStar(require("./models/HallWorkflowModel"), exports);
329
329
  __exportStar(require("./models/HallMasterModel"), exports);
330
330
  __exportStar(require("./models/HallHistoryModel"), exports);
331
+ __exportStar(require("./models/GiftsModel"), exports);
332
+ __exportStar(require("./models/GiftAttachmentModel"), exports);
331
333
  // Employee Milestones Models
332
334
  __exportStar(require("./models/EmployeeMilestonesModel"), exports);
333
335
  __exportStar(require("./models/EmployeeMilestoneDetailsModel"), exports);
@@ -0,0 +1,9 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class GiftAttachments extends BaseModel {
3
+ gift_id: number | null;
4
+ file_url: string;
5
+ file_name: string | null;
6
+ file_type: string | null;
7
+ file_size: number | null;
8
+ constructor(gift_id?: number | null, file_url?: string, file_name?: string | null, file_type?: string | null, file_size?: number | null);
9
+ }
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.GiftAttachments = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let GiftAttachments = class GiftAttachments extends BaseModel_1.BaseModel {
16
+ constructor(gift_id, file_url, file_name, file_type, file_size) {
17
+ super();
18
+ this.gift_id = gift_id ?? null;
19
+ if (file_url)
20
+ this.file_url = file_url;
21
+ this.file_name = file_name ?? null;
22
+ this.file_type = file_type ?? null;
23
+ this.file_size = file_size ?? null;
24
+ }
25
+ };
26
+ exports.GiftAttachments = GiftAttachments;
27
+ __decorate([
28
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
29
+ __metadata("design:type", Object)
30
+ ], GiftAttachments.prototype, "gift_id", void 0);
31
+ __decorate([
32
+ (0, typeorm_1.Column)({ type: 'varchar', length: 1000, nullable: false }),
33
+ __metadata("design:type", String)
34
+ ], GiftAttachments.prototype, "file_url", void 0);
35
+ __decorate([
36
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
37
+ __metadata("design:type", Object)
38
+ ], GiftAttachments.prototype, "file_name", void 0);
39
+ __decorate([
40
+ (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
41
+ __metadata("design:type", Object)
42
+ ], GiftAttachments.prototype, "file_type", void 0);
43
+ __decorate([
44
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
45
+ __metadata("design:type", Object)
46
+ ], GiftAttachments.prototype, "file_size", void 0);
47
+ exports.GiftAttachments = GiftAttachments = __decorate([
48
+ (0, typeorm_1.Entity)({ name: 'gift_attachments' }),
49
+ __metadata("design:paramtypes", [Object, String, Object, Object, Object])
50
+ ], GiftAttachments);
@@ -0,0 +1,17 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare enum GiftExchangeType {
3
+ MINISTRY_TO_MINISTRY = "Ministry to Ministry",
4
+ MINISTRY_TO_EMBASSY = "Ministry to Embassy",
5
+ MANDC_TO_MINISTRY = "M&C to Ministry",
6
+ MINISTRY_TO_COMPANY = "Ministry to Company"
7
+ }
8
+ export declare class Gifts extends BaseModel {
9
+ meeting_id: number | null;
10
+ gift_type: GiftExchangeType | null;
11
+ description: string | null;
12
+ date_of_exchange: string | null;
13
+ location_id: number | null;
14
+ gift_given_by: string | null;
15
+ gift_received_by: string | null;
16
+ constructor(meeting_id?: number | null, gift_type?: GiftExchangeType | null, description?: string | null, date_of_exchange?: string | null, location_id?: number | null, gift_given_by?: string | null, gift_received_by?: string | null);
17
+ }
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.Gifts = exports.GiftExchangeType = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var GiftExchangeType;
16
+ (function (GiftExchangeType) {
17
+ GiftExchangeType["MINISTRY_TO_MINISTRY"] = "Ministry to Ministry";
18
+ GiftExchangeType["MINISTRY_TO_EMBASSY"] = "Ministry to Embassy";
19
+ GiftExchangeType["MANDC_TO_MINISTRY"] = "M&C to Ministry";
20
+ GiftExchangeType["MINISTRY_TO_COMPANY"] = "Ministry to Company";
21
+ })(GiftExchangeType || (exports.GiftExchangeType = GiftExchangeType = {}));
22
+ let Gifts = class Gifts extends BaseModel_1.BaseModel {
23
+ constructor(meeting_id, gift_type, description, date_of_exchange, location_id, gift_given_by, gift_received_by) {
24
+ super();
25
+ this.meeting_id = meeting_id ?? null;
26
+ this.gift_type = gift_type ?? null;
27
+ this.description = description ?? null;
28
+ this.date_of_exchange = date_of_exchange ?? null;
29
+ this.location_id = location_id ?? null;
30
+ this.gift_given_by = gift_given_by ?? null;
31
+ this.gift_received_by = gift_received_by ?? null;
32
+ }
33
+ };
34
+ exports.Gifts = Gifts;
35
+ __decorate([
36
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
37
+ __metadata("design:type", Object)
38
+ ], Gifts.prototype, "meeting_id", void 0);
39
+ __decorate([
40
+ (0, typeorm_1.Column)({ type: 'enum', enum: GiftExchangeType, nullable: true }),
41
+ __metadata("design:type", Object)
42
+ ], Gifts.prototype, "gift_type", void 0);
43
+ __decorate([
44
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
45
+ __metadata("design:type", Object)
46
+ ], Gifts.prototype, "description", void 0);
47
+ __decorate([
48
+ (0, typeorm_1.Column)({ type: 'date', nullable: true }),
49
+ __metadata("design:type", Object)
50
+ ], Gifts.prototype, "date_of_exchange", void 0);
51
+ __decorate([
52
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
53
+ __metadata("design:type", Object)
54
+ ], Gifts.prototype, "location_id", void 0);
55
+ __decorate([
56
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
57
+ __metadata("design:type", Object)
58
+ ], Gifts.prototype, "gift_given_by", void 0);
59
+ __decorate([
60
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
61
+ __metadata("design:type", Object)
62
+ ], Gifts.prototype, "gift_received_by", void 0);
63
+ exports.Gifts = Gifts = __decorate([
64
+ (0, typeorm_1.Entity)({ name: 'gifts' }),
65
+ __metadata("design:paramtypes", [Object, Object, Object, Object, Object, Object, Object])
66
+ ], Gifts);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platform-modules/foreign-ministry",
3
- "version": "1.3.138",
3
+ "version": "1.3.139",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {
@@ -183,6 +183,8 @@ import { HallRequestChat } from './models/HallChatModel';
183
183
  import { HallWorkFlow } from './models/HallWorkflowModel';
184
184
  import { HallMaster } from './models/HallMasterModel';
185
185
  import { HallHistory } from './models/HallHistoryModel';
186
+ import { Gifts } from './models/GiftsModel';
187
+ import { GiftAttachments } from './models/GiftAttachmentModel';
186
188
 
187
189
 
188
190
  export const AppDataSource = new DataSource({
@@ -367,5 +369,7 @@ export const AppDataSource = new DataSource({
367
369
  HallWorkFlow,
368
370
  HallMaster,
369
371
  HallHistory,
372
+ Gifts,
373
+ GiftAttachments,
370
374
  ],
371
375
  });
package/src/index.ts CHANGED
@@ -276,6 +276,8 @@ export * from './models/HallWorkflowModel';
276
276
  export * from './models/HallMasterModel';
277
277
 
278
278
  export * from './models/HallHistoryModel';
279
+ export * from './models/GiftsModel';
280
+ export * from './models/GiftAttachmentModel';
279
281
 
280
282
  // Employee Milestones Models
281
283
  export * from './models/EmployeeMilestonesModel';
@@ -0,0 +1,30 @@
1
+ import { Column, Entity } from 'typeorm';
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ @Entity({ name: 'gift_attachments' })
5
+ export class GiftAttachments extends BaseModel {
6
+ @Column({ type: 'int', nullable: true })
7
+ gift_id: number | null;
8
+
9
+ @Column({ type: 'varchar', length: 1000, nullable: false })
10
+ file_url: string;
11
+
12
+ @Column({ type: 'varchar', length: 255, nullable: true })
13
+ file_name: string | null;
14
+
15
+ @Column({ type: 'varchar', length: 100, nullable: true })
16
+ file_type: string | null;
17
+
18
+ @Column({ type: 'int', nullable: true })
19
+ file_size: number | null;
20
+
21
+ constructor(gift_id?: number | null, file_url?: string, file_name?: string | null, file_type?: string | null, file_size?: number | null) {
22
+ super();
23
+ this.gift_id = gift_id ?? null;
24
+ if (file_url) this.file_url = file_url;
25
+ this.file_name = file_name ?? null;
26
+ this.file_type = file_type ?? null;
27
+ this.file_size = file_size ?? null;
28
+ }
29
+ }
30
+
@@ -0,0 +1,53 @@
1
+ import { Column, Entity } from 'typeorm';
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ export enum GiftExchangeType {
5
+ MINISTRY_TO_MINISTRY = 'Ministry to Ministry',
6
+ MINISTRY_TO_EMBASSY = 'Ministry to Embassy',
7
+ MANDC_TO_MINISTRY = 'M&C to Ministry',
8
+ MINISTRY_TO_COMPANY = 'Ministry to Company'
9
+ }
10
+
11
+ @Entity({ name: 'gifts' })
12
+ export class Gifts extends BaseModel {
13
+ @Column({ type: 'int', nullable: true })
14
+ meeting_id: number | null;
15
+
16
+ @Column({ type: 'enum', enum: GiftExchangeType, nullable: true })
17
+ gift_type: GiftExchangeType | null;
18
+
19
+ @Column({ type: 'text', nullable: true })
20
+ description: string | null;
21
+
22
+ @Column({ type: 'date', nullable: true })
23
+ date_of_exchange: string | null;
24
+
25
+ @Column({ type: 'int', nullable: true })
26
+ location_id: number | null;
27
+
28
+ @Column({ type: 'varchar', length: 255, nullable: true })
29
+ gift_given_by: string | null;
30
+
31
+ @Column({ type: 'varchar', length: 255, nullable: true })
32
+ gift_received_by: string | null;
33
+
34
+ constructor(
35
+ meeting_id?: number | null,
36
+ gift_type?: GiftExchangeType | null,
37
+ description?: string | null,
38
+ date_of_exchange?: string | null,
39
+ location_id?: number | null,
40
+ gift_given_by?: string | null,
41
+ gift_received_by?: string | null
42
+ ) {
43
+ super();
44
+ this.meeting_id = meeting_id ?? null;
45
+ this.gift_type = gift_type ?? null;
46
+ this.description = description ?? null;
47
+ this.date_of_exchange = date_of_exchange ?? null;
48
+ this.location_id = location_id ?? null;
49
+ this.gift_given_by = gift_given_by ?? null;
50
+ this.gift_received_by = gift_received_by ?? null;
51
+ }
52
+ }
53
+