I'm working on Workbench module on Drupal 7. There is a "File List" tab and showing all images and files from the site. I would like to change this to be showing their uploaded files only.
PS: the "File List" Tab is from the "workbench_files" Views
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.Sign up to join this community
First open the workbench file tab, then from the contextual menu on the right select edit view.
Add the relationship 'The user that uploaded the file.' if it does not already exist. Above Relationship, you will see Contextual Filters (these are dynamic contextual parameters you pass to views). Add a contextual filter 'The User ID' and set the relationship to 'User who Uploaded'.
In the same window just below that there is a section 'When the filter value is not in the URL'. You select 'Provide default value'. This opens a select list, from which you choose 'Use ID from logged in user'