easywork-common-lib 1.0.691 → 1.0.693
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/dist/common/functions/image.d.ts +1 -0
- package/dist/common/functions/image.js +5 -3
- package/dist/common/functions/image.js.map +1 -1
- package/dist/entities/capacitation/course-evaluation.entity.d.ts +1 -1
- package/dist/entities/capacitation/course-evaluation.entity.js +2 -2
- package/dist/entities/capacitation/course-evaluation.entity.js.map +1 -1
- package/dist/entities/helpers/sales/agent/h_agent_recruiment_stage.entity.d.ts +5 -0
- package/dist/entities/helpers/sales/agent/h_agent_recruiment_stage.entity.js +40 -0
- package/dist/entities/helpers/sales/agent/h_agent_recruiment_stage.entity.js.map +1 -0
- package/dist/entities/helpers/sales/poliza/poliza_file.entity.d.ts +11 -0
- package/dist/entities/helpers/sales/poliza/poliza_file.entity.js +68 -0
- package/dist/entities/helpers/sales/poliza/poliza_file.entity.js.map +1 -0
- package/package.json +1 -1
- package/tsconfig.tsbuildinfo +1 -1
- package/dist/entities/capacitation/course-progress.entity.d.ts +0 -14
- package/dist/entities/capacitation/course-progress.entity.js +0 -53
- package/dist/entities/capacitation/course-progress.entity.js.map +0 -1
- package/dist/entities/capacitation/folder-page.entity.d.ts +0 -11
- package/dist/entities/capacitation/folder-page.entity.js +0 -57
- package/dist/entities/capacitation/folder-page.entity.js.map +0 -1
|
@@ -4,11 +4,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.resizeImage = resizeImage;
|
|
7
|
+
exports.resizeImageAsync = resizeImageAsync;
|
|
7
8
|
const rxjs_1 = require("rxjs");
|
|
8
9
|
const sharp_1 = __importDefault(require("sharp"));
|
|
9
10
|
function resizeImage(buffer, width = 200) {
|
|
10
|
-
return (0, rxjs_1.from)((0, sharp_1.default)(buffer)
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
return (0, rxjs_1.from)((0, sharp_1.default)(buffer).resize({ width }).toBuffer());
|
|
12
|
+
}
|
|
13
|
+
async function resizeImageAsync(buffer, width = 200) {
|
|
14
|
+
return (0, sharp_1.default)(buffer).resize({ width }).toBuffer();
|
|
13
15
|
}
|
|
14
16
|
//# sourceMappingURL=image.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"image.js","sourceRoot":"","sources":["../../../src/common/functions/image.ts"],"names":[],"mappings":";;;;;AAGA,
|
|
1
|
+
{"version":3,"file":"image.js","sourceRoot":"","sources":["../../../src/common/functions/image.ts"],"names":[],"mappings":";;;;;AAGA,kCAKC;AACD,4CAKC;AAdD,+BAAwC;AACxC,kDAA0B;AAE1B,SAAgB,WAAW,CACzB,MAAc,EACd,QAAgB,GAAG;IAEnB,OAAO,IAAA,WAAI,EAAC,IAAA,eAAK,EAAC,MAAM,CAAC,CAAC,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC1D,CAAC;AACM,KAAK,UAAU,gBAAgB,CACpC,MAAc,EACd,QAAgB,GAAG;IAEnB,OAAO,IAAA,eAAK,EAAC,MAAM,CAAC,CAAC,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;AACpD,CAAC"}
|
|
@@ -27,7 +27,7 @@ var QuestionType;
|
|
|
27
27
|
QuestionType["videoSection"] = "video-section";
|
|
28
28
|
})(QuestionType || (exports.QuestionType = QuestionType = {}));
|
|
29
29
|
let CourseEvaluation = class CourseEvaluation extends base_entity_1.EntityBase {
|
|
30
|
-
|
|
30
|
+
questions;
|
|
31
31
|
page;
|
|
32
32
|
course;
|
|
33
33
|
createdBy;
|
|
@@ -36,7 +36,7 @@ exports.CourseEvaluation = CourseEvaluation;
|
|
|
36
36
|
__decorate([
|
|
37
37
|
(0, typeorm_1.Column)({ type: 'jsonb', nullable: false, default: [] }),
|
|
38
38
|
__metadata("design:type", Array)
|
|
39
|
-
], CourseEvaluation.prototype, "
|
|
39
|
+
], CourseEvaluation.prototype, "questions", void 0);
|
|
40
40
|
__decorate([
|
|
41
41
|
(0, swagger_1.ApiProperty)({ type: () => course_folder_page_entity_1.CourseFolderPage, description: "Page' evaluation", required: false }),
|
|
42
42
|
(0, typeorm_1.OneToOne)(() => course_folder_page_entity_1.CourseFolderPage, page => page.evaluation, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"course-evaluation.entity.js","sourceRoot":"","sources":["../../../src/entities/capacitation/course-evaluation.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAA8D;AAC9D,6CAA8C;AAE9C,mEAA+D;AAC/D,gDAAsC;AAEtC,mDAAyC;AACzC,2EAA+D;AAE/D,IAAY,YAQX;AARD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,kDAAkC,CAAA;IAClC,0CAA0B,CAAA;IAC1B,uCAAuB,CAAA;IACvB,wCAAwB,CAAA;IACxB,8CAA8B,CAAA;IAC9B,8CAA8B,CAAA;AAChC,CAAC,EARW,YAAY,4BAAZ,YAAY,QAQvB;AAWM,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,wBAAU;IAE9C,
|
|
1
|
+
{"version":3,"file":"course-evaluation.entity.js","sourceRoot":"","sources":["../../../src/entities/capacitation/course-evaluation.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAA8D;AAC9D,6CAA8C;AAE9C,mEAA+D;AAC/D,gDAAsC;AAEtC,mDAAyC;AACzC,2EAA+D;AAE/D,IAAY,YAQX;AARD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,kDAAkC,CAAA;IAClC,0CAA0B,CAAA;IAC1B,uCAAuB,CAAA;IACvB,wCAAwB,CAAA;IACxB,8CAA8B,CAAA;IAC9B,8CAA8B,CAAA;AAChC,CAAC,EARW,YAAY,4BAAZ,YAAY,QAQvB;AAWM,IAAM,gBAAgB,GAAtB,MAAM,gBAA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AgB,CAqB5B"}
|
|
@@ -0,0 +1,40 @@
|
|
|
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.AgentRecruimentStage = void 0;
|
|
13
|
+
const base_entity_1 = require("../../../../common/database/base.entity");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const typeorm_1 = require("typeorm");
|
|
16
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
17
|
+
let AgentRecruimentStage = class AgentRecruimentStage extends base_entity_1.BaseEntitySimple {
|
|
18
|
+
name;
|
|
19
|
+
idx;
|
|
20
|
+
};
|
|
21
|
+
exports.AgentRecruimentStage = AgentRecruimentStage;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, swagger_1.ApiProperty)({
|
|
24
|
+
type: String,
|
|
25
|
+
description: "Name of the Agent Recruiment stage",
|
|
26
|
+
minLength: 1,
|
|
27
|
+
}),
|
|
28
|
+
(0, class_validator_1.MinLength)(1),
|
|
29
|
+
(0, typeorm_1.Column)({ unique: true }),
|
|
30
|
+
__metadata("design:type", String)
|
|
31
|
+
], AgentRecruimentStage.prototype, "name", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, swagger_1.ApiProperty)({ type: Number, description: "Index of the lead stage" }),
|
|
34
|
+
(0, typeorm_1.Column)(),
|
|
35
|
+
__metadata("design:type", Number)
|
|
36
|
+
], AgentRecruimentStage.prototype, "idx", void 0);
|
|
37
|
+
exports.AgentRecruimentStage = AgentRecruimentStage = __decorate([
|
|
38
|
+
(0, typeorm_1.Entity)()
|
|
39
|
+
], AgentRecruimentStage);
|
|
40
|
+
//# sourceMappingURL=h_agent_recruiment_stage.entity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"h_agent_recruiment_stage.entity.js","sourceRoot":"","sources":["../../../../../src/entities/helpers/sales/agent/h_agent_recruiment_stage.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yEAA2E;AAC3E,qDAA4C;AAC5C,qCAAyC;AACzC,6CAA8C;AAGvC,IAAM,oBAAoB,GAA1B,MAAM,oBAAqB,SAAQ,8BAAgB;IAQxD,IAAI,CAAS;IAIb,GAAG,CAAS;CACb,CAAA;AAbY,oDAAoB;AAQ/B;IAPC,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,MAAM;QACZ,WAAW,EAAE,oCAAoC;QACjD,SAAS,EAAE,CAAC;KACb,CAAC;IACD,IAAA,2BAAS,EAAC,CAAC,CAAC;IACZ,IAAA,gBAAM,EAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;;kDACZ;AAIb;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,yBAAyB,EAAE,CAAC;IACrE,IAAA,gBAAM,GAAE;;iDACG;+BAZD,oBAAoB;IADhC,IAAA,gBAAM,GAAE;GACI,oBAAoB,CAahC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BaseEntity } from "typeorm";
|
|
2
|
+
import { Poliza } from "../../../sales/poliza.entity";
|
|
3
|
+
import { File } from "../../../drive";
|
|
4
|
+
export declare class PolizaFile extends BaseEntity {
|
|
5
|
+
id?: string;
|
|
6
|
+
polizaId: string;
|
|
7
|
+
fileId: string;
|
|
8
|
+
relation: string;
|
|
9
|
+
poliza: Poliza;
|
|
10
|
+
file: File;
|
|
11
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
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.PolizaFile = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const class_transformer_1 = require("class-transformer");
|
|
15
|
+
const poliza_entity_1 = require("../../../sales/poliza.entity");
|
|
16
|
+
const drive_1 = require("../../../drive");
|
|
17
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
18
|
+
let PolizaFile = class PolizaFile extends typeorm_1.BaseEntity {
|
|
19
|
+
id;
|
|
20
|
+
polizaId;
|
|
21
|
+
fileId;
|
|
22
|
+
relation;
|
|
23
|
+
poliza;
|
|
24
|
+
file;
|
|
25
|
+
};
|
|
26
|
+
exports.PolizaFile = PolizaFile;
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, swagger_1.ApiProperty)({ type: String, description: 'UUID of the policy file', format: 'uuid' }),
|
|
29
|
+
(0, typeorm_1.PrimaryGeneratedColumn)("uuid"),
|
|
30
|
+
__metadata("design:type", String)
|
|
31
|
+
], PolizaFile.prototype, "id", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, swagger_1.ApiProperty)({ type: String, description: 'ID of the associated policy' }),
|
|
34
|
+
(0, typeorm_1.Column)(),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], PolizaFile.prototype, "polizaId", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, swagger_1.ApiProperty)({ type: String, description: 'ID of the associated file', format: 'uuid' }),
|
|
39
|
+
(0, typeorm_1.Column)({ type: "uuid" }),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], PolizaFile.prototype, "fileId", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, swagger_1.ApiProperty)({ type: String, description: 'Relation description or type', required: false }),
|
|
44
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
45
|
+
__metadata("design:type", String)
|
|
46
|
+
], PolizaFile.prototype, "relation", void 0);
|
|
47
|
+
__decorate([
|
|
48
|
+
(0, class_transformer_1.Exclude)(),
|
|
49
|
+
(0, swagger_1.ApiProperty)({ type: () => poliza_entity_1.Poliza, description: 'Policy entity associated' }),
|
|
50
|
+
(0, typeorm_1.ManyToOne)(() => poliza_entity_1.Poliza, poliza => poliza.files, {
|
|
51
|
+
onDelete: "CASCADE",
|
|
52
|
+
onUpdate: "CASCADE",
|
|
53
|
+
}),
|
|
54
|
+
__metadata("design:type", poliza_entity_1.Poliza)
|
|
55
|
+
], PolizaFile.prototype, "poliza", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, swagger_1.ApiProperty)({ type: () => drive_1.File, description: 'File entity associated' }),
|
|
58
|
+
(0, typeorm_1.ManyToOne)(() => drive_1.File, {
|
|
59
|
+
onDelete: "CASCADE",
|
|
60
|
+
onUpdate: "CASCADE",
|
|
61
|
+
eager: true,
|
|
62
|
+
}),
|
|
63
|
+
__metadata("design:type", drive_1.File)
|
|
64
|
+
], PolizaFile.prototype, "file", void 0);
|
|
65
|
+
exports.PolizaFile = PolizaFile = __decorate([
|
|
66
|
+
(0, typeorm_1.Entity)()
|
|
67
|
+
], PolizaFile);
|
|
68
|
+
//# sourceMappingURL=poliza_file.entity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"poliza_file.entity.js","sourceRoot":"","sources":["../../../../../src/entities/helpers/sales/poliza/poliza_file.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAAwF;AACxF,yDAA4C;AAC5C,gEAAsD;AACtD,0CAAsC;AACtC,6CAA8C;AAGvC,IAAM,UAAU,GAAhB,MAAM,UAAW,SAAQ,oBAAU;IAGxC,EAAE,CAAU;IAIZ,QAAQ,CAAS;IAIjB,MAAM,CAAS;IAIf,QAAQ,CAAS;IAQV,MAAM,CAAS;IAQf,IAAI,CAAO;CACnB,CAAA;AAhCY,gCAAU;AAGrB;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,yBAAyB,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACrF,IAAA,gCAAsB,EAAC,MAAM,CAAC;;sCACnB;AAIZ;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,6BAA6B,EAAE,CAAC;IACzE,IAAA,gBAAM,GAAE;;4CACQ;AAIjB;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,2BAA2B,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACvF,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0CACV;AAIf;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,8BAA8B,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;IAC3F,IAAA,gBAAM,EAAC,EAAE,QAAQ,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