Forum Replies Created

Viewing 15 posts - 1 through 15 (of 22 total)
  • Author
    Posts

  • jonfrain
    Participant

    I’m doing something like the following to handle it:

    if (myJsonData1.length == 0) {
    currentDataOpened.find(“.jqxchart1”).jqxChart({title: ‘No Data to Plot’});
    currentDataOpened.find(“.jqxchart1″).jqxChart({description: ”});

    currentDataOpened.find(“.jqxchart1”).jqxChart({enabled: false});
    }

    in reply to: Weird filtering bug Weird filtering bug #56447

    jonfrain
    Participant

    Any help or advice?

    Is there an easy way to clear the column filters on grid load to at least prevent the nasty bug?

    in reply to: Weird filtering bug Weird filtering bug #56378

    jonfrain
    Participant

    I’m not sure if I’ll get a response to this. Is there a good place to call

    jqxGrid(‘clearfilters’);

    When reloading the grid? Putting it in the ready function didn’t seem to have an affect and I’m trying to find a short term fix of clearing the filters on reload.

    in reply to: Weird filtering bug Weird filtering bug #56374

    jonfrain
    Participant

    I sure wish I could edit posts. Anyway, I assume that sorting makes a second call to get data and filtering makes a third and somehow gets messed up in updating the bounddata on grid redraw?

    sort: function (){                                               
       currentDataOpened.find("."+currentGrid).jqxGrid('updatebounddata');
    },
    
    filter: function () {  
       //var str = 'currentDataOpened= ' + currentDataOpened + "  currentGrid = " + currentGrid;
       //console.log(str);
       currentDataOpened.find("."+currentGrid).jqxGrid('updatebounddata', 'filter');
    }
    in reply to: Weird filtering bug Weird filtering bug #56372

    jonfrain
    Participant

    For sorting, the call for grid data occurs twice which is one too many but they are both formed properly. Somehow the filtering adds a third call.

    in reply to: Weird filtering bug Weird filtering bug #56371

    jonfrain
    Participant

    What I’m actually seeing is one call to get the headers and three calls to get the data:

    6.	Request Payloadview source
    {location_descriptionoperator:and, filtervalue0:orange, filtercondition0:CONTAINS, filteroperator0:0,…}
    1.	data: "data"
    2.	expansion: "expansion1"
    3.	filtercondition0: "CONTAINS"
    4.	filterdatafield0: "location_description"
    5.	filteroperator0: 0
    6.	filterscount: 1
    7.	filtervalue0: "orange"
    8.	grid: "jqxgrid1"
    9.	groupscount: 0
    10.	location_descriptionoperator: "and"
    11.	module: "intransit"
    12.	pagenum: 0
    13.	pagesize: 10
    14.	recordendindex: 10
    15.	recordstartindex: 0
    

    The request above properly returns 1 row of data

    6.	Request Payloadview source
    {location_descriptionoperator:and, filtervalue0:orange, filtercondition0:CONTAINS, filteroperator0:0,…}
    1.	data: "data"
    2.	expansion: "expansion1"
    3.	filtercondition0: "CONTAINS"
    4.	filterdatafield0: "location_description"
    5.	filteroperator0: 0
    6.	filterscount: 1
    7.	filtervalue0: "orange"
    8.	grid: "jqxgrid1"
    9.	groupscount: 0
    10.	location_descriptionoperator: "and"
    11.	module: "intransit"
    12.	pagenum: 0
    13.	pagesize: 10
    14.	recordendindex: 10
    15.	recordstartindex: 0
    

    The request above is exactly identical to the first one and properly returns 1 row of data

    6.	Request Payloadview source
    {filterscount:0, groupscount:0, pagenum:0, pagesize:10, recordstartindex:0, recordendindex:10,…}
    1.	data: "data"
    2.	expansion: "expansion1"
    3.	filterscount: 0
    4.	grid: "jqxgrid1"
    5.	groupscount: 0
    6.	module: "intransit"
    7.	pagenum: 0
    8.	pagesize: 10
    9.	recordendindex: 10
    10.	recordstartindex: 0
    

    This request is completely missing the filtering info and wants to return 34 rows of data but the grid is already locked to just one row. The grid on teh screen shows one empty row and a never ending loading symbol

    in reply to: Weird filtering bug Weird filtering bug #56367

    jonfrain
    Participant

    I think eventually I’ll want to store all filter settings per grid on the server, but for now I could close the grid and make them reset the filters in the short term.


    jonfrain
    Participant

    I’m posting the answer in case someone goes searching.

    I’m not sure why this works but it does. I’ve taken the code from the post linked above and modified it. I’ve commented out the actual return and just set the tooltip value directly. I assume I can get rid of the return somehow.

    My question is how does columnHeaderElement get passed in to the internal function.

    // centers each heading
    var headerTooltipRenderer = function(text) {                     
         return function (columnHeaderElement) {
              $(columnHeaderElement).jqxTooltip( {position: 'mouse', content: text } );
              //return "<div style='margin-left: 10px;margin-top: 5px' title='" + text + "'>" + columnHeaderElement + "</div>";
              return;
         };
    };

    Here is how the function is called with the custom argument

    // eventually use variable for field widths //width: entry1.grid_field_width
    var dataColsRow = { text: entry.display_name, 
                        datafield: entry.attribute_var_name, 
                        width: entry.grid_field_width_percent, 
                        minwidth: 200, 
                        cellsformat: cellsFormat,
                        cellsalign: cellsAlign,
                        renderer: columnsrenderer,
                        rendered: headerTooltipRenderer(entry.tooltip) 
                   };                                                
    myColumns.push(dataColsRow);

    jonfrain
    Participant

    I just found the following post which shows a wrapper method.

    http://www.jqwidgets.com/community/topic/tool-tip-for-column/

    Hopefully that method of doing it still works.


    jonfrain
    Participant

    Is there a way to add custom information that I can get access to? Right now I don’t see where to tell the grid to use a specific piece of text for the tooltip.

    How could I tell the grid what tooltip text I want and then access it in the tooltiprenderer method?


    jonfrain
    Participant

    I should say that the method obviously needs the element, but I’m wondering if I can tie a new cosutm value to the element that is retrievable or add a second parameter with the tooltip I want assigned.


    jonfrain
    Participant

    I guess I’m asking if the grid can be drawn but not be in focus.


    jonfrain
    Participant

    It happens even if I click outside of the grid and try to scroll down


    jonfrain
    Participant

    I just figured it out. I misused minwidth as it isn’t in ‘100px’ format it is inn just 100 format.


    jonfrain
    Participant

    I’m not actually using autowidth in this example. Any thoughts on why the minwidth is being overridden and it’s only using %

Viewing 15 posts - 1 through 15 (of 22 total)