@plasoft/boletos 1.0.61 → 1.0.63
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/build/index.d.mts +2 -2
- package/build/index.d.ts +2 -2
- package/build/index.js +6 -8
- package/build/index.js.map +1 -1
- package/build/index.mjs +6 -8
- package/build/index.mjs.map +1 -1
- package/build/itau-boleto.hbs +4 -4
- package/package.json +1 -1
package/build/index.mjs
CHANGED
|
@@ -1829,9 +1829,7 @@ function gerarRemessa4({ dados }) {
|
|
|
1829
1829
|
arquivo.add(" ".padEnd(5, " "));
|
|
1830
1830
|
arquivo.add(dadosBancario.carteira);
|
|
1831
1831
|
arquivo.add("0 22");
|
|
1832
|
-
|
|
1833
|
-
const documento = `${boleto.numeroDocumento}/${Number(boleto.parcela)}`.padEnd(14, " ");
|
|
1834
|
-
arquivo.add(documento.substring(0, 15));
|
|
1832
|
+
arquivo.add(`${boleto.numeroDocumento}/${Number(boleto.parcela)}`.padEnd(15, " "));
|
|
1835
1833
|
arquivo.add(vencimento);
|
|
1836
1834
|
arquivo.add(Number(boleto.valor).toFixed(2).replace(".", "").padStart(15, "0"));
|
|
1837
1835
|
arquivo.add("00000");
|
|
@@ -2560,7 +2558,7 @@ function gerarRemessa5({ dados }) {
|
|
|
2560
2558
|
arquivo.add("00000000");
|
|
2561
2559
|
arquivo.add(valorJurosDia.toFixed(2).replace(".", "").padStart(15, "0"));
|
|
2562
2560
|
arquivo.add(codigoDesconto);
|
|
2563
|
-
arquivo.add(vencimento);
|
|
2561
|
+
arquivo.add(codigoDesconto == "0" ? vencimento : "00000000");
|
|
2564
2562
|
arquivo.add(desconto.replace(".", "").padStart(15, "0"));
|
|
2565
2563
|
arquivo.add("000000000000000");
|
|
2566
2564
|
arquivo.add("000000000000000");
|
|
@@ -2764,7 +2762,7 @@ function gerarPDF6(_0) {
|
|
|
2764
2762
|
return __async(this, arguments, function* ({ dados }) {
|
|
2765
2763
|
try {
|
|
2766
2764
|
const { dadosPDF } = dados;
|
|
2767
|
-
if (!dadosPDF.pagador.
|
|
2765
|
+
if (!dadosPDF.pagador.cnpjCpf) {
|
|
2768
2766
|
throw new Error("CPF/CNPJ do pagador na\u0303o informado!");
|
|
2769
2767
|
}
|
|
2770
2768
|
const codigoBarra2 = yield BwipJs6.toBuffer({
|
|
@@ -2774,8 +2772,8 @@ function gerarPDF6(_0) {
|
|
|
2774
2772
|
});
|
|
2775
2773
|
dadosPDF.beneficiario.dadosBancario.agencia = dadosPDF.beneficiario.dadosBancario.agencia.padStart(4, "0");
|
|
2776
2774
|
dadosPDF.boleto.linhaDigitavel = maskFormat_default.codigoBarra(dadosPDF.boleto.linhaDigitavel);
|
|
2777
|
-
dadosPDF.beneficiario.
|
|
2778
|
-
dadosPDF.beneficiario.
|
|
2775
|
+
dadosPDF.beneficiario.cnpjCpf = maskFormat_default.retornaCpfCnpjFormatado(
|
|
2776
|
+
dadosPDF.beneficiario.cnpjCpf
|
|
2779
2777
|
);
|
|
2780
2778
|
dadosPDF.beneficiario.endereco.cep = maskFormat_default.retornaCEPFormatado(
|
|
2781
2779
|
dadosPDF.beneficiario.endereco.cep
|
|
@@ -2783,7 +2781,7 @@ function gerarPDF6(_0) {
|
|
|
2783
2781
|
dadosPDF.pagador.endereco.cep = maskFormat_default.retornaCEPFormatado(
|
|
2784
2782
|
dadosPDF.pagador.endereco.cep
|
|
2785
2783
|
);
|
|
2786
|
-
dadosPDF.pagador.
|
|
2784
|
+
dadosPDF.pagador.cnpjCpf = maskFormat_default.retornaCpfCnpjFormatado(dadosPDF.pagador.cnpjCpf);
|
|
2787
2785
|
const valorDocumento = Number(dadosPDF.boleto.valorDocumento);
|
|
2788
2786
|
dadosPDF.boleto.valorDocumento = maskFormat_default.numberToReal(
|
|
2789
2787
|
dadosPDF.boleto.valorDocumento
|