I have a custom content type with a custom 'Yes'/'no' rate widget. I would like to show nodes in a View, including rate widgets (so users can easily vote for multiple nodes).

The problem: I get duplicate rows

These are my fields:
Screenshot

The Votes field has as 'appearance' setting: 'Default appearance'

This is the result.
Screenshot

As you see the two rows are identical, expect for the value in the "Include in results?" kolom, which is being generated by the Rate module.

If if change the 'appearance' setting to: 'Rate widget', it will still give me two rows, with identical widgets:

Screenshot

How to get rid of the identical rows?

Comments

koosvdkolk created an issue. See original summary.

jvdkolk’s picture

Asking above question gave me a clue: it seems that I see each vote as a separate row. If 3 users voted, there will be 3 rows. From a MySQL-perspective this makes sense, but how can I limit it to 1 row?

I suppose I cannot use the currently logged in user in WHERE, because this will hide exactly the nodes that I would like to show: the nodes for which the currently logged in user hasn't cast a vote yet...

ivnish’s picture

Status: Active » Closed (outdated)
Issue tags: -views integration

Drupal 7 is EOL. Issue will be closed

Now that this issue is closed, please review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, please credit people who helped resolve this issue.