Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Note

For the Cell Click and the Row Click events to function, the attribute data-single-click = "true" must be defined. As we are configuring the template for a column, we need to define the attribute data-column-id = 'columId<Column ID>' as well.

For example, when you click a textbox on the Reference Number column of the Beneficiary Details widget, the Cell Click event is raised.

...

Code Block
languagexml
<input 
	type = "text"
	data-single-click = "true"
	value = {{ BENE_ID }}
	data-column-id = "BENE_ID"
>
<!-- BENE_ID"
 is the Reference Number column's ID. -->

On a cell click, the column ID is returned followed by the template configuration (value) and the row details. On a row click the column ID is returned followed by the row details and the template configuration (value) as shown in the following image:

...

  • Cell Click event

    Code Block
    languagejs
    CWEH.registerHandler('BENE_WGT', CWEC.CELL_CLICK, function(columnId, value, record)
    {
    	LOGGER.info('The CELL_CLICK click event is triggered', [columnId, value, record]);
    });
    
    // Here, 'BENE_WGT' is the widget ID.


  • Row Click event

    Code Block
    languagejs
    CWEH.registerHandler('BENE_WGT', CWEC.ROW_CLICK, function(columnId, record, value)
    {
    	LOGGER.info('fired ROW_CLICK', [columnId, record, value]);
    });
    
    // Here, 'BENE_WGT' is the widget ID.


Cell Double-Click and Row Double-Click Events

The Cell Double Click event occurs when a cell is clicked twice. The Cell Double Click event also raises the Row Double Click event.

The Row Double Click event occurs when a row is clicked twice.

Note

For the Cell Double Click and the Row Double Click events to function, the attribute data-single-click = "true" must be defined. As we are configuring the template for a column, we need to define the attribute data-column-id = '<Column ID>' as well.