jQWidgets Forums

jQuery UI Widgets Forums Grid Display "today" if the event is today

This topic contains 2 replies, has 2 voices, and was last updated by  AndySimpson 11 years ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author

  • AndySimpson
    Participant

    Hi guys,

    I have the following grid showing events only in the future:

     var source =
                            {
                                datatype: "json",
                                datafields: [ ...
                                    {name: 'start', type: 'date', format: "yyyy-MM-dd HH:mm"},
                                    {name: 'end', type: 'date', format: "yyyy-MM-dd HH:mm"},
                                   ...
                                ],
                               ...
                            };
    

    After that, a beforeLoadComplete function filters all entries in the past, displaying only future events.

    My grid:

    $("#jqxgrid").jqxGrid(
                            {
                               ....
                                source: dataAdapter,
                                columns: [
                                 ...
                                    {text: 'Von', dataField: 'start', width: 190, cellsformat: 'dddd.MM -- HH:mm', cellsalign: 'center'},
                                    {text: 'Bis', dataField: 'end', width: 190, cellsformat: 'dd.MM -- HH:mm', cellsalign: 'center'},
    
    

    This gives me something like this:
    Von: | Bis :
    Thursday.05 — 18:00 | 29.05 — 20:00

    The question: Is it possible to display “TODAY — 18:00” instead of “Thursday.05 — 18:00″?

    Best,
    Andy


    Peter Stoev
    Keymaster

    Hi Andy,

    If you implement cellsrenderer, you can display whatever HTML you wish in the cell, but we don’t have built-in code which will display Today – 18.00 or something like that.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com


    AndySimpson
    Participant

    Thanks for your fast reply Peter. I’ll give it a shot!

    cheers
    Andy

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.