Closed (fixed)
Project:
Workflow
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
2 Feb 2010 at 18:42 UTC
Updated:
12 Mar 2012 at 22:57 UTC
Jump to comment: Most recent file
Comments
Comment #1
dstolErr, forgot the patch.
Comment #2
eforth commentedAny progress on this? I've been trying, but I'm lack of skills ^^
Comment #3
ngocleanh commentedI want name not uid?
Comment #4
dstolHere's the added relationship to accomplish adding the user name rather then the UID.
So add the relationship called User and then you can add the field for the user name.
Comment #5
jcisio commentedThanks for the patch, dstol. It works as expected. But, could you add just more: not only display this field, but can filter this field (like, show all nodes that are currently set by the user XYZ)?
Comment #6
jcisio commentedMarking #486896: Add Workflow-User relationship to View as duplicate. The patch provided from that issue complement this patch to solve the problem!
Comment #7
pbeakley commentedI'm having some trouble working out the logic of the relationship. Say I wanted to get the user who triggered the change in a particular workflow state of a node -- how would I go about doing that? Is that even possible with this patch?
EDIT: Okay, so what I've attempted is a View with the node's argument, two fields (previous workflow and user) and a Workflow: user relationship. For the user field, I'm requiring the Workflow: User relationship. However, all I'm getting is the last user to have moved the node's workflow state. What I was hoping for was a table, say, of all the states and the user who triggered each state.
Comment #8
alasda commentedThis patch adds argument and filter support, along with the relationship and field.
Comment #9
andreiashu commentedI tested the patch from #8 for relationship and filtering and it works as expected. RTBC
Comment #10
restyler commentedThank you, guys!
The latest patch is not working as expected (by me) when I add Workflow:user field to view.
It shows user uid instead of showing (expected by me) username.
I'm not sure that is a bug, just wanted to highlight that.
Comment #11
Exploratus commentedWhen I add it as a filter, it just shows the user id of the node author???? What good is that for?
I basically have the same issue as #7
Comment #12
leoklein commented@whatmetropolis: You need to create a 'relationship' for workflow user and then point to that relationship when adding the user field to your View.
In any case, patch from #8 works for me. Thanks.
Comment #13
hlopes commentedThis patch throws me a warning on views 6.x.2.11.
warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/escr/public_html/includes/bootstrap.inc on line 859.
This happens as soon as i select "Link this field to its node" on a display that has this relationship and an argument that uses it.
#EDIT: Sorry, my bad.... It has nothing to do with this patch.
Comment #14
jdwfly commentedI'm for this too. Using the relationship to get the user name worked quite well. The patch failed to apply for me but I put it in by hand so it may need to be rerolled with the latest version.
Comment #15
Bastlynn commentedDuplicate of:
#1313430: Expose the last person that made a change to the state of a node to be usable by views
#178962: Provide views field for user who most recently changed the workflow
Comment #16
Bastlynn commentedI'm going to re-roll the patch for the 7.x branch and try to resolve the issues we're seeing with it applying. Once I've got that, the fix will get backported to 6.x.
Comment #17
Bastlynn commentedI tweaked the code in #8 a little to make the need for the relationship to get the data in clearer. Otherwise, nice work! It's committed to the D7 branch and I'll backport to D6.
Comment #18
Bastlynn commentedPatch has been backported to 6 on the 6.x-1.x branch. It's currently in dev, but when the branch is next released it'll be out there official like.
Comment #19
dstolAwesome thanks Bastlynn!
Comment #20
leoklein commentedThank you! I had the same problem this year!