{"action":"created","issue":{"url":"https://api.github.com/repos/olifolkerd/tabulator/issues/142","repository_url":"https://api.github.com/repos/olifolkerd/tabulator","labels_url":"https://api.github.com/repos/olifolkerd/tabulator/issues/142/labels{/name}","comments_url":"https://api.github.com/repos/olifolkerd/tabulator/issues/142/comments","events_url":"https://api.github.com/repos/olifolkerd/tabulator/issues/142/events","html_url":"https://github.com/olifolkerd/tabulator/issues/142","id":197198068,"number":142,"title":"Access sort options in custom paginator","user":{"login":"Gonzalo788","id":24566273,"avatar_url":"https://avatars.githubusercontent.com/u/24566273?v=3","gravatar_id":"","url":"https://api.github.com/users/Gonzalo788","html_url":"https://github.com/Gonzalo788","followers_url":"https://api.github.com/users/Gonzalo788/followers","following_url":"https://api.github.com/users/Gonzalo788/following{/other_user}","gists_url":"https://api.github.com/users/Gonzalo788/gists{/gist_id}","starred_url":"https://api.github.com/users/Gonzalo788/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gonzalo788/subscriptions","organizations_url":"https://api.github.com/users/Gonzalo788/orgs","repos_url":"https://api.github.com/users/Gonzalo788/repos","events_url":"https://api.github.com/users/Gonzalo788/events{/privacy}","received_events_url":"https://api.github.com/users/Gonzalo788/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-12-22T15:24:15Z","updated_at":"2016-12-24T11:49:27Z","closed_at":"2016-12-24T11:49:27Z","body":"I wrote a custom paginator which you can see below. Is there any chance to access the sort parameters from tabular to pass it to the url. \r\n\r\n```\r\n\tpaginator: function(url, pageNo, pageSize, ajaxParams ){\r\n\t\tvar searchValue = $(\"#inpit-id\").val();\r\n\t\t\r\n\t\tvar queryParameters = {\r\n\t\t\tpage: pageNo,\r\n\t\t\tsize: pageSize\r\n\t\t};\r\n\t\t\r\n\t\tif(searchValue != \"\") {\r\n\t\t\tqueryParameters[\"filter_value\"] = searchValue;\r\n\t\t}\r\n\t\t\r\n\t\tqueryParameters[\"sort\"] = ajaxParams;\r\n\t\t\r\n\t\treturn url + \"?\" + $.param(queryParameters);\r\n\t}\r\n```"},"comment":{"url":"https://api.github.com/repos/olifolkerd/tabulator/issues/comments/269081297","html_url":"https://github.com/olifolkerd/tabulator/issues/142#issuecomment-269081297","issue_url":"https://api.github.com/repos/olifolkerd/tabulator/issues/142","id":269081297,"user":{"login":"olifolkerd","id":6840524,"avatar_url":"https://avatars.githubusercontent.com/u/6840524?v=3","gravatar_id":"","url":"https://api.github.com/users/olifolkerd","html_url":"https://github.com/olifolkerd","followers_url":"https://api.github.com/users/olifolkerd/followers","following_url":"https://api.github.com/users/olifolkerd/following{/other_user}","gists_url":"https://api.github.com/users/olifolkerd/gists{/gist_id}","starred_url":"https://api.github.com/users/olifolkerd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/olifolkerd/subscriptions","organizations_url":"https://api.github.com/users/olifolkerd/orgs","repos_url":"https://api.github.com/users/olifolkerd/repos","events_url":"https://api.github.com/users/olifolkerd/events{/privacy}","received_events_url":"https://api.github.com/users/olifolkerd/received_events","type":"User","site_admin":false},"created_at":"2016-12-24T11:49:27Z","updated_at":"2016-12-24T11:49:27Z","body":"You can use the ***getSort*** function:\r\n\r\n```js\r\n$(\"#example-table\").tabulator(\"getSort\");\r\n```\r\n\r\nThis will return an object with the sort information as properties:\r\n```js\r\n{\r\n    field:\"name\", //field name\r\n    dir:\"asc\", //sort direction (asc|desc)\r\n}\r\n```"}}
{"actor":{"display_login":"olifolkerd"}}