The Issue
Custom views are not showing node view count results until after I clear cache.
Steps to reproduce
1. create a custom view of content, with a relationship to the node view count stats and some user data.
2. Open an private browser, and view a node with a user that has the ability to trigger a node view count.
3. View the custom view
- The recent views will not appear.
4. Clear cache
- The recent views will appear.
What I have tried.
- I have tried various user roles and configuration combinations.
- I have tried to determine which cache clear causes the results to show, but only when "Clear all caches" is clicked do they show.
- I have NOT tried on a clean install
Comments
Comment #2
grn commentedI confirm this cache issue. The count does not update even when the cache is disabled.
Comment #3
nejcramsak commentedThis can be solved by going to your custom view, then under advanced settings change caching to "none".
Comment #4
nejcramsak commentedHi, i also created a patch for this if you want to keep caching on "tag based". Needs review.
Comment #5
grn commentedI see. I thought it was a global setting. On my drupal 8 site I have disabled all cache and applied this patch: https://www.drupal.org/files/issues/2020-06-04/nodeviewcount_extra-field... to be able to add "node view count" as a pseudo field on content (https://www.drupal.org/project/nodeviewcount/issues/3145688).
Would any of this solve my issue?
Thank you.
Comment #6
meri_atanasovska commentedSolution #3 is working for me, also patch #4 working correctly.