fdis 0.1.5 → 0.1.7
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.
- checksums.yaml +4 -4
- data/lib/fdis/config.rb +0 -2
- data/lib/fdis/facturacion.rb +6 -3
- data/lib/fdis/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: af3f9899b4bb678e8a054349e34ca808e6533b8797a2bba13aabb45b54133e6c
|
|
4
|
+
data.tar.gz: 783b74699c9546a2d9598d1c497bea8826d889f7866e5cbaa51928b5fd150656
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 241b331dc599408fc797ebde4353338b55c9083253f9b66202113212b98f08c1605381e7af1c8e38a940e7372bff17ee7a31a42dace0b7fb017a18395347de14
|
|
7
|
+
data.tar.gz: 84f07a0fdb7285a8d79e72e802a790726ee551fe1a911e5b53789533bfade46902e5f29881b59ec2d3dacb8540e2265a2f4ddcbb9c6a1ea933f432cfb610206d
|
data/lib/fdis/config.rb
CHANGED
|
@@ -33,10 +33,8 @@ module Fdis
|
|
|
33
33
|
def key_to_pem
|
|
34
34
|
puts "---- Fdis:config:key_to_pem"
|
|
35
35
|
|
|
36
|
-
puts "-- 1"
|
|
37
36
|
@pem = %x[openssl pkcs8 -inform DER -in #{@doc_key_path} -passin pass:#{@key_pass}]
|
|
38
37
|
# @pem = %x[openssl rsa -inform DER -in #{@doc_key_path} -passin pass:#{@key_pass}]
|
|
39
|
-
puts "-- 2"
|
|
40
38
|
@pem_cadena = @pem.clone
|
|
41
39
|
@pem_cadena.slice!("-----BEGIN PRIVATE KEY-----")
|
|
42
40
|
@pem_cadena.slice!("-----END PRIVATE KEY-----")
|
data/lib/fdis/facturacion.rb
CHANGED
|
@@ -243,7 +243,7 @@ module Fdis
|
|
|
243
243
|
else
|
|
244
244
|
response = {
|
|
245
245
|
status: json_response.code,
|
|
246
|
-
message_error: "Error: #{
|
|
246
|
+
message_error: "Error: #{response['errorMessages']}",
|
|
247
247
|
xml: '',
|
|
248
248
|
uuid: '',
|
|
249
249
|
fecha_timbrado: '',
|
|
@@ -520,7 +520,7 @@ module Fdis
|
|
|
520
520
|
|
|
521
521
|
|
|
522
522
|
base_doc = %(<?xml version="1.0" encoding="utf-8"?>
|
|
523
|
-
<cfdi:Comprobante xsi:schemaLocation="http://www.sat.gob.mx/cfd/4 http://www.sat.gob.mx/sitio_internet/cfd/4/cfdv40.xsd" Version="4.0" xmlns:cfdi="http://www.sat.gob.mx/cfd/4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Fecha="" Serie="" Folio="" FormaPago="" SubTotal="" Moneda="MXN" Total="" TipoDeComprobante="I" MetodoPago="" LugarExpedicion="" Certificado="" NoCertificado="" Sello="" >
|
|
523
|
+
<cfdi:Comprobante xsi:schemaLocation="http://www.sat.gob.mx/cfd/4 http://www.sat.gob.mx/sitio_internet/cfd/4/cfdv40.xsd" Version="4.0" xmlns:cfdi="http://www.sat.gob.mx/cfd/4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Fecha="" Serie="" Folio="" FormaPago="" SubTotal="" Moneda="MXN" Total="" TipoDeComprobante="I" MetodoPago="" LugarExpedicion="" Certificado="" NoCertificado="" Sello="" Exportacion="01">
|
|
524
524
|
|
|
525
525
|
<cfdi:Emisor Rfc="" Nombre="" RegimenFiscal="" />
|
|
526
526
|
<cfdi:Receptor Rfc="" Nombre="" DomicilioFiscalReceptor="" RegimenFiscalReceptor="" UsoCFDI="" />
|
|
@@ -777,6 +777,9 @@ module Fdis
|
|
|
777
777
|
http.request(request)
|
|
778
778
|
end
|
|
779
779
|
|
|
780
|
+
puts "---- Fdis: request"
|
|
781
|
+
puts "-- body: #{request.body} --"
|
|
782
|
+
|
|
780
783
|
puts "---- Fdis: Respuesta"
|
|
781
784
|
puts "-- Codigo: #{json_response.code} --"
|
|
782
785
|
puts "-- Mensaje: #{json_response.message} --"
|
|
@@ -818,7 +821,7 @@ module Fdis
|
|
|
818
821
|
else
|
|
819
822
|
response = {
|
|
820
823
|
status: json_response.code,
|
|
821
|
-
message_error: "Error: #{
|
|
824
|
+
message_error: "Error: #{response['errorMessages']}",
|
|
822
825
|
xml: '',
|
|
823
826
|
uuid: '',
|
|
824
827
|
fecha_timbrado: '',
|
data/lib/fdis/version.rb
CHANGED