Adists: OutputRK: Fix save and table display.

scenarios
Pierre-Antoine 2025-08-22 09:36:26 +02:00
parent 0e1e3665a6
commit ffa065a3e6
2 changed files with 7 additions and 5 deletions

View File

@ -195,7 +195,7 @@ class OutputRKAdists(SQLSubModel):
"VALUES (" +
f"{self.id}, {self._db_format({self.is_deleted()})}" +
f"{self._reach}, {self._rk}, " +
f"'{self._db_format(self._title)}'" +
f"'{self._db_format(self._title)}', " +
f"{self._status.scenario_id}" +
")"
)

View File

@ -65,11 +65,13 @@ class ComboBoxDelegate(QItemDelegate):
.get(index.row()) \
.reach
reach = next(filter(
lambda edge: edge.id == reach_id, self._data.edges()
))
if reach_id is not None:
reach = next(
filter(
lambda edge: edge.id == reach_id, self._data.edges()
)
)
val = list(
map(
lambda rk: str(rk), reach.reach.get_rk()