Sencha Touch: List sorted on Date not working in Android Emulator -
i have list view , sorting items based on date. sorting done in store
ext.define('techhelp.store.tickets', { extend: 'ext.data.store', config: { model: 'techhelp.model.ticket', autoload: true, sorters:[{ property: 'opendate', direction: 'desc'}], grouper: { sortproperty: 'opendate', direction: 'desc', groupfn: function (record) { if (record && record.data.opendate) { return convertdate(record.data.opendate); } else { return ''; } } } } });
the convertdate code is
function convertdate(rec){ var formated = ext.date.format(new date(rec),'d-m-y'); return formated; }
this seems work fine in chrome browser, when package native app , run in android emulator date appears nan , therefore sorting on list not work.
if has faced issue please let me know how resolved it
thanks p
in model techhelp.model.ticket
, type
property of field opendate
set date?
Comments
Post a Comment