24pullrequests/24pullrequests — pull request #834 by blainesch (2014-12-15 17:25:39+00:00)
Title: Add meta information to the pull requests endpoint.

On the dashboard we want the last display to be the "total pull requests" so instead of making hundreds of api requests, I figured this would be a little nicer.

~~~
-> % curl -i http://127.0.0.1:3000/pull_requests/meta.json
HTTP/1.1 200 OK
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
Content-Type: application/json; charset=utf-8
ETag: "62ea61d4dfb933326182e82e25183552"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: 91d55997-5b54-4b10-9d4e-c8a9f5267866
X-Runtime: 0.084581
Vary: Accept-Encoding
Connection: close
Server: thin

{"count":563,"total_pages":23}
~~~

The html view just mirrors the pull_requests html endpoint.