From 2332b16c6e7b7e57898f1dd0a3fb40cb2665ee01 Mon Sep 17 00:00:00 2001 From: mikibonacci Date: Tue, 3 Dec 2024 18:16:24 +0000 Subject: [PATCH] Putting back the results panel in the init. --- src/aiidalab_qe_vibroscopy/app/__init__.py | 6 ++++++ src/aiidalab_qe_vibroscopy/app/result/result.py | 8 ++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/aiidalab_qe_vibroscopy/app/__init__.py b/src/aiidalab_qe_vibroscopy/app/__init__.py index e77ed16..361de09 100644 --- a/src/aiidalab_qe_vibroscopy/app/__init__.py +++ b/src/aiidalab_qe_vibroscopy/app/__init__.py @@ -6,6 +6,8 @@ VibroResourceSettingsModel, VibroResourcesSettingsPanel, ) +from aiidalab_qe_vibroscopy.app.result.result import VibroResultsPanel +from aiidalab_qe_vibroscopy.app.result.model import VibroResultsModel from aiidalab_qe_vibroscopy.app.workchain import workchain_and_builder @@ -24,5 +26,9 @@ class VibroPluginOutline(PluginOutline): "panel": VibroResourcesSettingsPanel, "model": VibroResourceSettingsModel, }, + "result": { + "panel": VibroResultsPanel, + "model": VibroResultsModel, + }, "workchain": workchain_and_builder, } diff --git a/src/aiidalab_qe_vibroscopy/app/result/result.py b/src/aiidalab_qe_vibroscopy/app/result/result.py index 1e376c1..2ce571a 100644 --- a/src/aiidalab_qe_vibroscopy/app/result/result.py +++ b/src/aiidalab_qe_vibroscopy/app/result/result.py @@ -65,9 +65,8 @@ def render(self): tab_data.append(("Raman/IR spectra", irraman_widget)) - needs_dielectri_tab = self._model.needs_dielectric_tab() - - if needs_dielectri_tab: + needs_dielectric_tab = self._model.needs_dielectric_tab() + if needs_dielectric_tab: dielectric_model = DielectricModel() dielectric_widget = DielectricWidget( model=dielectric_model, @@ -75,7 +74,8 @@ def render(self): ) tab_data.append(("Dielectric Properties", dielectric_widget)) - if self._model.needs_euphonic_tab(): + needs_euphonic_tab = self._model.needs_euphonic_tab() + if needs_euphonic_tab: euphonic_model = EuphonicModel() euphonic_widget = EuphonicWidget( model=euphonic_model,