Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Is there any incompatibility between Custom pagers and Views 3?
I can't see the navigation links using Views 3
Comment | File | Size | Author |
---|---|---|---|
#11 | custom_pagers-d7-views-896776-11.patch | 3.24 KB | sarvab |
#4 | 896776.patch | 859 bytes | bojanz |
Comments
Comment #1
michael.k CreditAttribution: michael.k commentedI am also seeing some problems with Views 3 (6.x-3.x-dev, 2010-Sep-14).
The Custom Pagers are completely gone from both the node and block, and I get this error:
Some context: With Views 2 I was able to get Custom Pagers to cycle through whatever collection of picture nodes that passed through the filter (ie, pictures for everybody). This worked okay as long as the list was small and relevant, but it was not how I intended it. My goal was to limit the paging to the relevant nodes associated to a taxonomy term by passing an argument for a term ID (ie, pictures for a specific person). This didn't work for me, even though I was able to make it work in the Views 2 interface. So maybe I wasn't properly configuring my taxonomy terms to work with Custom Pagers in the first place, I'm not sure.
Comment #2
anonymous07 CreditAttribution: anonymous07 commentedSubscribe. With the latest Views update 6.x-3.0-alpha3, there don't appear to be any Custom Pager links anymore :(
(Or I haven't figured out the right combination of Views settings to make it work again).
Comment #3
JordanMagnuson CreditAttribution: JordanMagnuson commentedSubscribing. Definitely interested in using this with Views 3.
Comment #4
bojanz CreditAttribution: bojanz commentedAs you know, Views 3 changes the way queries are made, in order to support pluggable query backends.
This apparently doesn't sit well with Custom Pagers.
Here's what you need to do to get it working:
1) Apply the patch (or make the change yourself)
2) Make sure that the View your using (I'm assuming it's a node view) either uses Row Style: Node, or Row Style: Fields with the base field added (in this case Node:nid)
3) ??
4) Profit!
Oh, and please do use the latest dev version of Views 3. Alpha3 is horribly outdated.
Comment #5
Finn Lewis CreditAttribution: Finn Lewis commentedPathch in #4 works for me!
Thanks bojanz!
Comment #6
Anonymous (not verified) CreditAttribution: Anonymous commentedPatch #4 works for me too
Comment #7
fictionindustries CreditAttribution: fictionindustries commentedYES! works
Comment #8
anonymous07 CreditAttribution: anonymous07 commentedWorks for me too.
@ bojanz: I think I put the wrong version, I was using the Dev version. Thanks for the patch!
Comment #9
jjjames CreditAttribution: jjjames commentedPatch worked for me... thanks!!
Comment #10
jjjames CreditAttribution: jjjames commentedUPDATE: Limit to 10 nodes?
The pager now shows up, but only on the last 10 nodes and I can only navigate back and forth through the last 10 nodes. I have no idea what's causing it. I've tried several different times and end up with the same 10 node limit.
Comment #11
sarvab CreditAttribution: sarvab commentedHere is a different patch that accomplishes the same and a bit more:
1) Works regardless of what fields / row styles are used (do not need to add the NID field)
2) Ignores all enabled fields to prevent potential slower-then-necessary queries
3) Forces view to not use a pager to ensure it can look at all results (likely fixes previous comments 10 node limit problem)
Comment #12
GrahamShepherd CreditAttribution: GrahamShepherd commented#11 worked for me including fixing the 10 node limit. Many thanks @sarvab.
Comment #13
GrahamShepherd CreditAttribution: GrahamShepherd commentedCan this patch be added incorporated the next release? It is a pain having to insert it each time on each site whenever there is a module update.
Comment #14
grigorym CreditAttribution: grigorym commentedIs it working with view arguments? I'm still unable to make it honor the contextual filter 'OG membership: Group ID' which i'm passing.
Edit: Mea culpa! The view was of type 'page', or something... I've made a brand new view (unchecking 'create page' by the way) and contextual filters worked!