@experts_hub/shared 1.0.548 → 1.0.554

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/index.d.mts CHANGED
@@ -2842,8 +2842,8 @@ declare class AdminJobBasicInformationV2Dto {
2842
2842
  openings: number;
2843
2843
  location: JobLocationAdminEnumDto;
2844
2844
  typeOfEmployment: EmploymentTypeAdminEnumDto;
2845
- expectedSalaryFrom: number;
2846
- expectedSalaryTo: number;
2845
+ expectedSalaryFrom?: number;
2846
+ expectedSalaryTo?: number;
2847
2847
  locations: JobLocationAdminDto[];
2848
2848
  academicQualification?: string;
2849
2849
  yearsOfExperienceType: typeOfExperienceAdminEnumDto;
package/dist/index.d.ts CHANGED
@@ -2842,8 +2842,8 @@ declare class AdminJobBasicInformationV2Dto {
2842
2842
  openings: number;
2843
2843
  location: JobLocationAdminEnumDto;
2844
2844
  typeOfEmployment: EmploymentTypeAdminEnumDto;
2845
- expectedSalaryFrom: number;
2846
- expectedSalaryTo: number;
2845
+ expectedSalaryFrom?: number;
2846
+ expectedSalaryTo?: number;
2847
2847
  locations: JobLocationAdminDto[];
2848
2848
  academicQualification?: string;
2849
2849
  yearsOfExperienceType: typeOfExperienceAdminEnumDto;
package/dist/index.js CHANGED
@@ -1316,17 +1316,17 @@ __decorateClass([
1316
1316
  })
1317
1317
  ], JobBasicInformationDto.prototype, "location", 2);
1318
1318
  __decorateClass([
1319
- (0, import_class_validator33.ValidateIf)((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1319
+ (0, import_class_validator33.IsOptional)(),
1320
1320
  (0, import_class_validator33.IsNumber)({}, { message: "Country id must be a number" }),
1321
1321
  (0, import_class_transformer2.Type)(() => Number)
1322
1322
  ], JobBasicInformationDto.prototype, "countryId", 2);
1323
1323
  __decorateClass([
1324
- (0, import_class_validator33.ValidateIf)((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1324
+ (0, import_class_validator33.IsOptional)(),
1325
1325
  (0, import_class_validator33.IsNumber)({}, { message: "State id must be a number" }),
1326
1326
  (0, import_class_transformer2.Type)(() => Number)
1327
1327
  ], JobBasicInformationDto.prototype, "stateId", 2);
1328
1328
  __decorateClass([
1329
- (0, import_class_validator33.ValidateIf)((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1329
+ (0, import_class_validator33.IsOptional)(),
1330
1330
  (0, import_class_validator33.IsNumber)({}, { message: "City id must be a number" }),
1331
1331
  (0, import_class_transformer2.Type)(() => Number)
1332
1332
  ], JobBasicInformationDto.prototype, "cityId", 2);
@@ -1488,20 +1488,14 @@ var JobLocationDto = class {
1488
1488
  };
1489
1489
  __decorateClass([
1490
1490
  (0, import_class_validator38.IsOptional)(),
1491
- (0, import_class_validator38.ValidateIf)((o) => o.countryId !== null && o.countryId !== void 0),
1492
- (0, import_class_validator38.IsNumber)({}, { message: "Country id must be a number" }),
1493
1491
  (0, import_class_transformer4.Type)(() => Number)
1494
1492
  ], JobLocationDto.prototype, "countryId", 2);
1495
1493
  __decorateClass([
1496
1494
  (0, import_class_validator38.IsOptional)(),
1497
- (0, import_class_validator38.ValidateIf)((o) => o.stateId !== null && o.stateId !== void 0),
1498
- (0, import_class_validator38.IsNumber)({}, { message: "State id must be a number" }),
1499
1495
  (0, import_class_transformer4.Type)(() => Number)
1500
1496
  ], JobLocationDto.prototype, "stateId", 2);
1501
1497
  __decorateClass([
1502
1498
  (0, import_class_validator38.IsOptional)(),
1503
- (0, import_class_validator38.ValidateIf)((o) => o.cityId !== null && o.cityId !== void 0),
1504
- (0, import_class_validator38.IsNumber)({}, { message: "City id must be a number" }),
1505
1499
  (0, import_class_transformer4.Type)(() => Number)
1506
1500
  ], JobLocationDto.prototype, "cityId", 2);
1507
1501
  var JobBasicInformationV2Dto = class {
@@ -1558,11 +1552,8 @@ __decorateClass([
1558
1552
  })
1559
1553
  ], JobBasicInformationV2Dto.prototype, "locationMode", 2);
1560
1554
  __decorateClass([
1561
- (0, import_class_validator38.ValidateIf)((o) => !o.isDraft && (o.locationMode === "ONSITE" /* ONSITE */ || o.locationMode === "HYBRID" /* HYBRID */)),
1562
- (0, import_class_validator38.IsArray)({ message: "locations must be an array" }),
1563
- (0, import_class_validator38.ValidateNested)({ each: true }),
1564
- (0, import_class_transformer4.Type)(() => JobLocationDto),
1565
- (0, import_class_validator38.IsOptional)()
1555
+ (0, import_class_validator38.IsOptional)(),
1556
+ (0, import_class_transformer4.Type)(() => JobLocationDto)
1566
1557
  ], JobBasicInformationV2Dto.prototype, "locations", 2);
1567
1558
  __decorateClass([
1568
1559
  (0, import_class_validator38.ValidateIf)((o) => !o.isDraft),
@@ -7337,12 +7328,15 @@ __decorateClass([
7337
7328
  (0, import_class_validator62.IsString)({ message: "Additional comment must be a string." })
7338
7329
  ], AdminCreateJobInformationDto.prototype, "additionalComment", 2);
7339
7330
  __decorateClass([
7331
+ (0, import_class_validator62.IsOptional)(),
7340
7332
  (0, import_class_validator62.IsInt)({ message: "Country ID must be a valid integer." })
7341
7333
  ], AdminCreateJobInformationDto.prototype, "countryId", 2);
7342
7334
  __decorateClass([
7335
+ (0, import_class_validator62.IsOptional)(),
7343
7336
  (0, import_class_validator62.IsInt)({ message: "State ID must be a valid integer." })
7344
7337
  ], AdminCreateJobInformationDto.prototype, "stateId", 2);
7345
7338
  __decorateClass([
7339
+ (0, import_class_validator62.IsOptional)(),
7346
7340
  (0, import_class_validator62.IsInt)({ message: "City ID must be a valid integer." })
7347
7341
  ], AdminCreateJobInformationDto.prototype, "cityId", 2);
7348
7342
  __decorateClass([
@@ -7434,12 +7428,15 @@ __decorateClass([
7434
7428
  (0, import_class_validator63.IsString)({ message: "Additional comment must be a string." })
7435
7429
  ], AdminUpdateJobInformationDto.prototype, "additionalComment", 2);
7436
7430
  __decorateClass([
7431
+ (0, import_class_validator63.IsOptional)(),
7437
7432
  (0, import_class_validator63.IsInt)({ message: "Country ID must be a valid integer." })
7438
7433
  ], AdminUpdateJobInformationDto.prototype, "countryId", 2);
7439
7434
  __decorateClass([
7435
+ (0, import_class_validator63.IsOptional)(),
7440
7436
  (0, import_class_validator63.IsInt)({ message: "State ID must be a valid integer." })
7441
7437
  ], AdminUpdateJobInformationDto.prototype, "stateId", 2);
7442
7438
  __decorateClass([
7439
+ (0, import_class_validator63.IsOptional)(),
7443
7440
  (0, import_class_validator63.IsInt)({ message: "City ID must be a valid integer." })
7444
7441
  ], AdminUpdateJobInformationDto.prototype, "cityId", 2);
7445
7442
  __decorateClass([
@@ -7534,24 +7531,20 @@ __decorateClass([
7534
7531
  })
7535
7532
  ], AdminJobBasicInformationV2Dto.prototype, "typeOfEmployment", 2);
7536
7533
  __decorateClass([
7537
- (0, import_class_validator64.ValidateIf)((o) => !o.isDraft),
7534
+ (0, import_class_validator64.IsOptional)(),
7538
7535
  (0, import_class_validator64.IsNumber)({}, { message: "Expected salary (from) must be a number" }),
7539
7536
  (0, import_class_validator64.Min)(0, { message: "Expected salary (from) cannot be negative" }),
7540
7537
  (0, import_class_transformer14.Type)(() => Number)
7541
7538
  ], AdminJobBasicInformationV2Dto.prototype, "expectedSalaryFrom", 2);
7542
7539
  __decorateClass([
7543
- (0, import_class_validator64.ValidateIf)((o) => !o.isDraft),
7540
+ (0, import_class_validator64.IsOptional)(),
7544
7541
  (0, import_class_validator64.IsNumber)({}, { message: "Expected salary (to) must be a number" }),
7545
7542
  (0, import_class_validator64.Min)(0, { message: "Expected salary (to) cannot be negative" }),
7546
7543
  (0, import_class_transformer14.Type)(() => Number)
7547
7544
  ], AdminJobBasicInformationV2Dto.prototype, "expectedSalaryTo", 2);
7548
7545
  __decorateClass([
7549
- (0, import_class_validator64.ValidateIf)((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
7550
- (0, import_class_validator64.IsArray)({ message: "locations must be an array" }),
7551
- (0, import_class_validator64.ArrayNotEmpty)({ message: "Please select at least one location" }),
7552
- (0, import_class_validator64.ValidateNested)({ each: true }),
7553
- (0, import_class_transformer14.Type)(() => JobLocationAdminDto),
7554
- (0, import_class_validator64.IsOptional)()
7546
+ (0, import_class_validator64.IsOptional)(),
7547
+ (0, import_class_transformer14.Type)(() => JobLocationAdminDto)
7555
7548
  ], AdminJobBasicInformationV2Dto.prototype, "locations", 2);
7556
7549
  __decorateClass([
7557
7550
  (0, import_class_validator64.ValidateIf)((o) => !o.isDraft),
package/dist/index.mjs CHANGED
@@ -1073,17 +1073,17 @@ __decorateClass([
1073
1073
  })
1074
1074
  ], JobBasicInformationDto.prototype, "location", 2);
1075
1075
  __decorateClass([
1076
- ValidateIf3((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1076
+ IsOptional12(),
1077
1077
  IsNumber2({}, { message: "Country id must be a number" }),
1078
1078
  Type(() => Number)
1079
1079
  ], JobBasicInformationDto.prototype, "countryId", 2);
1080
1080
  __decorateClass([
1081
- ValidateIf3((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1081
+ IsOptional12(),
1082
1082
  IsNumber2({}, { message: "State id must be a number" }),
1083
1083
  Type(() => Number)
1084
1084
  ], JobBasicInformationDto.prototype, "stateId", 2);
1085
1085
  __decorateClass([
1086
- ValidateIf3((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
1086
+ IsOptional12(),
1087
1087
  IsNumber2({}, { message: "City id must be a number" }),
1088
1088
  Type(() => Number)
1089
1089
  ], JobBasicInformationDto.prototype, "cityId", 2);
@@ -1230,8 +1230,7 @@ import {
1230
1230
  Min as Min2,
1231
1231
  ValidateIf as ValidateIf4,
1232
1232
  MaxLength as MaxLength9,
1233
- Max as Max2,
1234
- ValidateNested
1233
+ Max as Max2
1235
1234
  } from "class-validator";
1236
1235
  import { Type as Type3 } from "class-transformer";
1237
1236
  var JobLocationEnumV2 = /* @__PURE__ */ ((JobLocationEnumV22) => {
@@ -1258,20 +1257,14 @@ var JobLocationDto = class {
1258
1257
  };
1259
1258
  __decorateClass([
1260
1259
  IsOptional15(),
1261
- ValidateIf4((o) => o.countryId !== null && o.countryId !== void 0),
1262
- IsNumber3({}, { message: "Country id must be a number" }),
1263
1260
  Type3(() => Number)
1264
1261
  ], JobLocationDto.prototype, "countryId", 2);
1265
1262
  __decorateClass([
1266
1263
  IsOptional15(),
1267
- ValidateIf4((o) => o.stateId !== null && o.stateId !== void 0),
1268
- IsNumber3({}, { message: "State id must be a number" }),
1269
1264
  Type3(() => Number)
1270
1265
  ], JobLocationDto.prototype, "stateId", 2);
1271
1266
  __decorateClass([
1272
1267
  IsOptional15(),
1273
- ValidateIf4((o) => o.cityId !== null && o.cityId !== void 0),
1274
- IsNumber3({}, { message: "City id must be a number" }),
1275
1268
  Type3(() => Number)
1276
1269
  ], JobLocationDto.prototype, "cityId", 2);
1277
1270
  var JobBasicInformationV2Dto = class {
@@ -1328,11 +1321,8 @@ __decorateClass([
1328
1321
  })
1329
1322
  ], JobBasicInformationV2Dto.prototype, "locationMode", 2);
1330
1323
  __decorateClass([
1331
- ValidateIf4((o) => !o.isDraft && (o.locationMode === "ONSITE" /* ONSITE */ || o.locationMode === "HYBRID" /* HYBRID */)),
1332
- IsArray2({ message: "locations must be an array" }),
1333
- ValidateNested({ each: true }),
1334
- Type3(() => JobLocationDto),
1335
- IsOptional15()
1324
+ IsOptional15(),
1325
+ Type3(() => JobLocationDto)
1336
1326
  ], JobBasicInformationV2Dto.prototype, "locations", 2);
1337
1327
  __decorateClass([
1338
1328
  ValidateIf4((o) => !o.isDraft),
@@ -7432,12 +7422,15 @@ __decorateClass([
7432
7422
  IsString34({ message: "Additional comment must be a string." })
7433
7423
  ], AdminCreateJobInformationDto.prototype, "additionalComment", 2);
7434
7424
  __decorateClass([
7425
+ IsOptional34(),
7435
7426
  IsInt7({ message: "Country ID must be a valid integer." })
7436
7427
  ], AdminCreateJobInformationDto.prototype, "countryId", 2);
7437
7428
  __decorateClass([
7429
+ IsOptional34(),
7438
7430
  IsInt7({ message: "State ID must be a valid integer." })
7439
7431
  ], AdminCreateJobInformationDto.prototype, "stateId", 2);
7440
7432
  __decorateClass([
7433
+ IsOptional34(),
7441
7434
  IsInt7({ message: "City ID must be a valid integer." })
7442
7435
  ], AdminCreateJobInformationDto.prototype, "cityId", 2);
7443
7436
  __decorateClass([
@@ -7540,12 +7533,15 @@ __decorateClass([
7540
7533
  IsString35({ message: "Additional comment must be a string." })
7541
7534
  ], AdminUpdateJobInformationDto.prototype, "additionalComment", 2);
7542
7535
  __decorateClass([
7536
+ IsOptional35(),
7543
7537
  IsInt8({ message: "Country ID must be a valid integer." })
7544
7538
  ], AdminUpdateJobInformationDto.prototype, "countryId", 2);
7545
7539
  __decorateClass([
7540
+ IsOptional35(),
7546
7541
  IsInt8({ message: "State ID must be a valid integer." })
7547
7542
  ], AdminUpdateJobInformationDto.prototype, "stateId", 2);
7548
7543
  __decorateClass([
7544
+ IsOptional35(),
7549
7545
  IsInt8({ message: "City ID must be a valid integer." })
7550
7546
  ], AdminUpdateJobInformationDto.prototype, "cityId", 2);
7551
7547
  __decorateClass([
@@ -7565,7 +7561,6 @@ import {
7565
7561
  ValidateIf as ValidateIf9,
7566
7562
  MaxLength as MaxLength20,
7567
7563
  Max as Max4,
7568
- ValidateNested as ValidateNested6,
7569
7564
  IsInt as IsInt9
7570
7565
  } from "class-validator";
7571
7566
  import { Type as Type12 } from "class-transformer";
@@ -7654,24 +7649,20 @@ __decorateClass([
7654
7649
  })
7655
7650
  ], AdminJobBasicInformationV2Dto.prototype, "typeOfEmployment", 2);
7656
7651
  __decorateClass([
7657
- ValidateIf9((o) => !o.isDraft),
7652
+ IsOptional36(),
7658
7653
  IsNumber9({}, { message: "Expected salary (from) must be a number" }),
7659
7654
  Min8(0, { message: "Expected salary (from) cannot be negative" }),
7660
7655
  Type12(() => Number)
7661
7656
  ], AdminJobBasicInformationV2Dto.prototype, "expectedSalaryFrom", 2);
7662
7657
  __decorateClass([
7663
- ValidateIf9((o) => !o.isDraft),
7658
+ IsOptional36(),
7664
7659
  IsNumber9({}, { message: "Expected salary (to) must be a number" }),
7665
7660
  Min8(0, { message: "Expected salary (to) cannot be negative" }),
7666
7661
  Type12(() => Number)
7667
7662
  ], AdminJobBasicInformationV2Dto.prototype, "expectedSalaryTo", 2);
7668
7663
  __decorateClass([
7669
- ValidateIf9((o) => !o.isDraft && (o.location === "ONSITE" /* ONSITE */ || o.location === "HYBRID" /* HYBRID */)),
7670
- IsArray14({ message: "locations must be an array" }),
7671
- ArrayNotEmpty9({ message: "Please select at least one location" }),
7672
- ValidateNested6({ each: true }),
7673
- Type12(() => JobLocationAdminDto),
7674
- IsOptional36()
7664
+ IsOptional36(),
7665
+ Type12(() => JobLocationAdminDto)
7675
7666
  ], AdminJobBasicInformationV2Dto.prototype, "locations", 2);
7676
7667
  __decorateClass([
7677
7668
  ValidateIf9((o) => !o.isDraft),
@@ -29,8 +29,8 @@ export declare class AdminJobBasicInformationV2Dto {
29
29
  openings: number;
30
30
  location: JobLocationAdminEnumDto;
31
31
  typeOfEmployment: EmploymentTypeAdminEnumDto;
32
- expectedSalaryFrom: number;
33
- expectedSalaryTo: number;
32
+ expectedSalaryFrom?: number;
33
+ expectedSalaryTo?: number;
34
34
  locations: JobLocationAdminDto[];
35
35
  academicQualification?: string;
36
36
  yearsOfExperienceType: typeOfExperienceAdminEnumDto;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@experts_hub/shared",
3
- "version": "1.0.548",
3
+ "version": "1.0.554",
4
4
  "description": "Shared DTOs, interfaces, and utilities for experts hub applications",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/",