easywork-common-lib 1.0.1162 → 1.0.1165
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/entities/capacitation/index.d.ts +8 -8
- package/dist/entities/capacitation/index.js +2 -1
- package/dist/entities/capacitation/index.js.map +1 -1
- package/dist/entities/index.d.ts +1 -0
- package/dist/entities/index.js +1 -0
- package/dist/entities/index.js.map +1 -1
- package/dist/entities/subscriptions/feature.d.ts +15 -0
- package/dist/entities/subscriptions/feature.js +64 -0
- package/dist/entities/subscriptions/feature.js.map +1 -0
- package/dist/entities/subscriptions/plan-feature.d.ts +8 -0
- package/dist/entities/subscriptions/plan-feature.js +44 -0
- package/dist/entities/subscriptions/plan-feature.js.map +1 -0
- package/dist/entities/tools/mail/mail-gmail.entity.d.ts +7 -0
- package/dist/entities/tools/mail/mail-gmail.entity.js +41 -0
- package/dist/entities/tools/mail/mail-gmail.entity.js.map +1 -0
- package/dist/entities/tools/mail/mail.entity.d.ts +4 -5
- package/dist/entities/tools/mail/mail.entity.js +8 -15
- package/dist/entities/tools/mail/mail.entity.js.map +1 -1
- package/dist/entities/user-group.entity.d.ts +1 -5
- package/dist/entities/user-group.entity.js +7 -41
- package/dist/entities/user-group.entity.js.map +1 -1
- package/dist/grpc/drive/drive.proto +310 -310
- package/dist/grpc/drive/leads.proto +114 -114
- package/dist/modules/authorization/services/resource-access-filter.service.js +21 -21
- package/package.json +54 -54
- package/dist/entities/helpers/sales/agent/recruitment/h_agent_recruitment_other_referrals.d.ts +0 -9
- package/dist/entities/helpers/sales/agent/recruitment/h_agent_recruitment_other_referrals.js +0 -64
- package/dist/entities/helpers/sales/agent/recruitment/h_agent_recruitment_other_referrals.js.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { Capacitation } from
|
|
2
|
-
export { Course } from
|
|
3
|
-
export { CourseFolder } from
|
|
4
|
-
export { CourseFolderPage } from
|
|
5
|
-
export { CourseAssigned } from
|
|
6
|
-
export { CourseOrder } from
|
|
7
|
-
export { CourseEvaluation, EvaluationQuestion } from
|
|
8
|
-
export { CourseEvaluationAttempt, CourseEvaluationAttemptStatus } from
|
|
1
|
+
export { Capacitation, CapacitationStatus } from "./capacitation.entity";
|
|
2
|
+
export { Course } from "./course.entity";
|
|
3
|
+
export { CourseFolder } from "./course-folder.entity";
|
|
4
|
+
export { CourseFolderPage } from "./course-folder-page.entity";
|
|
5
|
+
export { CourseAssigned } from "./course-assigned.entity";
|
|
6
|
+
export { CourseOrder } from "./course-order.entity";
|
|
7
|
+
export { CourseEvaluation, EvaluationQuestion, } from "./course-evaluation.entity";
|
|
8
|
+
export { CourseEvaluationAttempt, CourseEvaluationAttemptStatus, } from "./course-evaluation-attempt.entity";
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.CourseEvaluationAttemptStatus = exports.CourseEvaluationAttempt = exports.CourseEvaluation = exports.CourseOrder = exports.CourseAssigned = exports.CourseFolderPage = exports.CourseFolder = exports.Course = exports.Capacitation = void 0;
|
|
3
|
+
exports.CourseEvaluationAttemptStatus = exports.CourseEvaluationAttempt = exports.CourseEvaluation = exports.CourseOrder = exports.CourseAssigned = exports.CourseFolderPage = exports.CourseFolder = exports.Course = exports.CapacitationStatus = exports.Capacitation = void 0;
|
|
4
4
|
var capacitation_entity_1 = require("./capacitation.entity");
|
|
5
5
|
Object.defineProperty(exports, "Capacitation", { enumerable: true, get: function () { return capacitation_entity_1.Capacitation; } });
|
|
6
|
+
Object.defineProperty(exports, "CapacitationStatus", { enumerable: true, get: function () { return capacitation_entity_1.CapacitationStatus; } });
|
|
6
7
|
var course_entity_1 = require("./course.entity");
|
|
7
8
|
Object.defineProperty(exports, "Course", { enumerable: true, get: function () { return course_entity_1.Course; } });
|
|
8
9
|
var course_folder_entity_1 = require("./course-folder.entity");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/entities/capacitation/index.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/entities/capacitation/index.ts"],"names":[],"mappings":";;;AAAA,6DAAyE;AAAhE,mHAAA,YAAY,OAAA;AAAE,yHAAA,kBAAkB,OAAA;AACzC,iDAAyC;AAAhC,uGAAA,MAAM,OAAA;AACf,+DAAsD;AAA7C,oHAAA,YAAY,OAAA;AACrB,yEAA+D;AAAtD,6HAAA,gBAAgB,OAAA;AACzB,mEAA0D;AAAjD,wHAAA,cAAc,OAAA;AACvB,6DAAoD;AAA3C,kHAAA,WAAW,OAAA;AACpB,uEAGoC;AAFlC,4HAAA,gBAAgB,OAAA;AAGlB,uFAG4C;AAF1C,2IAAA,uBAAuB,OAAA;AACvB,iJAAA,6BAA6B,OAAA"}
|
package/dist/entities/index.d.ts
CHANGED
|
@@ -33,6 +33,7 @@ export * from './tools/mail/email-signature.entity';
|
|
|
33
33
|
export * from './tools/mail/mailbox-user-access.entity';
|
|
34
34
|
export * from './tools/mail/mailbox.entity';
|
|
35
35
|
export * from './tools/mail/mail.entity';
|
|
36
|
+
export * from './tools/mail/mail-gmail.entity';
|
|
36
37
|
export * from './all-activities.entity';
|
|
37
38
|
export * from './thirdparty/google-webhooks-config.entity';
|
|
38
39
|
export * from './thirdparty/google-gmail-watch-record.entity';
|
package/dist/entities/index.js
CHANGED
|
@@ -49,6 +49,7 @@ __exportStar(require("./tools/mail/email-signature.entity"), exports);
|
|
|
49
49
|
__exportStar(require("./tools/mail/mailbox-user-access.entity"), exports);
|
|
50
50
|
__exportStar(require("./tools/mail/mailbox.entity"), exports);
|
|
51
51
|
__exportStar(require("./tools/mail/mail.entity"), exports);
|
|
52
|
+
__exportStar(require("./tools/mail/mail-gmail.entity"), exports);
|
|
52
53
|
__exportStar(require("./all-activities.entity"), exports);
|
|
53
54
|
__exportStar(require("./thirdparty/google-webhooks-config.entity"), exports);
|
|
54
55
|
__exportStar(require("./thirdparty/google-gmail-watch-record.entity"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/entities/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iEAA+C;AAC/C,oDAAkC;AAClC,0CAAwB;AACxB,+DAA6C;AAC7C,iDAA+B;AAC/B,iDAA+B;AAC/B,uDAAqC;AACrC,yDAAuC;AACvC,2DAAyC;AACzC,mDAAiC;AACjC,4DAA0C;AAC1C,kDAAgC;AAChC,mDAAiC;AACjC,sDAAoC;AACpC,iDAA+B;AAC/B,2CAAyB;AACzB,mDAAiC;AACjC,oDAAkC;AAClC,yDAAuC;AACvC,gDAA8B;AAC9B,0CAAwB;AACxB,+CAA6B;AAC7B,4DAA0C;AAC1C,gDAA8B;AAC9B,6DAA2C;AAC3C,6DAA2C;AAC3C,mDAAiC;AACjC,6DAA2C;AAG3C,iDAA+B;AAG/B,0CAAwB;AAGxB,uDAAqC;AAGrC,sEAAoD;AACpD,0EAAwD;AACxD,8DAA4C;AAC5C,2DAAyC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/entities/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iEAA+C;AAC/C,oDAAkC;AAClC,0CAAwB;AACxB,+DAA6C;AAC7C,iDAA+B;AAC/B,iDAA+B;AAC/B,uDAAqC;AACrC,yDAAuC;AACvC,2DAAyC;AACzC,mDAAiC;AACjC,4DAA0C;AAC1C,kDAAgC;AAChC,mDAAiC;AACjC,sDAAoC;AACpC,iDAA+B;AAC/B,2CAAyB;AACzB,mDAAiC;AACjC,oDAAkC;AAClC,yDAAuC;AACvC,gDAA8B;AAC9B,0CAAwB;AACxB,+CAA6B;AAC7B,4DAA0C;AAC1C,gDAA8B;AAC9B,6DAA2C;AAC3C,6DAA2C;AAC3C,mDAAiC;AACjC,6DAA2C;AAG3C,iDAA+B;AAG/B,0CAAwB;AAGxB,uDAAqC;AAGrC,sEAAoD;AACpD,0EAAwD;AACxD,8DAA4C;AAC5C,2DAAyC;AACzC,iEAA+C;AAG/C,0DAAwC;AAGxC,6EAA2D;AAC3D,gFAA8D;AAC9D,4DAA0C;AAC1C,uEAAqD;AACrD,oDAAkC;AAGlC,8DAA4C;AAC5C,iEAA+C;AAC/C,sEAAoD;AACpD,sEAAoD;AACpD,yEAAuD;AAGvD,4CAA0B;AAG1B,iDAA+B;AAC/B,0DAAwC;AAGxC,2DAAyC;AAGzC,oDAAkC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { BaseEntityOnlyEssential } from '../../common/database/base.entity';
|
|
2
|
+
import { PlanFeature } from './plan-feature';
|
|
3
|
+
export declare enum FeatureType {
|
|
4
|
+
BOOLEAN = "boolean",
|
|
5
|
+
LIMIT = "limit",
|
|
6
|
+
TEXT = "text"
|
|
7
|
+
}
|
|
8
|
+
export declare class Feature extends BaseEntityOnlyEssential {
|
|
9
|
+
key: string;
|
|
10
|
+
name: string;
|
|
11
|
+
description: string;
|
|
12
|
+
category: string;
|
|
13
|
+
type: FeatureType;
|
|
14
|
+
planFeatures: PlanFeature[];
|
|
15
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
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.Feature = exports.FeatureType = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const base_entity_1 = require("../../common/database/base.entity");
|
|
15
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
16
|
+
const plan_feature_1 = require("./plan-feature");
|
|
17
|
+
var FeatureType;
|
|
18
|
+
(function (FeatureType) {
|
|
19
|
+
FeatureType["BOOLEAN"] = "boolean";
|
|
20
|
+
FeatureType["LIMIT"] = "limit";
|
|
21
|
+
FeatureType["TEXT"] = "text";
|
|
22
|
+
})(FeatureType || (exports.FeatureType = FeatureType = {}));
|
|
23
|
+
let Feature = class Feature extends base_entity_1.BaseEntityOnlyEssential {
|
|
24
|
+
key;
|
|
25
|
+
name;
|
|
26
|
+
description;
|
|
27
|
+
category;
|
|
28
|
+
type;
|
|
29
|
+
planFeatures;
|
|
30
|
+
};
|
|
31
|
+
exports.Feature = Feature;
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, swagger_1.ApiProperty)({ description: 'Nombre único y programático de la característica', example: 'PRO_POLICY_READER' }),
|
|
34
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 100, unique: true, nullable: false }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], Feature.prototype, "key", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, swagger_1.ApiProperty)({ description: 'Nombre de la característica para mostrar al usuario', example: 'Lector de Pólizas Pro' }),
|
|
39
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], Feature.prototype, "name", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, swagger_1.ApiProperty)({ description: 'Descripción detallada de lo que hace la característica', example: 'Permite analizar y extraer datos de pólizas en formato PDF.' }),
|
|
44
|
+
(0, typeorm_1.Column)({ type: 'text', nullable: true }),
|
|
45
|
+
__metadata("design:type", String)
|
|
46
|
+
], Feature.prototype, "description", void 0);
|
|
47
|
+
__decorate([
|
|
48
|
+
(0, swagger_1.ApiProperty)({ description: 'Categoría para agrupar en la UI', example: 'Reportes' }),
|
|
49
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
|
|
50
|
+
__metadata("design:type", String)
|
|
51
|
+
], Feature.prototype, "category", void 0);
|
|
52
|
+
__decorate([
|
|
53
|
+
(0, swagger_1.ApiProperty)({ description: 'El tipo de valor que esta característica almacena', enum: FeatureType, example: FeatureType.BOOLEAN }),
|
|
54
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: FeatureType, nullable: false }),
|
|
55
|
+
__metadata("design:type", String)
|
|
56
|
+
], Feature.prototype, "type", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, typeorm_1.OneToMany)(() => plan_feature_1.PlanFeature, planFeature => planFeature.feature),
|
|
59
|
+
__metadata("design:type", Array)
|
|
60
|
+
], Feature.prototype, "planFeatures", void 0);
|
|
61
|
+
exports.Feature = Feature = __decorate([
|
|
62
|
+
(0, typeorm_1.Entity)('features')
|
|
63
|
+
], Feature);
|
|
64
|
+
//# sourceMappingURL=feature.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feature.js","sourceRoot":"","sources":["../../../src/entities/subscriptions/feature.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,qCAAoD;AACpD,mEAA4E;AAC5E,6CAA8C;AAC9C,iDAA6C;AAE7C,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,kCAAmB,CAAA;IACnB,8BAAe,CAAA;IACf,4BAAa,CAAA;AACf,CAAC,EAJW,WAAW,2BAAX,WAAW,QAItB;AAGM,IAAM,OAAO,GAAb,MAAM,OAAQ,SAAQ,qCAAuB;IAGlD,GAAG,CAAS;IAIZ,IAAI,CAAS;IAIb,WAAW,CAAS;IA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AC,GAAG,EAAE,CAAC,0BAAW,EAAE,WAAW,CAAC,EAAE,CAAC,WAAW,CAAC,OAAO,CAAC;;6CACrC;kBAtBjB,OAAO;IADnB,IAAA,gBAAM,EAAC,UAAU,CAAC;GACN,OAAO,CAuBnB"}
|
|
@@ -0,0 +1,44 @@
|
|
|
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.PlanFeature = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const plan_entity_1 = require("./plan.entity");
|
|
15
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
16
|
+
const feature_1 = require("./feature");
|
|
17
|
+
let PlanFeature = class PlanFeature {
|
|
18
|
+
id;
|
|
19
|
+
value;
|
|
20
|
+
plan;
|
|
21
|
+
feature;
|
|
22
|
+
};
|
|
23
|
+
exports.PlanFeature = PlanFeature;
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], PlanFeature.prototype, "id", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, swagger_1.ApiProperty)({ description: 'Valor de la característica para este plan. Puede ser "true", "100", "ilimitado", etc.', example: 'true' }),
|
|
30
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], PlanFeature.prototype, "value", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, typeorm_1.ManyToOne)(() => plan_entity_1.Plan, plan => plan.planFeatures, { onDelete: 'CASCADE' }),
|
|
35
|
+
__metadata("design:type", plan_entity_1.Plan)
|
|
36
|
+
], PlanFeature.prototype, "plan", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, typeorm_1.ManyToOne)(() => feature_1.Feature, feature => feature.planFeatures, { onDelete: 'CASCADE', eager: true }),
|
|
39
|
+
__metadata("design:type", feature_1.Feature)
|
|
40
|
+
], PlanFeature.prototype, "feature", void 0);
|
|
41
|
+
exports.PlanFeature = PlanFeature = __decorate([
|
|
42
|
+
(0, typeorm_1.Entity)('plan_features')
|
|
43
|
+
], PlanFeature);
|
|
44
|
+
//# sourceMappingURL=plan-feature.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plan-feature.js","sourceRoot":"","sources":["../../../src/entities/subscriptions/plan-feature.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAA4E;AAC5E,+CAAqC;AACrC,6CAA8C;AAC9C,uCAAoC;AAG7B,IAAM,WAAW,GAAjB,MAAM,WAAW;IAEtB,EAAE,CAAS;IAIX,KAAK,CAAS;IAGd,IAAI,CAAO;IAGX,OAAO,CAAU;CAClB,CAAA;AAbY,kCAAW;AAEtB;IADC,IAAA,gCAAsB,EAAC,MAAM,CAAC;;uCACpB;AAIX;IAFC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,uFAAuF,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IACtI,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;0CAC5C;AAGd;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,kBAAI,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,YAAY,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;8BACpE,kBAAI;yCAAC;AAGX;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,iBAAO,EAAE,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,YAAY,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;8BACvF,iBAAO;4CAAC;sBAZN,WAAW;IADvB,IAAA,gBAAM,EAAC,eAAe,CAAC;GACX,WAAW,CAavB"}
|
|
@@ -0,0 +1,41 @@
|
|
|
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.MailMessageGmail = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
+
const common_1 = require("common");
|
|
16
|
+
const mail_entity_1 = require("./mail.entity");
|
|
17
|
+
let MailMessageGmail = class MailMessageGmail extends common_1.BaseEntityOnlyEssential {
|
|
18
|
+
messageId;
|
|
19
|
+
threadId;
|
|
20
|
+
mailMessage;
|
|
21
|
+
};
|
|
22
|
+
exports.MailMessageGmail = MailMessageGmail;
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, swagger_1.ApiProperty)({ description: 'ID del encabezado Message-ID del correo', required: false }),
|
|
25
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], MailMessageGmail.prototype, "messageId", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, swagger_1.ApiProperty)({ description: 'ID del hilo (thread) al que pertenece el mensaje en Gmail' }),
|
|
30
|
+
(0, typeorm_1.Column)(),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], MailMessageGmail.prototype, "threadId", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, typeorm_1.OneToOne)(() => mail_entity_1.MailMessage, mailMessage => mailMessage.gmail, { onDelete: 'CASCADE' }),
|
|
35
|
+
(0, typeorm_1.JoinColumn)(),
|
|
36
|
+
__metadata("design:type", mail_entity_1.MailMessage)
|
|
37
|
+
], MailMessageGmail.prototype, "mailMessage", void 0);
|
|
38
|
+
exports.MailMessageGmail = MailMessageGmail = __decorate([
|
|
39
|
+
(0, typeorm_1.Entity)()
|
|
40
|
+
], MailMessageGmail);
|
|
41
|
+
//# sourceMappingURL=mail-gmail.entity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mail-gmail.entity.js","sourceRoot":"","sources":["../../../../src/entities/tools/mail/mail-gmail.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAA+D;AAC/D,6CAA8C;AAE9C,mCAAiD;AACjD,+CAA4C;AAGrC,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,gCAAuB;IAG3D,SAAS,CAAS;IAIlB,QAAQ,CAAS;IAIjB,WAAW,CAAc;CAC1B,CAAA;AAZY,4CAAgB;AAG3B;IAFC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,yCAAyC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;IACxF,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDACT;AAIlB;IAFC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,2DAA2D,EAAE,CAAC;IACzF,IAAA,gBAAM,GAAE;;kDACQ;AAIjB;IAFC,IAAA,kBAAQ,EAAC,GAAG,EAAE,CAAC,yBAAW,EAAE,WAAW,CAAC,EAAE,CAAC,WAAW,CAAC,KAAK,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;IACtF,IAAA,oBAAU,GAAE;8BACA,yBAAW;qDAAC;2BAXd,gBAAgB;IAD5B,IAAA,gBAAM,GAAE;GACI,gBAAgB,CAY5B"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { BaseEntity } from 'typeorm';
|
|
2
1
|
import { Mailbox } from './mailbox.entity';
|
|
3
2
|
import { Task } from '../task.entity';
|
|
4
3
|
import { EventCalendar } from '../calendar';
|
|
4
|
+
import { MailMessageGmail } from './mail-gmail.entity';
|
|
5
|
+
import { BaseEntityOnlyEssential } from 'common';
|
|
5
6
|
export declare enum MailCRMType {
|
|
6
7
|
CONTACT = "contact",
|
|
7
8
|
LEAD = "lead",
|
|
@@ -42,8 +43,7 @@ export type MailMessageAttachment = {
|
|
|
42
43
|
attachmentId: string | null;
|
|
43
44
|
size: number;
|
|
44
45
|
};
|
|
45
|
-
export declare class MailMessage extends
|
|
46
|
-
id: string;
|
|
46
|
+
export declare class MailMessage extends BaseEntityOnlyEssential {
|
|
47
47
|
labelIds: string[];
|
|
48
48
|
to: MailMessageTo;
|
|
49
49
|
messageId: string;
|
|
@@ -58,6 +58,5 @@ export declare class MailMessage extends BaseEntity {
|
|
|
58
58
|
mailbox: Mailbox;
|
|
59
59
|
task?: Task;
|
|
60
60
|
event?: EventCalendar;
|
|
61
|
-
|
|
62
|
-
updatedAt?: Date;
|
|
61
|
+
gmail?: MailMessageGmail;
|
|
63
62
|
}
|
|
@@ -15,8 +15,9 @@ const swagger_1 = require("@nestjs/swagger");
|
|
|
15
15
|
const mailbox_entity_1 = require("./mailbox.entity");
|
|
16
16
|
const task_entity_1 = require("../task.entity");
|
|
17
17
|
const calendar_1 = require("../calendar");
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
const mail_gmail_entity_1 = require("./mail-gmail.entity");
|
|
19
|
+
const common_1 = require("common");
|
|
20
|
+
let MailMessage = class MailMessage extends common_1.BaseEntityOnlyEssential {
|
|
20
21
|
labelIds;
|
|
21
22
|
to;
|
|
22
23
|
messageId;
|
|
@@ -31,14 +32,9 @@ let MailMessage = class MailMessage extends typeorm_1.BaseEntity {
|
|
|
31
32
|
mailbox;
|
|
32
33
|
task;
|
|
33
34
|
event;
|
|
34
|
-
|
|
35
|
-
updatedAt;
|
|
35
|
+
gmail;
|
|
36
36
|
};
|
|
37
37
|
exports.MailMessage = MailMessage;
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, typeorm_1.PrimaryColumn)('varchar'),
|
|
40
|
-
__metadata("design:type", String)
|
|
41
|
-
], MailMessage.prototype, "id", void 0);
|
|
42
38
|
__decorate([
|
|
43
39
|
(0, swagger_1.ApiProperty)({ description: 'Mail labels', required: false }),
|
|
44
40
|
(0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
|
|
@@ -107,13 +103,10 @@ __decorate([
|
|
|
107
103
|
__metadata("design:type", calendar_1.EventCalendar)
|
|
108
104
|
], MailMessage.prototype, "event", void 0);
|
|
109
105
|
__decorate([
|
|
110
|
-
(0,
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
(0, typeorm_1.UpdateDateColumn)(),
|
|
115
|
-
__metadata("design:type", Date)
|
|
116
|
-
], MailMessage.prototype, "updatedAt", void 0);
|
|
106
|
+
(0, swagger_1.ApiProperty)({ description: 'Datos específicos de Gmail para este mensaje', required: false }),
|
|
107
|
+
(0, typeorm_1.OneToOne)(() => mail_gmail_entity_1.MailMessageGmail, gmailMessage => gmailMessage.mailMessage, { cascade: true, nullable: true }),
|
|
108
|
+
__metadata("design:type", mail_gmail_entity_1.MailMessageGmail)
|
|
109
|
+
], MailMessage.prototype, "gmail", void 0);
|
|
117
110
|
exports.MailMessage = MailMessage = __decorate([
|
|
118
111
|
(0, typeorm_1.Entity)()
|
|
119
112
|
], MailMessage);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mail.entity.js","sourceRoot":"","sources":["../../../../src/entities/tools/mail/mail.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"mail.entity.js","sourceRoot":"","sources":["../../../../src/entities/tools/mail/mail.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAA8D;AAC9D,6CAA8C;AAE9C,qDAA2C;AAC3C,gDAAsC;AACtC,0CAA4C;AAC5C,2DAAuD;AACvD,mCAAiD;AAiD1C,IAAM,WAAW,GAAjB,MAAM,WAAY,SAAQ,gCAAuB;IAGtD,QAAQ,CAAW;IAInB,EAAE,CAAgB;IAIlB,SAAS,CAAS;IAIlB,IAAI,CAAS;IAIb,OAAO,CAAS;IAIhB,IAAI,CAAkB;IAItB,OAAO,CAAS;IAIhB,YAAY,CAAO;IAInB,IAAI,CAAkB;IAItB,WAAW,CAA0B;IAIrC,GAAG,CAAuB;IAG1B,OAAO,CAAU;IAGjB,IAAI,CAAQ;IAGZ,KAAK,CAAiB;IAItB,KAAK,CAAoB;CAC1B,CAAA;AAzDY,kCAAW;AAGtB;IAFC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;IAC5D,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;6CACvB;AAInB;IAFC,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AAA,kBAAQ,EAAC,GAAG,EAAE,CAAC,oCAAgB,EAAE,YAAY,CAAC,EAAE,CAAC,YAAY,CAAC,WAAW,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACtG,oCAAgB;0CAAC;sBAxDd,WAAW;IADvB,IAAA,gBAAM,GAAE;GACI,WAAW,CAyDvB"}
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
import { EntityBase } from '../common/database/base.entity';
|
|
2
|
-
import { User } from './user.entity';
|
|
3
|
-
import { Group } from './group.entity';
|
|
4
2
|
import { Role } from './role.entity';
|
|
5
|
-
export declare class
|
|
6
|
-
user: User;
|
|
7
|
-
group: Group;
|
|
3
|
+
export declare class UserGroupNewRelation extends EntityBase {
|
|
8
4
|
role: Role;
|
|
9
5
|
}
|
|
@@ -9,57 +9,23 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
13
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
12
|
+
exports.UserGroupNewRelation = void 0;
|
|
14
13
|
const typeorm_1 = require("typeorm");
|
|
15
14
|
const base_entity_1 = require("../common/database/base.entity");
|
|
16
|
-
const user_entity_1 = require("./user.entity");
|
|
17
|
-
const group_entity_1 = require("./group.entity");
|
|
18
15
|
const role_entity_1 = require("./role.entity");
|
|
19
|
-
let
|
|
20
|
-
user;
|
|
21
|
-
group;
|
|
16
|
+
let UserGroupNewRelation = class UserGroupNewRelation extends base_entity_1.EntityBase {
|
|
22
17
|
role;
|
|
23
18
|
};
|
|
24
|
-
exports.
|
|
19
|
+
exports.UserGroupNewRelation = UserGroupNewRelation;
|
|
25
20
|
__decorate([
|
|
26
|
-
(0, swagger_1.ApiProperty)({
|
|
27
|
-
type: () => user_entity_1.User,
|
|
28
|
-
description: 'User in the group',
|
|
29
|
-
}),
|
|
30
|
-
(0, typeorm_1.ManyToOne)(() => user_entity_1.User, user => user.userGroups, {
|
|
31
|
-
onDelete: 'CASCADE',
|
|
32
|
-
onUpdate: 'CASCADE',
|
|
33
|
-
}),
|
|
34
|
-
(0, typeorm_1.JoinColumn)(),
|
|
35
|
-
__metadata("design:type", user_entity_1.User)
|
|
36
|
-
], UserGroup.prototype, "user", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, swagger_1.ApiProperty)({
|
|
39
|
-
type: () => group_entity_1.Group,
|
|
40
|
-
description: 'Group where the user belongs',
|
|
41
|
-
}),
|
|
42
|
-
(0, typeorm_1.ManyToOne)(() => group_entity_1.Group, group => group.userGroups, {
|
|
43
|
-
onDelete: 'CASCADE',
|
|
44
|
-
onUpdate: 'CASCADE',
|
|
45
|
-
}),
|
|
46
|
-
(0, typeorm_1.JoinColumn)(),
|
|
47
|
-
__metadata("design:type", group_entity_1.Group)
|
|
48
|
-
], UserGroup.prototype, "group", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, swagger_1.ApiProperty)({
|
|
51
|
-
type: () => role_entity_1.Role,
|
|
52
|
-
description: 'Role assigned to the user in this specific group',
|
|
53
|
-
}),
|
|
54
21
|
(0, typeorm_1.ManyToOne)(() => role_entity_1.Role, {
|
|
55
22
|
onDelete: 'RESTRICT',
|
|
56
23
|
onUpdate: 'CASCADE',
|
|
57
24
|
}),
|
|
58
25
|
(0, typeorm_1.JoinColumn)(),
|
|
59
26
|
__metadata("design:type", role_entity_1.Role)
|
|
60
|
-
],
|
|
61
|
-
exports.
|
|
62
|
-
(0, typeorm_1.Entity)()
|
|
63
|
-
|
|
64
|
-
], UserGroup);
|
|
27
|
+
], UserGroupNewRelation.prototype, "role", void 0);
|
|
28
|
+
exports.UserGroupNewRelation = UserGroupNewRelation = __decorate([
|
|
29
|
+
(0, typeorm_1.Entity)()
|
|
30
|
+
], UserGroupNewRelation);
|
|
65
31
|
//# sourceMappingURL=user-group.entity.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-group.entity.js","sourceRoot":"","sources":["../../src/entities/user-group.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"user-group.entity.js","sourceRoot":"","sources":["../../src/entities/user-group.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAAwD;AACxD,gEAA4D;AAG5D,+CAAqC;AAI9B,IAAM,oBAAoB,GAA1B,MAAM,oBAAqB,SAAQ,wBAAU;IA4BlD,IAAI,CAAO;CACZ,CAAA;AA7BY,oDAAoB;AA4B/B;IALC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,kBAAI,EAAE;QACrB,QAAQ,EAAE,UAAU;QACpB,QAAQ,EAAE,SAAS;KACpB,CAAC;IACD,IAAA,oBAAU,GAAE;8BACP,kBAAI;kDAAC;+BA5BA,oBAAoB;IAFhC,IAAA,gBAAM,GAAE;GAEI,oBAAoB,CA6BhC"}
|