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

Wrong setting of model_count in ViewHelpers #199

Open
dima4p opened this issue Nov 13, 2011 · 3 comments
Open

Wrong setting of model_count in ViewHelpers #199

dima4p opened this issue Nov 13, 2011 · 3 comments

Comments

@dima4p
Copy link

dima4p commented Nov 13, 2011

The code in question is
model_count = collection.total_pages > 1 ? 5 : collection.size

I can not catch the idea of setting model_count to five for multypage case, but it will not work properly for the last page in non-English languages, in particular, Russian.

@mislav
Copy link
Owner

mislav commented Nov 13, 2011

Can you elaborate a litle more?

@dima4p
Copy link
Author

dima4p commented Nov 13, 2011

I could if you explain the reason of setting model_count to 5.
For example, you set the page size to 30 and got 21 records. You will end up with the same form of the noun as for one record. But the context you put the obtained 'model' into does not fit the form of the noun.

@mislav
Copy link
Owner

mislav commented Nov 18, 2011

I think I understand what are you saying. The "5" thing was a hack that I need to get rid of. Thanks for reporting; I will get to this when I'm making the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants