- Status changed to Needs review
about 2 years ago 2:36pm 30 January 2023 - Status changed to Needs work
about 2 years ago 12:01am 31 January 2023 The Needs Review Queue Bot โ tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".
Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.
Consult the Drupal Contributor Guide โ to find step-by-step guides for working with issues.
- Status changed to Needs review
about 2 years ago 4:48am 31 January 2023 - ๐ฎ๐ณIndia pooja saraah Chennai
Fixed failed commands on #70
Attached patch against Drupal 10.1.x The last submitted patch, 72: 343535-72.patch, failed testing. View results โ
- Status changed to Needs work
almost 2 years ago 7:42pm 24 May 2023 - last update
almost 2 years ago Custom Commands Failed - ๐ง๐พBelarus kachinsky
Hi @webdrips
Your patch doesn't work, the view returns the error after applying:
Error: Class "Drupal\views\Ajax\SetBrowserUrl" not found in Drupal\views\Controller\ViewAjaxController->ajaxView() (line 219 of /code/web/core/modules/views/src/Controller/ViewAjaxController.php)
- ๐ฎ๐ณIndia shabana.navas
Is there a quick way we can clean up the URL that is built? Right now, I only have a couple of exposed filters and the URL already looks like this:
?date%5Bmin%5D%5Bdate%5D=2023-05-29&date%5Bmax%5D%5Bdate%5D=2023-06-16&promotion_type%5B6%5D=6&promotion_type%5B1%5D=1
- ๐ซ๐ทFrance prudloff Lille
#72 does not apply to 10.1.0. Here is a reroll.
(I tried to generate an interdiff but it fails for some reason.)
- ๐ฐ๐ฌKyrgyzstan elaman
The most recent patch causes a bug if user visits bookmarked url and tries to uncheck the existing filter. The main reason is that queryString is preserved when performing request to the ajax callback page:
this.element_settings = { url: ajaxPath + queryString, submit: settings, httpMethod: 'GET', setClick: true, event: 'click', selector, progress: { type: 'fullscreen' }, };
So you can't really reset bookmarked filters.
Also it is better to push new filter state into history, so you can use browser navigation to restore previous filter state.
- ๐ฐ๐ฌKyrgyzstan elaman
Instead of removing queryString that caused issues, now remove only params that represent exposed filters.
- ๐ซ๐ทFrance prudloff Lille
#82 causes a problem with pagination, for example :
- Check a filter that returns 3 page of results.
- Browse to page 3.
- Check another filter that only has one page of results.
- The view stays on page 3 and displays no result.
Remove the page param from the query string seems to fix it.
- First commit to issue fork.
- ๐ฎ๐ณIndia sakthi_dev
sakthi_dev โ changed the visibility of the branch 10.0.x to hidden.
- ๐ซ๐ทFrance GaรซlG Lille, France
GaรซlG โ made their first commit to this issueโs fork.
- ๐ซ๐ทFrance GaรซlG Lille, France
I made a fix so that browser URL is not updated if the view is in a dialog/modal, because in that case the browser URL is not the URL containing the view parameters.
It's like there's an URL for the page which is behind the modal (the one shown in the browser URL field), and one other URL ("hidden") for the "page" shown in the modal.
Without this fix, we got a strange behavior when using media library search in modal: it works the first time, but as soon as params are added to the browser URL, subsequent search is buggy until the whole page is reloaded.
I guess a test should be added for the modal case? Like just test that browser URL is not updated when an AJAX exposed form is used inside a modal.And automated tests do not pass, I guess it's just some test code that needs to be updated for compatibility with current 11.x.
Then, I believe the merge request will be ready for review again.
- First commit to issue fork.
- ๐ซ๐ทFrance prudloff Lille
prudloff โ changed the visibility of the branch 11.x to hidden.
- ๐ซ๐ทFrance prudloff Lille
prudloff โ changed the visibility of the branch 343535-ajax to hidden.
- ๐ซ๐ทFrance prudloff Lille
I rebased and fixed tests but I can't remove the draft status on the MR.
I had to change the order of GET params in some related tests, I'm not sure why.
I suppose that's because the code generating the SetBrowserUrl command does not process them in the same order as the code generating the pager links.
I'm not sure it is a problem as long as the GET params themselves are still the same. - ๐บ๐ธUnited States smustgrave
Have not reviewed as the issue summary needs some attention please.
- ๐ซ๐ทFrance prudloff Lille
I updated the summary but now the MR has a conflict.
- ๐ซ๐ทFrance prudloff Lille
I fixed the conflict (it was caused by ๐ Pagination not working correctly in AJAX view with exposed filters Needs review ).
I also noticed we were mixing two ways to remove parameters from the query (a regex and parsing it as an array). I moved everything to the new way.