Merge pull request 'MTN6-169' (#95) from gug into main

Reviewed-on: #95
This commit is contained in:
gigi.mamaladze 2025-05-20 10:29:14 +00:00
commit 6f14ae8a5e
6 changed files with 300 additions and 235 deletions

View File

@ -83,4 +83,20 @@ div[data-component="ia.input.fileupload"] .ia_button--primary {
.psc-rotate {
animation: rotation 2s infinite linear;
}
}
#popup-errorPopup .ia_popup__header {
color: red;
font-weight: bold;
font-size: 16px;
}
#popup-errorPopup .ia_popup__header:before {
color: red;
content: "⛔ ";
font-weight: bold;
font-size: 16px;
padding-right: 4px;
}

File diff suppressed because one or more lines are too long

View File

@ -6,9 +6,9 @@
"$": [
"ts",
192,
1745914528657
1747730947188
],
"$ts": 1745914528656
"$ts": 1747730947187
}
}
},
@ -442,6 +442,81 @@
},
"type": "ia.container.flex"
},
{
"meta": {
"name": "Icon_1",
"tooltip": {
"enabled": true
}
},
"position": {
"basis": "30px"
},
"propConfig": {
"meta.tooltip.text": {
"binding": {
"config": {
"expression": "{[System]Gateway/Database/MariaDB/Available}"
},
"transforms": [
{
"fallback": "Database Connection Status: LOST",
"inputType": "scalar",
"mappings": [
{
"input": true,
"output": "Database Connection Status: GOOD"
},
{
"input": false,
"output": "Database Connection Status: LOST"
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "expr"
}
},
"props.color": {
"binding": {
"config": {
"expression": "{[System]Gateway/Database/MariaDB/Available}"
},
"transforms": [
{
"fallback": "#FF0000",
"inputType": "scalar",
"mappings": [
{
"input": true,
"output": "#47FF47"
},
{
"input": false,
"output": "#FF0000"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "expr"
},
"onChange": {
"enabled": null,
"script": " db_tag_path \u003d \"[System]Gateway/Database/MariaDB/Available\"\n\t\n if not (system.tag.readBlocking([db_tag_path])[0].value):\n \tsystem.perspective.openPopup(\"errorPopup\",\u0027PopUp-Views/DatabaseError\u0027, title\u003d\"Database Error\")\n\t"
},
"persistent": true
}
},
"props": {
"color": "#FF0000",
"path": "material/table_chart"
},
"type": "ia.display.icon"
},
{
"meta": {
"hasDelegate": true,

View File

@ -0,0 +1,17 @@
{
"scope": "G",
"version": 1,
"restricted": false,
"overridable": true,
"files": [
"view.json",
"thumbnail.png"
],
"attributes": {
"lastModification": {
"actor": "admin",
"timestamp": "2025-05-20T09:49:07Z"
},
"lastModificationSignature": "cb7026f671f17bc4ef7ebb50ab9735c971cb50752a412e2a4e14d784891500f5"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

View File

@ -0,0 +1,91 @@
{
"custom": {},
"params": {},
"props": {
"defaultSize": {
"height": 165,
"width": 400
}
},
"root": {
"children": [
{
"children": [
{
"meta": {
"name": "Label"
},
"position": {
"basis": "32px"
},
"props": {
"text": "An error occurred while connecting to the database."
},
"type": "ia.display.label"
},
{
"meta": {
"name": "Label_0"
},
"position": {
"basis": "32px"
},
"props": {
"text": "Network or database connection failed. Check your settings or contact IT support."
},
"type": "ia.display.label"
}
],
"meta": {
"name": "FlexContainer"
},
"position": {
"grow": 1
},
"props": {
"alignItems": "flex-start",
"direction": "column",
"justify": "space-around",
"style": {
"paddingLeft": 5,
"paddingRight": 5
}
},
"type": "ia.container.flex"
},
{
"events": {
"component": {
"onActionPerformed": {
"config": {
"script": "\tsystem.perspective.closePopup(\"\")"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "Button"
},
"props": {
"primary": false,
"style": {
"marginTop": 3
},
"text": "Dismiss"
},
"type": "ia.input.button"
}
],
"meta": {
"name": "root"
},
"props": {
"alignContent": "flex-start",
"direction": "column",
"justify": "space-around"
},
"type": "ia.container.flex"
}
}