diff --git a/pagure/api/group.py b/pagure/api/group.py index d521cee..0b41dd2 100644 --- a/pagure/api/group.py +++ b/pagure/api/group.py @@ -63,7 +63,7 @@ def api_groups(): u'pagination': { 'first': 'http://localhost/api/0/groups?per_page=20&extended=1&page=1', 'last': 'http://localhost/api/0/groups?per_page=20&extended=1&page=1', - 'next': None, + 'next': null, 'page': 1, 'pages': 1, 'per_page': 20, diff --git a/pagure/api/issue.py b/pagure/api/issue.py index 87520b7..2b0e5b9 100644 --- a/pagure/api/issue.py +++ b/pagure/api/issue.py @@ -439,11 +439,17 @@ def api_view_issues(repo, username=None, namespace=None): { "assignee": null, "blocks": ["1"], + "close_status": null, + "closed_at": null, "comments": [], "content": "asd", + "custom_fields": [], "date_created": "1427442217", "depends": [], "id": 4, + "last_updated": "1533815358", + "milestone": null, + "priority": null, "private": false, "status": "Fixed", "tags": [ @@ -456,14 +462,14 @@ def api_view_issues(repo, username=None, namespace=None): } } ], - u'pagination': { + 'pagination': { 'first': 'http://localhost/api/0/test/issues?per_page=20&page=1', 'last': 'http://localhost/api/0/test/issues?per_page=20&page=1', - 'next': None, + 'next': null, 'page': 1, 'pages': 1, 'per_page': 20, - 'prev': None + 'prev': null }, } diff --git a/pagure/api/project.py b/pagure/api/project.py index f787d38..9470a23 100644 --- a/pagure/api/project.py +++ b/pagure/api/project.py @@ -406,6 +406,7 @@ def api_projects(): "parent": null, "priorities": {}, "tags": [], + "url_path": "test1", "user": { "fullname": "Matt Prahl", "name": "mprahl" @@ -437,6 +438,7 @@ def api_projects(): "parent": null, "priorities": {}, "tags": [], + "url_path": "test2", "user": { "fullname": "Matt Prahl", "name": "mprahl" diff --git a/pagure/api/user.py b/pagure/api/user.py index 986a96f..589236e 100644 --- a/pagure/api/user.py +++ b/pagure/api/user.py @@ -101,6 +101,15 @@ def api_view_user(username): "name": "pagure" } ], + "repos_pagination": { + "first": "http://localhost:5000/api/0/user/ralph?per_page=1&repopage=1", + "last": "http://localhost:5000/api/0/user/ralph?per_page=1&repopage=123", + "next": "http://localhost:5000/api/0/user/ralph?per_page=1&repopage=2", + "pages": 123, + "per_page": 1, + "prev": null, + "repopage": 1 + }, "user": { "fullname": "ralph", "name": "ralph" @@ -257,10 +266,13 @@ def api_view_user_issues(username): { "args": { + "assignee": true, + "author": true, "milestones": [], "no_stones": null, "order": null, "order_key": null, + "page": 1, "since": null, "status": null, "tags": [] @@ -321,6 +333,24 @@ def api_view_user_issues(username): } } ], + "pagination_issues_assigned": { + "first": "http://localhost:5000/api/0/user/anar/issues?per_page=1&page=1", + "last": "http://localhost:5000/api/0/user/anar/issues?per_page=1&page=0", + "next": null, + "page": 1, + "pages": 0, + "per_page": 1, + "prev": null + }, + "pagination_issues_created": { + "first": "http://localhost:5000/api/0/user/anar/issues?per_page=1&page=1", + "last": "http://localhost:5000/api/0/user/anar/issues?per_page=1&page=200", + "next": "http://localhost:5000/api/0/user/anar/issues?per_page=1&page=2", + "page": 1, + "pages": 200, + "per_page": 1, + "prev": null + }, "total_issues_assigned": 1, "total_issues_created": 1 } @@ -745,6 +775,15 @@ def api_view_user_requests_filed(username): "username": "dudemcpants", "page": 1, }, + "pagination": { + "first": "http://localhost:5000/api/0/user/dudemcpants/requests/filed?per_page=1&page=1", + "last": "http://localhost:5000/api/0/user/dudemcpants/requests/filed?per_page=1&page=61", + "next": "http://localhost:5000/api/0/user/dudemcpants/requests/filed?per_page=1&page=2", + "page": 1, + "pages": 61, + "per_page": 1, + "prev": null + }, "requests": [ { "assignee": null, @@ -975,6 +1014,15 @@ def api_view_user_requests_actionable(username): "username": "ryanlerch", "page": 1, }, + "pagination": { + "first": "http://localhost:5000/api/0/user/ryanlerch/requests/actionable?per_page=1&page=1", + "last": "http://localhost:5000/api/0/user/ryanlerch/requests/actionable?per_page=1&page=61", + "next": "http://localhost:5000/api/0/user/ryanlerch/requests/actionable?per_page=1&page=2", + "page": 1, + "pages": 61, + "per_page": 1, + "prev": null + }, "requests": [ { "assignee": null,