Author Topic: AddClass not setting color on cell  (Read 2394 times)

kshipra

  • Pro Enterprise
  • Jr. Member
  • *
  • Posts: 94
    • View Profile
AddClass not setting color on cell
« on: March 29, 2017, 03:02:23 am »

   {
                    type: 'button',
                    label: 'Add Class',
                    listener: function (ui) {
                       
                        var dataIndx = $(".sl_dataIndx").val() ? $(".sl_dataIndx").val() : null;
                   
                        this.addClass({
                            rowIndx: $(".sl_rowIndx").val(),
                            dataIndx: dataIndx,
                            cls: $(".sl_class").val()
                        });
                     
                    }
                },

AddClass button in toolbar has above code. When I inspect the cell it has blue color, but cell is not colored blue

<td class="pq-grid-cell blue" pq-col-indx="2" title="Tom Jones">Tom Jones</td>

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: AddClass not setting color on cell
« Reply #1 on: March 31, 2017, 02:47:51 pm »
Simply adding a class named blue doesn't affect the color of any element, you have to assign required styles to the class in css.