From a0be038bbfd479ecd6631fec7b0773e3fa263911 Mon Sep 17 00:00:00 2001 From: mistangl Date: Wed, 14 Feb 2024 16:05:42 +0100 Subject: [PATCH] =?UTF-8?q?Aufruf=20mit=20-use=5Flocal=20m=C3=B6glich,=20s?= =?UTF-8?q?o=20dass=20auch=20das=20kopieren=20vom=20Netzlaufwerk=20nicht?= =?UTF-8?q?=20stattfindet.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/get_teilestamm.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/get_teilestamm.py b/lib/get_teilestamm.py index ddc3c3a..499c3b4 100644 --- a/lib/get_teilestamm.py +++ b/lib/get_teilestamm.py @@ -31,7 +31,7 @@ class FetchSivasTeilestamm: if __name__ == '__main__': parser = argparse.ArgumentParser(description='fetches data from sivas or ruledesigner fusion', prog='update_database') parser.add_argument('-s', '--sivasid', action='store', help='fetch teilestamm-data for all unmigrated parts in the bom of a given asm-id. Specifiy multiple ids as comma separated values without space, e.g. 200000089,200000090', metavar='id(s)') - parser.add_argument('-l', '--uselocal', action='store_true', help='Do not connect to database. Use local files (if already existing) for the given asm-id') + parser.add_argument('-l', '--uselocal', action='store_true', help='Do not connect to database. Use local files (if already existing) for the given asm-id', default=False) args = parser.parse_args() @@ -43,7 +43,8 @@ if __name__ == '__main__': if args.uselocal: sivas_teilestamm.use_local(args.uselocal) sivas_teilestamm.fetch_from_db() - sivas_teilestamm.get_unmigrated_teilstamm_csvs() + if args.uselocal == False: + sivas_teilestamm.get_unmigrated_teilstamm_csvs(args.uselocal) else: parser.print_help() \ No newline at end of file