mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-06 00:07:29 -04:00
Make argument setting consistent
This commit is contained in:
parent
5302feb2dd
commit
0a3b7d36f8
@ -125,6 +125,13 @@ class OneSideBuffer(GdalAlgorithm):
|
||||
|
||||
output, outputFormat = GdalUtils.ogrConnectionStringAndFormat(outFile, context)
|
||||
|
||||
other_fields_exist = any(
|
||||
True for f in fields
|
||||
if f.name() != geometry
|
||||
)
|
||||
|
||||
other_fields = ',*' if other_fields_exist else ''
|
||||
|
||||
arguments = [
|
||||
output,
|
||||
ogrLayer,
|
||||
@ -133,13 +140,6 @@ class OneSideBuffer(GdalAlgorithm):
|
||||
'-sql'
|
||||
]
|
||||
|
||||
other_fields_exist = any(
|
||||
True for f in fields
|
||||
if f.name() != geometry
|
||||
)
|
||||
|
||||
other_fields = ',*' if other_fields_exist else ''
|
||||
|
||||
if dissolve or fieldName:
|
||||
sql = 'SELECT ST_Union(ST_SingleSidedBuffer({}, {}, {})) AS {}{} FROM "{}"'.format(geometry, distance, side, geometry, other_fields, layerName)
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user