@alba-cars/common-modules 2.0.0 → 2.1.0

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.
Files changed (146) hide show
  1. package/dist/index.js +1 -21
  2. package/package.json +10 -6
  3. package/dist/core/enums/HttpMethods.js +0 -14
  4. package/dist/core/enums/HttpStatusCodes.js +0 -19
  5. package/dist/core/enums/index.js +0 -18
  6. package/dist/core/error-handling/AppError.js +0 -48
  7. package/dist/core/error-handling/index.js +0 -17
  8. package/dist/core/index.js +0 -21
  9. package/dist/core/models/index.js +0 -19
  10. package/dist/core/models/media/index.js +0 -17
  11. package/dist/core/models/media/media_data.js +0 -2
  12. package/dist/core/models/pagination/index.js +0 -17
  13. package/dist/core/models/pagination/paginated_data.js +0 -21
  14. package/dist/core/models/range.js +0 -26
  15. package/dist/core/network/api-client.d.ts +0 -1
  16. package/dist/core/network/api-client.js +0 -22
  17. package/dist/core/network/endpoint-config.js +0 -260
  18. package/dist/core/network/fetch-api.js +0 -206
  19. package/dist/core/network/index.js +0 -18
  20. package/dist/core/utils/formatCurrency.js +0 -39
  21. package/dist/core/utils/global-constants.js +0 -9
  22. package/dist/core/utils/global-utils.js +0 -190
  23. package/dist/core/utils/global_validators.js +0 -20
  24. package/dist/core/utils/index.js +0 -20
  25. package/dist/core/utils/query_flatten.js +0 -15
  26. package/dist/features/auth/data/dto/AuthDTO.js +0 -106
  27. package/dist/features/auth/data/dto/RoleDTO.js +0 -132
  28. package/dist/features/auth/data/dto/UserDTO.js +0 -222
  29. package/dist/features/auth/data/index.js +0 -19
  30. package/dist/features/auth/index.js +0 -17
  31. package/dist/features/bank-valuation-request/data/dto/BankValuationRequestDTO.js +0 -132
  32. package/dist/features/bank-valuation-request/index.js +0 -17
  33. package/dist/features/blog/data/dto/BlogDTO.js +0 -176
  34. package/dist/features/blog/index.js +0 -17
  35. package/dist/features/callback-request/data/dto/CallBackRequestDTO.js +0 -110
  36. package/dist/features/callback-request/index.js +0 -17
  37. package/dist/features/deposits/data/dto/DepositDTOs.js +0 -303
  38. package/dist/features/deposits/data/index.js +0 -17
  39. package/dist/features/deposits/index.js +0 -17
  40. package/dist/features/faq/data/dtos/CreateFaqDTO.js +0 -87
  41. package/dist/features/faq/data/dtos/FaqFetchDTO.js +0 -349
  42. package/dist/features/faq/data/dtos/UpdateFaqDTO.js +0 -91
  43. package/dist/features/faq/data/dtos/index.js +0 -19
  44. package/dist/features/faq/data/enums/index.js +0 -10
  45. package/dist/features/faq/data/index.js +0 -18
  46. package/dist/features/faq/index.js +0 -17
  47. package/dist/features/finance-eligibilty-request/data/dto/FinanceEligibilityRequestDTO.js +0 -429
  48. package/dist/features/finance-eligibilty-request/data/index.js +0 -17
  49. package/dist/features/finance-eligibilty-request/index.js +0 -17
  50. package/dist/features/google-review/data/dto/google_review_dto.js +0 -466
  51. package/dist/features/google-review/data/dto/index.js +0 -17
  52. package/dist/features/google-review/data/enums/index.js +0 -8
  53. package/dist/features/google-review/data/index.js +0 -18
  54. package/dist/features/google-review/index.js +0 -17
  55. package/dist/features/index.js +0 -34
  56. package/dist/features/lead/data/dto/index.js +0 -20
  57. package/dist/features/lead/data/dto/lead_documents_dto.js +0 -73
  58. package/dist/features/lead/data/dto/lead_dto.js +0 -435
  59. package/dist/features/lead/data/dto/lead_preference_history_dto.js +0 -321
  60. package/dist/features/lead/data/dto/lead_prefernce_dto.js +0 -308
  61. package/dist/features/lead/data/enum/index.js +0 -18
  62. package/dist/features/lead/data/enum/lead_source_status_types.js +0 -19
  63. package/dist/features/lead/data/enum/lead_status_type.js +0 -12
  64. package/dist/features/lead/index.js +0 -18
  65. package/dist/features/models/BankValuationRequest.js +0 -6
  66. package/dist/features/models/Base.js +0 -6
  67. package/dist/features/models/Deposit.js +0 -6
  68. package/dist/features/models/Lead.js +0 -6
  69. package/dist/features/models/Payment.js +0 -7
  70. package/dist/features/models/Roles.js +0 -2
  71. package/dist/features/models/Ticket.js +0 -12
  72. package/dist/features/models/User.js +0 -2
  73. package/dist/features/models/UserFavoriteVehicle.js +0 -6
  74. package/dist/features/models/Vehicle.js +0 -17
  75. package/dist/features/models/VehicleBodyType.js +0 -7
  76. package/dist/features/models/VehicleCategory.js +0 -7
  77. package/dist/features/models/VehicleFeature.js +0 -7
  78. package/dist/features/models/VehicleFeatureCategory.js +0 -7
  79. package/dist/features/models/VehicleFinance.js +0 -7
  80. package/dist/features/models/VehicleMake.js +0 -7
  81. package/dist/features/models/VehicleMedia.js +0 -7
  82. package/dist/features/models/VehicleMetaData.js +0 -7
  83. package/dist/features/models/VehicleModel.js +0 -7
  84. package/dist/features/models/VehicleOrder.js +0 -7
  85. package/dist/features/models/_index.js +0 -30
  86. package/dist/features/models/index.js +0 -37
  87. package/dist/features/newsletter/data/dto/NewsletterDTO.js +0 -79
  88. package/dist/features/newsletter/index.js +0 -17
  89. package/dist/features/sales-team/data/dto/LanguageDTO.js +0 -89
  90. package/dist/features/sales-team/data/dto/SalesAgentDTO.js +0 -613
  91. package/dist/features/sales-team/data/index.js +0 -18
  92. package/dist/features/sales-team/index.js +0 -17
  93. package/dist/features/sell-car-request/data/dto/SellCarRequestDTO.js +0 -672
  94. package/dist/features/sell-car-request/data/index.js +0 -17
  95. package/dist/features/sell-car-request/index.js +0 -17
  96. package/dist/features/showroom-visit/data/dto/ShowroomVisit.js +0 -237
  97. package/dist/features/showroom-visit/data/enums/index.js +0 -17
  98. package/dist/features/showroom-visit/data/index.js +0 -18
  99. package/dist/features/showroom-visit/index.js +0 -17
  100. package/dist/features/test-drive-request/api/GetTestDriveVehicles.js +0 -8
  101. package/dist/features/test-drive-request/api/index.js +0 -17
  102. package/dist/features/test-drive-request/data/dto/TestDriveRequestDTO.js +0 -179
  103. package/dist/features/test-drive-request/data/enums/index.js +0 -29
  104. package/dist/features/test-drive-request/data/index.js +0 -20
  105. package/dist/features/test-drive-request/data/models/TestDriveRequest.js +0 -7
  106. package/dist/features/test-drive-request/data/models/index.js +0 -5
  107. package/dist/features/test-drive-request/data/utilities.js +0 -100
  108. package/dist/features/test-drive-request/index.js +0 -18
  109. package/dist/features/tickets/data/dto/TicketDto.js +0 -293
  110. package/dist/features/tickets/data/enums/index.js +0 -18
  111. package/dist/features/tickets/index.js +0 -18
  112. package/dist/features/vehicle/data/dto/BaseDTO.js +0 -34
  113. package/dist/features/vehicle/data/dto/MediaDTO.js +0 -2
  114. package/dist/features/vehicle/data/dto/PaymentDTO.js +0 -161
  115. package/dist/features/vehicle/data/dto/SimilarVehicleDTO.js +0 -38
  116. package/dist/features/vehicle/data/dto/VehicleCategoryDTO.js +0 -114
  117. package/dist/features/vehicle/data/dto/VehicleDTO.js +0 -587
  118. package/dist/features/vehicle/data/dto/VehicleFavoritesDTO.js +0 -60
  119. package/dist/features/vehicle/data/dto/VehicleFeatureCategoriesDTO.js +0 -114
  120. package/dist/features/vehicle/data/dto/VehicleFeatureDTO.js +0 -125
  121. package/dist/features/vehicle/data/dto/VehicleFilterDTO.js +0 -771
  122. package/dist/features/vehicle/data/dto/VehicleFinanceDTO.js +0 -183
  123. package/dist/features/vehicle/data/dto/VehicleInspectionDTO.js +0 -765
  124. package/dist/features/vehicle/data/dto/VehicleMakeDTO.js +0 -189
  125. package/dist/features/vehicle/data/dto/VehicleMedia.js +0 -152
  126. package/dist/features/vehicle/data/dto/VehicleModelDTO.js +0 -182
  127. package/dist/features/vehicle/data/dto/VehicleOrderDTO.js +0 -139
  128. package/dist/features/vehicle/data/dto/VehicleTypeDTO.js +0 -102
  129. package/dist/features/vehicle/data/dto/VehicleWarrantyDTO.js +0 -47
  130. package/dist/features/vehicle/data/dto/index.js +0 -35
  131. package/dist/features/vehicle/data/enums/index.js +0 -46
  132. package/dist/features/vehicle/data/index.js +0 -20
  133. package/dist/features/vehicle/data/utilities.js +0 -520
  134. package/dist/features/vehicle/index.js +0 -17
  135. package/dist/features/vehicle-reservations/data/dto/VehicleReservationDTO.js +0 -346
  136. package/dist/features/vehicle-reservations/data/dto/index.js +0 -17
  137. package/dist/features/vehicle-reservations/data/enums/finance-type.js +0 -9
  138. package/dist/features/vehicle-reservations/data/enums/index.js +0 -19
  139. package/dist/features/vehicle-reservations/data/enums/reservation-type.js +0 -13
  140. package/dist/features/vehicle-reservations/data/enums/vehicle-reservation-type.js +0 -8
  141. package/dist/features/vehicle-reservations/index.js +0 -18
  142. package/dist/global/dto/BaseGetDTO.js +0 -18
  143. package/dist/global/dto/index.js +0 -17
  144. package/dist/global/index.js +0 -18
  145. package/dist/global/utilities.js +0 -173
  146. package/dist/models.js +0 -17
@@ -1,321 +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.LeadPreferenceHistoryGetDTO = exports.LeadPreferenceHistoryFilter = exports.LeadPreferenceHistoryCreateDTO = exports.LeadPreferenceHistoryDTO = exports.FuelType = exports.TransmissionType = exports.CarCondition = void 0;
13
- const class_validator_1 = require("class-validator");
14
- const class_transformer_1 = require("class-transformer");
15
- const global_1 = require("../../../../global");
16
- const lead_dto_1 = require("./lead_dto");
17
- const core_1 = require("../../../../core");
18
- var CarCondition;
19
- (function (CarCondition) {
20
- CarCondition["NEW"] = "NEW";
21
- CarCondition["USED"] = "USED";
22
- CarCondition["BOTH"] = "BOTH";
23
- })(CarCondition = exports.CarCondition || (exports.CarCondition = {}));
24
- var TransmissionType;
25
- (function (TransmissionType) {
26
- TransmissionType["AUTOMATIC"] = "AUTOMATIC";
27
- TransmissionType["MANUAL"] = "MANUAL";
28
- TransmissionType["BOTH"] = "BOTH";
29
- })(TransmissionType = exports.TransmissionType || (exports.TransmissionType = {}));
30
- var FuelType;
31
- (function (FuelType) {
32
- FuelType["PETROL"] = "PETROL";
33
- FuelType["DIESEL"] = "DIESEL";
34
- FuelType["ELECTRIC"] = "ELECTRIC";
35
- FuelType["HYBRID"] = "HYBRID";
36
- FuelType["ANY"] = "ANY";
37
- })(FuelType = exports.FuelType || (exports.FuelType = {}));
38
- class LeadPreferenceHistoryDTO {
39
- validate() {
40
- const errors = (0, class_validator_1.validateSync)(this);
41
- return errors.map((error) => { var _a; return Object.values((_a = error.constraints) !== null && _a !== void 0 ? _a : {}); }).flat();
42
- }
43
- static fromPlain(plain) {
44
- return (0, class_transformer_1.plainToClass)(LeadPreferenceHistoryDTO, plain);
45
- }
46
- toPlain() {
47
- return (0, class_transformer_1.classToPlain)(this);
48
- }
49
- }
50
- __decorate([
51
- (0, class_validator_1.IsUUID)(),
52
- __metadata("design:type", String)
53
- ], LeadPreferenceHistoryDTO.prototype, "id", void 0);
54
- __decorate([
55
- (0, class_validator_1.ValidateNested)(),
56
- (0, class_transformer_1.Type)(() => lead_dto_1.LeadDTO),
57
- __metadata("design:type", lead_dto_1.LeadDTO)
58
- ], LeadPreferenceHistoryDTO.prototype, "lead", void 0);
59
- __decorate([
60
- (0, class_validator_1.IsOptional)(),
61
- (0, class_validator_1.IsNumber)(),
62
- __metadata("design:type", Number)
63
- ], LeadPreferenceHistoryDTO.prototype, "budgetMin", void 0);
64
- __decorate([
65
- (0, class_validator_1.IsOptional)(),
66
- (0, class_validator_1.IsNumber)(),
67
- __metadata("design:type", Number)
68
- ], LeadPreferenceHistoryDTO.prototype, "budgetMax", void 0);
69
- __decorate([
70
- (0, class_validator_1.IsOptional)(),
71
- (0, class_validator_1.IsString)(),
72
- __metadata("design:type", String)
73
- ], LeadPreferenceHistoryDTO.prototype, "preferredMake", void 0);
74
- __decorate([
75
- (0, class_validator_1.IsOptional)(),
76
- (0, class_validator_1.IsString)(),
77
- __metadata("design:type", String)
78
- ], LeadPreferenceHistoryDTO.prototype, "preferredModel", void 0);
79
- __decorate([
80
- (0, class_validator_1.IsOptional)(),
81
- (0, class_validator_1.IsNumber)(),
82
- __metadata("design:type", Number)
83
- ], LeadPreferenceHistoryDTO.prototype, "preferredYearMin", void 0);
84
- __decorate([
85
- (0, class_validator_1.IsOptional)(),
86
- (0, class_validator_1.IsNumber)(),
87
- __metadata("design:type", Number)
88
- ], LeadPreferenceHistoryDTO.prototype, "preferredYearMax", void 0);
89
- __decorate([
90
- (0, class_validator_1.IsOptional)(),
91
- (0, class_validator_1.IsArray)(),
92
- (0, class_validator_1.IsString)({ each: true }),
93
- __metadata("design:type", Array)
94
- ], LeadPreferenceHistoryDTO.prototype, "preferredColors", void 0);
95
- __decorate([
96
- (0, class_validator_1.IsOptional)(),
97
- (0, class_validator_1.IsArray)(),
98
- (0, class_validator_1.IsString)({ each: true }),
99
- __metadata("design:type", Array)
100
- ], LeadPreferenceHistoryDTO.prototype, "preferredFeatures", void 0);
101
- __decorate([
102
- (0, class_validator_1.IsEnum)(CarCondition),
103
- __metadata("design:type", String)
104
- ], LeadPreferenceHistoryDTO.prototype, "carCondition", void 0);
105
- __decorate([
106
- (0, class_validator_1.IsEnum)(TransmissionType),
107
- __metadata("design:type", String)
108
- ], LeadPreferenceHistoryDTO.prototype, "transmissionType", void 0);
109
- __decorate([
110
- (0, class_validator_1.IsEnum)(FuelType),
111
- __metadata("design:type", String)
112
- ], LeadPreferenceHistoryDTO.prototype, "fuelType", void 0);
113
- __decorate([
114
- (0, class_validator_1.IsOptional)(),
115
- (0, class_validator_1.IsString)(),
116
- __metadata("design:type", String)
117
- ], LeadPreferenceHistoryDTO.prototype, "additionalPreferences", void 0);
118
- __decorate([
119
- (0, class_validator_1.IsOptional)(),
120
- (0, class_validator_1.IsString)(),
121
- __metadata("design:type", String)
122
- ], LeadPreferenceHistoryDTO.prototype, "changeReason", void 0);
123
- __decorate([
124
- (0, class_validator_1.IsUUID)(),
125
- __metadata("design:type", String)
126
- ], LeadPreferenceHistoryDTO.prototype, "changedByUserId", void 0);
127
- __decorate([
128
- (0, class_validator_1.IsString)(),
129
- __metadata("design:type", Date)
130
- ], LeadPreferenceHistoryDTO.prototype, "createdAt", void 0);
131
- __decorate([
132
- (0, class_validator_1.IsString)(),
133
- __metadata("design:type", Date)
134
- ], LeadPreferenceHistoryDTO.prototype, "updatedAt", void 0);
135
- exports.LeadPreferenceHistoryDTO = LeadPreferenceHistoryDTO;
136
- class LeadPreferenceHistoryCreateDTO {
137
- constructor() {
138
- this.carCondition = CarCondition.BOTH;
139
- this.transmissionType = TransmissionType.BOTH;
140
- this.fuelType = FuelType.ANY;
141
- }
142
- validate() {
143
- const errors = (0, class_validator_1.validateSync)(this);
144
- return errors.map((error) => { var _a; return Object.values((_a = error.constraints) !== null && _a !== void 0 ? _a : {}); }).flat();
145
- }
146
- static fromPlain(plain) {
147
- return (0, class_transformer_1.plainToClass)(LeadPreferenceHistoryCreateDTO, plain);
148
- }
149
- toPlain() {
150
- return (0, class_transformer_1.classToPlain)(this);
151
- }
152
- }
153
- __decorate([
154
- (0, class_validator_1.IsUUID)(),
155
- __metadata("design:type", String)
156
- ], LeadPreferenceHistoryCreateDTO.prototype, "leadId", void 0);
157
- __decorate([
158
- (0, class_validator_1.IsOptional)(),
159
- (0, class_validator_1.IsNumber)(),
160
- __metadata("design:type", Number)
161
- ], LeadPreferenceHistoryCreateDTO.prototype, "budgetMin", void 0);
162
- __decorate([
163
- (0, class_validator_1.IsOptional)(),
164
- (0, class_validator_1.IsNumber)(),
165
- __metadata("design:type", Number)
166
- ], LeadPreferenceHistoryCreateDTO.prototype, "budgetMax", void 0);
167
- __decorate([
168
- (0, class_validator_1.IsOptional)(),
169
- (0, class_validator_1.IsString)(),
170
- __metadata("design:type", String)
171
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredMake", void 0);
172
- __decorate([
173
- (0, class_validator_1.IsOptional)(),
174
- (0, class_validator_1.IsString)(),
175
- __metadata("design:type", String)
176
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredModel", void 0);
177
- __decorate([
178
- (0, class_validator_1.IsOptional)(),
179
- (0, class_validator_1.IsNumber)(),
180
- __metadata("design:type", Number)
181
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredYearMin", void 0);
182
- __decorate([
183
- (0, class_validator_1.IsOptional)(),
184
- (0, class_validator_1.IsNumber)(),
185
- __metadata("design:type", Number)
186
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredYearMax", void 0);
187
- __decorate([
188
- (0, class_validator_1.IsOptional)(),
189
- (0, class_validator_1.IsArray)(),
190
- (0, class_validator_1.IsString)({ each: true }),
191
- __metadata("design:type", Array)
192
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredColors", void 0);
193
- __decorate([
194
- (0, class_validator_1.IsOptional)(),
195
- (0, class_validator_1.IsArray)(),
196
- (0, class_validator_1.IsString)({ each: true }),
197
- __metadata("design:type", Array)
198
- ], LeadPreferenceHistoryCreateDTO.prototype, "preferredFeatures", void 0);
199
- __decorate([
200
- (0, class_validator_1.IsEnum)(CarCondition),
201
- __metadata("design:type", String)
202
- ], LeadPreferenceHistoryCreateDTO.prototype, "carCondition", void 0);
203
- __decorate([
204
- (0, class_validator_1.IsEnum)(TransmissionType),
205
- __metadata("design:type", String)
206
- ], LeadPreferenceHistoryCreateDTO.prototype, "transmissionType", void 0);
207
- __decorate([
208
- (0, class_validator_1.IsEnum)(FuelType),
209
- __metadata("design:type", String)
210
- ], LeadPreferenceHistoryCreateDTO.prototype, "fuelType", void 0);
211
- __decorate([
212
- (0, class_validator_1.IsOptional)(),
213
- (0, class_validator_1.IsString)(),
214
- __metadata("design:type", String)
215
- ], LeadPreferenceHistoryCreateDTO.prototype, "additionalPreferences", void 0);
216
- __decorate([
217
- (0, class_validator_1.IsString)(),
218
- __metadata("design:type", String)
219
- ], LeadPreferenceHistoryCreateDTO.prototype, "changeReason", void 0);
220
- __decorate([
221
- (0, class_validator_1.IsUUID)(),
222
- __metadata("design:type", String)
223
- ], LeadPreferenceHistoryCreateDTO.prototype, "changedByUserId", void 0);
224
- exports.LeadPreferenceHistoryCreateDTO = LeadPreferenceHistoryCreateDTO;
225
- class LeadPreferenceHistoryFilter extends global_1.TypedFilter {
226
- }
227
- __decorate([
228
- (0, class_validator_1.IsOptional)(),
229
- (0, class_validator_1.IsString)({ each: true }),
230
- __metadata("design:type", Object)
231
- ], LeadPreferenceHistoryFilter.prototype, "id", void 0);
232
- __decorate([
233
- (0, class_validator_1.IsOptional)(),
234
- (0, class_validator_1.IsString)({ each: true }),
235
- __metadata("design:type", Object)
236
- ], LeadPreferenceHistoryFilter.prototype, "leadId", void 0);
237
- __decorate([
238
- (0, class_validator_1.IsOptional)(),
239
- (0, class_validator_1.ValidateNested)(),
240
- (0, class_transformer_1.Type)(() => core_1.Range),
241
- __metadata("design:type", core_1.Range)
242
- ], LeadPreferenceHistoryFilter.prototype, "budgetRange", void 0);
243
- __decorate([
244
- (0, class_validator_1.IsOptional)(),
245
- (0, class_validator_1.IsString)(),
246
- __metadata("design:type", String)
247
- ], LeadPreferenceHistoryFilter.prototype, "make", void 0);
248
- __decorate([
249
- (0, class_validator_1.IsOptional)(),
250
- (0, class_validator_1.IsString)(),
251
- __metadata("design:type", String)
252
- ], LeadPreferenceHistoryFilter.prototype, "model", void 0);
253
- __decorate([
254
- (0, class_validator_1.IsOptional)(),
255
- (0, class_validator_1.ValidateNested)(),
256
- (0, class_transformer_1.Type)(() => core_1.Range),
257
- __metadata("design:type", core_1.Range)
258
- ], LeadPreferenceHistoryFilter.prototype, "yearRange", void 0);
259
- __decorate([
260
- (0, class_validator_1.IsOptional)(),
261
- (0, class_validator_1.IsArray)(),
262
- (0, class_validator_1.IsString)({ each: true }),
263
- __metadata("design:type", Array)
264
- ], LeadPreferenceHistoryFilter.prototype, "colors", void 0);
265
- __decorate([
266
- (0, class_validator_1.IsOptional)(),
267
- (0, class_validator_1.IsArray)(),
268
- (0, class_validator_1.IsString)({ each: true }),
269
- __metadata("design:type", Array)
270
- ], LeadPreferenceHistoryFilter.prototype, "features", void 0);
271
- __decorate([
272
- (0, class_validator_1.IsOptional)(),
273
- (0, class_validator_1.IsEnum)(CarCondition, { each: true }),
274
- __metadata("design:type", Object)
275
- ], LeadPreferenceHistoryFilter.prototype, "carCondition", void 0);
276
- __decorate([
277
- (0, class_validator_1.IsOptional)(),
278
- (0, class_validator_1.IsEnum)(TransmissionType, { each: true }),
279
- __metadata("design:type", Object)
280
- ], LeadPreferenceHistoryFilter.prototype, "transmissionType", void 0);
281
- __decorate([
282
- (0, class_validator_1.IsOptional)(),
283
- (0, class_validator_1.IsEnum)(FuelType, { each: true }),
284
- __metadata("design:type", Object)
285
- ], LeadPreferenceHistoryFilter.prototype, "fuelType", void 0);
286
- __decorate([
287
- (0, class_validator_1.IsOptional)(),
288
- (0, class_validator_1.IsString)({ each: true }),
289
- __metadata("design:type", Object)
290
- ], LeadPreferenceHistoryFilter.prototype, "changedByUserId", void 0);
291
- __decorate([
292
- (0, class_validator_1.IsOptional)(),
293
- (0, class_validator_1.IsString)(),
294
- __metadata("design:type", String)
295
- ], LeadPreferenceHistoryFilter.prototype, "search", void 0);
296
- __decorate([
297
- (0, class_validator_1.IsOptional)(),
298
- (0, class_transformer_1.Type)(() => Date),
299
- __metadata("design:type", Date)
300
- ], LeadPreferenceHistoryFilter.prototype, "fromDate", void 0);
301
- __decorate([
302
- (0, class_validator_1.IsOptional)(),
303
- (0, class_transformer_1.Type)(() => Date),
304
- __metadata("design:type", Date)
305
- ], LeadPreferenceHistoryFilter.prototype, "toDate", void 0);
306
- exports.LeadPreferenceHistoryFilter = LeadPreferenceHistoryFilter;
307
- class LeadPreferenceHistoryGetDTO extends global_1.BaseGetDTO {
308
- }
309
- __decorate([
310
- (0, class_validator_1.ValidateNested)(),
311
- (0, class_transformer_1.Type)(() => LeadPreferenceHistoryFilter),
312
- (0, class_validator_1.IsOptional)(),
313
- __metadata("design:type", LeadPreferenceHistoryFilter)
314
- ], LeadPreferenceHistoryGetDTO.prototype, "filters", void 0);
315
- __decorate([
316
- (0, class_validator_1.ValidateNested)(),
317
- (0, class_transformer_1.Type)(() => global_1.TypedOptions),
318
- (0, class_validator_1.IsOptional)(),
319
- __metadata("design:type", global_1.TypedOptions)
320
- ], LeadPreferenceHistoryGetDTO.prototype, "options", void 0);
321
- exports.LeadPreferenceHistoryGetDTO = LeadPreferenceHistoryGetDTO;
@@ -1,308 +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.LeadPreferencesGetDTO = exports.LeadPreferencesFilter = exports.LeadPreferencesCreateDTO = exports.LeadPreferencesUpdateDTO = exports.LeadPreferencesDTO = void 0;
13
- const class_validator_1 = require("class-validator");
14
- const class_transformer_1 = require("class-transformer");
15
- const global_1 = require("../../../../global");
16
- const core_1 = require("../../../../core");
17
- class LeadPreferencesDTO {
18
- validate() {
19
- const errors = (0, class_validator_1.validateSync)(this);
20
- return errors.map((error) => { var _a; return Object.values((_a = error.constraints) !== null && _a !== void 0 ? _a : {}); }).flat();
21
- }
22
- static fromPlain(plain) {
23
- return (0, class_transformer_1.plainToClass)(LeadPreferencesDTO, plain);
24
- }
25
- toPlain() {
26
- return (0, class_transformer_1.classToPlain)(this);
27
- }
28
- }
29
- __decorate([
30
- (0, class_validator_1.IsUUID)(),
31
- __metadata("design:type", String)
32
- ], LeadPreferencesDTO.prototype, "id", void 0);
33
- __decorate([
34
- (0, class_validator_1.IsOptional)(),
35
- (0, class_validator_1.IsNumber)(),
36
- __metadata("design:type", Number)
37
- ], LeadPreferencesDTO.prototype, "budgetMin", void 0);
38
- __decorate([
39
- (0, class_validator_1.IsOptional)(),
40
- (0, class_validator_1.IsNumber)(),
41
- __metadata("design:type", Number)
42
- ], LeadPreferencesDTO.prototype, "budgetMax", void 0);
43
- __decorate([
44
- (0, class_validator_1.IsOptional)(),
45
- (0, class_validator_1.IsString)(),
46
- __metadata("design:type", String)
47
- ], LeadPreferencesDTO.prototype, "preferredMake", void 0);
48
- __decorate([
49
- (0, class_validator_1.IsOptional)(),
50
- (0, class_validator_1.IsString)(),
51
- __metadata("design:type", String)
52
- ], LeadPreferencesDTO.prototype, "preferredModel", void 0);
53
- __decorate([
54
- (0, class_validator_1.IsOptional)(),
55
- (0, class_validator_1.IsNumber)(),
56
- __metadata("design:type", Number)
57
- ], LeadPreferencesDTO.prototype, "preferredYearMin", void 0);
58
- __decorate([
59
- (0, class_validator_1.IsOptional)(),
60
- (0, class_validator_1.IsNumber)(),
61
- __metadata("design:type", Number)
62
- ], LeadPreferencesDTO.prototype, "preferredYearMax", void 0);
63
- __decorate([
64
- (0, class_validator_1.IsOptional)(),
65
- (0, class_validator_1.IsNumber)(),
66
- __metadata("design:type", Number)
67
- ], LeadPreferencesDTO.prototype, "mileageMin", void 0);
68
- __decorate([
69
- (0, class_validator_1.IsOptional)(),
70
- (0, class_validator_1.IsNumber)(),
71
- __metadata("design:type", Number)
72
- ], LeadPreferencesDTO.prototype, "mileageMax", void 0);
73
- __decorate([
74
- (0, class_validator_1.IsOptional)(),
75
- (0, class_validator_1.IsArray)(),
76
- (0, class_validator_1.IsString)({ each: true }),
77
- __metadata("design:type", Array)
78
- ], LeadPreferencesDTO.prototype, "preferredColors", void 0);
79
- __decorate([
80
- (0, class_validator_1.IsOptional)(),
81
- (0, class_validator_1.IsArray)(),
82
- (0, class_validator_1.IsString)({ each: true }),
83
- __metadata("design:type", Array)
84
- ], LeadPreferencesDTO.prototype, "preferredFeatures", void 0);
85
- __decorate([
86
- (0, class_validator_1.IsOptional)(),
87
- (0, class_validator_1.IsString)(),
88
- __metadata("design:type", String)
89
- ], LeadPreferencesDTO.prototype, "additionalPreferences", void 0);
90
- exports.LeadPreferencesDTO = LeadPreferencesDTO;
91
- class LeadPreferencesUpdateDTO {
92
- validate() {
93
- const errors = (0, class_validator_1.validateSync)(this);
94
- return errors.map((error) => { var _a; return Object.values((_a = error.constraints) !== null && _a !== void 0 ? _a : {}); }).flat();
95
- }
96
- static fromPlain(plain) {
97
- return (0, class_transformer_1.plainToClass)(LeadPreferencesUpdateDTO, plain);
98
- }
99
- toPlain() {
100
- return (0, class_transformer_1.classToPlain)(this);
101
- }
102
- }
103
- __decorate([
104
- (0, class_validator_1.IsOptional)(),
105
- (0, class_validator_1.IsNumber)(),
106
- __metadata("design:type", Number)
107
- ], LeadPreferencesUpdateDTO.prototype, "budgetMin", void 0);
108
- __decorate([
109
- (0, class_validator_1.IsOptional)(),
110
- (0, class_validator_1.IsNumber)(),
111
- __metadata("design:type", Number)
112
- ], LeadPreferencesUpdateDTO.prototype, "budgetMax", void 0);
113
- __decorate([
114
- (0, class_validator_1.IsOptional)(),
115
- (0, class_validator_1.IsString)(),
116
- __metadata("design:type", String)
117
- ], LeadPreferencesUpdateDTO.prototype, "preferredMake", void 0);
118
- __decorate([
119
- (0, class_validator_1.IsOptional)(),
120
- (0, class_validator_1.IsString)(),
121
- __metadata("design:type", String)
122
- ], LeadPreferencesUpdateDTO.prototype, "preferredModel", void 0);
123
- __decorate([
124
- (0, class_validator_1.IsOptional)(),
125
- (0, class_validator_1.IsNumber)(),
126
- __metadata("design:type", Number)
127
- ], LeadPreferencesUpdateDTO.prototype, "preferredYearMin", void 0);
128
- __decorate([
129
- (0, class_validator_1.IsOptional)(),
130
- (0, class_validator_1.IsNumber)(),
131
- __metadata("design:type", Number)
132
- ], LeadPreferencesUpdateDTO.prototype, "preferredYearMax", void 0);
133
- __decorate([
134
- (0, class_validator_1.IsOptional)(),
135
- (0, class_validator_1.IsNumber)(),
136
- __metadata("design:type", Number)
137
- ], LeadPreferencesUpdateDTO.prototype, "mileageMin", void 0);
138
- __decorate([
139
- (0, class_validator_1.IsOptional)(),
140
- (0, class_validator_1.IsNumber)(),
141
- __metadata("design:type", Number)
142
- ], LeadPreferencesUpdateDTO.prototype, "mileageMax", void 0);
143
- __decorate([
144
- (0, class_validator_1.IsOptional)(),
145
- (0, class_validator_1.IsArray)(),
146
- (0, class_validator_1.IsString)({ each: true }),
147
- __metadata("design:type", Array)
148
- ], LeadPreferencesUpdateDTO.prototype, "preferredColors", void 0);
149
- __decorate([
150
- (0, class_validator_1.IsOptional)(),
151
- (0, class_validator_1.IsArray)(),
152
- (0, class_validator_1.IsString)({ each: true }),
153
- __metadata("design:type", Array)
154
- ], LeadPreferencesUpdateDTO.prototype, "preferredFeatures", void 0);
155
- __decorate([
156
- (0, class_validator_1.IsOptional)(),
157
- (0, class_validator_1.IsString)(),
158
- __metadata("design:type", String)
159
- ], LeadPreferencesUpdateDTO.prototype, "additionalPreferences", void 0);
160
- exports.LeadPreferencesUpdateDTO = LeadPreferencesUpdateDTO;
161
- class LeadPreferencesCreateDTO {
162
- validate() {
163
- const errors = (0, class_validator_1.validateSync)(this);
164
- return errors.map((error) => { var _a; return Object.values((_a = error.constraints) !== null && _a !== void 0 ? _a : {}); }).flat();
165
- }
166
- static fromPlain(plain) {
167
- return (0, class_transformer_1.plainToClass)(LeadPreferencesCreateDTO, plain);
168
- }
169
- toPlain() {
170
- return (0, class_transformer_1.classToPlain)(this);
171
- }
172
- }
173
- __decorate([
174
- (0, class_validator_1.IsOptional)(),
175
- (0, class_validator_1.IsNumber)(),
176
- __metadata("design:type", Number)
177
- ], LeadPreferencesCreateDTO.prototype, "budgetMin", void 0);
178
- __decorate([
179
- (0, class_validator_1.IsOptional)(),
180
- (0, class_validator_1.IsNumber)(),
181
- __metadata("design:type", Number)
182
- ], LeadPreferencesCreateDTO.prototype, "budgetMax", void 0);
183
- __decorate([
184
- (0, class_validator_1.IsOptional)(),
185
- (0, class_validator_1.IsString)(),
186
- __metadata("design:type", String)
187
- ], LeadPreferencesCreateDTO.prototype, "preferredMake", void 0);
188
- __decorate([
189
- (0, class_validator_1.IsOptional)(),
190
- (0, class_validator_1.IsString)(),
191
- __metadata("design:type", String)
192
- ], LeadPreferencesCreateDTO.prototype, "preferredModel", void 0);
193
- __decorate([
194
- (0, class_validator_1.IsOptional)(),
195
- (0, class_validator_1.IsNumber)(),
196
- __metadata("design:type", Number)
197
- ], LeadPreferencesCreateDTO.prototype, "preferredYearMin", void 0);
198
- __decorate([
199
- (0, class_validator_1.IsOptional)(),
200
- (0, class_validator_1.IsNumber)(),
201
- __metadata("design:type", Number)
202
- ], LeadPreferencesCreateDTO.prototype, "preferredYearMax", void 0);
203
- __decorate([
204
- (0, class_validator_1.IsOptional)(),
205
- (0, class_validator_1.IsNumber)(),
206
- __metadata("design:type", Number)
207
- ], LeadPreferencesCreateDTO.prototype, "mileageMin", void 0);
208
- __decorate([
209
- (0, class_validator_1.IsOptional)(),
210
- (0, class_validator_1.IsNumber)(),
211
- __metadata("design:type", Number)
212
- ], LeadPreferencesCreateDTO.prototype, "mileageMax", void 0);
213
- __decorate([
214
- (0, class_validator_1.IsOptional)(),
215
- (0, class_validator_1.IsArray)(),
216
- (0, class_validator_1.IsString)({ each: true }),
217
- __metadata("design:type", Array)
218
- ], LeadPreferencesCreateDTO.prototype, "preferredColors", void 0);
219
- __decorate([
220
- (0, class_validator_1.IsOptional)(),
221
- (0, class_validator_1.IsArray)(),
222
- (0, class_validator_1.IsString)({ each: true }),
223
- __metadata("design:type", Array)
224
- ], LeadPreferencesCreateDTO.prototype, "preferredFeatures", void 0);
225
- __decorate([
226
- (0, class_validator_1.IsOptional)(),
227
- (0, class_validator_1.IsString)(),
228
- __metadata("design:type", String)
229
- ], LeadPreferencesCreateDTO.prototype, "additionalPreferences", void 0);
230
- exports.LeadPreferencesCreateDTO = LeadPreferencesCreateDTO;
231
- class LeadPreferencesFilter extends global_1.TypedFilter {
232
- }
233
- __decorate([
234
- (0, class_validator_1.IsOptional)(),
235
- (0, class_validator_1.IsString)({ each: true }),
236
- __metadata("design:type", Object)
237
- ], LeadPreferencesFilter.prototype, "id", void 0);
238
- __decorate([
239
- (0, class_validator_1.IsOptional)(),
240
- (0, class_validator_1.ValidateNested)(),
241
- (0, class_transformer_1.Type)(() => core_1.Range),
242
- __metadata("design:type", core_1.Range)
243
- ], LeadPreferencesFilter.prototype, "budgetRange", void 0);
244
- __decorate([
245
- (0, class_validator_1.IsOptional)(),
246
- (0, class_validator_1.IsString)(),
247
- __metadata("design:type", String)
248
- ], LeadPreferencesFilter.prototype, "make", void 0);
249
- __decorate([
250
- (0, class_validator_1.IsOptional)(),
251
- (0, class_validator_1.IsString)(),
252
- __metadata("design:type", String)
253
- ], LeadPreferencesFilter.prototype, "model", void 0);
254
- __decorate([
255
- (0, class_validator_1.IsOptional)(),
256
- (0, class_validator_1.ValidateNested)(),
257
- (0, class_transformer_1.Type)(() => core_1.Range),
258
- __metadata("design:type", core_1.Range)
259
- ], LeadPreferencesFilter.prototype, "yearRange", void 0);
260
- __decorate([
261
- (0, class_validator_1.IsOptional)(),
262
- (0, class_validator_1.ValidateNested)(),
263
- (0, class_transformer_1.Type)(() => core_1.Range),
264
- __metadata("design:type", core_1.Range)
265
- ], LeadPreferencesFilter.prototype, "mileageRange", void 0);
266
- __decorate([
267
- (0, class_validator_1.IsOptional)(),
268
- (0, class_validator_1.IsArray)(),
269
- (0, class_validator_1.IsString)({ each: true }),
270
- __metadata("design:type", Array)
271
- ], LeadPreferencesFilter.prototype, "colors", void 0);
272
- __decorate([
273
- (0, class_validator_1.IsOptional)(),
274
- (0, class_validator_1.IsArray)(),
275
- (0, class_validator_1.IsString)({ each: true }),
276
- __metadata("design:type", Array)
277
- ], LeadPreferencesFilter.prototype, "features", void 0);
278
- __decorate([
279
- (0, class_validator_1.IsOptional)(),
280
- (0, class_validator_1.IsString)(),
281
- __metadata("design:type", String)
282
- ], LeadPreferencesFilter.prototype, "search", void 0);
283
- __decorate([
284
- (0, class_validator_1.IsOptional)(),
285
- (0, class_transformer_1.Type)(() => Date),
286
- __metadata("design:type", Date)
287
- ], LeadPreferencesFilter.prototype, "fromDate", void 0);
288
- __decorate([
289
- (0, class_validator_1.IsOptional)(),
290
- (0, class_transformer_1.Type)(() => Date),
291
- __metadata("design:type", Date)
292
- ], LeadPreferencesFilter.prototype, "toDate", void 0);
293
- exports.LeadPreferencesFilter = LeadPreferencesFilter;
294
- class LeadPreferencesGetDTO extends global_1.BaseGetDTO {
295
- }
296
- __decorate([
297
- (0, class_validator_1.ValidateNested)(),
298
- (0, class_transformer_1.Type)(() => LeadPreferencesFilter),
299
- (0, class_validator_1.IsOptional)(),
300
- __metadata("design:type", LeadPreferencesFilter)
301
- ], LeadPreferencesGetDTO.prototype, "filters", void 0);
302
- __decorate([
303
- (0, class_validator_1.ValidateNested)(),
304
- (0, class_transformer_1.Type)(() => global_1.TypedOptions),
305
- (0, class_validator_1.IsOptional)(),
306
- __metadata("design:type", global_1.TypedOptions)
307
- ], LeadPreferencesGetDTO.prototype, "options", void 0);
308
- exports.LeadPreferencesGetDTO = LeadPreferencesGetDTO;
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./lead_source_status_types"), exports);
18
- __exportStar(require("./lead_status_type"), exports);
@@ -1,19 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LeadSource = void 0;
4
- var LeadSource;
5
- (function (LeadSource) {
6
- LeadSource["WEBSITE"] = "WEBSITE";
7
- LeadSource["TEST_DRIVE_REQUEST"] = "TEST_DRIVE_REQUEST";
8
- LeadSource["SELL_CAR_REQUEST"] = "SELL_CAR_REQUEST";
9
- LeadSource["EXCHANGE_CAR_FORM"] = "EXCHANGE_CAR_FORM";
10
- LeadSource["SHOWROOM_VISIT"] = "SHOWROOM_VISIT";
11
- LeadSource["FINANCE_ELIGIBILITY_REQUEST"] = "FINANCE_ELIGIBILITY_REQUEST";
12
- LeadSource["BANK_VALUATION_REQUEST"] = "BANK_VALUATION_REQUEST";
13
- LeadSource["FREE_VALUATION"] = "FREE_VALUATION";
14
- LeadSource["PHONE"] = "PHONE";
15
- LeadSource["WALK_IN"] = "WALK_IN";
16
- LeadSource["REFERRAL"] = "REFERRAL";
17
- LeadSource["SOCIAL_MEDIA"] = "SOCIAL_MEDIA";
18
- LeadSource["OTHER"] = "OTHER";
19
- })(LeadSource = exports.LeadSource || (exports.LeadSource = {}));
@@ -1,12 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LeadStatus = void 0;
4
- var LeadStatus;
5
- (function (LeadStatus) {
6
- LeadStatus["NEW"] = "NEW";
7
- LeadStatus["CONTACTED"] = "CONTACTED";
8
- LeadStatus["QUALIFIED"] = "QUALIFIED";
9
- LeadStatus["NEGOTIATING"] = "NEGOTIATING";
10
- LeadStatus["CLOSED_WON"] = "CLOSED_WON";
11
- LeadStatus["CLOSED_LOST"] = "CLOSED_LOST";
12
- })(LeadStatus = exports.LeadStatus || (exports.LeadStatus = {}));