Hello i saw this issue
In backend Article Manager:
Then page navigation buttons at bottom of page to not work.
I was disable cache in global configuration, in system plugin, i cleared browser's cache but this issue with pagination in backend exist.
The Template is isis - Default
This happened after update Joomla 3.4.0 to Joomla 3.4.1
Joomla 3.4.1
Database Version 5.6.23
PHP Version 5.4.38
Labels |
Removed:
?
|
and what kind of hint is it?
With that PR some javascript was removed from many places. I think would be nice to test if restoring that code the problem vanish… I am in the middle of something right now and cannot test it myself, that’s the reason I tagged it as hint.
I will try if that work
nope, it doesn't solve this issue
I had similiar issue in a custom component some weeks ago. After some investigations I found out that under some circumstances
$this->getUserStateFromRequest
resets limitstart to 0.
See \libraries\legacy\model\list.php line 663
if (($cur_state != $new_state) && ($resetPage))
{
$input->set('limitstart', 0);
}
but
$app->getUserStateFromRequest(
does not reset to 0.
So, changing
\administrator\components\com_content\models\articles.php line 99
to
$categoryId = $app->getUserStateFromRequest($this->context . '.filter.category_id', 'filter_category_id');
$this->setState('filter.category_id', $categoryId);
seems to fix the issue.
Please don't ask for a PR because I haven't understood what happens there in list.php and why and if it should happen or not ;-)
this change in \administrator\components\com_content\models\articles.php line 99 works
But why did it work in J! <= 3.4.0 without $app ???
If you use the getUserStateFromRequest method from JApplication instead of the one in JModelList (changing $this->getUserStateFromRequest to $app->getUserStateFromRequest) you cant force the user back to the first page, when a filter has changed.
After some trial and error I replaced
/libraries/vendor/joomla/registry/src/Registry.php
with file from Joomla 3.4.0.
Pagination worked now.
Afterwards I replaced just
public function get($path, $default = null)
with method from Joomla 3.4.0.
Pagination worked.
88b9d4a#diff-f2d808f72f76a9bb5865ae501e659bd0R195
@mbabker Perhaps you can help?
I just had a quick look at the code and see that:
https://github.com/joomla/joomla-cms/blob/staging/libraries/legacy/model/list.php#L471-L477
Remove the block of code I mentioned seems fix the pagination issue.
I might be wrong as I haven't looked at the code carefully enough. Will look at it again when I get home.
Seems this issue happens with page navigation on all other core components :(.
Yes, everywhere the search tool above the columns is used. Not with the filters in the left column.
Could anyone try the solution I proposed above to see whether it works?
The real issue here is that an (object)
casting was removed in Registry
and then things are accessed differently. To be honest the real issue is that I used arrays to handle filters from searchtools and patched JRegistry to always cast data to (object) which after discussing it with @Hackwar I see it was wrong (See commit phproberto@ad9963b )
I tried to provide a fix on my branch https://github.com/phproberto/joomla-cms/commits/4467-categories which fixes the main issue because the casting is done in a custom getFilterStateFromRequest
in JModelList
instead of expecting Registry to do that for us (see phproberto@883b508#diff-0e0b8a6a2b081b6dbb1c0e7d27ae4f1aR700 )
I think that's a better fix than #6548 but for sure harder to test with third part extension using search tools now.
Labels |
Added:
?
|
@phproberto the (object)
casting was removed from Registry
in 3.3
$app-> in this line https://github.com/joomla/joomla-cms/blob/staging/libraries/legacy/model/list.php#L471 should be replaced with $this-> so that when states change, you will be back to page 1
Just to mention it from my point of view (who cares ;-) ): I have never understood why view returns to page 1 when I change filter settings. With your PR 6548 it works correctly I think. When I'm on the last page (let's say 17) and see 5 items with filter "Published" (Display # = 5) and change state of these items to "Unpuplished" the view changes correctly to page 16 (new last page). Also correct handling with pages in the middle.
the (object) casting was removed from Registry in 3.3
What does this mean for dump testers like me. Patch of phproberto is not an alternative for this issue?
@bertmert When you change the states (filters), the total records returned will be changed. I thought that when you are on page 17, and with the state/fiter changes, the system can only found 5 records for example (which match the filter).
If the page is not reset to first page, no records will be displayed which is wrong. However, somehow, Joomla still handle this case properly (I haven't had time to look at it yet). So please ignore that comment from me (I didn't make that change in the PR, too).
I am facing issue only with the page breaks inside an article in front end UI. No issues were recorded in Read More or Page navigation under article lists. This all started after updating to Joomla 3.4.1
When selecting a different page using the page breaks, the article will simply go blank.
PHP Version 5.4.28
Web Server Apache
WebServer to PHP Interface cgi-fcgi
Joomla! Version Joomla! 3.4.1 Stable [ Ember ] 21-March-2015 20:30 GMT
Joomla! Platform Version Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT
Please help.
Regards
Syed H
@syhussaini can you open a new issue at http://issues.joomla.org/tracker/joomla-cms as this here is for issues in the backend together with the searchtools
I can confirm immediatly the same issue.
When enabling filtering in articles view it always stays on the first selection when clic on 2.. 3.. in pagination tabs
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2015-06-27 08:22:13 |
Closed_By | ⇒ | zero-24 | |
Build | master | ⇒ | staging |
@test confirmed, page navigation doesn't work when search filters are used. Expect of the author filter