@uniorganization/uni-lib 4.0.12 → 4.0.14

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.
@@ -82,3 +82,4 @@ export * from './service-center.entity';
82
82
  export * from './service-center-interaction.entity';
83
83
  export * from './service-center-review.entity';
84
84
  export * from './service-center-phone.entity';
85
+ export * from './service-center-distance-cache.entity';
@@ -98,3 +98,4 @@ __exportStar(require("./service-center.entity"), exports);
98
98
  __exportStar(require("./service-center-interaction.entity"), exports);
99
99
  __exportStar(require("./service-center-review.entity"), exports);
100
100
  __exportStar(require("./service-center-phone.entity"), exports);
101
+ __exportStar(require("./service-center-distance-cache.entity"), exports);
@@ -0,0 +1,17 @@
1
+ import { ServiceCenterEntity } from './service-center.entity';
2
+ import { Users } from './usr.entity';
3
+ export declare class ServiceCenterDistanceCacheEntity {
4
+ id: number;
5
+ serviceCenterId: number;
6
+ serviceCenter: ServiceCenterEntity;
7
+ fullOriginalAddress: string;
8
+ street: string;
9
+ city: string;
10
+ state: string;
11
+ zipCode: string;
12
+ responseJson: Record<string, any>;
13
+ createdById: number;
14
+ createdBy: Users;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ }
@@ -0,0 +1,76 @@
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.ServiceCenterDistanceCacheEntity = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const service_center_entity_1 = require("./service-center.entity");
15
+ const usr_entity_1 = require("./usr.entity");
16
+ let ServiceCenterDistanceCacheEntity = class ServiceCenterDistanceCacheEntity {
17
+ };
18
+ exports.ServiceCenterDistanceCacheEntity = ServiceCenterDistanceCacheEntity;
19
+ __decorate([
20
+ (0, typeorm_1.PrimaryGeneratedColumn)(),
21
+ __metadata("design:type", Number)
22
+ ], ServiceCenterDistanceCacheEntity.prototype, "id", void 0);
23
+ __decorate([
24
+ (0, typeorm_1.Column)({ name: 'service_center_id', type: 'integer', nullable: false }),
25
+ __metadata("design:type", Number)
26
+ ], ServiceCenterDistanceCacheEntity.prototype, "serviceCenterId", void 0);
27
+ __decorate([
28
+ (0, typeorm_1.ManyToOne)(() => service_center_entity_1.ServiceCenterEntity),
29
+ (0, typeorm_1.JoinColumn)({ name: 'service_center_id' }),
30
+ __metadata("design:type", service_center_entity_1.ServiceCenterEntity)
31
+ ], ServiceCenterDistanceCacheEntity.prototype, "serviceCenter", void 0);
32
+ __decorate([
33
+ (0, typeorm_1.Column)({ name: 'full_original_address', type: 'text', nullable: false }),
34
+ __metadata("design:type", String)
35
+ ], ServiceCenterDistanceCacheEntity.prototype, "fullOriginalAddress", void 0);
36
+ __decorate([
37
+ (0, typeorm_1.Column)({ name: 'street', type: 'varchar', length: 255, nullable: true }),
38
+ __metadata("design:type", String)
39
+ ], ServiceCenterDistanceCacheEntity.prototype, "street", void 0);
40
+ __decorate([
41
+ (0, typeorm_1.Column)({ name: 'city', type: 'varchar', length: 100, nullable: true }),
42
+ __metadata("design:type", String)
43
+ ], ServiceCenterDistanceCacheEntity.prototype, "city", void 0);
44
+ __decorate([
45
+ (0, typeorm_1.Column)({ name: 'state', type: 'varchar', length: 100, nullable: true }),
46
+ __metadata("design:type", String)
47
+ ], ServiceCenterDistanceCacheEntity.prototype, "state", void 0);
48
+ __decorate([
49
+ (0, typeorm_1.Column)({ name: 'zip_code', type: 'varchar', length: 20, nullable: true }),
50
+ __metadata("design:type", String)
51
+ ], ServiceCenterDistanceCacheEntity.prototype, "zipCode", void 0);
52
+ __decorate([
53
+ (0, typeorm_1.Column)({ name: 'response_json', type: 'jsonb', nullable: false }),
54
+ __metadata("design:type", Object)
55
+ ], ServiceCenterDistanceCacheEntity.prototype, "responseJson", void 0);
56
+ __decorate([
57
+ (0, typeorm_1.Column)({ name: 'created_by_id', type: 'integer', nullable: true }),
58
+ __metadata("design:type", Number)
59
+ ], ServiceCenterDistanceCacheEntity.prototype, "createdById", void 0);
60
+ __decorate([
61
+ (0, typeorm_1.ManyToOne)(() => usr_entity_1.Users),
62
+ (0, typeorm_1.JoinColumn)({ name: 'created_by_id' }),
63
+ __metadata("design:type", usr_entity_1.Users)
64
+ ], ServiceCenterDistanceCacheEntity.prototype, "createdBy", void 0);
65
+ __decorate([
66
+ (0, typeorm_1.CreateDateColumn)({ name: 'created_at', type: 'timestamptz' }),
67
+ __metadata("design:type", Date)
68
+ ], ServiceCenterDistanceCacheEntity.prototype, "createdAt", void 0);
69
+ __decorate([
70
+ (0, typeorm_1.UpdateDateColumn)({ name: 'updated_at', type: 'timestamptz' }),
71
+ __metadata("design:type", Date)
72
+ ], ServiceCenterDistanceCacheEntity.prototype, "updatedAt", void 0);
73
+ exports.ServiceCenterDistanceCacheEntity = ServiceCenterDistanceCacheEntity = __decorate([
74
+ (0, typeorm_1.Entity)('service_center_distance_cache', { schema: 'enr' }),
75
+ (0, typeorm_1.Index)(['serviceCenterId', 'fullOriginalAddress'])
76
+ ], ServiceCenterDistanceCacheEntity);
@@ -3,17 +3,33 @@ import { ServiceCenterPhoneEntity } from './service-center-phone.entity';
3
3
  export declare class ServiceCenterEntity {
4
4
  id: number;
5
5
  servicerAccount: string;
6
+ useFlag: string;
7
+ system: string;
6
8
  servicerName: string;
9
+ contact: string;
7
10
  address: string;
8
11
  city: string;
9
12
  county: string;
10
13
  state: string;
11
14
  zipCode: string;
12
15
  country: string;
16
+ servicerType: string;
13
17
  active: boolean;
18
+ eligible: boolean;
19
+ locatingFlag: boolean;
20
+ autoAcceptanceFlag: boolean;
21
+ partsManagementProgramFlag: boolean;
22
+ zipcodeCoverage: boolean;
23
+ brandCoverage: boolean;
24
+ productCoverage: boolean;
25
+ overwriteCutOffTime: string;
26
+ excludeServicerFromEmail: boolean;
27
+ notesNotificationEmail: string;
28
+ classification: string;
14
29
  fax: string;
15
30
  email: string;
16
31
  lgScore: number;
32
+ profileIndicator: string;
17
33
  isAuthorized: boolean;
18
34
  overallReviewScore: number;
19
35
  totalReviews: number;
@@ -25,10 +25,22 @@ __decorate([
25
25
  (0, typeorm_1.Column)({ name: 'servicer_account', type: 'varchar', nullable: false }),
26
26
  __metadata("design:type", String)
27
27
  ], ServiceCenterEntity.prototype, "servicerAccount", void 0);
28
+ __decorate([
29
+ (0, typeorm_1.Column)({ name: 'use_flag', type: 'varchar', nullable: true, select: false }),
30
+ __metadata("design:type", String)
31
+ ], ServiceCenterEntity.prototype, "useFlag", void 0);
32
+ __decorate([
33
+ (0, typeorm_1.Column)({ name: 'system', type: 'varchar', nullable: true }),
34
+ __metadata("design:type", String)
35
+ ], ServiceCenterEntity.prototype, "system", void 0);
28
36
  __decorate([
29
37
  (0, typeorm_1.Column)({ name: 'servicer_name', type: 'varchar', nullable: true }),
30
38
  __metadata("design:type", String)
31
39
  ], ServiceCenterEntity.prototype, "servicerName", void 0);
40
+ __decorate([
41
+ (0, typeorm_1.Column)({ name: 'contact', type: 'varchar', nullable: true, select: false }),
42
+ __metadata("design:type", String)
43
+ ], ServiceCenterEntity.prototype, "contact", void 0);
32
44
  __decorate([
33
45
  (0, typeorm_1.Column)({ name: 'address', type: 'varchar', nullable: true }),
34
46
  __metadata("design:type", String)
@@ -53,10 +65,58 @@ __decorate([
53
65
  (0, typeorm_1.Column)({ name: 'country', type: 'varchar', nullable: true }),
54
66
  __metadata("design:type", String)
55
67
  ], ServiceCenterEntity.prototype, "country", void 0);
68
+ __decorate([
69
+ (0, typeorm_1.Column)({ name: 'servicer_type', type: 'varchar', nullable: true, select: false }),
70
+ __metadata("design:type", String)
71
+ ], ServiceCenterEntity.prototype, "servicerType", void 0);
56
72
  __decorate([
57
73
  (0, typeorm_1.Column)({ name: 'active', type: 'boolean', default: true }),
58
74
  __metadata("design:type", Boolean)
59
75
  ], ServiceCenterEntity.prototype, "active", void 0);
76
+ __decorate([
77
+ (0, typeorm_1.Column)({ name: 'eligible', type: 'boolean', nullable: true, select: false }),
78
+ __metadata("design:type", Boolean)
79
+ ], ServiceCenterEntity.prototype, "eligible", void 0);
80
+ __decorate([
81
+ (0, typeorm_1.Column)({ name: 'locating_flag', type: 'boolean', nullable: true, select: false }),
82
+ __metadata("design:type", Boolean)
83
+ ], ServiceCenterEntity.prototype, "locatingFlag", void 0);
84
+ __decorate([
85
+ (0, typeorm_1.Column)({ name: 'auto_acceptance_flag', type: 'boolean', nullable: true, select: false }),
86
+ __metadata("design:type", Boolean)
87
+ ], ServiceCenterEntity.prototype, "autoAcceptanceFlag", void 0);
88
+ __decorate([
89
+ (0, typeorm_1.Column)({ name: 'parts_management_program_flag', type: 'boolean', nullable: true, select: false }),
90
+ __metadata("design:type", Boolean)
91
+ ], ServiceCenterEntity.prototype, "partsManagementProgramFlag", void 0);
92
+ __decorate([
93
+ (0, typeorm_1.Column)({ name: 'zipcode_coverage', type: 'boolean', nullable: true, select: false }),
94
+ __metadata("design:type", Boolean)
95
+ ], ServiceCenterEntity.prototype, "zipcodeCoverage", void 0);
96
+ __decorate([
97
+ (0, typeorm_1.Column)({ name: 'brand_coverage', type: 'boolean', nullable: true, select: false }),
98
+ __metadata("design:type", Boolean)
99
+ ], ServiceCenterEntity.prototype, "brandCoverage", void 0);
100
+ __decorate([
101
+ (0, typeorm_1.Column)({ name: 'product_coverage', type: 'boolean', nullable: true, select: false }),
102
+ __metadata("design:type", Boolean)
103
+ ], ServiceCenterEntity.prototype, "productCoverage", void 0);
104
+ __decorate([
105
+ (0, typeorm_1.Column)({ name: 'overwrite_cut_off_time', type: 'varchar', nullable: true, select: false }),
106
+ __metadata("design:type", String)
107
+ ], ServiceCenterEntity.prototype, "overwriteCutOffTime", void 0);
108
+ __decorate([
109
+ (0, typeorm_1.Column)({ name: 'exclude_servicer_from_email', type: 'boolean', nullable: true, select: false }),
110
+ __metadata("design:type", Boolean)
111
+ ], ServiceCenterEntity.prototype, "excludeServicerFromEmail", void 0);
112
+ __decorate([
113
+ (0, typeorm_1.Column)({ name: 'notes_notification_email', type: 'varchar', nullable: true, select: false }),
114
+ __metadata("design:type", String)
115
+ ], ServiceCenterEntity.prototype, "notesNotificationEmail", void 0);
116
+ __decorate([
117
+ (0, typeorm_1.Column)({ name: 'classification', type: 'varchar', nullable: true, select: false }),
118
+ __metadata("design:type", String)
119
+ ], ServiceCenterEntity.prototype, "classification", void 0);
60
120
  __decorate([
61
121
  (0, typeorm_1.Column)({ name: 'fax', type: 'varchar', nullable: true }),
62
122
  __metadata("design:type", String)
@@ -69,6 +129,10 @@ __decorate([
69
129
  (0, typeorm_1.Column)({ name: 'lg_score', type: 'integer', nullable: true }),
70
130
  __metadata("design:type", Number)
71
131
  ], ServiceCenterEntity.prototype, "lgScore", void 0);
132
+ __decorate([
133
+ (0, typeorm_1.Column)({ name: 'profile_indicator', type: 'varchar', nullable: true, select: false }),
134
+ __metadata("design:type", String)
135
+ ], ServiceCenterEntity.prototype, "profileIndicator", void 0);
72
136
  __decorate([
73
137
  (0, typeorm_1.Column)({ name: 'is_authorized', type: 'boolean', default: false }),
74
138
  __metadata("design:type", Boolean)
@@ -0,0 +1,2 @@
1
+ export declare class GoogleMapsModule {
2
+ }
@@ -0,0 +1,24 @@
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
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.GoogleMapsModule = void 0;
10
+ const common_1 = require("@nestjs/common");
11
+ const google_maps_service_1 = require("./google-maps.service");
12
+ const axios_1 = require("@nestjs/axios");
13
+ let GoogleMapsModule = class GoogleMapsModule {
14
+ };
15
+ exports.GoogleMapsModule = GoogleMapsModule;
16
+ exports.GoogleMapsModule = GoogleMapsModule = __decorate([
17
+ (0, common_1.Module)({
18
+ imports: [
19
+ axios_1.HttpModule,
20
+ ],
21
+ providers: [google_maps_service_1.GoogleMapsService],
22
+ exports: [google_maps_service_1.GoogleMapsService],
23
+ })
24
+ ], GoogleMapsModule);
@@ -0,0 +1,7 @@
1
+ import { DistanceMatrixResponseData } from '@googlemaps/google-maps-services-js';
2
+ export declare class GoogleMapsService {
3
+ private client;
4
+ private readonly logger;
5
+ constructor();
6
+ getDistanceMatrix(origin: string, destination: string): Promise<DistanceMatrixResponseData>;
7
+ }
@@ -0,0 +1,62 @@
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
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
12
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
13
+ return new (P || (P = Promise))(function (resolve, reject) {
14
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
15
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
16
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
17
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
18
+ });
19
+ };
20
+ var GoogleMapsService_1;
21
+ Object.defineProperty(exports, "__esModule", { value: true });
22
+ exports.GoogleMapsService = void 0;
23
+ const common_1 = require("@nestjs/common");
24
+ const google_maps_services_js_1 = require("@googlemaps/google-maps-services-js");
25
+ let GoogleMapsService = GoogleMapsService_1 = class GoogleMapsService {
26
+ constructor() {
27
+ this.logger = new common_1.Logger(GoogleMapsService_1.name);
28
+ this.client = new google_maps_services_js_1.Client({});
29
+ }
30
+ getDistanceMatrix(origin, destination) {
31
+ return __awaiter(this, void 0, void 0, function* () {
32
+ const apiKey = process.env.GOOGLE_MAPS_API_KEY;
33
+ if (!apiKey) {
34
+ this.logger.error('GOOGLE_MAPS_API_KEY is not defined');
35
+ throw new Error('Google Maps API configuration missing');
36
+ }
37
+ try {
38
+ const response = yield this.client.distancematrix({
39
+ params: {
40
+ origins: [origin],
41
+ destinations: [destination],
42
+ key: apiKey,
43
+ units: google_maps_services_js_1.UnitSystem.imperial,
44
+ },
45
+ });
46
+ if (response.status !== 200) {
47
+ throw new Error(`Google Maps API returned status ${response.status}: ${response.data.error_message || ''}`);
48
+ }
49
+ return response.data;
50
+ }
51
+ catch (e) {
52
+ this.logger.error(`Google Maps API Error: ${e.message}`, e.stack);
53
+ throw e;
54
+ }
55
+ });
56
+ }
57
+ };
58
+ exports.GoogleMapsService = GoogleMapsService;
59
+ exports.GoogleMapsService = GoogleMapsService = GoogleMapsService_1 = __decorate([
60
+ (0, common_1.Injectable)(),
61
+ __metadata("design:paramtypes", [])
62
+ ], GoogleMapsService);
@@ -1,2 +1,4 @@
1
1
  export * from './common';
2
2
  export * from './encryption';
3
+ export * from './google-maps/google-maps.module';
4
+ export * from './google-maps/google-maps.service';
@@ -16,3 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./common"), exports);
18
18
  __exportStar(require("./encryption"), exports);
19
+ __exportStar(require("./google-maps/google-maps.module"), exports);
20
+ __exportStar(require("./google-maps/google-maps.service"), exports);
package/package.json CHANGED
@@ -1,71 +1,73 @@
1
- {
2
- "name": "@uniorganization/uni-lib",
3
- "version": "4.0.12",
4
- "description": "UNI Library",
5
- "author": "Jhomiguel",
6
- "main": "dist/index.js",
7
- "types": "dist/index.d.ts",
8
- "files": [
9
- "dist/**/*",
10
- "*.md"
11
- ],
12
- "scripts": {
13
- "start:dev": "tsc -w",
14
- "build": "tsc",
15
- "prepare": "npm run build",
16
- "format": "prettier --write \"src/**/*.ts\"",
17
- "lint": "tslint -p tsconfig.json -c tslint.json",
18
- "test": "jest",
19
- "test:watch": "jest --watch",
20
- "test:cov": "jest --coverage",
21
- "test:e2e": "jest --config ./test/jest-e2e.json"
22
- },
23
- "dependencies": {
24
- "@nestjs/axios": "3.0.3",
25
- "@nestjs/jwt": "^10.2.0",
26
- "@nestjs/common": "^10.4.1",
27
- "@nestjs/core": "^10.4.1",
28
- "@nestjs/passport": "^10.0.3",
29
- "@nestjs/swagger": "^7.4.0",
30
- "csvtojson": "^2.0.10",
31
- "passport": "^0.7.0",
32
- "passport-jwt": "^4.0.1",
33
- "rxjs": "^7.8.1",
34
- "swagger-ui-express": "^5.0.1",
35
- "typeorm": "^0.3.20"
36
- },
37
- "devDependencies": {
38
- "@nestjs/cli": "^10.4.5",
39
- "@nestjs/platform-express": "^10.4.1",
40
- "@nestjs/testing": "^10.4.1",
41
- "@nestjs/typeorm": "^10.0.2",
42
- "@types/express": "4.17.21",
43
- "@types/jest": "^29.5.12",
44
- "@types/node": "^22.5.4",
45
- "@types/passport-jwt": "^4.0.1",
46
- "@types/supertest": "^6.0.2",
47
- "jest": "^29.7.0",
48
- "prettier": "^3.3.3",
49
- "supertest": "^7.0.0",
50
- "ts-jest": "^29.2.5",
51
- "ts-loader": "^9.5.1",
52
- "ts-node": "^10.9.2",
53
- "tsconfig-paths": "^4.2.0",
54
- "tslint": "6.1.3",
55
- "typescript": "^5.5.4"
56
- },
57
- "jest": {
58
- "moduleFileExtensions": [
59
- "js",
60
- "json",
61
- "ts"
62
- ],
63
- "rootDir": "src",
64
- "testRegex": ".spec.ts$",
65
- "transform": {
66
- "^.+\\.(t|j)s$": "ts-jest"
67
- },
68
- "coverageDirectory": "../coverage",
69
- "testEnvironment": "node"
70
- }
71
- }
1
+ {
2
+ "name": "@uniorganization/uni-lib",
3
+ "version": "4.0.14",
4
+ "description": "UNI Library",
5
+ "author": "Jhomiguel",
6
+ "main": "dist/index.js",
7
+ "types": "dist/index.d.ts",
8
+ "files": [
9
+ "dist/**/*",
10
+ "*.md"
11
+ ],
12
+ "scripts": {
13
+ "start:dev": "tsc -w",
14
+ "build": "tsc",
15
+ "prepare": "npm run build",
16
+ "format": "prettier --write \"src/**/*.ts\"",
17
+ "lint": "tslint -p tsconfig.json -c tslint.json",
18
+ "test": "jest",
19
+ "test:watch": "jest --watch",
20
+ "test:cov": "jest --coverage",
21
+ "test:e2e": "jest --config ./test/jest-e2e.json"
22
+ },
23
+ "dependencies": {
24
+ "@googlemaps/google-maps-services-js": "^3.4.2",
25
+ "@nestjs/axios": "3.0.3",
26
+ "@nestjs/common": "^10.4.1",
27
+ "@nestjs/core": "^10.4.1",
28
+ "@nestjs/jwt": "^10.2.0",
29
+ "@nestjs/passport": "^10.0.3",
30
+ "@nestjs/swagger": "^7.4.0",
31
+ "axios": "^1.13.2",
32
+ "csvtojson": "^2.0.10",
33
+ "passport": "^0.7.0",
34
+ "passport-jwt": "^4.0.1",
35
+ "rxjs": "^7.8.1",
36
+ "swagger-ui-express": "^5.0.1",
37
+ "typeorm": "^0.3.20"
38
+ },
39
+ "devDependencies": {
40
+ "@nestjs/cli": "^10.4.5",
41
+ "@nestjs/platform-express": "^10.4.1",
42
+ "@nestjs/testing": "^10.4.1",
43
+ "@nestjs/typeorm": "^10.0.2",
44
+ "@types/express": "4.17.21",
45
+ "@types/jest": "^29.5.12",
46
+ "@types/node": "^22.5.4",
47
+ "@types/passport-jwt": "^4.0.1",
48
+ "@types/supertest": "^6.0.2",
49
+ "jest": "^29.7.0",
50
+ "prettier": "^3.3.3",
51
+ "supertest": "^7.0.0",
52
+ "ts-jest": "^29.2.5",
53
+ "ts-loader": "^9.5.1",
54
+ "ts-node": "^10.9.2",
55
+ "tsconfig-paths": "^4.2.0",
56
+ "tslint": "6.1.3",
57
+ "typescript": "^5.5.4"
58
+ },
59
+ "jest": {
60
+ "moduleFileExtensions": [
61
+ "js",
62
+ "json",
63
+ "ts"
64
+ ],
65
+ "rootDir": "src",
66
+ "testRegex": ".spec.ts$",
67
+ "transform": {
68
+ "^.+\\.(t|j)s$": "ts-jest"
69
+ },
70
+ "coverageDirectory": "../coverage",
71
+ "testEnvironment": "node"
72
+ }
73
+ }
@@ -1,30 +0,0 @@
1
- export declare class ServicerEntity {
2
- id: number;
3
- servicerAccount: string;
4
- servicerName: string;
5
- contact: string;
6
- address: string;
7
- city: string;
8
- county: string;
9
- state: string;
10
- zipCode: string;
11
- country: string;
12
- servicerType: string;
13
- active: string;
14
- eligible: string;
15
- locatingFlag: string;
16
- autoAcceptanceFlag: string;
17
- partsManagementProgramFlag: string;
18
- zipcodeCoverage: string;
19
- brandCoverage: string;
20
- productCoverage: string;
21
- overwriteCutOffTime: string;
22
- excludeServicerFromEmail: string;
23
- notesNotificationEmail: string;
24
- classification: string;
25
- phone: string;
26
- fax: string;
27
- email: string;
28
- lgScore: number;
29
- profileIndicator: string;
30
- }
@@ -1,132 +0,0 @@
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.ServicerEntity = void 0;
13
- const typeorm_1 = require("typeorm");
14
- let ServicerEntity = class ServicerEntity {
15
- };
16
- exports.ServicerEntity = ServicerEntity;
17
- __decorate([
18
- (0, typeorm_1.PrimaryGeneratedColumn)(),
19
- __metadata("design:type", Number)
20
- ], ServicerEntity.prototype, "id", void 0);
21
- __decorate([
22
- (0, typeorm_1.Index)({ unique: true }),
23
- (0, typeorm_1.Column)({ name: 'servicer_account', type: 'varchar', nullable: false }),
24
- __metadata("design:type", String)
25
- ], ServicerEntity.prototype, "servicerAccount", void 0);
26
- __decorate([
27
- (0, typeorm_1.Column)({ name: 'servicer_name', type: 'varchar', nullable: true }),
28
- __metadata("design:type", String)
29
- ], ServicerEntity.prototype, "servicerName", void 0);
30
- __decorate([
31
- (0, typeorm_1.Column)({ name: 'contact', type: 'varchar', nullable: true }),
32
- __metadata("design:type", String)
33
- ], ServicerEntity.prototype, "contact", void 0);
34
- __decorate([
35
- (0, typeorm_1.Column)({ name: 'address', type: 'varchar', nullable: true }),
36
- __metadata("design:type", String)
37
- ], ServicerEntity.prototype, "address", void 0);
38
- __decorate([
39
- (0, typeorm_1.Column)({ name: 'city', type: 'varchar', nullable: true }),
40
- __metadata("design:type", String)
41
- ], ServicerEntity.prototype, "city", void 0);
42
- __decorate([
43
- (0, typeorm_1.Column)({ name: 'county', type: 'varchar', nullable: true }),
44
- __metadata("design:type", String)
45
- ], ServicerEntity.prototype, "county", void 0);
46
- __decorate([
47
- (0, typeorm_1.Column)({ name: 'state', type: 'varchar', nullable: true }),
48
- __metadata("design:type", String)
49
- ], ServicerEntity.prototype, "state", void 0);
50
- __decorate([
51
- (0, typeorm_1.Column)({ name: 'zip_code', type: 'varchar', nullable: true }),
52
- __metadata("design:type", String)
53
- ], ServicerEntity.prototype, "zipCode", void 0);
54
- __decorate([
55
- (0, typeorm_1.Column)({ name: 'country', type: 'varchar', nullable: true }),
56
- __metadata("design:type", String)
57
- ], ServicerEntity.prototype, "country", void 0);
58
- __decorate([
59
- (0, typeorm_1.Column)({ name: 'servicer_type', type: 'varchar', nullable: true }),
60
- __metadata("design:type", String)
61
- ], ServicerEntity.prototype, "servicerType", void 0);
62
- __decorate([
63
- (0, typeorm_1.Column)({ name: 'active', type: 'varchar', nullable: true }),
64
- __metadata("design:type", String)
65
- ], ServicerEntity.prototype, "active", void 0);
66
- __decorate([
67
- (0, typeorm_1.Column)({ name: 'eligible', type: 'varchar', nullable: true }),
68
- __metadata("design:type", String)
69
- ], ServicerEntity.prototype, "eligible", void 0);
70
- __decorate([
71
- (0, typeorm_1.Column)({ name: 'locating_flag', type: 'varchar', nullable: true }),
72
- __metadata("design:type", String)
73
- ], ServicerEntity.prototype, "locatingFlag", void 0);
74
- __decorate([
75
- (0, typeorm_1.Column)({ name: 'auto_acceptance_flag', type: 'varchar', nullable: true }),
76
- __metadata("design:type", String)
77
- ], ServicerEntity.prototype, "autoAcceptanceFlag", void 0);
78
- __decorate([
79
- (0, typeorm_1.Column)({ name: 'parts_management_program_flag', type: 'varchar', nullable: true }),
80
- __metadata("design:type", String)
81
- ], ServicerEntity.prototype, "partsManagementProgramFlag", void 0);
82
- __decorate([
83
- (0, typeorm_1.Column)({ name: 'zipcode_coverage', type: 'varchar', nullable: true }),
84
- __metadata("design:type", String)
85
- ], ServicerEntity.prototype, "zipcodeCoverage", void 0);
86
- __decorate([
87
- (0, typeorm_1.Column)({ name: 'brand_coverage', type: 'varchar', nullable: true }),
88
- __metadata("design:type", String)
89
- ], ServicerEntity.prototype, "brandCoverage", void 0);
90
- __decorate([
91
- (0, typeorm_1.Column)({ name: 'product_coverage', type: 'varchar', nullable: true }),
92
- __metadata("design:type", String)
93
- ], ServicerEntity.prototype, "productCoverage", void 0);
94
- __decorate([
95
- (0, typeorm_1.Column)({ name: 'overwrite_cut_off_time', type: 'varchar', nullable: true }),
96
- __metadata("design:type", String)
97
- ], ServicerEntity.prototype, "overwriteCutOffTime", void 0);
98
- __decorate([
99
- (0, typeorm_1.Column)({ name: 'exclude_servicer_from_email', type: 'varchar', nullable: true }),
100
- __metadata("design:type", String)
101
- ], ServicerEntity.prototype, "excludeServicerFromEmail", void 0);
102
- __decorate([
103
- (0, typeorm_1.Column)({ name: 'notes_notification_email', type: 'varchar', nullable: true }),
104
- __metadata("design:type", String)
105
- ], ServicerEntity.prototype, "notesNotificationEmail", void 0);
106
- __decorate([
107
- (0, typeorm_1.Column)({ name: 'classification', type: 'varchar', nullable: true }),
108
- __metadata("design:type", String)
109
- ], ServicerEntity.prototype, "classification", void 0);
110
- __decorate([
111
- (0, typeorm_1.Column)({ name: 'phone', type: 'varchar', nullable: true }),
112
- __metadata("design:type", String)
113
- ], ServicerEntity.prototype, "phone", void 0);
114
- __decorate([
115
- (0, typeorm_1.Column)({ name: 'fax', type: 'varchar', nullable: true }),
116
- __metadata("design:type", String)
117
- ], ServicerEntity.prototype, "fax", void 0);
118
- __decorate([
119
- (0, typeorm_1.Column)({ name: 'email', type: 'varchar', nullable: true }),
120
- __metadata("design:type", String)
121
- ], ServicerEntity.prototype, "email", void 0);
122
- __decorate([
123
- (0, typeorm_1.Column)({ name: 'lg_score', type: 'integer', nullable: true }),
124
- __metadata("design:type", Number)
125
- ], ServicerEntity.prototype, "lgScore", void 0);
126
- __decorate([
127
- (0, typeorm_1.Column)({ name: 'profile_indicator', type: 'varchar', nullable: true }),
128
- __metadata("design:type", String)
129
- ], ServicerEntity.prototype, "profileIndicator", void 0);
130
- exports.ServicerEntity = ServicerEntity = __decorate([
131
- (0, typeorm_1.Entity)('servicer', { schema: 'enr' })
132
- ], ServicerEntity);