Sorting by date-de

Sorting by date-de

Kossin17Kossin17 Posts: 3Questions: 2Answers: 0

Hello! :)

A have code, its work good. I sorting date by plugin 'de_datetime'

https://datatables.net/plug-ins/sorting/date-de

var table = $('#historyOp').DataTable( {
        "language": {
            "url": "/assets/vendor/datatables/Russian.json"
        }
        ,"filter":     false
        ,"lengthChange": false
        /*,"order": [ [0,'DESC']]*/
        
        ,"drawCallback": function () {
          var api = this.api();
        }
        ,"columnDefs": [
            { "type": "de_datetime", targets: 0 }
        ]
    });

But, I need sorting DESC this colums.

If i add

,"order": [ [0,'DESC']]

give error
http://joxi.ru/KAg7zleC4WK9qA

How i can sorting this colum?

Answers

  • allanallan Posts: 63,461Questions: 1Answers: 10,466 Site admin

    Use desc, not DESC. It is case sensitive.

    Allan

This discussion has been closed.