Skip to content
Snippets Groups Projects
Commit 4c519334 authored by juanf's avatar juanf
Browse files

SSDM-13422: XLSX files support

parent 842c4b3f
No related branches found
No related tags found
1 merge request!40SSDM-13578 : 2PT : Database and V3 Implementation - include the new AFS "free"...
...@@ -56,6 +56,9 @@ def process(context, parameters): ...@@ -56,6 +56,9 @@ def process(context, parameters):
tempPath = temp.getAbsolutePath() tempPath = temp.getAbsolutePath()
MasterDataRegistrationHelper.extractToDestination(zip_bytes, tempPath) MasterDataRegistrationHelper.extractToDestination(zip_bytes, tempPath)
byteArrays = MasterDataRegistrationHelper.getByteArrays(Path.of(tempPath), ".xls") byteArrays = MasterDataRegistrationHelper.getByteArrays(Path.of(tempPath), ".xls")
byteArrays.addAll(MasterDataRegistrationHelper.getByteArrays(Path.of(tempPath), ".xlsx"))
if len(byteArrays) == 0:
raise UserFailureException('No .xls or .xlsx fields found. These should be on the root folder of the zip file.')
parameters.put('xls', byteArrays) parameters.put('xls', byteArrays)
allScripts = MasterDataRegistrationHelper.getAllScripts(Path.of(tempPath)) allScripts = MasterDataRegistrationHelper.getAllScripts(Path.of(tempPath))
parameters.put('scripts', allScripts) parameters.put('scripts', allScripts)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment