@experts_hub/shared 1.0.91 → 1.0.92
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.js +8 -21
- package/dist/index.mjs +8 -21
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -199,17 +199,6 @@ var IfscOrOtherFieldsConstraint = class {
|
|
|
199
199
|
IfscOrOtherFieldsConstraint = __decorateClass([
|
|
200
200
|
(0, import_class_validator4.ValidatorConstraint)({ async: false })
|
|
201
201
|
], IfscOrOtherFieldsConstraint);
|
|
202
|
-
function IfscOrOtherFields(relatedFields, validationOptions) {
|
|
203
|
-
return function(object, propertyName) {
|
|
204
|
-
(0, import_class_validator4.registerDecorator)({
|
|
205
|
-
target: object.constructor,
|
|
206
|
-
propertyName,
|
|
207
|
-
options: validationOptions,
|
|
208
|
-
constraints: [relatedFields],
|
|
209
|
-
validator: IfscOrOtherFieldsConstraint
|
|
210
|
-
});
|
|
211
|
-
};
|
|
212
|
-
}
|
|
213
202
|
|
|
214
203
|
// src/modules/onboarding/dto/freelancer-create-account.dto.ts
|
|
215
204
|
var FreelancerCreateAccountDto = class {
|
|
@@ -1444,22 +1433,20 @@ __decorateClass([
|
|
|
1444
1433
|
(0, import_class_validator24.IsNotEmpty)({ message: "Please enter Branch Name." })
|
|
1445
1434
|
], FreelancerBankDetailsDto.prototype, "branchName", 2);
|
|
1446
1435
|
__decorateClass([
|
|
1447
|
-
(0, import_class_validator24.
|
|
1448
|
-
|
|
1449
|
-
message: "IFSC Code is required ."
|
|
1450
|
-
})
|
|
1436
|
+
(0, import_class_validator24.ValidateIf)((dto) => dto.accountScope === "domestic"),
|
|
1437
|
+
(0, import_class_validator24.IsNotEmpty)({ message: "IFSC Code is required for domestic accounts." })
|
|
1451
1438
|
], FreelancerBankDetailsDto.prototype, "ifscCode", 2);
|
|
1452
1439
|
__decorateClass([
|
|
1453
|
-
(0, import_class_validator24.ValidateIf)((dto) =>
|
|
1454
|
-
(0, import_class_validator24.IsNotEmpty)({ message: "Routing Number/Sort Code is required " })
|
|
1440
|
+
(0, import_class_validator24.ValidateIf)((dto) => dto.accountScope === "international"),
|
|
1441
|
+
(0, import_class_validator24.IsNotEmpty)({ message: "Routing Number/Sort Code is required for international accounts." })
|
|
1455
1442
|
], FreelancerBankDetailsDto.prototype, "routingNo", 2);
|
|
1456
1443
|
__decorateClass([
|
|
1457
|
-
(0, import_class_validator24.ValidateIf)((dto) =>
|
|
1458
|
-
(0, import_class_validator24.IsNotEmpty)({ message: "ABA Number is required " })
|
|
1444
|
+
(0, import_class_validator24.ValidateIf)((dto) => dto.accountScope === "international"),
|
|
1445
|
+
(0, import_class_validator24.IsNotEmpty)({ message: "ABA Number is required for international accounts." })
|
|
1459
1446
|
], FreelancerBankDetailsDto.prototype, "abaNumber", 2);
|
|
1460
1447
|
__decorateClass([
|
|
1461
|
-
(0, import_class_validator24.ValidateIf)((dto) =>
|
|
1462
|
-
(0, import_class_validator24.IsNotEmpty)({ message: "IBAN is required " })
|
|
1448
|
+
(0, import_class_validator24.ValidateIf)((dto) => dto.accountScope === "international"),
|
|
1449
|
+
(0, import_class_validator24.IsNotEmpty)({ message: "IBAN is required for international accounts." })
|
|
1463
1450
|
], FreelancerBankDetailsDto.prototype, "iban", 2);
|
|
1464
1451
|
__decorateClass([
|
|
1465
1452
|
(0, import_class_validator24.IsOptional)()
|
package/dist/index.mjs
CHANGED
|
@@ -126,17 +126,6 @@ var IfscOrOtherFieldsConstraint = class {
|
|
|
126
126
|
IfscOrOtherFieldsConstraint = __decorateClass([
|
|
127
127
|
ValidatorConstraint({ async: false })
|
|
128
128
|
], IfscOrOtherFieldsConstraint);
|
|
129
|
-
function IfscOrOtherFields(relatedFields, validationOptions) {
|
|
130
|
-
return function(object, propertyName) {
|
|
131
|
-
registerDecorator({
|
|
132
|
-
target: object.constructor,
|
|
133
|
-
propertyName,
|
|
134
|
-
options: validationOptions,
|
|
135
|
-
constraints: [relatedFields],
|
|
136
|
-
validator: IfscOrOtherFieldsConstraint
|
|
137
|
-
});
|
|
138
|
-
};
|
|
139
|
-
}
|
|
140
129
|
|
|
141
130
|
// src/modules/onboarding/dto/freelancer-create-account.dto.ts
|
|
142
131
|
var FreelancerCreateAccountDto = class {
|
|
@@ -1486,22 +1475,20 @@ __decorateClass([
|
|
|
1486
1475
|
IsNotEmpty19({ message: "Please enter Branch Name." })
|
|
1487
1476
|
], FreelancerBankDetailsDto.prototype, "branchName", 2);
|
|
1488
1477
|
__decorateClass([
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
message: "IFSC Code is required ."
|
|
1492
|
-
})
|
|
1478
|
+
ValidateIf((dto) => dto.accountScope === "domestic"),
|
|
1479
|
+
IsNotEmpty19({ message: "IFSC Code is required for domestic accounts." })
|
|
1493
1480
|
], FreelancerBankDetailsDto.prototype, "ifscCode", 2);
|
|
1494
1481
|
__decorateClass([
|
|
1495
|
-
ValidateIf((dto) =>
|
|
1496
|
-
IsNotEmpty19({ message: "Routing Number/Sort Code is required " })
|
|
1482
|
+
ValidateIf((dto) => dto.accountScope === "international"),
|
|
1483
|
+
IsNotEmpty19({ message: "Routing Number/Sort Code is required for international accounts." })
|
|
1497
1484
|
], FreelancerBankDetailsDto.prototype, "routingNo", 2);
|
|
1498
1485
|
__decorateClass([
|
|
1499
|
-
ValidateIf((dto) =>
|
|
1500
|
-
IsNotEmpty19({ message: "ABA Number is required " })
|
|
1486
|
+
ValidateIf((dto) => dto.accountScope === "international"),
|
|
1487
|
+
IsNotEmpty19({ message: "ABA Number is required for international accounts." })
|
|
1501
1488
|
], FreelancerBankDetailsDto.prototype, "abaNumber", 2);
|
|
1502
1489
|
__decorateClass([
|
|
1503
|
-
ValidateIf((dto) =>
|
|
1504
|
-
IsNotEmpty19({ message: "IBAN is required " })
|
|
1490
|
+
ValidateIf((dto) => dto.accountScope === "international"),
|
|
1491
|
+
IsNotEmpty19({ message: "IBAN is required for international accounts." })
|
|
1505
1492
|
], FreelancerBankDetailsDto.prototype, "iban", 2);
|
|
1506
1493
|
__decorateClass([
|
|
1507
1494
|
IsOptional8()
|