[PR #5244] [MERGED] [PM-21577] Handle organization limitItemDeletion from sync response. #5605

Closed
opened 2025-11-27 00:10:43 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/5244
Author: @andrebispo5
Created: 5/21/2025
Status: Merged
Merged: 5/22/2025
Merged by: @andrebispo5

Base: mainHead: pm-21577/limit-item-deletion


📝 Commits (4)

  • 61759a3 [PM-21577] Handle organization limitItemDeletion from sync response.
  • 4bacf02 [PM-21577] Fix tests
  • ee50ae5 [PM-21577] Add missing test.
  • 60d7bcc [PM-21577] Fix PR suggestions

📊 Changes

10 files changed (+127 additions, -13 deletions)

View changed files

📝 app/src/main/kotlin/com/x8bit/bitwarden/data/auth/repository/model/Organization.kt (+3 -0)
📝 app/src/main/kotlin/com/x8bit/bitwarden/data/auth/repository/util/SyncResponseJsonExtensions.kt (+1 -0)
📝 app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModel.kt (+13 -1)
📝 app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/item/VaultItemViewModel.kt (+10 -0)
📝 app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/util/CollectionViewExtensions.kt (+17 -2)
📝 app/src/test/kotlin/com/x8bit/bitwarden/data/auth/repository/AuthRepositoryTest.kt (+5 -0)
📝 app/src/test/kotlin/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModelTest.kt (+29 -8)
📝 app/src/test/kotlin/com/x8bit/bitwarden/ui/vault/feature/util/CollectionViewExtensionsTest.kt (+43 -2)
📝 network/src/main/kotlin/com/bitwarden/network/model/SyncResponseJson.kt (+4 -0)
📝 network/src/testFixtures/kotlin/com/bitwarden/network/model/SyncResponseProfileUtil.kt (+2 -0)

📄 Description

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-21577

📔 Objective

When organization Limit item deletion to Members with Manage permission is off, users with Can Edit permission or Can edit, hide password permission should be able to see the delete button in the menu.

📸 Screenshots

Soon™

Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/5244 **Author:** [@andrebispo5](https://github.com/andrebispo5) **Created:** 5/21/2025 **Status:** ✅ Merged **Merged:** 5/22/2025 **Merged by:** [@andrebispo5](https://github.com/andrebispo5) **Base:** `main` ← **Head:** `pm-21577/limit-item-deletion` --- ### 📝 Commits (4) - [`61759a3`](https://github.com/bitwarden/android/commit/61759a3def0b444b8e51580b81b7b5b45c143f76) [PM-21577] Handle organization limitItemDeletion from sync response. - [`4bacf02`](https://github.com/bitwarden/android/commit/4bacf02fd3902ce352b9e9c26a475cf1e07e34de) [PM-21577] Fix tests - [`ee50ae5`](https://github.com/bitwarden/android/commit/ee50ae5ef0ab591c528c1e81438bddf57a1a9324) [PM-21577] Add missing test. - [`60d7bcc`](https://github.com/bitwarden/android/commit/60d7bcc64c9acc4e2e2e63983050cf56c6ff498b) [PM-21577] Fix PR suggestions ### 📊 Changes **10 files changed** (+127 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `app/src/main/kotlin/com/x8bit/bitwarden/data/auth/repository/model/Organization.kt` (+3 -0) 📝 `app/src/main/kotlin/com/x8bit/bitwarden/data/auth/repository/util/SyncResponseJsonExtensions.kt` (+1 -0) 📝 `app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModel.kt` (+13 -1) 📝 `app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/item/VaultItemViewModel.kt` (+10 -0) 📝 `app/src/main/kotlin/com/x8bit/bitwarden/ui/vault/feature/util/CollectionViewExtensions.kt` (+17 -2) 📝 `app/src/test/kotlin/com/x8bit/bitwarden/data/auth/repository/AuthRepositoryTest.kt` (+5 -0) 📝 `app/src/test/kotlin/com/x8bit/bitwarden/ui/vault/feature/addedit/VaultAddEditViewModelTest.kt` (+29 -8) 📝 `app/src/test/kotlin/com/x8bit/bitwarden/ui/vault/feature/util/CollectionViewExtensionsTest.kt` (+43 -2) 📝 `network/src/main/kotlin/com/bitwarden/network/model/SyncResponseJson.kt` (+4 -0) 📝 `network/src/testFixtures/kotlin/com/bitwarden/network/model/SyncResponseProfileUtil.kt` (+2 -0) </details> ### 📄 Description ## 🎟️ Tracking <!-- Paste the link to the Jira or GitHub issue or otherwise describe / point to where this change is coming from. --> https://bitwarden.atlassian.net/browse/PM-21577 ## 📔 Objective <!-- Describe what the purpose of this PR is, for example what bug you're fixing or new feature you're adding. --> When organization `Limit item deletion to Members with Manage permission` is off, users with `Can Edit` permission or `Can edit, hide password` permission should be able to see the delete button in the menu. ## 📸 Screenshots <!-- Required for any UI changes; delete if not applicable. Use fixed width images for better display. --> Soon™ ## ⏰ Reminders before review - Contributor guidelines followed - All formatters and local linters executed and passed - Written new unit and / or integration tests where applicable - Protected functional changes with optionality (feature flags) - Used internationalization (i18n) for all UI strings - CI builds passed - Communicated to DevOps any deployment requirements - Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team ## 🦮 Reviewer guidelines <!-- Suggested interactions but feel free to use (or not) as you desire! --> - 👍 (`:+1:`) or similar for great changes - 📝 (`:memo:`) or ℹ️ (`:information_source:`) for notes or general info - ❓ (`:question:`) for questions - 🤔 (`:thinking:`) or 💭 (`:thought_balloon:`) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion - 🎨 (`:art:`) for suggestions / improvements - ❌ (`:x:`) or ⚠️ (`:warning:`) for more significant problems or concerns needing attention - 🌱 (`:seedling:`) or ♻️ (`:recycle:`) for future improvements or indications of technical debt - ⛏ (`:pick:`) for minor or nitpick changes --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-27 00:10:43 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#5605