Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Result object in the promise could be different than the same paginator instance. #1

Open
alfredooo opened this issue May 19, 2015 · 0 comments
Assignees
Milestone

Comments

@alfredooo
Copy link
Member

Result object in the promise could be different than the same paginator instance.

Insted of this:
paginator.paginate().then(function(paginator) {
paginator.getResults(); // return a person collection
paginator.getTotal(); // return total register
paginator.getOffset(); // return offset
paginator.getLimit(); // return limit
});

we chould have something like:
paginator.paginate().then(function(resultObject) {
resultObject.getResults(); // return a person collection
resultObject.getTotal(); // return total register
resultObject.getOffset(); // return offset
resultObject.getLimit(); // return limit
});

And that way we could do something like:
$q.all[
Paginator.get({limit: 25,offset: 0}),
Paginator.get({limit: 25,offset: 25})
].

@rkmax rkmax added this to the v1.1.0 milestone May 19, 2015
@rkmax rkmax self-assigned this May 19, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants