jQWidgets Forums

jQuery UI Widgets Forums Grid error date filter

Tagged: 

This topic contains 2 replies, has 1 voice, and was last updated by  Hugo 10 years, 8 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • error date filter #61609

    Hugo
    Participant

    guys, I’m having problem with one of two column type date

    Column “Date 1”:
    when I select a date -> Uncaught TypeError: Cannot read property ‘toString’ of null
    when you clean the filter -> Uncaught TypeError: Cannot read property ‘filtercolumn’ of undefined

    Column “Date 2”:
    no problem!

    
    // Source
    ...
    datafields: [
        ...
        { name: 'date_one', type: 'date' },
        { name: 'date_two', type: 'date' }
    ],
    ...
    
    // Column
    {
      text: 'Date 1',
      datafield: 'date_one',
      width: 90,
      align: 'right',
      cellsalign: 'right',
      cellsformat: 'd',
      columngroup: 'My',
      editable: false,
      filtertype: 'date'
    },
    {
      text: 'Date 2',
      datafield: 'date_two',
      width: 90,
      align: 'right',
      cellsalign: 'right',
      cellsformat: 'd',
      columngroup: 'My',
      editable: false,
      filtertype: 'date'
    }
    
    // My localization
    localizationobj.patterns = {
      d: "dd/MM/yyyy"
    };
    
    error date filter #61612

    Hugo
    Participant

    guys, i noticed that in the second column the date is not in the correct format

    return php example: dd/MM/yyyy

    
    '05/10/2014' // Date 1
    '20/10/2014' // Date 2
    

    They appear in the jqxGrid is as follows:

    
    Date 1: 05/10/2014 // correct
    Date 2: 10/05/2014 // incorrect
    

    see above that is configured correctly or not?

    error date filter #61615

    Hugo
    Participant

    Solved!

    Include objects below in the two columns

    
    ..., cellsformat: 'dd/MM/yyyy', columntype: 'inputdate', ...
    
Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.