From 20f1bfa0ea617d5fff42f1abd951d093f9b20cb1 Mon Sep 17 00:00:00 2001 From: belalshehab Date: Fri, 12 Jul 2024 15:07:20 +0300 Subject: [PATCH] fix(wallet)_: filter out non-transferable collectibles in send modal Description: Enhanced the SendModal.qml to filter out non-transferable (soulbound) collectibles from the send model. This ensures that only transferable collectibles are displayed when sending. Changes: Updated SendModal.qml to include a SortFilterProxyModel with a ValueFilter. The ValueFilter targets the soulbound role and filters out collectibles with soulbound set to false. Issue: Closes #14578 --- ui/imports/shared/popups/send/SendModal.qml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/ui/imports/shared/popups/send/SendModal.qml b/ui/imports/shared/popups/send/SendModal.qml index d3155b7e3d..9f42b8a656 100644 --- a/ui/imports/shared/popups/send/SendModal.qml +++ b/ui/imports/shared/popups/send/SendModal.qml @@ -328,9 +328,14 @@ StatusDialog { sourceComponent: CollectiblesSelectionAdaptor { accountKey: popup.preSelectedAccount ? popup.preSelectedAccount.address : "" - collectiblesModel: collectiblesStore - ? collectiblesStore.jointCollectiblesBySymbolModel - : null + + collectiblesModel: SortFilterProxyModel { + sourceModel: collectiblesStore ? collectiblesStore.jointCollectiblesBySymbolModel : null + filters: ValueFilter { + roleName: "soulbound" + value: false + } + } } }