155 lines
3.9 KiB
Plaintext
155 lines
3.9 KiB
Plaintext
{
|
|
"custom": {
|
|
"activityLogger": {
|
|
"alt_pageid": "tools",
|
|
"start_time": {
|
|
"$": [
|
|
"ts",
|
|
192,
|
|
1716471122012
|
|
],
|
|
"$ts": 1716471122012
|
|
}
|
|
}
|
|
},
|
|
"events": {
|
|
"system": {
|
|
"onShutdown": {
|
|
"config": {
|
|
"script": "\tactivityLog.productMetrics.callLogger(self, \u0027page\u0027)"
|
|
},
|
|
"scope": "G",
|
|
"type": "script"
|
|
},
|
|
"onStartup": {
|
|
"config": {
|
|
"script": "\tself.session.custom.view_in_focus \u003d self.page.props.path\n\tself.custom.activityLogger.start_time \u003d system.date.now()"
|
|
},
|
|
"scope": "G",
|
|
"type": "script"
|
|
}
|
|
}
|
|
},
|
|
"params": {},
|
|
"propConfig": {
|
|
"custom.activityLogger": {
|
|
"persistent": true
|
|
},
|
|
"custom.activityLogger.pageid": {
|
|
"binding": {
|
|
"config": {
|
|
"expression": "{/root.props.currentTabIndex}"
|
|
},
|
|
"transforms": [
|
|
{
|
|
"code": "\tpageid\u003d self.custom.activityLogger.alt_pageid+\u0027/\u0027+self.getChild(\"root\").props.tabs[value]\n\treturn pageid.replace(\u0027 \u0027,\u0027\u0027)",
|
|
"type": "script"
|
|
}
|
|
],
|
|
"type": "expr"
|
|
}
|
|
}
|
|
},
|
|
"props": {
|
|
"defaultSize": {
|
|
"height": 1080,
|
|
"width": 1920
|
|
}
|
|
},
|
|
"root": {
|
|
"children": [
|
|
{
|
|
"meta": {
|
|
"name": "CommissioningTool"
|
|
},
|
|
"props": {
|
|
"path": "Main-Views/Commissioning Tool/CT_Main"
|
|
},
|
|
"type": "ia.display.view"
|
|
},
|
|
{
|
|
"meta": {
|
|
"name": "S3"
|
|
},
|
|
"position": {
|
|
"tabIndex": 1
|
|
},
|
|
"propConfig": {
|
|
"props.params.selected_site": {
|
|
"binding": {
|
|
"config": {
|
|
"path": "session.custom.fc"
|
|
},
|
|
"type": "property"
|
|
}
|
|
}
|
|
},
|
|
"props": {
|
|
"params": {
|
|
"selected_image": null
|
|
},
|
|
"path": "Main-Views/S3/manage"
|
|
},
|
|
"type": "ia.display.view"
|
|
},
|
|
{
|
|
"meta": {
|
|
"name": "NotifyTool"
|
|
},
|
|
"position": {
|
|
"tabIndex": 2
|
|
},
|
|
"props": {
|
|
"path": "Main-Views/Notify-Tool/Notify-Main"
|
|
},
|
|
"type": "ia.display.view"
|
|
},
|
|
{
|
|
"meta": {
|
|
"name": "EmbeddedView"
|
|
},
|
|
"position": {
|
|
"tabIndex": 3
|
|
},
|
|
"props": {
|
|
"path": "Main-Views/Config-Tool/MainView"
|
|
},
|
|
"type": "ia.display.view"
|
|
}
|
|
],
|
|
"meta": {
|
|
"name": "root"
|
|
},
|
|
"propConfig": {
|
|
"props.currentTabIndex": {
|
|
"onChange": {
|
|
"enabled": null,
|
|
"script": "\ttry:\n\t\tpageid \u003d self.view.custom.activityLogger.alt_pageid + \u0027/\u0027+ self.props.tabs[previousValue.value]\n\t\tpageid \u003d pageid.replace(\u0027 \u0027,\u0027\u0027)\n\t\tpayload \u003d activityLog.productMetrics.createActivityPayload(self.view, \u0027page\u0027, pageid, pageid)\n\t\tif payload:\n\t\t\tself.view.custom.activityLogger.start_time \u003d system.date.now()\n\t\t\tsystem.perspective.sendMessage(\u0027activityLogger-TabChanged\u0027, payload \u003d payload, scope \u003d \u0027page\u0027)\n\texcept:\n\t\tpass"
|
|
}
|
|
}
|
|
},
|
|
"props": {
|
|
"currentTabIndex": 3,
|
|
"tabs": [
|
|
"CT",
|
|
"S3",
|
|
"Notify Tool",
|
|
"Site Config"
|
|
]
|
|
},
|
|
"scripts": {
|
|
"customMethods": [],
|
|
"extensionFunctions": null,
|
|
"messageHandlers": [
|
|
{
|
|
"messageType": "activityLogger-TabChanged",
|
|
"pageScope": true,
|
|
"script": "\t# implement your handler here\n\tif payload:\n\t\tactivityLog.productMetrics.callActivityLoggerAPI(payload)\n",
|
|
"sessionScope": false,
|
|
"viewScope": false
|
|
}
|
|
]
|
|
},
|
|
"type": "ia.container.tab"
|
|
}
|
|
} |