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

Trust for role #2589

Merged
merged 13 commits into from Sep 30, 2022
Merged

Trust for role #2589

merged 13 commits into from Sep 30, 2022

Conversation

tiltec
Copy link
Member

@tiltec tiltec commented Sep 23, 2022

Implement another "trust" button to let editors grant the approved role to users.

  • 'approved' trust button next to editor trust button that only shows when the role is enabled for the group
    • currently can only be done manually on the server, as there's no API or UI for customizing roles yet
  • can select 'approved' role for activity participant types

Based on #2361

Needs karrot-dev/karrot-backend#1167 backend.

@tiltec tiltec marked this pull request as ready for review September 29, 2022 22:55
@codecov
Copy link

codecov bot commented Sep 29, 2022

Codecov Report

Merging #2589 (a267b6e) into master (ecfc7f0) will decrease coverage by 0.34%.
The diff coverage is 40.06%.

@@            Coverage Diff             @@
##           master    #2589      +/-   ##
==========================================
- Coverage   77.17%   76.82%   -0.35%     
==========================================
  Files         375      376       +1     
  Lines       39639    39936     +297     
  Branches     1966     1974       +8     
==========================================
+ Hits        30592    30682      +90     
- Misses       9047     9254     +207     
Impacted Files Coverage Δ
src/group/api/groups.js 47.31% <0.00%> (-0.52%) ⬇️
src/history/helpers.js 61.29% <33.33%> (-1.43%) ⬇️
src/users/components/ApproveButton.vue 34.86% <34.86%> (ø)
src/users/pages/Profile.vue 91.01% <50.00%> (-8.00%) ⬇️
src/activities/helpers.js 95.48% <100.00%> (+0.06%) ⬆️
src/agreements/pages/Agreement.vue 100.00% <100.00%> (ø)
src/group/mutations.js 58.42% <100.00%> (ø)
src/group/services.js 89.53% <100.00%> (+0.04%) ⬆️
src/notifications/helpers.js 99.42% <100.00%> (+0.03%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Member

@nicksellen nicksellen left a comment

Choose a reason for hiding this comment

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

Great work! A couple of missing words in i18n files.

And a few comments from using it locally:

revokeapproved

It shows me I can revoke the trust, and will make a delete request, which succeeds, but the approved role doesn't go away, which was confusing. I know you mentioned that somewhere, as it would need a bunch of notifications, etc... I wonder if it could just remove the role and leave the notifications till later... right now it's a bit confusing (especially as the threshold is 1).

missingrolename

In both screenshots the role is not in missing in the text, missing i18n var?

missingrolename2

Same for history, missing role name in text.

notinlist

Would be nice to see approved status in the member list too, can wait. I think it'll come up as a need quite quickly though.

editors can give trust for approved (editors only)

I think this bit got missed out - the idea was only editors can give approval. Although @nathalie-sz and @brnsolikyl proposed editors or approved can approve (https://community.karrot.world/t/applicant-trial-pickup-proposal/575/59).

The first use case we are aiming to support is from @dwaxweiler, who said this about it:

Concerning the discussion about who approves: My concern is that not every member should be able to approve because in our group, for example, we have designated a person who checks whether the new person has fulfilled all criteria before approving them.

... personally, I would vote for limiting it to just editors to give trust for approval role right now.

Sorry if that seems a lot of stuff at the last minute! I have capacity to help out!

src/activities/helpers.js Show resolved Hide resolved
src/group/services.js Show resolved Hide resolved
src/group/api/groups.js Show resolved Hide resolved
src/locales/locale-en.json Show resolved Hide resolved
src/locales/locale-en.json Outdated Show resolved Hide resolved
test/mockBackend/groups.js Show resolved Hide resolved
src/users/components/ApproveButton.vue Show resolved Hide resolved
@tiltec
Copy link
Member Author

tiltec commented Sep 30, 2022

Would be nice to see approved status in the member list too, can wait. I think it'll come up as a need quite quickly though.

My idea was to remove the trust button in the member list and replace it with a more simple display of roles and trust.. maybe with a "table" component.

@nicksellen nicksellen merged commit 3eb6a25 into master Sep 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants