ParamQuery grid support forum

General Category => Help for ParamQuery Pro => Topic started by: mikep on July 29, 2021, 08:38:24 pm

Title: Adding column with indicator icos
Post by: mikep on July 29, 2021, 08:38:24 pm
Do you have any example on how to create a column that can contain 0 to many indicator icons, based on the row's data?
Title: Re: Adding column with indicator icons
Post by: mikep on July 30, 2021, 06:47:24 pm
I updated the Subject line to "icons"
Title: Re: Adding column with indicator icos
Post by: paramvir on July 31, 2021, 01:59:44 pm
Please use column.render callback

Code: [Select]
render: function(ui){
  var rd = ui.rowData;
  if ( condition based on rd ){
    //return html for rendering icons / images.
  }
}
Title: Re: Adding column with indicator icons
Post by: mikep on August 04, 2021, 12:44:03 am
-What is syntax to add an icon to a column?
-Do I need to create a column for each icon? If not, how do I show/hide each icon in a single column?
Title: Re: Adding column with indicator icos
Post by: paramvir on August 04, 2021, 09:40:03 am
Any no of icons can be displayed in a single column.

Code: [Select]
<img src='path to icon1'/>
<img src='path to icon2'/>
...