Question

Add button to row section

Hi community!

How are you?

How could I add a button on row section?

Thanks you!

Regards,

Ezequiel!

Like 0

Like

2 comments

Please investigate the code in the basesectionv2 module. Please use google chrome dev tools for the investigation.

You can create a replacing client module for the section and add the button in the same way as other buttons were added. 

http://prntscr.com/kqgyym

Additionally, you'll need to override the "onActiveRowAction" method and add a handler for the button. 

http://prntscr.com/kqgzs4

 

Miroslav Kytka,

define("AccountSectionV2", ["AccountSectionV2Resources"], function(resources) {
	return {
		entitySchemaName: "Account",
		details: /**SCHEMA_DETAILS*/{}/**SCHEMA_DETAILS*/,
		diff: /**SCHEMA_DIFF*/[
			{
				"operation": "insert",
				"name": "MyCustomLockAction",
				"parentName": "DataGrid",
				"propertyName": "activeRowActions",
				"values": {
					"className": "Terrasoft.Button",
					"style": Terrasoft.controls.ButtonEnums.style.BLUE,
					"caption": resources.localizableStrings.UsrLockCaption, 
					"tag": "lock",
					"enabled": true,
					"visible": true
				}
			}
		]/**SCHEMA_DIFF*/,
		methods: {}
	};
});

 

Show all comments