@driveup/schema 0.3.20 → 0.3.21

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.
@@ -0,0 +1,77 @@
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.PublicLearningHubItemEntity = void 0;
13
+ const shared_1 = require("@driveup/shared");
14
+ const typeorm_1 = require("typeorm");
15
+ // TODO: come up with better name (publicLearningResource?)
16
+ let PublicLearningHubItemEntity = class PublicLearningHubItemEntity {
17
+ /************************* Methods *************************/
18
+ constructor(props) {
19
+ Object.assign(this, props);
20
+ }
21
+ };
22
+ exports.PublicLearningHubItemEntity = PublicLearningHubItemEntity;
23
+ __decorate([
24
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
25
+ __metadata("design:type", Number)
26
+ ], PublicLearningHubItemEntity.prototype, "id", void 0);
27
+ __decorate([
28
+ (0, typeorm_1.Column)({
29
+ type: 'enum',
30
+ enum: shared_1.Language,
31
+ default: shared_1.Language.En,
32
+ nullable: false
33
+ }),
34
+ __metadata("design:type", String)
35
+ ], PublicLearningHubItemEntity.prototype, "language", void 0);
36
+ __decorate([
37
+ (0, typeorm_1.Column)({
38
+ type: 'enum',
39
+ enum: shared_1.ProfileType,
40
+ default: shared_1.ProfileType.Company,
41
+ nullable: false
42
+ }),
43
+ __metadata("design:type", String)
44
+ ], PublicLearningHubItemEntity.prototype, "profile", void 0);
45
+ __decorate([
46
+ (0, typeorm_1.Column)({
47
+ nullable: true,
48
+ default: null
49
+ }),
50
+ __metadata("design:type", String)
51
+ ], PublicLearningHubItemEntity.prototype, "title", void 0);
52
+ __decorate([
53
+ (0, typeorm_1.Column)({
54
+ nullable: true,
55
+ default: null
56
+ }),
57
+ __metadata("design:type", String)
58
+ ], PublicLearningHubItemEntity.prototype, "description", void 0);
59
+ __decorate([
60
+ (0, typeorm_1.Column)({
61
+ nullable: false,
62
+ default: 0
63
+ }),
64
+ __metadata("design:type", Number)
65
+ ], PublicLearningHubItemEntity.prototype, "sort", void 0);
66
+ __decorate([
67
+ (0, typeorm_1.Column)({
68
+ nullable: true,
69
+ default: null
70
+ }),
71
+ __metadata("design:type", String)
72
+ ], PublicLearningHubItemEntity.prototype, "media", void 0);
73
+ exports.PublicLearningHubItemEntity = PublicLearningHubItemEntity = __decorate([
74
+ (0, typeorm_1.Entity)('publicLearningHubItems'),
75
+ __metadata("design:paramtypes", [Object])
76
+ ], PublicLearningHubItemEntity);
77
+ //# sourceMappingURL=learning-hub.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"learning-hub.js","sourceRoot":"","sources":["../../src/public/learning-hub.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,4CAAwD;AACxD,qCAAiE;AAEjE,2DAA2D;AAEpD,IAAM,2BAA2B,GAAjC,MAAM,2BAA2B;IA+DvC,6DAA6D;IAE7D,YAAY,KAA4C;QACvD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD,CAAA;AApEY,kEAA2B;AAMvC;IADC,IAAA,gCAAsB,GAAE;;uDACd;AAWX;IANC,IAAA,gBAAM,EAAC;QACP,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,iBAAQ;QACd,OAAO,EAAE,iBAAQ,CAAC,EAAE;QACpB,QAAQ,EAAE,KAAK;KACf,CAAC;;6DACiB;AAQnB;IANC,IAAA,gBAAM,EAAC;QACP,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,oBAAW;QACjB,OAAO,EAAE,oBAAW,CAAC,OAAO;QAC5B,QAAQ,EAAE,KAAK;KACf,CAAC;;4DACmB;AASrB;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;0DACY;AASd;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;gEACkB;AASpB;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE,CAAC;KACV,CAAC;;yDACW;AASb;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;0DACY;sCA7DF,2BAA2B;IADvC,IAAA,gBAAM,EAAC,wBAAwB,CAAC;;GACpB,2BAA2B,CAoEvC"}
@@ -0,0 +1,40 @@
1
+ import { Language } from '@driveup/shared';
2
+ import { CountryEntity } from '../system/country/country.entity';
3
+ export declare class PublicTestimonialEntity {
4
+ /**
5
+ * Primary key - auto-generated sequential ID
6
+ */
7
+ id: number;
8
+ /**
9
+ * Country ID
10
+ */
11
+ countryId: number;
12
+ /**
13
+ * Language of the content of the testimonial
14
+ */
15
+ language: Language;
16
+ /**
17
+ * Testimony title
18
+ */
19
+ title: string;
20
+ /**
21
+ * User feedback
22
+ */
23
+ feedback: string;
24
+ /**
25
+ * User image/avatar
26
+ */
27
+ image: string;
28
+ /**
29
+ * User name
30
+ */
31
+ name: string;
32
+ /**
33
+ * User position/job title
34
+ */
35
+ position: string;
36
+ /************************* Relations *************************/
37
+ country: Promise<CountryEntity>;
38
+ /************************* Methods *************************/
39
+ constructor(props?: Partial<PublicTestimonialEntity>);
40
+ }
@@ -0,0 +1,85 @@
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.PublicTestimonialEntity = void 0;
13
+ const shared_1 = require("@driveup/shared");
14
+ const typeorm_1 = require("typeorm");
15
+ const country_entity_1 = require("../system/country/country.entity");
16
+ let PublicTestimonialEntity = class PublicTestimonialEntity {
17
+ /************************* Methods *************************/
18
+ constructor(props) {
19
+ Object.assign(this, props);
20
+ }
21
+ };
22
+ exports.PublicTestimonialEntity = PublicTestimonialEntity;
23
+ __decorate([
24
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
25
+ __metadata("design:type", Number)
26
+ ], PublicTestimonialEntity.prototype, "id", void 0);
27
+ __decorate([
28
+ (0, typeorm_1.Column)({
29
+ nullable: false
30
+ }),
31
+ __metadata("design:type", Number)
32
+ ], PublicTestimonialEntity.prototype, "countryId", void 0);
33
+ __decorate([
34
+ (0, typeorm_1.Column)({
35
+ type: 'enum',
36
+ enum: shared_1.Language,
37
+ default: shared_1.Language.En,
38
+ nullable: false
39
+ }),
40
+ __metadata("design:type", String)
41
+ ], PublicTestimonialEntity.prototype, "language", void 0);
42
+ __decorate([
43
+ (0, typeorm_1.Column)({
44
+ nullable: true,
45
+ default: null
46
+ }),
47
+ __metadata("design:type", String)
48
+ ], PublicTestimonialEntity.prototype, "title", void 0);
49
+ __decorate([
50
+ (0, typeorm_1.Column)({
51
+ nullable: true,
52
+ default: null
53
+ }),
54
+ __metadata("design:type", String)
55
+ ], PublicTestimonialEntity.prototype, "feedback", void 0);
56
+ __decorate([
57
+ (0, typeorm_1.Column)({
58
+ nullable: true,
59
+ default: null
60
+ }),
61
+ __metadata("design:type", String)
62
+ ], PublicTestimonialEntity.prototype, "image", void 0);
63
+ __decorate([
64
+ (0, typeorm_1.Column)({
65
+ nullable: true,
66
+ default: null
67
+ }),
68
+ __metadata("design:type", String)
69
+ ], PublicTestimonialEntity.prototype, "name", void 0);
70
+ __decorate([
71
+ (0, typeorm_1.Column)({
72
+ nullable: true,
73
+ default: null
74
+ }),
75
+ __metadata("design:type", String)
76
+ ], PublicTestimonialEntity.prototype, "position", void 0);
77
+ __decorate([
78
+ (0, typeorm_1.ManyToOne)(() => country_entity_1.CountryEntity, country => country.testimonies),
79
+ __metadata("design:type", Promise)
80
+ ], PublicTestimonialEntity.prototype, "country", void 0);
81
+ exports.PublicTestimonialEntity = PublicTestimonialEntity = __decorate([
82
+ (0, typeorm_1.Entity)('publicTestimonials'),
83
+ __metadata("design:paramtypes", [Object])
84
+ ], PublicTestimonialEntity);
85
+ //# sourceMappingURL=testimonial.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"testimonial.js","sourceRoot":"","sources":["../../src/public/testimonial.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,4CAA2C;AAC3C,qCAA4E;AAE5E,qEAAiE;AAG1D,IAAM,uBAAuB,GAA7B,MAAM,uBAAuB;IA6EnC,6DAA6D;IAE7D,YAAY,KAAwC;QACnD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD,CAAA;AAlFY,0DAAuB;AAMnC;IADC,IAAA,gCAAsB,GAAE;;mDACd;AAQX;IAHC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,KAAK;KACf,CAAC;;0DACgB;AAWlB;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