make empty projects display correctly for non-managers #1606
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1605
Description
This allows the message "Looks like there are no entries yet." to appear for any member of the project (including commenters), and the two buttons to appear for any member of the project who can edit. Previously, with empty projects, these items only displayed if the member was a manager (to include owners and admins, but not editors or commenters).
Type of Change
Only keep lines below that describe this change, then delete the rest.
Screenshots
This is what we were seeing before, for anyone with permissions less than a manager's:
Now viewers and commenters will see this:
and editors, managers, and above will see this:
Checklist
How to test
1.Create an empty project and share it with another user, giving them only the (default) "can edit" permissions. Sign in as the other user and view the project. Verify that you see the message and can add entries if you like.
2.Create an empty project and share it with another user, giving them view or comment permissions only. Sign in as the other user and view the project. Verify that you see the message and can add entries if you like.
qa.languageforge.org testing
Testers should add his/her findings to end of the PR in a comment and include screenshots, files, etc that are beneficial.