1

I have an entityform type that uses a term reference (department). This term reference was also added to user accounts.

I'd like to make a view that displays the form submission for the same department as the currently logged in user.

I can't seem to make it work because if I go with a user view, I'm not able to retrieve all the entityform fields that I need. If I go with an entityform view, I'm not able to retrieve the current user's department. I can make a relationship only with the form submitter and that field is never empty so I don't think I can default to the 'current logged in user'

Any ideas?

1 Answer 1

0

Since you want to list entities that use the same term reference as the user account, its best to create a view of terms and add relationships to the user and entityform.

Add the entityform fields that you want, using the entityform submission relationship.

Then add the term reference field two times, one with the user relationship and one with the entityform submission relationship. You may hide these fields.

Then add filter 'field comparison', selecting both term reference fields, and choose 'is equal to'. Also add the filter User (using relationship) is 'currently logged in user'

The result is a view showing entityform submissions that have the same term reference value (department) as the currently logged in user.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.