File tree Expand file tree Collapse file tree 2 files changed +3
-7
lines changed
python/plugins/processing/algs/qgis Expand file tree Collapse file tree 2 files changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -151,9 +151,6 @@ def checkParameterValuesBeforeExecuting(self):
151
151
if newField and len (fieldName ) == 0 :
152
152
return self .tr ('Field name is not set. Please enter a field name' )
153
153
154
- outputName = self .getOutputValue (self .OUTPUT_LAYER ).strip ()
155
- if outputName == '' :
156
- return self .tr ('Output is not set. Please specify valid filename' )
157
154
158
155
def getCustomParametersDialog (self ):
159
156
return FieldsCalculatorDialog (self )
Original file line number Diff line number Diff line change @@ -142,8 +142,8 @@ def selectFile(self):
142
142
filename = unicode (files [0 ])
143
143
selectedFileFilter = unicode (fileDialog .selectedNameFilter ())
144
144
if not filename .lower ().endswith (
145
- tuple (re .findall ("\*(\.[a-z]{1,5 })" , fileFilter ))):
146
- ext = re .search ("\*(\.[a-z]{1,5 })" , selectedFileFilter )
145
+ tuple (re .findall ("\*(\.[a-z]{1,10 })" , fileFilter ))):
146
+ ext = re .search ("\*(\.[a-z]{1,10 })" , selectedFileFilter )
147
147
if ext :
148
148
filename = filename + ext .group (1 )
149
149
self .leOutputFile .setText (filename )
@@ -184,8 +184,7 @@ def setParamValues(self):
184
184
self .alg .setParameterValue ('NEW_FIELD' ,
185
185
self .mNewFieldGroupBox .isChecked ())
186
186
self .alg .setParameterValue ('FORMULA' , self .builder .expressionText ())
187
- self .alg .setOutputValue ('OUTPUT_LAYER' ,
188
- self .leOutputFile .text ())
187
+ self .alg .setOutputValue ('OUTPUT_LAYER' , self .leOutputFile .text ().strip () or None )
189
188
190
189
msg = self .alg .checkParameterValuesBeforeExecuting ()
191
190
if msg :
You can’t perform that action at this time.
0 commit comments