-
Notifications
You must be signed in to change notification settings - Fork 2
Ho to show URL in text field
Kyryl Krylov, CPA edited this page Apr 8, 2020
·
1 revision
- Add the following properties to already defined Text filed
"showValueAsLink": true,
"href": {
"bindTo": "UsrFieldName",
"bindConfig": {"converter": "getUsrFieldNameLink"}
},
"controlConfig": {
"className": "Terrasoft.TextEdit",
"linkclick": { bindTo: "onUsrFieldNameLinkClick"}
}
- Add 2 methods
getUsrFieldNameLink: function(value) {
return {
"url": value,
"caption": value
};
},
onUsrFieldNameLinkClick: function(url) {
if (url != null) {
window.open(url, "_blank", "height=" + this.get("WindowHeight") + ",width=" + this.get("WindowWidth"));
return false;
}
}