- Issue created by @vbouchet
- 🇫🇷France vbouchet
As per my investigation, this is because the Recipes source is not updating the number of result.
Object.entries(data).forEach((item) => { const [source, result] = item; if (result.totalResults !== 0) { $activeTab = source; [project] = result.list; projectExists = true; } });
The JS behind /admin/modules/browse/{module_name} still invokes all the source plugins but expect only one source to return results.
Globally, I think the JS should be aware of the active source tab so other sources can act appropriately:
- In case it is the /browser, run a lightweight query as the goal is only to know the number of projects matching the criteria.
- In case it is the /browser/{project_name}, don't do anything - Merge request !521Issue #3455715: Get the total number of recipes after applying the filters. → (Open) created by vbouchet
- Status changed to Needs review
5 months ago 2:50pm 19 June 2024 - 🇫🇷France vbouchet
The suggested commit is not reworking the global implementation, just fixing the way total is counted in the Recipe sources so it does count only after filtering is applied.
- 🇮🇳India Kanchan Bhogade
Hi
I've tried to reproduce the issue on Drupal 11.x
But the Project detail page is working as expected without any error.
I followed the same steps as mentioned in the summary to reproduce the issue, please let me know if I'm missing something - 🇮🇳India vinmayiswamy
+1 to #5. I have also tried to reproduce the issue on Drupal versions 10.2.x and 11.x by following the steps outlined in the summary. However, the project details page is functioning as expected and does not throw any exceptions as described in the issue summary.
@vbouchet, please advise if we might have missed something.
Thanks!
- 🇫🇷France vbouchet
I will try to check but given the recent change in the js, it is possible the issue is not here anymore.
However, the suggested code change is still valid, the recipes source plugin is setting the $total before doing the filtering.
- 🇮🇳India prashant.c Dharamshala
Prashant.c → changed the visibility of the branch 3455715-project-detail-page to hidden.
- 🇮🇳India prashant.c Dharamshala
Prashant.c → changed the visibility of the branch 3455715-project-detail-page to active.
- Status changed to Closed: outdated
3 months ago 3:53pm 14 August 2024 - 🇺🇸United States chrisfromredfin Portland, Maine
The current MR has no changes to the active codebase, which I think means that this fix was implemented in a different issue, and this is Closed (Outdated).
If someone disagrees, you can open a new (related) issue.