Geographic Information Systems Asked by Pivi on September 11, 2020
I would like to ask if someone knows a way to press the "select all" button in Project>Properties>QGIS Server>WFS capabilities using python, or if is there a specific command to do the same thing.
Try the following
vectorLayers = [layer.id() for layer in QgsProject.instance().mapLayers().values() if isinstance(layer, QgsVectorLayer)]
QgsProject.instance().writeEntry( "WFSLayers" , "/", vectorLayers);
QgsProject.instance().write()
Adapted from my previous answer Publishing a layer as WFS with PyQGIS
Answered by ThomasG77 on September 11, 2020
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP