-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* indexer: rename GetListAccounts -> AccountsList * indexer: AccountsList, ProcessList and EntityList now return a TotalCount * indexer: EntityList inverted order of args (from, max) to be consistent with others * test: add TestAPIAccountsList and TestAPIElectionsList * api: unify hardcoded structs into a new types: * AccountsList * ElectionsList * OrganizationsList * CountResult * api: add `pagination` field to endpoints: * GET /elections * GET /accounts * GET /chain/organizations * api: refactor filtered endpoints to unify pagination logic (and add `pagination` field): * GET /accounts/{organizationID}/elections/status/{status}/page/{page} * GET /accounts/{organizationID}/elections/page/{page} * GET /elections/page/{page} * POST /elections/filter/page/{page} * GET /chain/organizations/page/{page} * POST /chain/organizations/filter/page/{page} * GET /accounts/page/{page} also, marked all of these endpoints as deprecated on swagger docs * api: return ErrPageNotFound on paginated endpoints, when page is negative or higher than last_page * api: deduplicate several code snippets, with marshalAndSend and parse* helpers * api: fix strings in errors returned to client, replacing "ID" -> "Id" * api: fix swagger docs, replace "electionID" -> "electionId" * rename api.MaxPageSize -> api.ItemsPerPage * fixed lots of swagger docs
- Loading branch information
Showing
24 changed files
with
1,003 additions
and
630 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.