Hi
I need to change the icon for a row-action once the user clicks on row/row action icon in table.
I am trying through a row action snippet, not knowing how to get it done.
I gave the icon “fa-square-o”.
Every time the user selects a row, change icon to “
fa-check-square-o” and if other row is selected change icon back on to “fa-square-o”
Below is my snippet I tried:
var params = arguments[0],
$ = skuid.$;
//console.log(‘FROM the row action for SELECTION - params are BELOW’);
//console.log(params);
var model = params.model;
var item = params.item; //console.log(‘item ==========’); console.log(item);
var list = item.list; //console.log(‘item list =====’); console.log(list);
/**** REMOVE the hightlight for rest of rows;
WHILE removing highlight for row already selected , CLEAR the TEMP model and
* in the END after hightlighting current row , push the selected row into MODEL
*
****************************************/
$.each(list.renderedItems, function()
{
this.element.removeClass(‘highlighted-row’);
//this.element.removeClass(‘fa-check-square-o’);
});
/ Highlight the current-ROW ********/
item.element.addClass(‘highlighted-row’);
Question
how to change row-action icon once the user select a row/clicks on a row in skuid table
This topic has been closed for replies.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
