Hello,
How can I add a button next to the (+) button on a detail.
See example.
thanks
Like
Hello,
Please use this code of UsrDetail schema as an example:
define("UsrDetail", [],
function() {
return {
entitySchemaName: "UsrDetailObject",
details: /**SCHEMA_DETAILS*/ {} /**SCHEMA_DETAILS*/ ,
diff: [
{
"operation": "insert",
"name": "AssignContactButton",
"parentName": "Detail",
"propertyName": "tools",
"values": {
"itemType": Terrasoft.ViewItemType.BUTTON,
"caption": {"bindTo": "Resources.Strings.AssignContactButtonCaption"},
"click": {"bindTo": "onAssignContactButtonClick"},
"style": Terrasoft.controls.ButtonEnums.style.TRANSPARENT,
"enabled": {"bindTo": "isAnySelected"}
}
}
],
methods: {
onAssignContactButtonClick: function() {
//logic
}
}
};
This will create a button on the detail and you will only need to add additional logic to this detail (where //logic comment is located).
Best regards,
Oscar