Skip to content
Permalink
Browse files

[processing] fixed exporting multiple vector layers in SAGA and GRASS…

… algs
  • Loading branch information
volaya committed Feb 15, 2016
1 parent 479d90a commit 961c35aeb572e370612856b03fde942e8b5449f8
@@ -268,7 +268,10 @@ def processAlgorithm(self, progress):
else:
self.setSessionProjectionFromLayer(layer, commands)
commands.append(self.exportRasterLayer(layer))
elif param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
elif param.datatype in [ParameterMultipleInput.TYPE_VECTOR_ANY,
ParameterMultipleInput.TYPE_VECTOR_LINE,
ParameterMultipleInput.TYPE_VECTOR_POLYGON,
ParameterMultipleInput.TYPE_VECTOR_POINT]:
for layer in layers:
if layer in self.exportedLayers.keys():
continue
@@ -325,7 +325,10 @@ def processInputs(self):
else:
self.setSessionProjectionFromLayer(layer, self.commands)
self.commands.append(self.exportRasterLayer(layer))
elif param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
elif param.datatype in [ParameterMultipleInput.TYPE_VECTOR_ANY,
ParameterMultipleInput.TYPE_VECTOR_LINE,
ParameterMultipleInput.TYPE_VECTOR_POLYGON,
ParameterMultipleInput.TYPE_VECTOR_POINT]:
for layer in layers:
if layer in self.exportedLayers.keys():
continue
@@ -162,7 +162,10 @@ def processAlgorithm(self, progress):
if exportCommand is not None:
commands.append(exportCommand)
param.value = ";".join(layers)
elif param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
elif param.datatype in [ParameterMultipleInput.TYPE_VECTOR_ANY,
ParameterMultipleInput.TYPE_VECTOR_LINE,
ParameterMultipleInput.TYPE_VECTOR_POLYGON,
ParameterMultipleInput.TYPE_VECTOR_POINT]:
for layerfile in layers:
layer = dataobjects.getObjectFromUri(layerfile, False)
if layer:
@@ -103,7 +103,10 @@ def processAlgorithm(self, progress):
if exportCommand is not None:
commands.append(exportCommand)
param.value = ";".join(layers)
elif param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
elif param.datatype in [ParameterMultipleInput.TYPE_VECTOR_ANY,
ParameterMultipleInput.TYPE_VECTOR_LINE,
ParameterMultipleInput.TYPE_VECTOR_POLYGON,
ParameterMultipleInput.TYPE_VECTOR_POINT]:
for layerfile in layers:
layer = dataobjects.getObjectFromUri(layerfile, False)
if layer:

0 comments on commit 961c35a

Please sign in to comment.
You can’t perform that action at this time.