Skip to content

Commit b072e6c

Browse files
committed
Added two new tabs, Type Getter and Shipment Tracker to Dashboard. Also updated the way hwdb-shipping generates shipping label. It now adds a bar-code besides a QR-code.
1 parent 42d4039 commit b072e6c

File tree

18 files changed

+4133
-247
lines changed

18 files changed

+4133
-247
lines changed

lib/Sisyphus/Gui/Dashboard/__main__.py

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
from .utils import silence_warnings
1+
from Sisyphus.Gui.Dashboard.utils import silence_warnings
22

33
import threading, webbrowser
44
from threading import Timer
5-
from dash import Dash
5+
from dash import Dash, html
66
import dash_bootstrap_components as dbc
77

88

@@ -15,11 +15,12 @@
1515
from Sisyphus.Configuration import config
1616
logger = config.getLogger(__name__)
1717

18-
from .layout.layout_main import layout, register_layout_callbacks
19-
from .callbacks.callbacks_preferences import register_preferences_callbacks
20-
from .callbacks.callbacks_jsonselect import register_jsonselect_callbacks
18+
from Sisyphus.Gui.Dashboard.layout.layout_main import layout, register_layout_callbacks
19+
from Sisyphus.Gui.Dashboard.callbacks.callbacks_preferences import register_preferences_callbacks
20+
from Sisyphus.Gui.Dashboard.callbacks.callbacks_jsonselect import register_jsonselect_callbacks
21+
from Sisyphus.Gui.Dashboard.callbacks.callbacks_typegetter import register_typegetter_callbacks
2122

22-
from .callbacks import (
23+
from Sisyphus.Gui.Dashboard.callbacks import (
2324
register_conditions_callbacks,
2425
register_filter_callbacks,
2526
register_valuefilter_callbacks,
@@ -28,6 +29,8 @@
2829
register_plot_callbacks,
2930
register_sync_callbacks,
3031
register_updatemenu_callbacks,
32+
register_shipment_callbacks,
33+
register_overlay_callbacks,
3134
)
3235

3336
#------------- create the website and interface -------
@@ -37,11 +40,18 @@
3740
suppress_callback_exceptions=True
3841
)
3942
app.title = "HWDB Dashboard"
40-
# Pass IsPro into layout generator
4143
app.layout = layout
44+
# Force Dash to validate the layout before callback registration
45+
#app.validation_layout = layout
46+
47+
#app.config.suppress_callback_exceptions = True
48+
49+
50+
# Now register layout-switching callback
4251
register_layout_callbacks(app)
4352

4453
# Register all callback modules
54+
register_typegetter_callbacks(app)
4555
register_preferences_callbacks(app)
4656
register_conditions_callbacks(app)
4757
register_filter_callbacks(app)
@@ -52,6 +62,8 @@
5262
register_sync_callbacks(app)
5363
register_updatemenu_callbacks(app)
5464
register_jsonselect_callbacks(app)
65+
register_shipment_callbacks(app)
66+
register_overlay_callbacks(app)
5567

5668
logger.info("Dashboard is starting up...")
5769
# Run the app

0 commit comments

Comments
 (0)