Whether you're creating content or user Views, you have to add the Flags Relationship (User flag in your case). This is the first step to introducing the flags information into the Views, and in most cases you'll want to set that Relationship to Any user, and use Contextual filters to restrict the results to your needs.
List users flagged by a user
This answers your first question, a page you can add to user profile pages (as a Drupal tab for example).
- Create user Views, Page Display
- Add the User flag Relationship and configure it:
Include only flagged content
Follow
Any user
- Add the Contextual filter User ID from the Flagging category (not the
User
Category!) and configure it:
It will use the Flags Relationship by default
When the filter value is NOT in the URL
Show "Page not found"
When the filter value IS in the URL or a default is provided
Specify validation criteria
User ID
- Change the Path to
user/%user/flags
- Add a Menu tab if you wish to show on user profiles
- Add No results behaviour
This user is not following any others.
- Add a Field Created from the Flagging Category to show when the flagging occured.
When you visit a person's page you'll see a list of users they follow.
List followers of a user
- Duplicate the Page from above
- Override the Contextual filters, remove the flagging one, and add User ID Contextual from the User Category and configure like the one above
- Change Path to
user/%user/followers
and Menu tabs
- Adjust the Title, No results text etc.
- Override Fields, remove the Name (it will always show the user who's page you're viewing so it's redundant)
- Add a Field User ID from Flagging Category (Label it
Who flagged
)
List content from users that are Followed
- Duplicate the first Page from above (List users flagged by a user)
- Add a new Relationship Content authored from the User Category, require it so you don't see people in the results that haven't authored any content
- Edit the Path to
user/%user/flags/content
or whatever makes sense to you, add the Menu tab
- Override the Fields and add the Title Field from Content Category
- Remove the Field showing the date when Flag was created
- You can Group by user Name under Format, to group Content by authors if you like
You can create Blocks instead of Page using similar logic, just configure the Contextual filters to react to use a default value from context, when it's not in URL.