Skip to content

6755: next_previous block skips pages#6756

Merged
aembler merged 3 commits intoconcretecms:developfrom
gfischershaw:Issue-#6755
Jun 14, 2018
Merged

6755: next_previous block skips pages#6756
aembler merged 3 commits intoconcretecms:developfrom
gfischershaw:Issue-#6755

Conversation

@gfischershaw
Copy link
Copy Markdown
Contributor

Equivalent date page get skipped as well as pages before/after an inaccessible page.

Equivalent date page get skipped as well as pages before/after an  inaccessible page.
@aembler aembler requested a review from mlocati June 11, 2018 16:33
@aembler
Copy link
Copy Markdown
Member

aembler commented Jun 11, 2018

I think we should review this – not sure about some of the constructs used in this code, although I understand the problem it's solving.

@mlocati
Copy link
Copy Markdown
Contributor

mlocati commented Jun 12, 2018

The only relevant changes are small changes in the queries.
For example, instead of
cvDatePublic > ?
we now have
((cvDatePublic = ? and cDisplayOrder > ?) or cvDatePublic > ?)
which is perfectly fine.

BTW, I'd optimize the code a bit, checking that pages are loaded without errors and reducing duplicated code: see gfischershaw#1

If @gfischershaw accepts gfischershaw#1 it will be added to #6756

@mlocati
Copy link
Copy Markdown
Contributor

mlocati commented Jun 12, 2018

LGTM, it does fixes the issue. Thanks @gfischershaw!

@aembler
Copy link
Copy Markdown
Member

aembler commented Jun 14, 2018

Thanks both of you!

@aembler aembler merged commit 1d6bca2 into concretecms:develop Jun 14, 2018
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

Successfully merging this pull request may close these issues.

3 participants