Skip to content

Commit

Permalink
[processing][needs-docs] Refine names for 'Import into PostGIS' algs
Browse files Browse the repository at this point in the history
Renames the existing algorithms for clarity and consistency
to the format 'Export to PostgreSQL...'. Add tags so that they
still show when searching for the old names, and add descriptions
to make their use more obvious from the toolbox.

Fixes #19658
  • Loading branch information
nyalldawson committed Aug 21, 2018
1 parent a7bf4f1 commit 5fab46f
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 5 deletions.
10 changes: 9 additions & 1 deletion python/plugins/processing/algs/gdal/OgrToPostGis.py
Expand Up @@ -163,7 +163,15 @@ def name(self):
return 'importvectorintopostgisdatabasenewconnection'

def displayName(self):
return self.tr('Import vector into PostGIS database (new connection)')
return self.tr('Export to PostgreSQL (new connection)')

def shortDescription(self):
return self.tr('Exports a vector layer to a new PostgreSQL database connection')

def tags(self):
t = self.tr('import,into,postgis,database,vector').split(',')
t.extend(super().tags())
return t

def group(self):
return self.tr('Vector miscellaneous')
Expand Down
10 changes: 9 additions & 1 deletion python/plugins/processing/algs/gdal/ogr2ogrtopostgislist.py
Expand Up @@ -171,7 +171,15 @@ def name(self):
return 'importvectorintopostgisdatabaseavailableconnections'

def displayName(self):
return self.tr('Import vector into PostGIS database (available connections)')
return self.tr('Export to PostgreSQL (available connections)')

def shortDescription(self):
return self.tr('Exports a vector layer to an existing PostgreSQL database connection')

def tags(self):
t = self.tr('import,into,postgis,database,vector').split(',')
t.extend(super().tags())
return t

def group(self):
return self.tr('Vector miscellaneous')
Expand Down
8 changes: 7 additions & 1 deletion python/plugins/processing/algs/qgis/ImportIntoPostGIS.py
Expand Up @@ -115,7 +115,13 @@ def name(self):
return 'importintopostgis'

def displayName(self):
return self.tr('Import into PostGIS')
return self.tr('Export to PostgreSQL')

def shortDescription(self):
return self.tr('Exports a vector layer to a PostgreSQL database')

def tags(self):
return self.tr('import,postgis,table,layer,into,copy').split(',')

def processAlgorithm(self, parameters, context, feedback):
connection = self.parameterAsString(parameters, self.DATABASE, context)
Expand Down
Expand Up @@ -89,7 +89,13 @@ def name(self):
return 'postgisexecuteandloadsql'

def displayName(self):
return self.tr('PostGIS execute and load SQL')
return self.tr('PostgreSQL execute and load SQL')

def shortDescription(self):
return self.tr('Executes a SQL command on a PostgreSQL database and loads the result as a table')

def tags(self):
return self.tr('postgis,table,database').split(',')

def processAlgorithm(self, parameters, context, feedback):
connection = self.parameterAsString(parameters, self.DATABASE, context)
Expand Down
8 changes: 7 additions & 1 deletion python/plugins/processing/algs/qgis/PostGISExecuteSQL.py
Expand Up @@ -58,7 +58,13 @@ def name(self):
return 'postgisexecutesql'

def displayName(self):
return self.tr('PostGIS execute SQL')
return self.tr('PostgreSQL execute SQL')

def shortDescription(self):
return self.tr('Executes a SQL command on a PostgreSQL database')

def tags(self):
return self.tr('postgis,database').split(',')

def processAlgorithm(self, parameters, context, feedback):
connection = self.parameterAsString(parameters, self.DATABASE, context)
Expand Down

0 comments on commit 5fab46f

Please sign in to comment.