Hello!
how are you?
I hope your can help me!
I have a button in EmployeePage, when I press the button call to method "downloadFile" in property "click". I want call to this method from various bottons but passing a distinct parameter for each button. Example:
{
"operation": "insert",
"name": "DownloadFileButton",
"values": {
"itemType": 5,
"imageConfig": {
"bindTo": "Resources.Images.FilesImage"
},
"click": {
"bindTo": "downloadFile"
//Pass parameter
},
"visible": true
"enabled": {
"bindTo": "UsrClaveAltaTemprana"
},
//Button Tooltip
"hint": {
"bindTo": "Resources.Strings.MensajeTooltipDownload"
},
"markerValue": "DownloadFileButton",
"layout": {
"colSpan": 1,
"rowSpan": 1,
"column": 11,
"row": 0
}
},
"parentName": "Taba317b6dcTabLabelGridLayout3826b978",
"propertyName": "items",
"index": 1
},
{
"operation": "insert",
"name": "DownloadFileButton2",
"values": {
"itemType": 5,
"imageConfig": {
"bindTo": "Resources.Images.FilesImage"
},
"click": {
"bindTo": "downloadFile"
//pass parameter
},
"visible": true
"enabled": {
"bindTo": "UsrClaveBajaTemprana"
},
//Button Tooltip
"hint": {
"bindTo": "Resources.Strings.MensajeTooltipDownload"
},
"markerValue": "DownloadFileButton2",
"layout": {
"colSpan": 1,
"rowSpan": 1,
"column": 11,
"row": 1
}
},
"parentName": "Taba317b6dcTabLabelGridLayout3826b978",
"propertyName": "items",
"index": 1
},
//method
methods: {
//method with parameter
downloadFile: function(parameter) {
var p = parameter;
if (p == "A")
//do some thing
else
//do some thing
}
I appreciated your help!
King Regards!
Ezequiel Gómez