Skip to content


[processing] Don't sort field names in multi-field input dialog
Browse files Browse the repository at this point in the history
Field names should always be listed in the order that the layer
defines them
  • Loading branch information
nyalldawson committed Dec 14, 2017
1 parent 9984962 commit bbf0027
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions python/plugins/processing/gui/
Expand Up @@ -1362,11 +1362,11 @@ def getFields(self):
elif self.param.dataType() == QgsProcessingParameterField.DateTime:
fieldTypes = [QVariant.Date, QVariant.Time, QVariant.DateTime]

fieldNames = set()
fieldNames = []
for field in self._layer.fields():
if not fieldTypes or field.type() in fieldTypes:
return sorted(list(fieldNames), key=cmp_to_key(locale.strcoll))
return fieldNames

def setValue(self, value):
if self.dialogType in (DIALOG_STANDARD, DIALOG_BATCH):
Expand Down

0 comments on commit bbf0027

Please sign in to comment.