Author Topic: ParamQuery ColModel  (Read 3926 times)

igor

  • Newbie
  • *
  • Posts: 3
    • View Profile
ParamQuery ColModel
« on: August 28, 2014, 07:50:26 pm »
Hi, we use the free version of param query and a weird situation is happening.
a well defined grid doesn't show the column model header.
what can be the cause to that ?

I have attached the grid initialization.
with the sample code it works ok, but not with my code.

var netColModel = [
                  { title: "CIDR Address", width: 100 },
                  { title: "Network Name", width: 100 }
                 ];
                  
   var netDataModel = [["345345","dfgdfg"],["234234","66565fg"]];
   
   var netGrid = $('#net-grid').pqGrid({ height: 440, width: 800,
        dataModel:  { data: netDataModel },
        colModel: netColModel,
        title: "Grid",
        resizable: true,
        draggable: false,
        columnBorders: true,
        sortable: false,
      editable: false,
      selectionModel: {type: 'row', mode: 'single'},
        scrollModel: {horizontal: false}
    });

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: ParamQuery ColModel
« Reply #1 on: August 28, 2014, 07:57:32 pm »
I don't see any problem here

http://jsfiddle.net/paramquery/n337xLf7/

Is that happening in a particular browser or have you been using some other libraries besides jQuery/jQueryUI.

igor

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: ParamQuery ColModel
« Reply #2 on: August 28, 2014, 08:06:12 pm »
We use additional plugins based on jquery and some of our own.
Also, sometimes we get "can't find children of null" type error, I am not sure that this is related though, and
a "cannot call methods on pqScrollBar prior to initialization; attempted to call method 'option'" exception, which means that we place the init code of the grid at an incorrect place.

Is there a certain spot this code should appear in code when writing JS ?
« Last Edit: August 28, 2014, 08:13:32 pm by igor »