jQWidgets Forums

Forum Replies Created

Viewing 3 posts - 16 through 18 (of 18 total)
  • Author
    Posts
  • in reply to: fyltertype: date not working fyltertype: date not working #63221

    rubenfernande3
    Participant

    Sorry Peter, this is the real code that doesnt work. As you can see the column that i get (FechaSolicitud) is a date. As i said the same code with another kind of datasource (tested with xml) works perfectly showing the calendar icon when i fylter the date.
    My question is that if there is a known problem for this case.

    var source = null;
    function sourceInicial() {
    source =
    {
    datatype: “json”,
    datafields: [

    { name: ‘FechaSolicitud’, type: ‘date’, format: “dd/MM/yyyy HH:mm:ss” }

    ],
    sort: function () {
    $(“#jqxgrid”).jqxGrid(‘updatebounddata’, ‘sort’);
    },
    filter: function () {
    $(“#jqxgrid”).jqxGrid(‘updatebounddata’, ‘filter’);
    },
    beforeprocessing: function (data) {
    var returnData = {};
    data = data.d;
    totalrecords = data.count;
    returnData.totalrecords = data.count;
    returnData.records = data.data;
    return returnData;
    },
    type: ‘get’,
    sortcolumn: ‘FechaSolicitud’,
    sortdirection: ‘desc’,
    formatdata: function (data) {
    data.pagenum = data.pagenum || 0;
    data.pagesize = data.pagesize || 15;
    data.sortdatafield = data.sortdatafield || ‘FechaSolicitud’;
    data.sortorder = data.sortorder || ‘desc’;
    data.filterscount = data.filterscount || 0;
    formatedData = buildQueryString(data);
    return formatedData;
    },
    updaterow: function (rowid, newdata, commit) {
    updaterow(newdata);
    },
    url: ‘NotificacionCompras.aspx/GetSolicitudesPendientes’
    };

    dataAdapter = new $.jqx.dataAdapter(source, {
    contentType: ‘application/json; charset=utf-8’,
    loadError: function (xhr, status, error) {
    alert(error);
    }
    });

    }

    var dataAdapter = null;
    sourceInicial();

    $(“#jqxgrid”).jqxGrid(
    {
    width: 850,
    theme: ‘energyblue’,
    source: dataAdapter,
    filterable: true,

    sortable: true,
    virtualmode: true,
    pagesize: 15,
    rendergridrows: function (args) {
    return args.data;
    },
    ready: function () {

    },
    autoshowfiltericon: true,
    columns: [
    { text: ‘Servicio’, datafield: ‘FechaSolicitud’, width: “100%”, align: ‘center’, filtertype: ‘date’, columntype: ‘datetimeinput’

    }

    ]
    });

    });

    in reply to: rowdetail focus on click rowdetail focus on click #60159

    rubenfernande3
    Participant

    thanks for the response anyway Dimitar.


    rubenfernande3
    Participant

    Perfect. Excellent job guys!

Viewing 3 posts - 16 through 18 (of 18 total)