Skip to content

Commit 1b79177

Browse files
committedNov 17, 2017
[bugfix] Fix WFS in metasearch
Fixes #17347
1 parent a0639b1 commit 1b79177

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed
 

‎python/plugins/MetaSearch/dialogs/maindialog.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -762,7 +762,9 @@ def add_to_ows(self):
762762
conn_cmb = ows_provider.findChild(QWidget, 'cmbConnections')
763763
connect = 'btnConnect_clicked'
764764
elif service_type == 'OGC:WFS':
765-
ows_provider.addWfsLayer.connect(self.iface.mainWindow().addWfsLayer)
765+
def addVectorLayer(path, name):
766+
self.iface.mainWindow().addVectorLayer(path, name, 'WFS')
767+
ows_provider.addVectorLayer.connect(addVectorLayer)
766768
conn_cmb = ows_provider.findChild(QWidget, 'cmbConnections')
767769
connect = 'connectToServer'
768770
elif service_type == 'OGC:WCS':
@@ -786,9 +788,9 @@ def add_to_ows(self):
786788
conn_cmb.setCurrentIndex(index)
787789
# only for wfs
788790
if service_type == 'OGC:WFS':
789-
ows_provider.on_cmbConnections_activated(index)
791+
ows_provider.cmbConnections_activated(index)
790792
elif service_type in ['ESRI:ArcGIS:MapServer', 'ESRI:ArcGIS:FeatureServer']:
791-
ows_provider.on_cmbConnections_activated(index)
793+
ows_provider.cmbConnections_activated(index)
792794
getattr(ows_provider, connect)()
793795

794796
def show_metadata(self):

0 commit comments

Comments
 (0)
Please sign in to comment.