320 Commits

Author SHA1 Message Date
Matthias Kuhn
bb225f562b Improve db_manager README 2016-10-20 12:54:54 +02:00
rldhont
010fc7c640 Fix [DB Manager] Allow lowercase field names for homogenize PostGIS Import 2016-10-19 14:35:17 +02:00
rldhont
a9795ad8ea [DB Manager] Allow lowercase field names for homogenize PostGIS Import
PostGIS provider has an option to lowercase field names. This options is available for user in QGIS algorithm ImportIntoPostGIS and not in DB Mananger.

This commit fix it.
2016-10-19 13:03:32 +02:00
Even Rouault
9786fc00e2 DBManager: python3 fix in create table dialog
The setAutoCompletion() method of QComboBox was deprecated in QT 4 and
has been removed in QT 5. Auto completion is enabled by default.
2016-10-18 13:43:26 +02:00
Matthias Kuhn
576ad138a9 Fix python calls to inexistent methods 2016-10-17 09:31:31 +02:00
nirvn
20d006e101 [db manager] fix spatialite error reporting 2016-10-07 12:07:55 +07:00
nirvn
dab18e7675 [db manager] fix non-spatial import 2016-10-07 11:53:30 +07:00
Sandro Santilli
0348dd5ce7 Force use of estimated metadata upon loading topologies 2016-10-05 12:17:57 +02:00
Juergen E. Fischer
31df84aa6b run 2to3 on source 2016-09-21 23:30:04 +02:00
Mathieu Pellerin
cd1d44be9d [db manager] python3 support (#3512) 2016-09-20 09:34:36 +02:00
Sandro Santilli
91052d5496 Use nullSymbol for label-only layers in topology viewer 2016-09-16 13:41:23 +02:00
Nyall Dawson
fe65063c2b Remove many deprecated methods 2016-09-15 18:34:15 +10:00
Hugo Mercier
5c3a43e286 Fix spatialite access with python3 2016-09-05 13:43:00 +02:00
Nyall Dawson
eba6101357 Fix broken python save/open dialogs under PyQt5
Will break stuff under PyQt4... oh well, better stuff working on Qt5
then Qt4
2016-09-05 11:41:49 +10:00
Even Rouault
8c3537bff2 [DBManager] Fix exception raised when adding a new Spatialite connection
This was accidentaly broken since 1f0fce7852e9f6a27af967d7ac7ee3989dce7b45

Fixes #15274
2016-09-01 20:51:26 +02:00
Juergen E. Fischer
a9464d7c94 db manager: don't consider added layer w/o a dataProvider
(cherry picked from commit 28aa9ebdb75eb099b83a3596b3f3c5c6e5c6f591)
2016-08-30 20:57:00 +02:00
Matthias Kuhn
3aff45cc13 Fix db_manager 2016-08-10 20:36:18 +02:00
Matthias Kuhn
bb79d13e82 Remove deprecated Qgis::WKBType and API cleanup (#3325)
* Remove deprecated Qgis::WKBType and API cleanup

Renames QgsWKBTypes to QgsWkbTypes

Replaces usage of the enums:

* Qgis::WKBType with QgsWkbTypes::Type
* Qgis::GeometryType with QgsWkbTypes::GeometryType

Their values should be forward compatible (a fact that was already
explited up to now by casting between the types)

Renames some SSLxxx to SslXxx and URIxxx to UriXxx

* Fix build warnings and simplify type handling

* Add a fixer to rewrite imports

* The forgotten rebase conflictThe forgotten rebase conflicts

* QgsDataSourcURI > QgsDataSourceUri

* QgsWKBTypes > QgsWkbTypes

* Qgis.WKBGeom > QgsWkbTypes.Geom

* Further python fixes

* Guess what... Qgis::wkbDimensions != QgsWkbTypes::wkbDimensions

* Fix tests

* Python 3 updates

* [travis] pull request caching cannot be disabled

so at least use it in r/w mode

* Fix python3 print in plugins
2016-08-04 09:10:08 +02:00
Alexander Bruy
2134112aab [dbmanager] fix signal/slot connection 2016-08-02 16:50:27 +03:00
Nyall Dawson
bd7d913379 Refine QgsFeature geometry getters/setters
All pointer based methods have been removed.

Now we have only:

  void setGeometry( const QgsGeometry& geom )

and

  QgsGeometry geometry() const

Benefits include avoiding a whole lot of tricky pointer lifetime
issues, potential memory leaks, and finally closing #777, which
has survived for over 9 years!...

Impacts on PyQGIS code:
- no more need for the messy
  g = QgsGeometry( feature.geometry() )
  workaround, just use g = feature.geometry() instead
- IMPORTANT: you can no longer test whether a feature has geometry
 using `if f.geometry():`, since QgsFeature::geometry() will
 *always* return an object. Instead, use
 `if not f.geometry().isEmpty():`, or preferably the new method
 `if not f.hasGeometry():`

Fix #777
2016-08-01 16:25:46 +10:00
rldhont
153b1c1d0e Merge pull request #3322 from rldhont/db_manager_update_sql_layer
[DB Manager] Add the ability to update SQL Layer
2016-07-26 15:36:11 +02:00
Nyall Dawson
1a2231f10c Rename QGis class to Qgis, for capitalisation consistency 2016-07-21 22:01:38 +10:00
rldhont
c1cdfe860d [DB Manager] Add the ability to update SQL Layer 2016-07-20 12:20:01 +02:00
Juergen E. Fischer
a6954b2771 [dbmanager] re-enable line number again (followup 5e36de7 and d9f934f) 2016-07-03 20:22:13 +02:00
Matthias Kuhn
5e36de70b0 [dbmanager] Fix error when opening SQL window 2016-07-03 14:48:17 +02:00
Juergen E. Fischer
4b00182482 oracle provider: by default skip additional geometry columns (on 64bit
Windows/Linux OCI crashes when there are more than three geometry
columns)
2016-06-23 22:22:46 +02:00
Juergen E. Fischer
d9f934f950 db manager: re-enable margins with line numbers in sql editor
(fixes #15110)
2016-06-22 22:41:44 +02:00
Juergen E. Fischer
1f0fce7852 db manager: fix drag and drop import (fixes #13712) 2016-06-22 12:35:17 +02:00
Juergen E. Fischer
ecf3b3719d db manager: show database name in postgis connection details (fixes #3489) 2016-06-21 00:17:41 +02:00
Salvatore Larosa
f1ec12133e [dbmanager] followup 8727799: again some emit signal fix 2016-06-11 18:29:29 +02:00
Salvatore Larosa
87277999a4 [dbmanager] Fix emit signal when refresh fields in table 2016-06-11 16:58:11 +02:00
Salvatore Larosa
3b998d21ed [dbmanager] fix some import statement 2016-06-10 22:18:52 +02:00
Salvatore Larosa
c578f3a635 [dbmanager] Fix some pyqtslot 2016-06-10 18:01:02 +02:00
Salvatore Larosa
b9d1544c64 [dbmanager] Fixes #14740 - Previews do not work and python error for PG layers 2016-06-10 17:22:19 +02:00
Salvatore Larosa
a8cf02ad8d [dbmanager] fix DeprecationWarning 2016-06-07 22:28:50 +02:00
Salvatore Larosa
65aa860121 [dbmanager] Fixes #14722 - Adding new GeoPackage connection to DB Manager is throwing error 2016-06-07 14:06:07 +02:00
Salvatore Larosa
2cf224cacf [dbmanager] remove maxsize constraint for reset button in query builder dialog 2016-05-30 14:26:25 +02:00
arnaud.morvan@camptocamp.com
8e5b28f3bb [db_manager] Fix #14796 - Quote values depending on data type in query builder 2016-05-29 23:59:03 +02:00
Sebastian Dietrich
c5308754eb [DbManager] allow to refresh materialized views
(fixes #13697)
2016-05-14 00:41:20 +02:00
Matthias Kuhn
25f2e637c0 Remove references to QPyNullVariant 2016-05-13 22:23:03 +02:00
Denis Rouzaud
8071acd064 move PyQt compat folder to python/qgis 2016-04-29 14:10:26 +02:00
elpaso
1e6dceb7d2 [dbmanager] Fixes various signal bugs after 8bda5c
Fixes some unreported glitches after new signals migration.

Also fixes #14649
2016-04-14 09:02:04 +02:00
Alessandro Pasotti
1eb63768d9 [dbmanager] Use user name as DB name if provided
Followup for 212b125
2016-04-12 14:40:23 +02:00
Alessandro Pasotti
212b125a2c [dbmanager] PG ignore env if service file is used
Fixes #14436

Funded by Boundless
2016-04-12 14:05:19 +02:00
Hugo Mercier
7dbc0bf819 [db manager] Fix virtual layers plugin (fixes #14404) 2016-03-23 17:39:41 +01:00
Juergen E. Fischer
c55f8b73f0 db_manager: cleanups 2016-03-21 17:00:24 +01:00
Juergen E. Fischer
8bda5c00a5 db_manager: migrate to new style signals 2016-03-15 23:46:54 +01:00
Juergen E. Fischer
c6d921729e python fixes:
* issues identified by pyflakes (star and unused imports)
* pyqtwrapper: add QtSvg
* some exceptions e.message => unicode(e)
* some translations tr("..." % foo) => tr("...") % foo
* TODO:
  python/console/console_sci.py:547 QsciScintillaCompat?
  python/plugins/db_manager/dlg_query_builder.py:304 pop_up_error?
2016-03-15 17:25:23 +01:00
Werner Macho
6acdfc6e84 improve import handling 2016-03-15 11:14:16 +01:00
Juergen E. Fischer
fb3fcfa3a0 Python3/Qt5/2to3 updates:
* pyqtwrappers update (add QtNetwork, QtXml, QtSql, QtTest, uic)
* 2to3 updates
* move QPyNullVariant/NULL to PyQt.QtCore
* add global unicode/basestring/long for Python3
* expand QtGui, QtCore module and star exports
* Qscintilla2
* replace Set import with set builtin
2016-03-14 20:38:20 +01:00