Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have a view with node.nid with LIMIT 1, but in the other view I use the first as filter it doesn't show any of the nodes from that one.
It seams that Limit is now working and entityreference filter take all of the nodes
Comments
Comment #1
maximpodorov CreditAttribution: maximpodorov commentedAs I understood, the limit for view which returns filter options is not applied. This is the standard behavior of entityreference views. Do you have cases which require such limits?
Comment #2
maximpodorov CreditAttribution: maximpodorov commentedComment #3
antiorario CreditAttribution: antiorario commentedI'm reopening this (with a more explanatory title), because I also think that if the entity reference display sets a limit in the number of results, this limit should be respected. In some cases, the results are too many to comfortably fit in a select list (very long select lists are barely usable, especially on mobile devices), and using a limit is a quick way to cut the number of results without adding complex filters to the entity reference display.
It's true that entity reference views tend to fetch all possible results, but not all results are displayed. For example, autocomplete fields show only the top 10 results of a given query—more than that and it would be very impractical to display.
Comment #4
maximpodorov CreditAttribution: maximpodorov commentedThis change can break all sites which use this module (since the default limit is 10, and there was no reason to change it). Can you find the way to protect the existing sites?
Comment #5
antiorario CreditAttribution: antiorario commentedPerhaps a way not to break existing sites would be to add an option, and if the option is not set nothing happens.
Comment #6
maximpodorov CreditAttribution: maximpodorov commentedYes, this should be configured on the filter's side. Any patch?
Comment #7
antiorario CreditAttribution: antiorario commentedI tried to work on it just in the past few days, with no luck.
Comment #8
pinueve CreditAttribution: pinueve commentedi have an ER view with limit of 10 results (wich is not respected, in preview it does), if i set my field with lets say 5 limited values and i set widget to check boxes (wich is my desired setting) i get a time-out error because it loads many many nodes (same error on select list), it "works" if i set my field wigdet to 'autocomplete', i'm not a good php expert, i post this to see if someone with better skills can have a deep look in a function that autocomplete widget do and make a patch to this beaty module to work with check-boxes.
Comment #9
reinaldoc CreditAttribution: reinaldoc as a volunteer commentedanyone interested to be paid for this feature in stable release?