('cbte_tipo', 3, N), ('cbte_punto_vta', 4, N), ('cbte_nro', 8, N), ('cbte_cuit', 11, N), ] else: print "!" * 78 print "importando formato segun pyfepdf" from formato_txt import ENCABEZADO, DETALLE, PERMISO, CMP_ASOC, IVA, TRIBUTO TIPOS_REG = '0', '1', '2', '3' if '/recex' in sys.argv: from recex import ENCABEZADO, DETALLE, PERMISO, CMP_ASOC ENCABEZADO[8] = ('nombre_cliente', 200, A) # 'Joao Da Silva' ENCABEZADO[7] = ('pais_dst_cmp', 3, N) ENCABEZADO[16] = ('obs_generales', 1000, A) DETALLE[5] = ('importe', 13, I, 2) DETALLE.append(('bonif', 12, I, 6)) def autorizar(ws, entrada, salida): # recupero el último número de transacción ##id = wsfex.ultnro(client, token, sign, cuit) detalles = [] permisos = [] cbtasocs = [] encabezado = [] if '/dbf' in sys.argv: formatos = [('Encabezado', ENCABEZADO, encabezado), ('Permisos', PERMISO, permisos), ('Comprobante Asociado', CMP_ASOC, cbtasocs), ('Detalles', DETALLE, detalles)] dic = leer_dbf(formatos, conf_dbf) encabezado = encabezado[0] else: