Fix get version in proforma

This commit is contained in:
Mauricio Baeza 2021-01-11 14:43:28 -06:00
parent 94f5df0723
commit 6785dfebf7
2 changed files with 31 additions and 2 deletions

View File

@ -1140,8 +1140,9 @@ class LIBO(object):
return
def _others_values(self, data):
version = data['version']
self._set_cell('{version}', version)
version = data.get('version', '')
if version:
self._set_cell('{version}', version)
return
def pdf(self, path, data, ods=False):

View File

@ -10497,6 +10497,32 @@ def _migrate_cert(rfc):
return
def _test(rfc):
if not rfc:
rfc = input('Introduce el RFC: ').strip().upper()
if not rfc:
msg = 'El RFC es requerido'
log.error(msg)
return
args = util.get_con(rfc)
if not args:
return
conectar(args)
log.info('Test con...')
query = Socios.select(Socios.id, Socios.nombre, Socios.rfc).where(Socios.nombre.contains('Lopez'))
print(query)
desconectar()
log.info('End test...')
return
def _process_command_line_arguments():
parser = argparse.ArgumentParser(
description='Empresa Libre')
@ -10569,6 +10595,8 @@ def main(args):
_migrate_cert(args.rfc)
return
# ~ _test(args.rfc)
return