Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add a default notice box based on access level of the user #1364

Merged
merged 2 commits into from
May 7, 2024

Conversation

Chisomchima
Copy link
Member

@Chisomchima Chisomchima commented Mar 27, 2024

Implements DHIS2-17083

Description

conditionally display update status in user group details page based on access levels


Known issues

  • None

Checklist

  • API docs are generated
  • Tests were added
  • Storybook demos were added

All points above should be relevant for feature PRs. For bugfixes, some points might not be relevant. In that case, just check them anyway to signal the work is done.


Screenshots

Screenshot 2024-03-27 at 08 59 18

@dhis2-bot
Copy link
Contributor

dhis2-bot commented Mar 27, 2024

🚀 Deployed on https://pr-1364--dhis2-user.netlify.app

@Chisomchima Chisomchima requested a review from tomzemp March 27, 2024 11:04
…roupDetails page

chore: fix lint error

chore: fix lint error
@Chisomchima Chisomchima force-pushed the DHIS2-17083/user-group-access-update branch from 4389ae3 to 619186d Compare April 4, 2024 16:09
Copy link
Member

@tomzemp tomzemp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Chisomchima: notice box looks great 🎉, but I think you need to refine the logic slightly (see comment)

@@ -34,6 +34,12 @@ const GroupDetails = ({ groupId }) => {

return (
<Details title={group.displayName}>
{group.access.read && (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Chisomchima. I think you need to display this when !group?.access?.write.

At the moment, because you display the message whenever a user has read access, the user will see this message if they have both read and write access to the group, e.g.:

image

Copy link
Member

@tomzemp tomzemp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good 🚀

@Chisomchima Chisomchima merged commit 2133a7b into master May 7, 2024
12 checks passed
@Chisomchima Chisomchima deleted the DHIS2-17083/user-group-access-update branch May 7, 2024 11:24
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 100.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Chisomchima added a commit that referenced this pull request May 8, 2024
feat: add a default notice box based on access level of the user
Chisomchima added a commit that referenced this pull request May 8, 2024
feat: add a default notice box based on access level of the user
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants