User Interface Customization
The UI can be customized using an external file.
The file format of the customization file is JSON. If the customization file is provided as a part of the custom static resource, the file must be named customization.json and placed in the top-level folder. The file should contain a single object. The object members are individual customization rules, where the member name is the selected attribute and the member value is the customization value.
Syntax for the customization rules:
<Object Type Name>#<Operation Name>#<Method Type>.<Parameter Name>
Syntax for the customization of references:
<Object Type Name>@<TeaReference Name>
The following is an example for customizing the references in the EMS sample provided with the product:
"EMS" : { "label": "TIBCO Enterprise Messaging Service", "app" : { "name": "ems-app", "modules": { "$strap.directives": "/tea/vendor/angularstrap/angular-strap.min.js", "ems": "scripts/ems.js" } }, "views": { "default": { "template": "partials/ems.html", "app": "ems-app" } } }, "EMS#registerEmsServer#UPDATE": { "label": "Register EMS Server" }, "EMS#registerEmsServer#UPDATE.serverName": { "label": "EMS Server Name" }, "EMS@members": { "title": "Servers", "columns": [ { "label": "name", "expr": "name", "entityLink": true }, { "label": "version", "expr": "config.versionInfo" }, { "label": "status", "expr": "status.state" } ] }, "server@queues": { "title": "Queues", "columns": [ { "label": "name", "expr": "name", "entityLink": true }, { "label": "pending message count", "expr": "config.pendingMessageCount" }, { "label": "pending message size", "expr": "config.pendingMessageSize" } ] }, "server@topics": { "title": "Topics", "columns": [ { "label": "name", "expr": "name", "entityLink": true }, { "label": "pending message count", "expr": "config.pendingMessageCount" }, { "label": "pending message size", "expr": "config.pendingMessageSize" } ] } }
code explanation:
The following additional properties can be set:
- "collapsed": this property can be set on a reference. If set, the panel containing the reference will be collapsed, on display.
- referenceOrder: is the order in which a reference is displayed. For example, "referenceOrder": ["foo", "bar"] indicates that "foo" is displayed before "bar".
- "confirm": this property can be set on an operation. If set to false, the confirmation dialog is skipped.
Usage
{ "CustomUI" : { "app" : { "name": "custom", "modules": { "dependency" : "scripts/dependency.module.js", "test" : "scripts/test.module.js" }, "libraries" : ["scripts/test.library.js"], "stylesheets" : ["css/test.css", "css/test1.css"] }, "views" : { "default": { "template": "mypage.html", "app": "custom" } } }, "CustomApp" : { "views" : { "default": { "template": "mygrouppage.html", "app": "custom" } } } }where the customization properties are as follows:
Copyright © Cloud Software Group, Inc. All Rights Reserved.