160 lines
4.1 KiB
Plaintext
160 lines
4.1 KiB
Plaintext
{
|
|
"custom": {},
|
|
"params": {},
|
|
"props": {
|
|
"defaultSize": {
|
|
"height": 400,
|
|
"width": 1600
|
|
}
|
|
},
|
|
"root": {
|
|
"children": [
|
|
{
|
|
"meta": {
|
|
"name": "Label"
|
|
},
|
|
"position": {
|
|
"height": 40,
|
|
"width": "100%"
|
|
},
|
|
"propConfig": {
|
|
"props.text": {
|
|
"binding": {
|
|
"config": {
|
|
"expression": "try(\r\n\tproperty(\"../TabContainer.props.tabs[\"+{../TabContainer.props.currentTabIndex}+\"]\"),\r\n\t\"No Configs\"\r\n)"
|
|
},
|
|
"type": "expr"
|
|
}
|
|
}
|
|
},
|
|
"props": {
|
|
"style": {
|
|
"backgroundColor": "#1A4A5E",
|
|
"borderBottomColor": "#000000",
|
|
"borderBottomStyle": "solid",
|
|
"borderBottomWidth": "2px",
|
|
"color": "#fff",
|
|
"fontFamily": "Helvetica",
|
|
"fontSize": 20,
|
|
"fontWeight": "bold",
|
|
"textAlign": "center"
|
|
}
|
|
},
|
|
"type": "ia.display.label"
|
|
},
|
|
{
|
|
"events": {
|
|
"component": {
|
|
"onActionPerformed": {
|
|
"config": {
|
|
"script": "\tsystem.perspective.sendMessage(\"export-data\")"
|
|
},
|
|
"scope": "G",
|
|
"type": "script"
|
|
}
|
|
}
|
|
},
|
|
"meta": {
|
|
"name": "Button"
|
|
},
|
|
"position": {
|
|
"height": 30,
|
|
"width": 100,
|
|
"x": "calc(100% - 105px)",
|
|
"y": 5
|
|
},
|
|
"props": {
|
|
"style": {
|
|
"classes": "Buttons/Grey"
|
|
},
|
|
"text": "Export"
|
|
},
|
|
"type": "ia.input.button"
|
|
},
|
|
{
|
|
"meta": {
|
|
"name": "TabContainer"
|
|
},
|
|
"position": {
|
|
"height": "calc(100% - 40px)",
|
|
"width": "100%",
|
|
"y": 40
|
|
},
|
|
"propConfig": {
|
|
"props.tabs": {
|
|
"binding": {
|
|
"config": {
|
|
"struct": {
|
|
"auth": "{session.props.auth.user.roles}",
|
|
"tabs": "{[default]Gateway/ConfigTabs}"
|
|
},
|
|
"waitOnAll": true
|
|
},
|
|
"transforms": [
|
|
{
|
|
"code": "\troles \u003d [\"Administrator\", \"Developer\", \"Supervisor\"]\n\tauth \u003d value.auth\n\ttabs \u003d value.tabs\n\tisNotAuth \u003d (auth \u003d\u003d None or len(auth) \u003d\u003d 0 or len([i for i in auth if i in roles]) \u003d\u003d 0)\n\treturn [v[\"title\"] for v in utils.datasetToJSON(tabs) if v[\"isVisible\"] and not (v[\"isSupervisor\"] and isNotAuth)]",
|
|
"type": "script"
|
|
}
|
|
],
|
|
"type": "expr-struct"
|
|
}
|
|
}
|
|
},
|
|
"props": {
|
|
"menuStyle": {
|
|
"backgroundColor": "#225E77"
|
|
},
|
|
"tabSize": {
|
|
"width": 140
|
|
},
|
|
"tabStyle": {
|
|
"active": {
|
|
"backgroundColor": "#2D7D9F",
|
|
"color": "#FFF",
|
|
"fontWeight": "bold"
|
|
},
|
|
"inactive": {
|
|
"backgroundColor": "#389CC7",
|
|
"color": "#FFF"
|
|
}
|
|
}
|
|
},
|
|
"type": "ia.container.tab"
|
|
},
|
|
{
|
|
"meta": {
|
|
"name": "EmbeddedView"
|
|
},
|
|
"position": {
|
|
"height": "calc(100% - 75px)",
|
|
"width": "100%",
|
|
"y": 75
|
|
},
|
|
"propConfig": {
|
|
"props.path": {
|
|
"binding": {
|
|
"config": {
|
|
"expression": " \"Windows/Configs/\"\r\n+replace(\r\n\tproperty(\"../TabContainer.props.tabs[\"+{../TabContainer.props.currentTabIndex}+\"]\"),\r\n\t\" \",\r\n\t\"\"\r\n)"
|
|
},
|
|
"type": "expr"
|
|
},
|
|
"persistent": true
|
|
}
|
|
},
|
|
"props": {
|
|
"path": "Windows/Configs/Shifts"
|
|
},
|
|
"type": "ia.display.view"
|
|
}
|
|
],
|
|
"meta": {
|
|
"name": "root"
|
|
},
|
|
"props": {
|
|
"style": {
|
|
"min-width": "1000px"
|
|
}
|
|
},
|
|
"type": "ia.container.coord"
|
|
}
|
|
} |