Model: Start export model into SQLite database.

* Study: Create table.
* River: Create node and reach table.
* Geometry: Create table only for profileXYZ and pointXYZ.
This commit is contained in:
Pierre-Antoine Rouby committed 2023-06-28 16:50:08 +02:00
1 parent 5566d87774
commit 2ed3254b46
12 files changed
+450 -29

No files matched your search

+3 -3
View File
@@ -213,7 +213,7 @@ class ApplicationWindow(QMainWindow, ListedSubWindow, WindowToolKit):
Returns:
Nothing
"""
if self.model.filename == "":
if self.model.filename is None or self.model.filename == "":
file_name, _ = QFileDialog.getSaveFileName(
self, "Save File",
"", "Pamhyr(*.pkl)"
@@ -282,9 +282,9 @@ class ApplicationWindow(QMainWindow, ListedSubWindow, WindowToolKit):
if self.model is None:
dialog = QFileDialog(self)
dialog.setFileMode(QFileDialog.FileMode.ExistingFile)
dialog.setDefaultSuffix(".pkl")
dialog.setDefaultSuffix(".pamhyr")
#dialog.setFilter(dialog.filter() | QtCore.QDir.Hidden)
dialog.setNameFilters(['PamHyr (*.pkl)'])
dialog.setNameFilters(['PamHyr (*.pamhyr)'])
if dialog.exec_():
file_name = dialog.selectedFiles()