Giter Site home page Giter Site logo

Comments (6)

serra avatar serra commented on July 19, 2024

Thanks for reporting, I'll check it out.

from twitter.bootstrap.mvc.

serra avatar serra commented on July 19, 2024

@maroquio - I think there is no error. The IPagedList model uses a zero-based PageIndex, so it was convenient for the currentPage argument of MvcHtmlString Pager to be zero-based too.

I admit that this might be a bit confusing, since the ToPagedList<T> takes a one-based page argument, so that we can immediately pass in the page parameter we get from the request.

I created a small sample project that adds paging to the sample app: 1 | 2 | 3 | 4 | 5

Please let me know if you still think there's a bu there.

from twitter.bootstrap.mvc.

maroquio avatar maroquio commented on July 19, 2024

Hi, Serra. While I was testing, I've tried 0-based index using, but I had to do some arithmetics on the GUI to make it work correctly. It was really confusing. I'm not sure if it is a good idea to keep it like that, but if it works well as 0-based index, its everything allright. Anyway, thanks for your answer and for keeping this very useful project.

from twitter.bootstrap.mvc.

serra avatar serra commented on July 19, 2024

Glad you worked it out, I agree it can be a bit confusing. Feel free to suggest some changes in a pull request. It would indeed be better if the full public api of the paged list implementation used the same base for the page index.

from twitter.bootstrap.mvc.

serra avatar serra commented on July 19, 2024

@maroquio - could you close this bug report? Thanks.

from twitter.bootstrap.mvc.

maroquio avatar maroquio commented on July 19, 2024

Done!
Regards.

2013/3/12 Marijn van der Zee [email protected]

@maroquio https://github.com/maroquio - could you close this bug
report? Thanks.


Reply to this email directly or view it on GitHubhttps://github.com//issues/80#issuecomment-14763067
.

from twitter.bootstrap.mvc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.