Open timlinux opened 5 years ago
Hey @timlinux !
A new button can be added in the toolbar. I guess it should be very easy:
layers = QgsProject.instance().mapLayers()
for layer in layers.values():
if layer.type() == QgsMapLayerType.VectorLayer:
layer.saveStyleToDatabase('name of style', 'description or None', True, '')
I didn't try, but it should more or less that.
Hey @Gustry! I just found your plugin. I was kinda hoping it would do what the title of this ticket suggests - iterate over all my project layers, saving the style of each layer as the default in the PostgreSQL database.