Commit f0a61a7f authored by Matthias's avatar Matthias
Browse files

handle non existing transform-files

parent 1f863bc3
Pipeline #24334 passed with stages
in 3 minutes
......@@ -22,7 +22,6 @@ class ImportProcessStart(Resource):
job_parameters['institutionId'] = institution_id
job_parameters['recordSetId'] = record_set_id
# add example parameters for missing ones (remove this block in production!)
if job_parameters is None:
job_parameters = {}
if 'drupalJobUuid' not in job_parameters:
......@@ -52,14 +51,22 @@ class ImportProcessStart(Resource):
'sessionId': job_parameters['sessionId'],
'shortSessionId': shortSessionId,
'institutionId': job_parameters['institutionId'],
'xmlIdentifierFieldName': job_parameters['xmlIdentifierFieldName'],
'isPublished': job_parameters['isPublished'],
'tableSheetIndex': job_parameters['tableSheetIndex'],
'tableHeaderCount': job_parameters['tableHeaderCount'],
'tableHeaderIndex': job_parameters['tableHeaderIndex'],
'tableIdentifierIndex': job_parameters['tableIdentifierIndex']
'isPublished': job_parameters['isPublished']
}
if 'xmlRecordTag' in job_parameters:
body['xmlRecordTag'] = job_parameters['xmlRecordTag']
if 'xmlIdentifierFieldName' in job_parameters:
body['xmlIdentifierFieldName'] = job_parameters['xmlIdentifierFieldName']
if 'tableSheetIndex' in job_parameters:
body['tableSheetIndex'] = job_parameters['tableSheetIndex']
if 'tableHeaderCount' in job_parameters:
body['tableHeaderCount'] = job_parameters['tableHeaderCount']
if 'tableHeaderIndex' in job_parameters:
body['tableHeaderIndex'] = job_parameters['tableHeaderIndex']
if 'tableIdentifierIndex' in job_parameters:
body['tableIdentifierIndex'] = job_parameters['tableIdentifierIndex']
helm = Helm()
response = helm.install(
chart=os.path.join(current_app.root_path, "charts", 'text-file-validation'),
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment