Currently we lack a row plugin for users to output user accounts through user_view() with a specific build mode.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dave Reid’s picture

Status: Active » Needs review
FileSize
5.19 KB
Dave Reid’s picture

Still trying to figure out why preprocess isn't running.

Dave Reid’s picture

- Fixed users do not have links by default, so links are disabled by default (modules can add them in).
- Removed the preprocess as removing links could easily be done in the render() plugin's function.

dawehner’s picture

Status: Needs review » Needs work
+++ b/modules/user.views.incundefined
@@ -484,6 +484,18 @@ function user_views_data() {
+        'base' => array('users'), // only works with 'node' as base.

node or users? :)

+++ b/modules/user.views.incundefined
@@ -484,6 +484,18 @@ function user_views_data() {
+        'help topic' => 'style-user',

If there is a help topic there should be probably also a help

+++ b/modules/user/views_plugin_row_user_view.incundefined
@@ -0,0 +1,85 @@
+class views_plugin_row_user_view extends views_plugin_row {

I'm wondering whether we could add a class which does nothing but loading / pre_render etc. but don't have the render method.

Then node and user could utilize it and any kind of contrib which supports entity_view as well

kevinquillen’s picture

I am using the latest version of views, where this patch seems to be applied already.

I have a view setup to show Users, and display as Rendered Entity, with a chosen view mode created by Entity View Modes module.

When dumping the result, it seems that the view mode is set to 'account' no matter what, and none of our field settings are respected since its not passing in and using the view mode.

I want to use a view to have a stylized search showing a couple fields, and on the user detail page, -not- use the 'Full' view mode. How can I do this?