mirror of https://gitlab.com/pamhyr/pamhyr2
BC: Open multiple edit window.
parent
1e4ddae21b
commit
db75315b6d
|
|
@ -63,7 +63,7 @@ class River(Graph):
|
|||
|
||||
@property
|
||||
def boundary_condition(self):
|
||||
return self._boundary_condition.copy()
|
||||
return self._boundary_condition
|
||||
|
||||
def has_current_reach(self):
|
||||
return self._current_reach is not None
|
||||
|
|
|
|||
|
|
@ -331,11 +331,11 @@ class BoundaryConditionWindow(ASubMainWindow, ListedSubWindow):
|
|||
)
|
||||
|
||||
def add(self):
|
||||
if len(self._lst) == 0:
|
||||
rows = self.index_selected_rows()
|
||||
if len(self._lst) == 0 or len(rows) == 0:
|
||||
self._table.add(0)
|
||||
else:
|
||||
row = self.index_selected_row()
|
||||
self._table.add(row)
|
||||
self._table.add(rows[0])
|
||||
|
||||
def delete(self):
|
||||
rows = self.index_selected_rows()
|
||||
|
|
@ -366,5 +366,10 @@ class BoundaryConditionWindow(ASubMainWindow, ListedSubWindow):
|
|||
self._table.redo()
|
||||
|
||||
def edit(self):
|
||||
win = EditBoundaryConditionWindow(data=None, parent=self)
|
||||
rows = self.index_selected_rows()
|
||||
for row in rows:
|
||||
win = EditBoundaryConditionWindow(
|
||||
data=self._lst[row],
|
||||
parent=self
|
||||
)
|
||||
win.show()
|
||||
|
|
|
|||
Loading…
Reference in New Issue