Browse Source

wxGUI/dbm: set default DB settings if not defined

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@42994 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 14 years ago
parent
commit
f1999a52dc
1 changed files with 3 additions and 0 deletions
  1. 3 0
      gui/wxpython/gui_modules/gdialogs.py

+ 3 - 0
gui/wxpython/gui_modules/gdialogs.py

@@ -299,6 +299,9 @@ def CreateNewVector(parent, cmd, title=_('Create new vector map'),
             key = UserSettings.Get(group='atm', key='keycolumn', subkey='value')
             sql = 'CREATE TABLE %s (%s INTEGER)' % (outmap, key)
             
+            gcmd.RunCommand('db.connect',
+                            flags = 'c')
+            
             gcmd.RunCommand('db.execute',
                             quiet = True,
                             parent = parent,