mirror of
https://github.com/natankeddem/bale.git
synced 2026-05-03 06:02:54 +00:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| db4f340898 | |||
| f58b03a86b |
+8
-12
@@ -91,20 +91,16 @@ class Tab:
|
||||
with el.WColumn():
|
||||
with el.Card() as card:
|
||||
card.tailwind.width("full")
|
||||
with el.WColumn():
|
||||
ui.label(f"#> {result.command}").classes("text-secondary")
|
||||
with el.WRow() as row:
|
||||
row.tailwind.justify_content("around")
|
||||
with ui.column() as col:
|
||||
col.tailwind.max_width("lg")
|
||||
ui.label(f"Host Name: {result.name}").classes("text-secondary")
|
||||
ui.label(f"Command: {result.command}").classes("text-secondary")
|
||||
timestamp = await ui.run_javascript(
|
||||
f"new Date({result.timestamp} * 1000).toLocaleString(undefined, {{dateStyle: 'short', timeStyle: 'short', hour12: 'false'}});"
|
||||
)
|
||||
ui.label(f"Timestamp: {timestamp}").classes("text-secondary")
|
||||
with ui.column() as col:
|
||||
col.tailwind.max_width("lg")
|
||||
ui.label(f"Task has failed: {result.failed}").classes("text-secondary")
|
||||
ui.label(f"Data is cached: {result.cached}").classes("text-secondary")
|
||||
ui.label(f"Host: {result.name}").classes("text-secondary")
|
||||
timestamp = await ui.run_javascript(
|
||||
f"new Date({result.timestamp} * 1000).toLocaleString(undefined, {{dateStyle: 'short', timeStyle: 'short', hour12: 'false'}});"
|
||||
)
|
||||
ui.label(f"Timestamp: {timestamp}").classes("text-secondary")
|
||||
ui.label(f"Return Code: {result.return_code}").classes("text-secondary")
|
||||
with el.Card() as card:
|
||||
with el.WColumn():
|
||||
terminal = cli.Terminal(options={"rows": 18, "cols": 120, "convertEol": True})
|
||||
|
||||
@@ -189,6 +189,7 @@ class Automation(Tab):
|
||||
var date = new Date(data.value * 1000).toLocaleString(undefined, {dateStyle: 'short', timeStyle: 'short', hour12: false});;
|
||||
return date;
|
||||
}""",
|
||||
"sort": "asc",
|
||||
},
|
||||
{
|
||||
"headerName": "Status",
|
||||
|
||||
@@ -34,7 +34,12 @@ class History(Tab):
|
||||
"rowSelection": "multiple",
|
||||
"paginationAutoPageSize": True,
|
||||
"pagination": True,
|
||||
"defaultColDef": {"resizable": True, "sortable": True, "suppressMovable": True, "sortingOrder": ["asc", "desc"]},
|
||||
"defaultColDef": {
|
||||
"resizable": True,
|
||||
"sortable": True,
|
||||
"suppressMovable": True,
|
||||
"sortingOrder": ["asc", "desc"],
|
||||
},
|
||||
"columnDefs": [
|
||||
{
|
||||
"headerName": "Host",
|
||||
@@ -57,6 +62,7 @@ class History(Tab):
|
||||
var date = new Date(data.value * 1000).toLocaleString(undefined, {dateStyle: 'short', timeStyle: 'short', hour12: false});;
|
||||
return date;
|
||||
}""",
|
||||
"sort": "desc",
|
||||
},
|
||||
{
|
||||
"headerName": "Status",
|
||||
|
||||
@@ -87,6 +87,7 @@ class Manage(Tab):
|
||||
var date = new Date(data.value * 1000).toLocaleString(undefined, {dateStyle: 'short', timeStyle: 'short', hour12: false});;
|
||||
return date;
|
||||
}""",
|
||||
"sort": "desc",
|
||||
},
|
||||
{"headerName": "Holds", "field": "userrefs", "filter": "agNumberColumnFilter", "maxWidth": 100},
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user