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

🚫 Allow Banning Users and Guests #3904

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open

Conversation

rapterjet2004
Copy link
Contributor

@rapterjet2004 rapterjet2004 commented May 8, 2024

Screenshots

Screenshot 2024-05-13 at 10 15 09 AM

Screenshot 2024-05-13 at 10 16 52 AM

Screenshot 2024-05-15 at 8 02 03 AM

Screenshot 2024-05-13 at 10 21 20 AM

ToDo

  • Add Capabilities and Moderator Check
  • Model
  • ViewModel
  • View
    • Ban button - for each participant in list. Show dialog for an internal Note.
    • "List Bans" Button should trigger a scrollable full screen dialog showing all the Bans. Display Internal Note if needed.
      • XML
      • Fragment class
      • Unban button, should be present as an option on every list item (Need to check if successful)
  • The UI is atrocious, need to make it look good
  • Need to implement it with Guests too

Bugs

  • Drop down color needs to be constantly, nc_grey

🏁 Checklist

  • ⛑️ Tests (unit and/or integration) are included or not needed
  • 🔖 Capability is checked or not needed
  • 🔙 Backport requests are created or not needed: /backport to stable-xx.x
  • 📅 Milestone is set
  • 🌸 PR title is meaningful (if it should be in the changelog: is it meaningful to users?)

- New option to ban participant if your a moderator and not in one-2-one
- New fragment to see previous bans, unban if wanted

Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
@rapterjet2004 rapterjet2004 added 3. to review Waiting for reviews and removed 2. developing Work in progress labels May 17, 2024
@rapterjet2004 rapterjet2004 marked this pull request as draft May 17, 2024 13:49
@rapterjet2004 rapterjet2004 removed the 3. to review Waiting for reviews label May 17, 2024
@rapterjet2004 rapterjet2004 added the 2. developing Work in progress label May 17, 2024
@rapterjet2004 rapterjet2004 marked this pull request as ready for review May 17, 2024 14:16
Copy link

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
@mahibi
Copy link
Collaborator

mahibi commented Jul 15, 2024

rebased on master and tested (not sure which things may not work because server is not ready yet..).

  • When i ban some user, he is still shown in the participants list (same on web).

  • He is also shown in the bans list. "Unban" seems to do nothing, after clicking he is still shown in the bans list. (for web, unban seems to work).

  • Actual banning does not work, the user can still write..

  • Date is always x.x.1970

Copy link

APK file: https://www.kaminsky.me/nc-dev/android-artifacts/3904-talk.apk

qrcode

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud Talk app.

# Conflicts:
#	app/src/main/java/com/nextcloud/talk/api/NcApi.java
#	app/src/main/java/com/nextcloud/talk/chat/data/ChatRepository.kt
#	app/src/main/java/com/nextcloud/talk/chat/data/network/NetworkChatRepositoryImpl.kt
#	app/src/main/java/com/nextcloud/talk/conversationinfo/ConversationInfoActivity.kt
#	app/src/main/java/com/nextcloud/talk/conversationinfo/viewmodel/ConversationInfoViewModel.kt
#	app/src/main/java/com/nextcloud/talk/models/json/participants/TalkBan.kt
#	app/src/main/java/com/nextcloud/talk/models/json/participants/TalkBanOCS.kt
#	app/src/main/java/com/nextcloud/talk/models/json/participants/TalkBanOverall.kt
#	app/src/main/java/com/nextcloud/talk/ui/dialog/DialogBanListFragment.kt
#	app/src/main/java/com/nextcloud/talk/utils/ApiUtils.kt
#	app/src/main/res/layout/ban_item_list.xml
#	app/src/main/res/layout/fragment_dialog_ban_list.xml
#	app/src/main/res/values/strings.xml
Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

⛔ Banning users and guests - Android
3 participants