http://drupal.org/node/1457174#comment-5658484

when you select the "replacement title" (field/title_field) instead of the "original title" (field/title), the option "Link this field to the original piece of content" in the field settings is not available (see a screenshot of the two configuration windows attached: the "original title" is on the left), and you cannot link the "replacement title" to its node.
A solution that I found is to add a "Link" field to the list of view fields after the "Title", to rewrite the output of this field with [title_field] token text, check "Output as a link" option, and to exclude the "Title" field from display.

Is it Title or Views issue?

Files: 
CommentFileSizeAuthor
#6 title-views_integration-1541414-6.patch3.42 KBpeximo
PASSED: [[SimpleTest]]: [MySQL] 186 pass(es).
[ View ]
#4 title-views_integration-1541414-4.patch3.21 KBplach
PASSED: [[SimpleTest]]: [MySQL] 186 pass(es).
[ View ]
#2 title-views_integration-1541414-2.patch3.25 KBpeximo
FAILED: [[SimpleTest]]: [MySQL] Invalid patch format in title-views_integration-1541414-2.patch.
[ View ]

Comments

Version:7.x-1.0-alpha2» 7.x-1.x-dev
Category:bug» feature

Is it Title or Views issue?

It's a Title issue: we need proper Views integration for this to work.

Issue summary:View changes

Fixing link

Status:Active» Needs review
StatusFileSize
new3.25 KB
FAILED: [[SimpleTest]]: [MySQL] Invalid patch format in title-views_integration-1541414-2.patch.
[ View ]

Hi, this patch should provide integration with Views, by providing the link between the title field and the corresponding entity. I tested the patch both with nodes and terms.

Status:Needs review» Needs work

The last submitted patch, title-views_integration-1541414-2.patch, failed testing.

Status:Needs work» Needs review
StatusFileSize
new3.21 KB
PASSED: [[SimpleTest]]: [MySQL] 186 pass(es).
[ View ]

Rerolled

Status:Needs review» Needs work

+++ b/views/title.views.inc
@@ -0,0 +1,14 @@
+ * Replace field default handler (views_handler_field_field) ¶
+ * ¶

Missing blank line above and the trailing dot. Moreover trailing white spaces are everywhere :)

+++ b/views/title.views.inc
@@ -0,0 +1,14 @@
+  if (isset($data['field_data_title_field'])) {
+    $data['field_data_title_field']['title_field']['field']['handler'] = 'views_handler_title_field';
+  }
+  if (isset($data['field_data_name_field'])) {
+    $data['field_data_name_field']['name_field']['field']['handler'] = 'views_handler_title_field';
+  }

I think this can be made work for any entity by inspecting the 'field replacement' key in entity info.

+++ b/views/views_handler_title_field.inc
@@ -0,0 +1,50 @@
+   * Provide link to entity option

Missing trailing dot.

Status:Needs work» Needs review
StatusFileSize
new3.42 KB
PASSED: [[SimpleTest]]: [MySQL] 186 pass(es).
[ View ]

Done.

Status:Needs review» Reviewed & tested by the community

Great work, thanks!

Status:Reviewed & tested by the community» Fixed

Committed and pushed, thanks!

Status:Fixed» Closed (fixed)

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

Issue summary:View changes

Emphasize the solution