Commit 02282705 authored by JonathanMM's avatar JonathanMM

Fix #3 : Mauvais tri des dates

parent e8c456d7
......@@ -125,6 +125,9 @@
if(data == 'Non ouvert')
return data;
var date = new Date(data);
if(type == 'sort') //Pour le tri, on fait en sorte que la valeur soit triable
return date.getFullYear() + '-' + putZero(date.getMonth()+1) + '-' + putZero(date.getDate());
return putZero(date.getDate()) + '/' + putZero(date.getMonth()+1) + '/' + date.getFullYear();
}
},{
......
......@@ -122,6 +122,8 @@
if(data == 'Non ouvert')
return data;
var date = new Date(data);
if(type == 'sort') //Pour le tri, on fait en sorte que la valeur soit triable
return date.getFullYear() + '-' + putZero(date.getMonth()+1) + '-' + putZero(date.getDate());
return putZero(date.getDate()) + '/' + putZero(date.getMonth()+1) + '/' + date.getFullYear();
}
},{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment