When in a node that is present in a group, the contextual search allows to search on nodes of the same type present in the same group. However the group name is not truncated properly which introduces a problem in the layout of some themes.

Comments

hernani’s picture

StatusFileSize
new1.88 KB

The following patch makes the group name truncating consistent:

ezra-g’s picture

Status: Active » Needs review
Issue tags: +Commons 2.7 radar

Marking as "needs review" and tagging for review for the 2.7 release.

ezra-g’s picture

Title: Fix the search dropdown » Group name not truncated in search widget, breaks layout

Adding a descriptive issue title.

greggles’s picture

Status: Needs review » Needs work

Shouldn't this be truncate_utf8 or at least drupal_substr instead of substr?

greggles’s picture

Status: Needs work » Needs review
StatusFileSize
new1.8 KB

How about this? It also gets drupal_strlen instead of strlen.

ezra-g’s picture

Status: Needs review » Needs work
StatusFileSize
new75.93 KB

The string handling looks good but unfortunately this uncovers a bug in og_features that causes the breadcrumb to not match the search filter when a node is in multiple groups. Not sure why we have og_features_get_group_context() but that's returning different context than og_get_group_context(), which it appears to duplicate.

group breadcrumb doesn't match group search filter

ezra-g’s picture

Status: Needs work » Needs review
StatusFileSize
new2.22 KB

This patch simply uses og_get_group_context() to set the group filter and resolves the problem in #6.

ezra-g’s picture

Status: Needs review » Fixed

Automatically closed -- issue fixed for 2 weeks with no activity.