{"action":"created","issue":{"url":"https://api.github.com/repos/l-lin/angular-datatables/issues/313","labels_url":"https://api.github.com/repos/l-lin/angular-datatables/issues/313/labels{/name}","comments_url":"https://api.github.com/repos/l-lin/angular-datatables/issues/313/comments","events_url":"https://api.github.com/repos/l-lin/angular-datatables/issues/313/events","html_url":"https://github.com/l-lin/angular-datatables/issues/313","id":76745782,"number":313,"title":"Sorting and formatting","user":{"login":"RoelRoel","id":531248,"avatar_url":"https://avatars.githubusercontent.com/u/531248?v=3","gravatar_id":"","url":"https://api.github.com/users/RoelRoel","html_url":"https://github.com/RoelRoel","followers_url":"https://api.github.com/users/RoelRoel/followers","following_url":"https://api.github.com/users/RoelRoel/following{/other_user}","gists_url":"https://api.github.com/users/RoelRoel/gists{/gist_id}","starred_url":"https://api.github.com/users/RoelRoel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RoelRoel/subscriptions","organizations_url":"https://api.github.com/users/RoelRoel/orgs","repos_url":"https://api.github.com/users/RoelRoel/repos","events_url":"https://api.github.com/users/RoelRoel/events{/privacy}","received_events_url":"https://api.github.com/users/RoelRoel/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/l-lin/angular-datatables/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":15,"created_at":"2015-05-15T14:35:52Z","updated_at":"2015-09-07T15:12:34Z","closed_at":"2015-05-21T12:05:18Z","body":"How to use this: \r\nhttps://datatables.net/blog/2014-12-18\r\n\r\nIn combination with angular-datatables? I tried a dosen of things but noting works."},"comment":{"url":"https://api.github.com/repos/l-lin/angular-datatables/issues/comments/138322331","html_url":"https://github.com/l-lin/angular-datatables/issues/313#issuecomment-138322331","issue_url":"https://api.github.com/repos/l-lin/angular-datatables/issues/313","id":138322331,"user":{"login":"l-lin","id":5452304,"avatar_url":"https://avatars.githubusercontent.com/u/5452304?v=3","gravatar_id":"","url":"https://api.github.com/users/l-lin","html_url":"https://github.com/l-lin","followers_url":"https://api.github.com/users/l-lin/followers","following_url":"https://api.github.com/users/l-lin/following{/other_user}","gists_url":"https://api.github.com/users/l-lin/gists{/gist_id}","starred_url":"https://api.github.com/users/l-lin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/l-lin/subscriptions","organizations_url":"https://api.github.com/users/l-lin/orgs","repos_url":"https://api.github.com/users/l-lin/repos","events_url":"https://api.github.com/users/l-lin/events{/privacy}","received_events_url":"https://api.github.com/users/l-lin/received_events","type":"User","site_admin":false},"created_at":"2015-09-07T15:12:34Z","updated_at":"2015-09-07T15:12:34Z","body":"> The -pre function is used as an optimisation - it calculated the data to be sorted, so it is only ever called once for every cell. Then the built in sorter can simply sort the data without needing to call external functions - a two fold optimisation.\r\n> If you do want the `-asc` and `-desc` functions to be called, don't provide `-pre`.\r\n\r\nSee [Allan's post](http://datatables.net/forums/discussion/21104/custom-sorting-asc-desc-not-called-when-pre-is-present#Comment_61099)."}}