@77sol-lab/form-schemas 2.0.0 → 3.0.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.
- package/{chunk-6U3W3WGJ.mjs → chunk-4T4DDJJZ.mjs} +6 -6
- package/{chunk-QGHAWR7N.mjs → chunk-65WB3CQB.mjs} +8 -8
- package/{chunk-AFF2ESHC.mjs → chunk-6AISIJ3O.mjs} +6 -6
- package/{chunk-P5QT636Q.mjs → chunk-7ULQG7YJ.mjs} +8 -8
- package/{chunk-QFCBUDTN.mjs → chunk-7VU2KIBV.mjs} +6 -6
- package/chunk-BXLQYGEB.mjs +105 -0
- package/{chunk-Z6PA77SA.mjs → chunk-CGBX6OCD.mjs} +6 -6
- package/{chunk-DKIUSETH.mjs → chunk-CJSJ3VDW.mjs} +109 -41
- package/{chunk-MKN3T4EC.mjs → chunk-EG5RVHCZ.mjs} +8 -8
- package/{chunk-2JHLFEU7.mjs → chunk-F4RMWUXJ.mjs} +9 -9
- package/{chunk-LXNKU6Q5.mjs → chunk-GBKY6QE3.mjs} +6 -6
- package/{chunk-KIN5ASCQ.mjs → chunk-HF7G6PTH.mjs} +8 -8
- package/{chunk-VGBIJ7LQ.mjs → chunk-HX5UJCA2.mjs} +6 -6
- package/{chunk-DRLPCEVY.mjs → chunk-HXHJSQ2X.mjs} +8 -8
- package/{chunk-ECQBM5TA.mjs → chunk-IVY6IQXZ.mjs} +8 -8
- package/{chunk-TGDPLYN3.mjs → chunk-K3QXEL6M.mjs} +19 -20
- package/{chunk-64RQV46Z.mjs → chunk-LDL7QLPB.mjs} +6 -6
- package/{chunk-DWOFPI2A.mjs → chunk-LRIO6V7H.mjs} +6 -6
- package/{chunk-FGNV6RT5.mjs → chunk-OIGZEDM3.mjs} +6 -6
- package/{chunk-FBL2YW6F.mjs → chunk-OJUTNXHL.mjs} +135 -38
- package/{chunk-E5SPEAZO.mjs → chunk-OKAMQBUN.mjs} +6 -6
- package/{chunk-KOB7CHDM.mjs → chunk-PCTF5JYB.mjs} +8 -8
- package/{chunk-26RFB4ZS.mjs → chunk-PCXYLWDD.mjs} +8 -8
- package/chunk-QEPJ2RLU.mjs +18 -0
- package/{chunk-LCD7MY35.mjs → chunk-QQCSQ3L4.mjs} +9 -9
- package/{chunk-IVT2ZFVR.mjs → chunk-R5TJYTTO.mjs} +8 -8
- package/{chunk-WVQ2LFIN.mjs → chunk-T2FBV7WO.mjs} +9 -9
- package/{chunk-LNPPAYB6.mjs → chunk-TNZ33455.mjs} +6 -6
- package/{chunk-J4BYCQDX.mjs → chunk-TWOBBIQC.mjs} +8 -8
- package/{chunk-NQIIQVGK.mjs → chunk-TZEPVIC4.mjs} +8 -8
- package/{chunk-QSMMXRNI.mjs → chunk-UK62IINL.mjs} +6 -6
- package/{chunk-6EBUH4MK.mjs → chunk-VTTNXB64.mjs} +6 -6
- package/{chunk-DQ6ZS36G.mjs → chunk-VWKF4I2L.mjs} +8 -8
- package/financing/formalization/index.d.cts +710 -708
- package/financing/formalization/index.d.ts +710 -708
- package/financing/formalization/index.js +454 -226
- package/financing/formalization/index.mjs +33 -33
- package/financing/formalization/schemas/AlfaPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/AlfaPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/AlfaPFSchema.js +94 -27
- package/financing/formalization/schemas/AlfaPFSchema.mjs +3 -3
- package/financing/formalization/schemas/AlfaPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/AlfaPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/AlfaPJSchema.js +97 -29
- package/financing/formalization/schemas/AlfaPJSchema.mjs +2 -2
- package/financing/formalization/schemas/BancoDoBrasilPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/BancoDoBrasilPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/BancoDoBrasilPFSchema.js +94 -27
- package/financing/formalization/schemas/BancoDoBrasilPFSchema.mjs +3 -3
- package/financing/formalization/schemas/BancoDoBrasilPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/BancoDoBrasilPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/BancoDoBrasilPJSchema.js +97 -29
- package/financing/formalization/schemas/BancoDoBrasilPJSchema.mjs +2 -2
- package/financing/formalization/schemas/BtgPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/BtgPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/BtgPFSchema.js +94 -27
- package/financing/formalization/schemas/BtgPFSchema.mjs +3 -3
- package/financing/formalization/schemas/BtgPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/BtgPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/BtgPJSchema.js +102 -30
- package/financing/formalization/schemas/BtgPJSchema.mjs +3 -3
- package/financing/formalization/schemas/BvPFSchema.d.cts +20 -20
- package/financing/formalization/schemas/BvPFSchema.d.ts +20 -20
- package/financing/formalization/schemas/BvPFSchema.js +96 -29
- package/financing/formalization/schemas/BvPFSchema.mjs +3 -3
- package/financing/formalization/schemas/BvPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/BvPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/BvPJSchema.js +102 -30
- package/financing/formalization/schemas/BvPJSchema.mjs +3 -3
- package/financing/formalization/schemas/CaixaEconomicaFederalPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/CaixaEconomicaFederalPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/CaixaEconomicaFederalPFSchema.js +94 -27
- package/financing/formalization/schemas/CaixaEconomicaFederalPFSchema.mjs +3 -3
- package/financing/formalization/schemas/CaixaEconomicaFederalPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/CaixaEconomicaFederalPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/CaixaEconomicaFederalPJSchema.js +97 -29
- package/financing/formalization/schemas/CaixaEconomicaFederalPJSchema.mjs +2 -2
- package/financing/formalization/schemas/CashMePFSchema.d.cts +16 -16
- package/financing/formalization/schemas/CashMePFSchema.d.ts +16 -16
- package/financing/formalization/schemas/CashMePFSchema.js +94 -27
- package/financing/formalization/schemas/CashMePFSchema.mjs +3 -3
- package/financing/formalization/schemas/CashMePJSchema.d.cts +16 -16
- package/financing/formalization/schemas/CashMePJSchema.d.ts +16 -16
- package/financing/formalization/schemas/CashMePJSchema.js +97 -29
- package/financing/formalization/schemas/CashMePJSchema.mjs +2 -2
- package/financing/formalization/schemas/Credito77PFSchema.d.cts +16 -16
- package/financing/formalization/schemas/Credito77PFSchema.d.ts +16 -16
- package/financing/formalization/schemas/Credito77PFSchema.js +94 -27
- package/financing/formalization/schemas/Credito77PFSchema.mjs +3 -3
- package/financing/formalization/schemas/Credito77PJSchema.d.cts +16 -16
- package/financing/formalization/schemas/Credito77PJSchema.d.ts +16 -16
- package/financing/formalization/schemas/Credito77PJSchema.js +97 -29
- package/financing/formalization/schemas/Credito77PJSchema.mjs +2 -2
- package/financing/formalization/schemas/EosPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/EosPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/EosPFSchema.js +94 -27
- package/financing/formalization/schemas/EosPFSchema.mjs +3 -3
- package/financing/formalization/schemas/EosPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/EosPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/EosPJSchema.js +97 -29
- package/financing/formalization/schemas/EosPJSchema.mjs +2 -2
- package/financing/formalization/schemas/HdtEnergyPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/HdtEnergyPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/HdtEnergyPFSchema.js +94 -27
- package/financing/formalization/schemas/HdtEnergyPFSchema.mjs +3 -3
- package/financing/formalization/schemas/HdtEnergyPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/HdtEnergyPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/HdtEnergyPJSchema.js +97 -29
- package/financing/formalization/schemas/HdtEnergyPJSchema.mjs +2 -2
- package/financing/formalization/schemas/LosangoPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/LosangoPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/LosangoPFSchema.js +94 -27
- package/financing/formalization/schemas/LosangoPFSchema.mjs +3 -3
- package/financing/formalization/schemas/LosangoPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/LosangoPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/LosangoPJSchema.js +97 -29
- package/financing/formalization/schemas/LosangoPJSchema.mjs +2 -2
- package/financing/formalization/schemas/SafraPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/SafraPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/SafraPFSchema.js +94 -27
- package/financing/formalization/schemas/SafraPFSchema.mjs +3 -3
- package/financing/formalization/schemas/SafraPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/SafraPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/SafraPJSchema.js +97 -29
- package/financing/formalization/schemas/SafraPJSchema.mjs +2 -2
- package/financing/formalization/schemas/SantanderPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/SantanderPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/SantanderPFSchema.js +94 -27
- package/financing/formalization/schemas/SantanderPFSchema.mjs +3 -3
- package/financing/formalization/schemas/SantanderPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/SantanderPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/SantanderPJSchema.js +97 -29
- package/financing/formalization/schemas/SantanderPJSchema.mjs +2 -2
- package/financing/formalization/schemas/SolAgoraPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/SolAgoraPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/SolAgoraPFSchema.js +94 -27
- package/financing/formalization/schemas/SolAgoraPFSchema.mjs +3 -3
- package/financing/formalization/schemas/SolAgoraPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/SolAgoraPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/SolAgoraPJSchema.js +102 -30
- package/financing/formalization/schemas/SolAgoraPJSchema.mjs +3 -3
- package/financing/formalization/schemas/SolfacilPFSchema.d.cts +16 -16
- package/financing/formalization/schemas/SolfacilPFSchema.d.ts +16 -16
- package/financing/formalization/schemas/SolfacilPFSchema.js +94 -27
- package/financing/formalization/schemas/SolfacilPFSchema.mjs +3 -3
- package/financing/formalization/schemas/SolfacilPJSchema.d.cts +16 -16
- package/financing/formalization/schemas/SolfacilPJSchema.d.ts +16 -16
- package/financing/formalization/schemas/SolfacilPJSchema.js +97 -29
- package/financing/formalization/schemas/SolfacilPJSchema.mjs +2 -2
- package/financing/formalization/schemas/UnifiedPFSchema.d.cts +48 -48
- package/financing/formalization/schemas/UnifiedPFSchema.d.ts +48 -48
- package/financing/formalization/schemas/UnifiedPFSchema.js +108 -41
- package/financing/formalization/schemas/UnifiedPFSchema.mjs +3 -3
- package/financing/formalization/schemas/UnifiedPJSchema.d.cts +118 -118
- package/financing/formalization/schemas/UnifiedPJSchema.d.ts +118 -118
- package/financing/formalization/schemas/UnifiedPJSchema.js +147 -75
- package/financing/formalization/schemas/UnifiedPJSchema.mjs +3 -3
- package/index.js +454 -226
- package/index.mjs +33 -33
- package/package.json +1 -1
- package/chunk-ARSY3NB7.mjs +0 -13
- package/chunk-QZ2BTLCH.mjs +0 -105
|
@@ -2,15 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
var zod = require('zod');
|
|
4
4
|
|
|
5
|
-
// src/
|
|
5
|
+
// src/shared/fields/primitives.ts
|
|
6
6
|
var REQUIRED_MESSAGE = "Campo obrigat\xF3rio";
|
|
7
|
-
var REQUIRED_STRING_PARAMS = { error: REQUIRED_MESSAGE };
|
|
8
7
|
function requiredString() {
|
|
9
|
-
return zod.z.string(
|
|
8
|
+
return zod.z.string({ error: REQUIRED_MESSAGE });
|
|
10
9
|
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
return
|
|
10
|
+
var DEFAULT_TEXT_MAX_LENGTH = 255;
|
|
11
|
+
function textField(maxLength = DEFAULT_TEXT_MAX_LENGTH) {
|
|
12
|
+
return requiredString().trim().min(1, REQUIRED_MESSAGE).max(maxLength, `M\xE1ximo ${maxLength} caracteres`);
|
|
14
13
|
}
|
|
15
14
|
function requiredNumber(invalidTypeMessage) {
|
|
16
15
|
return zod.z.number({
|
|
@@ -21,6 +20,29 @@ var numberField = requiredNumber("Valor num\xE9rico inv\xE1lido").nonnegative(
|
|
|
21
20
|
"Valor n\xE3o pode ser negativo"
|
|
22
21
|
);
|
|
23
22
|
var integerField = requiredNumber("Valor num\xE9rico inv\xE1lido").int("Deve ser um n\xFAmero inteiro").nonnegative("Valor n\xE3o pode ser negativo");
|
|
23
|
+
function optionalField(schema) {
|
|
24
|
+
return zod.z.preprocess(
|
|
25
|
+
(value) => typeof value === "string" && value.trim() === "" ? void 0 : value,
|
|
26
|
+
schema.optional()
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
function unrecognizedKeysMessage(keys) {
|
|
30
|
+
const list = keys.map((key) => `"${key}"`).join(", ");
|
|
31
|
+
return keys.length === 1 ? `Campo n\xE3o reconhecido: ${list}` : `Campos n\xE3o reconhecidos: ${list}`;
|
|
32
|
+
}
|
|
33
|
+
function requiredObject(shape) {
|
|
34
|
+
return zod.z.object(shape, {
|
|
35
|
+
error: (issue) => {
|
|
36
|
+
if (issue.code === "invalid_type") {
|
|
37
|
+
return REQUIRED_MESSAGE;
|
|
38
|
+
}
|
|
39
|
+
if (issue.code === "unrecognized_keys") {
|
|
40
|
+
return unrecognizedKeysMessage(issue.keys);
|
|
41
|
+
}
|
|
42
|
+
return void 0;
|
|
43
|
+
}
|
|
44
|
+
});
|
|
45
|
+
}
|
|
24
46
|
function enumField(values) {
|
|
25
47
|
return zod.z.enum(values, {
|
|
26
48
|
// No zod 4 todo input fora da lista (inclusive undefined/null) gera um único
|
|
@@ -32,14 +54,19 @@ function enumField(values) {
|
|
|
32
54
|
}
|
|
33
55
|
var MAX_UPLOAD_BYTES = 5 * 1024 * 1024;
|
|
34
56
|
var ACCEPTED_UPLOAD_MIME = ["image/jpeg", "image/png", "application/pdf"];
|
|
35
|
-
var
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
57
|
+
var UPLOAD_URL_PROTOCOL = /^https$/;
|
|
58
|
+
var UPLOAD_URL_HOSTNAME = /^(?!localhost$)(?!(\d{1,3}\.){3}\d{1,3}$)[a-z0-9.-]+$/i;
|
|
59
|
+
var fileUploadField = requiredObject({
|
|
60
|
+
url: optionalField(
|
|
61
|
+
zod.z.url({
|
|
62
|
+
protocol: UPLOAD_URL_PROTOCOL,
|
|
63
|
+
hostname: UPLOAD_URL_HOSTNAME,
|
|
64
|
+
error: "URL do arquivo inv\xE1lida"
|
|
65
|
+
})
|
|
66
|
+
),
|
|
67
|
+
mime: zod.z.enum(ACCEPTED_UPLOAD_MIME, { error: "Formato deve ser JPEG, PNG ou PDF" }),
|
|
68
|
+
sizeBytes: requiredNumber("Tamanho do arquivo inv\xE1lido").int("Tamanho do arquivo deve ser um n\xFAmero inteiro").positive("Tamanho do arquivo deve ser positivo").max(MAX_UPLOAD_BYTES, "Arquivo deve ter no m\xE1ximo 5MB")
|
|
69
|
+
});
|
|
43
70
|
|
|
44
71
|
// src/shared/enums/nature-of-occupation-type.ts
|
|
45
72
|
var NatureOfOccupationTypeEnum = enumField(["autonomo", "clt", "aposentado", "empresario"]);
|
|
@@ -77,7 +104,11 @@ var CommunionRegimeEnum = enumField([
|
|
|
77
104
|
// src/shared/enums/document-type.ts
|
|
78
105
|
var DocumentTypeEnum = enumField([
|
|
79
106
|
"documento_de_identidade",
|
|
80
|
-
"carteira_nacional_de_habilita\xE7\xE3o"
|
|
107
|
+
"carteira_nacional_de_habilita\xE7\xE3o",
|
|
108
|
+
// Exigido pela RN-015 para nacionalidade estrangeira. Sem este membro a
|
|
109
|
+
// regra seria insatisfazível: todo schema é .strict() com type_doc
|
|
110
|
+
// restrito a este enum.
|
|
111
|
+
"registro_de_estrangeiro"
|
|
81
112
|
]);
|
|
82
113
|
|
|
83
114
|
// src/shared/enums/nationality.ts
|
|
@@ -151,7 +182,10 @@ var PATTERNS = {
|
|
|
151
182
|
cep: /^\d{8}$/,
|
|
152
183
|
phoneBR: /^\d{11}$/,
|
|
153
184
|
email: /^[^\s@]+@[^\s@]+\.[^\s@]+$/,
|
|
154
|
-
dateDMY: /^\d{2}\/\d{2}\/\d{4}
|
|
185
|
+
dateDMY: /^\d{2}\/\d{2}\/\d{4}$/,
|
|
186
|
+
// Formato do RNE, exigido pela RN-015 para nacionalidade estrangeira.
|
|
187
|
+
rneNumber: /^[A-Za-z0-9]+$/
|
|
188
|
+
};
|
|
155
189
|
|
|
156
190
|
// src/shared/regex/validators.ts
|
|
157
191
|
function onlyDigits(value) {
|
|
@@ -268,22 +302,22 @@ function parseBRLCurrency(value) {
|
|
|
268
302
|
if (typeof value !== "string") {
|
|
269
303
|
return value;
|
|
270
304
|
}
|
|
271
|
-
const
|
|
272
|
-
if (
|
|
305
|
+
const normalized = value.replace(/R\$/gi, "").replace(/\s/g, "").replace(/\./g, "").replace(",", ".");
|
|
306
|
+
if (normalized === "") {
|
|
273
307
|
return void 0;
|
|
274
308
|
}
|
|
275
|
-
const normalized = trimmed.replace(/R\$/gi, "").replace(/\s/g, "").replace(/\./g, "").replace(",", ".");
|
|
276
309
|
const parsed = Number(normalized);
|
|
277
310
|
return Number.isNaN(parsed) ? value : parsed;
|
|
278
311
|
}
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
);
|
|
312
|
+
function brlAmount() {
|
|
313
|
+
return requiredNumber("Valor monet\xE1rio inv\xE1lido").positive("Valor deve ser positivo");
|
|
314
|
+
}
|
|
315
|
+
var currencySchema = zod.z.preprocess(parseBRLCurrency, brlAmount());
|
|
316
|
+
var optionalCurrencySchema = zod.z.preprocess(parseBRLCurrency, brlAmount().optional());
|
|
283
317
|
requiredNumber("Valor num\xE9rico inv\xE1lido").int("Deve ser um n\xFAmero inteiro").min(1, "M\xEDnimo 1").max(28, "M\xE1ximo 28");
|
|
284
318
|
var formalizationExtras = {
|
|
285
319
|
voucher_local_installation_address: fileUploadField,
|
|
286
|
-
proof_kinship_type: ProofKinshipTypeEnum
|
|
320
|
+
proof_kinship_type: optionalField(ProofKinshipTypeEnum),
|
|
287
321
|
proof_kinship: fileUploadField.optional(),
|
|
288
322
|
document_front_upload: fileUploadField,
|
|
289
323
|
document_back_upload: fileUploadField,
|
|
@@ -345,7 +379,36 @@ function applyCommonRefinements(data, ctx) {
|
|
|
345
379
|
});
|
|
346
380
|
}
|
|
347
381
|
}
|
|
382
|
+
var FOREIGN_DOCUMENT_TYPE = "registro_de_estrangeiro";
|
|
383
|
+
function applyForeignDocumentRefinement(data, ctx) {
|
|
384
|
+
const nationality = data.nationality;
|
|
385
|
+
const isForeign = typeof nationality === "string" && nationality.toLowerCase() !== NATIONALITY_BRAZIL;
|
|
386
|
+
if (!isForeign || !("type_doc" in data)) {
|
|
387
|
+
return;
|
|
388
|
+
}
|
|
389
|
+
if (data.type_doc !== FOREIGN_DOCUMENT_TYPE) {
|
|
390
|
+
ctx.addIssue({
|
|
391
|
+
code: "custom",
|
|
392
|
+
path: ["type_doc"],
|
|
393
|
+
message: "Para nacionalidade estrangeira, o documento deve ser Registro de Estrangeiro (RNE)"
|
|
394
|
+
});
|
|
395
|
+
return;
|
|
396
|
+
}
|
|
397
|
+
if (typeof data.doc === "string" && !PATTERNS.rneNumber.test(data.doc)) {
|
|
398
|
+
ctx.addIssue({
|
|
399
|
+
code: "custom",
|
|
400
|
+
path: ["doc"],
|
|
401
|
+
message: "RNE deve conter apenas letras e n\xFAmeros"
|
|
402
|
+
});
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
function isRecord(data) {
|
|
406
|
+
return typeof data === "object" && data !== null;
|
|
407
|
+
}
|
|
348
408
|
function applyPfRefinements(data, ctx) {
|
|
409
|
+
if (!isRecord(data)) {
|
|
410
|
+
return;
|
|
411
|
+
}
|
|
349
412
|
applyCommonRefinements(data, ctx);
|
|
350
413
|
applyPartnerRefinement(data, ctx);
|
|
351
414
|
if ("nature_of_occupation" in data && typeof data.nature_of_occupation === "string" && OCCUPATIONS_REQUIRING_CNPJ.includes(data.nature_of_occupation) && !data.cnpj_proprietary) {
|
|
@@ -365,8 +428,12 @@ function applyPfRefinements(data, ctx) {
|
|
|
365
428
|
});
|
|
366
429
|
}
|
|
367
430
|
}
|
|
431
|
+
applyForeignDocumentRefinement(data, ctx);
|
|
368
432
|
}
|
|
369
433
|
function applyPjRefinements(data, ctx) {
|
|
434
|
+
if (!isRecord(data)) {
|
|
435
|
+
return;
|
|
436
|
+
}
|
|
370
437
|
applyCommonRefinements(data, ctx);
|
|
371
438
|
}
|
|
372
439
|
function onlyUnknownKeysAborted(payload) {
|
|
@@ -380,7 +447,7 @@ zod.z.superRefine(applyPjRefinements, {
|
|
|
380
447
|
});
|
|
381
448
|
|
|
382
449
|
// src/domains/financing/formalization/schemas/UnifiedPFSchema.ts
|
|
383
|
-
var unifiedPfObject =
|
|
450
|
+
var unifiedPfObject = requiredObject({
|
|
384
451
|
name: textField(),
|
|
385
452
|
cep: cepSchema,
|
|
386
453
|
cpf: cpfSchema,
|
|
@@ -388,12 +455,12 @@ var unifiedPfObject = zod.z.object({
|
|
|
388
455
|
birth_date: birthDateSchema,
|
|
389
456
|
number: textField(),
|
|
390
457
|
sex: SexEnum,
|
|
391
|
-
complement: textField(15)
|
|
458
|
+
complement: optionalField(textField(15)),
|
|
392
459
|
mother_name: textField(),
|
|
393
460
|
district: textField(),
|
|
394
461
|
energy_account_in_requester_name: YesOrNoEnum,
|
|
395
462
|
city: textField(),
|
|
396
|
-
energy_bill_owner_document: cpfCnpjSchema
|
|
463
|
+
energy_bill_owner_document: optionalField(cpfCnpjSchema),
|
|
397
464
|
state: UfEnum,
|
|
398
465
|
nationality: NationalityEnum.default(NATIONALITY_BRAZIL),
|
|
399
466
|
cellphone: phoneBRSchema,
|
|
@@ -405,25 +472,25 @@ var unifiedPfObject = zod.z.object({
|
|
|
405
472
|
issuing_body: textField(6),
|
|
406
473
|
doc_issue_date: issueDateSchema,
|
|
407
474
|
residence_situation: ResidenceTypeEnum,
|
|
408
|
-
months_in_residence: integerField
|
|
475
|
+
months_in_residence: optionalField(integerField),
|
|
409
476
|
civil_status: CivilStatusEnum,
|
|
410
477
|
uf_naturalness: UfEnum,
|
|
411
|
-
naturalness: textField()
|
|
478
|
+
naturalness: optionalField(textField()),
|
|
412
479
|
nature_of_occupation: NatureOfOccupationTypeEnum,
|
|
413
|
-
company_time: numberField
|
|
414
|
-
cnpj_proprietary: cnpjSchema
|
|
415
|
-
equity_value:
|
|
480
|
+
company_time: optionalField(numberField),
|
|
481
|
+
cnpj_proprietary: optionalField(cnpjSchema),
|
|
482
|
+
equity_value: optionalCurrencySchema,
|
|
416
483
|
emitting_state: UfEnum,
|
|
417
484
|
pep_relationship: YesOrNoEnum,
|
|
418
|
-
social_name: textField()
|
|
419
|
-
partner_name: textField()
|
|
420
|
-
partner_birth: dateDMYSchema
|
|
421
|
-
partner_type_doc: DocumentTypeEnum
|
|
422
|
-
partner_doc: textField()
|
|
423
|
-
partner_cpf: cpfSchema
|
|
424
|
-
partner_city: textField()
|
|
425
|
-
communion_regime: CommunionRegimeEnum
|
|
426
|
-
rural_area: textField(3)
|
|
485
|
+
social_name: optionalField(textField()),
|
|
486
|
+
partner_name: optionalField(textField()),
|
|
487
|
+
partner_birth: optionalField(dateDMYSchema),
|
|
488
|
+
partner_type_doc: optionalField(DocumentTypeEnum),
|
|
489
|
+
partner_doc: optionalField(textField()),
|
|
490
|
+
partner_cpf: optionalField(cpfSchema),
|
|
491
|
+
partner_city: optionalField(textField()),
|
|
492
|
+
communion_regime: optionalField(CommunionRegimeEnum),
|
|
493
|
+
rural_area: optionalField(textField(3)),
|
|
427
494
|
...formalizationExtras
|
|
428
495
|
});
|
|
429
496
|
var unifiedPfSchema = unifiedPfObject.strict().check(pfRefinement);
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { unifiedPfObject, unifiedPfSchema } from '../../../chunk-
|
|
2
|
-
import '../../../chunk-
|
|
3
|
-
import '../../../chunk-
|
|
1
|
+
export { unifiedPfObject, unifiedPfSchema } from '../../../chunk-K3QXEL6M.mjs';
|
|
2
|
+
import '../../../chunk-QEPJ2RLU.mjs';
|
|
3
|
+
import '../../../chunk-CJSJ3VDW.mjs';
|
|
@@ -8,7 +8,7 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
8
8
|
address: z.ZodString;
|
|
9
9
|
number: z.ZodString;
|
|
10
10
|
email: z.ZodString;
|
|
11
|
-
complement: z.ZodOptional<z.ZodString
|
|
11
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
12
12
|
phone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
13
13
|
district: z.ZodString;
|
|
14
14
|
legal_nature: z.ZodString;
|
|
@@ -17,12 +17,12 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
17
17
|
[x: string]: string;
|
|
18
18
|
}>;
|
|
19
19
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
20
|
-
economic_activity: z.ZodOptional<z.ZodString
|
|
21
|
-
economic_activity_group: z.ZodOptional<z.ZodString
|
|
22
|
-
monthly_income: z.
|
|
23
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
24
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
25
|
-
capital_social: z.
|
|
20
|
+
economic_activity: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
21
|
+
economic_activity_group: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
22
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
23
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
24
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
25
|
+
capital_social: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
26
26
|
}, z.core.$strict>;
|
|
27
27
|
financing_company_guarantor: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
28
28
|
name: z.ZodString;
|
|
@@ -31,7 +31,7 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
31
31
|
address: z.ZodString;
|
|
32
32
|
number: z.ZodString;
|
|
33
33
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
34
|
-
complement: z.ZodOptional<z.ZodString
|
|
34
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
35
35
|
cellphone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
36
36
|
email: z.ZodString;
|
|
37
37
|
district: z.ZodString;
|
|
@@ -46,32 +46,32 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
46
46
|
nationality: z.ZodDefault<z.ZodEnum<{
|
|
47
47
|
[x: string]: string;
|
|
48
48
|
}>>;
|
|
49
|
-
office: z.ZodOptional<z.ZodString
|
|
50
|
-
phone: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string
|
|
51
|
-
civil_status: z.ZodOptional<z.ZodString
|
|
52
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
53
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
54
|
-
type_doc: z.ZodOptional<z.ZodEnum<{
|
|
49
|
+
office: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
50
|
+
phone: z.ZodPreprocess<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
51
|
+
civil_status: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
52
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
53
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
54
|
+
type_doc: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
55
55
|
[x: string]: string;
|
|
56
|
-
}
|
|
57
|
-
doc: z.ZodOptional<z.ZodString
|
|
58
|
-
issuing_body: z.ZodOptional<z.ZodString
|
|
59
|
-
uf_issuing_body: z.ZodOptional<z.ZodEnum<{
|
|
56
|
+
}>>>;
|
|
57
|
+
doc: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
58
|
+
issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
59
|
+
uf_issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
60
60
|
[x: string]: string;
|
|
61
|
-
}
|
|
62
|
-
doc_issue_date: z.ZodOptional<z.ZodString
|
|
63
|
-
doc_expiration_date: z.ZodOptional<z.ZodString
|
|
64
|
-
monthly_income: z.
|
|
65
|
-
patrimony: z.
|
|
66
|
-
naturalness: z.ZodOptional<z.ZodString
|
|
67
|
-
uf_naturalness: z.ZodOptional<z.ZodEnum<{
|
|
61
|
+
}>>>;
|
|
62
|
+
doc_issue_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
63
|
+
doc_expiration_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
64
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
65
|
+
patrimony: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
66
|
+
naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
67
|
+
uf_naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
68
68
|
[x: string]: string;
|
|
69
|
-
}
|
|
70
|
-
pep_relationship: z.ZodOptional<z.ZodString
|
|
71
|
-
entry_date: z.ZodOptional<z.ZodString
|
|
72
|
-
doc_issuance_uf: z.ZodOptional<z.ZodEnum<{
|
|
69
|
+
}>>>;
|
|
70
|
+
pep_relationship: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
71
|
+
entry_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
72
|
+
doc_issuance_uf: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
73
73
|
[x: string]: string;
|
|
74
|
-
}
|
|
74
|
+
}>>>;
|
|
75
75
|
}, z.core.$strict>>>;
|
|
76
76
|
financing_company_qsa: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
77
77
|
name: z.ZodString;
|
|
@@ -80,7 +80,7 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
80
80
|
address: z.ZodString;
|
|
81
81
|
number: z.ZodString;
|
|
82
82
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
83
|
-
complement: z.ZodOptional<z.ZodString
|
|
83
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
84
84
|
cellphone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
85
85
|
email: z.ZodString;
|
|
86
86
|
district: z.ZodString;
|
|
@@ -95,35 +95,35 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
95
95
|
nationality: z.ZodDefault<z.ZodEnum<{
|
|
96
96
|
[x: string]: string;
|
|
97
97
|
}>>;
|
|
98
|
-
office: z.ZodOptional<z.ZodString
|
|
99
|
-
phone: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string
|
|
100
|
-
civil_status: z.ZodOptional<z.ZodString
|
|
101
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
102
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
103
|
-
type_doc: z.ZodOptional<z.ZodEnum<{
|
|
98
|
+
office: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
99
|
+
phone: z.ZodPreprocess<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
100
|
+
civil_status: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
101
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
102
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
103
|
+
type_doc: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
104
104
|
[x: string]: string;
|
|
105
|
-
}
|
|
106
|
-
doc: z.ZodOptional<z.ZodString
|
|
107
|
-
issuing_body: z.ZodOptional<z.ZodString
|
|
108
|
-
uf_issuing_body: z.ZodOptional<z.ZodEnum<{
|
|
105
|
+
}>>>;
|
|
106
|
+
doc: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
107
|
+
issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
108
|
+
uf_issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
109
109
|
[x: string]: string;
|
|
110
|
-
}
|
|
111
|
-
doc_issue_date: z.ZodOptional<z.ZodString
|
|
112
|
-
doc_expiration_date: z.ZodOptional<z.ZodString
|
|
113
|
-
monthly_income: z.
|
|
114
|
-
patrimony: z.
|
|
115
|
-
naturalness: z.ZodOptional<z.ZodString
|
|
116
|
-
uf_naturalness: z.ZodOptional<z.ZodEnum<{
|
|
110
|
+
}>>>;
|
|
111
|
+
doc_issue_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
112
|
+
doc_expiration_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
113
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
114
|
+
patrimony: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
115
|
+
naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
116
|
+
uf_naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
117
117
|
[x: string]: string;
|
|
118
|
-
}
|
|
119
|
-
pep_relationship: z.ZodOptional<z.ZodString
|
|
120
|
-
entry_date: z.ZodOptional<z.ZodString
|
|
121
|
-
doc_issuance_uf: z.ZodOptional<z.ZodEnum<{
|
|
118
|
+
}>>>;
|
|
119
|
+
pep_relationship: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
120
|
+
entry_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
121
|
+
doc_issuance_uf: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
122
122
|
[x: string]: string;
|
|
123
|
-
}
|
|
123
|
+
}>>>;
|
|
124
124
|
}, z.core.$strict>>>;
|
|
125
125
|
voucher_local_installation_address: z.ZodObject<{
|
|
126
|
-
url: z.ZodOptional<z.ZodURL
|
|
126
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
127
127
|
mime: z.ZodEnum<{
|
|
128
128
|
"image/jpeg": "image/jpeg";
|
|
129
129
|
"image/png": "image/png";
|
|
@@ -131,11 +131,11 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
131
131
|
}>;
|
|
132
132
|
sizeBytes: z.ZodNumber;
|
|
133
133
|
}, z.core.$strip>;
|
|
134
|
-
proof_kinship_type: z.ZodOptional<z.ZodEnum<{
|
|
134
|
+
proof_kinship_type: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
135
135
|
[x: string]: string;
|
|
136
|
-
}
|
|
136
|
+
}>>>;
|
|
137
137
|
proof_kinship: z.ZodOptional<z.ZodObject<{
|
|
138
|
-
url: z.ZodOptional<z.ZodURL
|
|
138
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
139
139
|
mime: z.ZodEnum<{
|
|
140
140
|
"image/jpeg": "image/jpeg";
|
|
141
141
|
"image/png": "image/png";
|
|
@@ -144,7 +144,7 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
144
144
|
sizeBytes: z.ZodNumber;
|
|
145
145
|
}, z.core.$strip>>;
|
|
146
146
|
document_front_upload: z.ZodObject<{
|
|
147
|
-
url: z.ZodOptional<z.ZodURL
|
|
147
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
148
148
|
mime: z.ZodEnum<{
|
|
149
149
|
"image/jpeg": "image/jpeg";
|
|
150
150
|
"image/png": "image/png";
|
|
@@ -153,7 +153,7 @@ declare const unifiedPjObject: z.ZodObject<{
|
|
|
153
153
|
sizeBytes: z.ZodNumber;
|
|
154
154
|
}, z.core.$strip>;
|
|
155
155
|
document_back_upload: z.ZodObject<{
|
|
156
|
-
url: z.ZodOptional<z.ZodURL
|
|
156
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
157
157
|
mime: z.ZodEnum<{
|
|
158
158
|
"image/jpeg": "image/jpeg";
|
|
159
159
|
"image/png": "image/png";
|
|
@@ -171,7 +171,7 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
171
171
|
address: z.ZodString;
|
|
172
172
|
number: z.ZodString;
|
|
173
173
|
email: z.ZodString;
|
|
174
|
-
complement: z.ZodOptional<z.ZodString
|
|
174
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
175
175
|
phone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
176
176
|
district: z.ZodString;
|
|
177
177
|
legal_nature: z.ZodString;
|
|
@@ -180,12 +180,12 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
180
180
|
[x: string]: string;
|
|
181
181
|
}>;
|
|
182
182
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
183
|
-
economic_activity: z.ZodOptional<z.ZodString
|
|
184
|
-
economic_activity_group: z.ZodOptional<z.ZodString
|
|
185
|
-
monthly_income: z.
|
|
186
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
187
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
188
|
-
capital_social: z.
|
|
183
|
+
economic_activity: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
184
|
+
economic_activity_group: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
185
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
186
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
187
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
188
|
+
capital_social: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
189
189
|
}, z.core.$strict>;
|
|
190
190
|
financing_company_guarantor: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
191
191
|
name: z.ZodString;
|
|
@@ -194,7 +194,7 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
194
194
|
address: z.ZodString;
|
|
195
195
|
number: z.ZodString;
|
|
196
196
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
197
|
-
complement: z.ZodOptional<z.ZodString
|
|
197
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
198
198
|
cellphone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
199
199
|
email: z.ZodString;
|
|
200
200
|
district: z.ZodString;
|
|
@@ -209,32 +209,32 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
209
209
|
nationality: z.ZodDefault<z.ZodEnum<{
|
|
210
210
|
[x: string]: string;
|
|
211
211
|
}>>;
|
|
212
|
-
office: z.ZodOptional<z.ZodString
|
|
213
|
-
phone: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string
|
|
214
|
-
civil_status: z.ZodOptional<z.ZodString
|
|
215
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
216
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
217
|
-
type_doc: z.ZodOptional<z.ZodEnum<{
|
|
212
|
+
office: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
213
|
+
phone: z.ZodPreprocess<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
214
|
+
civil_status: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
215
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
216
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
217
|
+
type_doc: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
218
218
|
[x: string]: string;
|
|
219
|
-
}
|
|
220
|
-
doc: z.ZodOptional<z.ZodString
|
|
221
|
-
issuing_body: z.ZodOptional<z.ZodString
|
|
222
|
-
uf_issuing_body: z.ZodOptional<z.ZodEnum<{
|
|
219
|
+
}>>>;
|
|
220
|
+
doc: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
221
|
+
issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
222
|
+
uf_issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
223
223
|
[x: string]: string;
|
|
224
|
-
}
|
|
225
|
-
doc_issue_date: z.ZodOptional<z.ZodString
|
|
226
|
-
doc_expiration_date: z.ZodOptional<z.ZodString
|
|
227
|
-
monthly_income: z.
|
|
228
|
-
patrimony: z.
|
|
229
|
-
naturalness: z.ZodOptional<z.ZodString
|
|
230
|
-
uf_naturalness: z.ZodOptional<z.ZodEnum<{
|
|
224
|
+
}>>>;
|
|
225
|
+
doc_issue_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
226
|
+
doc_expiration_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
227
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
228
|
+
patrimony: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
229
|
+
naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
230
|
+
uf_naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
231
231
|
[x: string]: string;
|
|
232
|
-
}
|
|
233
|
-
pep_relationship: z.ZodOptional<z.ZodString
|
|
234
|
-
entry_date: z.ZodOptional<z.ZodString
|
|
235
|
-
doc_issuance_uf: z.ZodOptional<z.ZodEnum<{
|
|
232
|
+
}>>>;
|
|
233
|
+
pep_relationship: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
234
|
+
entry_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
235
|
+
doc_issuance_uf: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
236
236
|
[x: string]: string;
|
|
237
|
-
}
|
|
237
|
+
}>>>;
|
|
238
238
|
}, z.core.$strict>>>;
|
|
239
239
|
financing_company_qsa: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
240
240
|
name: z.ZodString;
|
|
@@ -243,7 +243,7 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
243
243
|
address: z.ZodString;
|
|
244
244
|
number: z.ZodString;
|
|
245
245
|
cep: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
246
|
-
complement: z.ZodOptional<z.ZodString
|
|
246
|
+
complement: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
247
247
|
cellphone: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
248
248
|
email: z.ZodString;
|
|
249
249
|
district: z.ZodString;
|
|
@@ -258,35 +258,35 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
258
258
|
nationality: z.ZodDefault<z.ZodEnum<{
|
|
259
259
|
[x: string]: string;
|
|
260
260
|
}>>;
|
|
261
|
-
office: z.ZodOptional<z.ZodString
|
|
262
|
-
phone: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string
|
|
263
|
-
civil_status: z.ZodOptional<z.ZodString
|
|
264
|
-
residence_situation: z.ZodOptional<z.ZodString
|
|
265
|
-
months_in_residence: z.ZodOptional<z.ZodNumber
|
|
266
|
-
type_doc: z.ZodOptional<z.ZodEnum<{
|
|
261
|
+
office: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
262
|
+
phone: z.ZodPreprocess<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
|
|
263
|
+
civil_status: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
264
|
+
residence_situation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
265
|
+
months_in_residence: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
266
|
+
type_doc: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
267
267
|
[x: string]: string;
|
|
268
|
-
}
|
|
269
|
-
doc: z.ZodOptional<z.ZodString
|
|
270
|
-
issuing_body: z.ZodOptional<z.ZodString
|
|
271
|
-
uf_issuing_body: z.ZodOptional<z.ZodEnum<{
|
|
268
|
+
}>>>;
|
|
269
|
+
doc: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
270
|
+
issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
271
|
+
uf_issuing_body: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
272
272
|
[x: string]: string;
|
|
273
|
-
}
|
|
274
|
-
doc_issue_date: z.ZodOptional<z.ZodString
|
|
275
|
-
doc_expiration_date: z.ZodOptional<z.ZodString
|
|
276
|
-
monthly_income: z.
|
|
277
|
-
patrimony: z.
|
|
278
|
-
naturalness: z.ZodOptional<z.ZodString
|
|
279
|
-
uf_naturalness: z.ZodOptional<z.ZodEnum<{
|
|
273
|
+
}>>>;
|
|
274
|
+
doc_issue_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
275
|
+
doc_expiration_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
276
|
+
monthly_income: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
277
|
+
patrimony: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
|
|
278
|
+
naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
279
|
+
uf_naturalness: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
280
280
|
[x: string]: string;
|
|
281
|
-
}
|
|
282
|
-
pep_relationship: z.ZodOptional<z.ZodString
|
|
283
|
-
entry_date: z.ZodOptional<z.ZodString
|
|
284
|
-
doc_issuance_uf: z.ZodOptional<z.ZodEnum<{
|
|
281
|
+
}>>>;
|
|
282
|
+
pep_relationship: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
283
|
+
entry_date: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
284
|
+
doc_issuance_uf: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
285
285
|
[x: string]: string;
|
|
286
|
-
}
|
|
286
|
+
}>>>;
|
|
287
287
|
}, z.core.$strict>>>;
|
|
288
288
|
voucher_local_installation_address: z.ZodObject<{
|
|
289
|
-
url: z.ZodOptional<z.ZodURL
|
|
289
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
290
290
|
mime: z.ZodEnum<{
|
|
291
291
|
"image/jpeg": "image/jpeg";
|
|
292
292
|
"image/png": "image/png";
|
|
@@ -294,11 +294,11 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
294
294
|
}>;
|
|
295
295
|
sizeBytes: z.ZodNumber;
|
|
296
296
|
}, z.core.$strip>;
|
|
297
|
-
proof_kinship_type: z.ZodOptional<z.ZodEnum<{
|
|
297
|
+
proof_kinship_type: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
|
|
298
298
|
[x: string]: string;
|
|
299
|
-
}
|
|
299
|
+
}>>>;
|
|
300
300
|
proof_kinship: z.ZodOptional<z.ZodObject<{
|
|
301
|
-
url: z.ZodOptional<z.ZodURL
|
|
301
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
302
302
|
mime: z.ZodEnum<{
|
|
303
303
|
"image/jpeg": "image/jpeg";
|
|
304
304
|
"image/png": "image/png";
|
|
@@ -307,7 +307,7 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
307
307
|
sizeBytes: z.ZodNumber;
|
|
308
308
|
}, z.core.$strip>>;
|
|
309
309
|
document_front_upload: z.ZodObject<{
|
|
310
|
-
url: z.ZodOptional<z.ZodURL
|
|
310
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
311
311
|
mime: z.ZodEnum<{
|
|
312
312
|
"image/jpeg": "image/jpeg";
|
|
313
313
|
"image/png": "image/png";
|
|
@@ -316,7 +316,7 @@ declare const unifiedPjSchema: z.ZodObject<{
|
|
|
316
316
|
sizeBytes: z.ZodNumber;
|
|
317
317
|
}, z.core.$strip>;
|
|
318
318
|
document_back_upload: z.ZodObject<{
|
|
319
|
-
url: z.ZodOptional<z.ZodURL
|
|
319
|
+
url: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
320
320
|
mime: z.ZodEnum<{
|
|
321
321
|
"image/jpeg": "image/jpeg";
|
|
322
322
|
"image/png": "image/png";
|