fix(sharedAddress): hide non fully imported accounts from shared address (#15480)
* fix(sharedAddress): hide non fully imported accounts from shared address Fixes #15471 We only filtered out watch only accounts, but we also need to make sure it was a fully imported account, ie an account that is usable, hence why using `canSend`. It is the same property they use in the SendTransaction modal
This commit is contained in:
parent
69e793277f
commit
ad612a794c
|
@ -11,6 +11,7 @@ ListModel {
|
||||||
color: "#2A4AF5",
|
color: "#2A4AF5",
|
||||||
address: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240",
|
address: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240",
|
||||||
walletType: "",
|
walletType: "",
|
||||||
|
canSend: true,
|
||||||
position: 0,
|
position: 0,
|
||||||
assets: [
|
assets: [
|
||||||
{
|
{
|
||||||
|
@ -55,6 +56,7 @@ ListModel {
|
||||||
color: "#216266",
|
color: "#216266",
|
||||||
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881",
|
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881",
|
||||||
walletType: Constants.generatedWalletType,
|
walletType: Constants.generatedWalletType,
|
||||||
|
canSend: true,
|
||||||
position: 3,
|
position: 3,
|
||||||
assets: [
|
assets: [
|
||||||
{
|
{
|
||||||
|
@ -81,6 +83,7 @@ ListModel {
|
||||||
color: "#EC266C",
|
color: "#EC266C",
|
||||||
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8882",
|
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8882",
|
||||||
walletType: Constants.seedWalletType,
|
walletType: Constants.seedWalletType,
|
||||||
|
canSend: true,
|
||||||
position: 1,
|
position: 1,
|
||||||
assets: [
|
assets: [
|
||||||
{
|
{
|
||||||
|
@ -116,6 +119,7 @@ ListModel {
|
||||||
color: "#CB6256",
|
color: "#CB6256",
|
||||||
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8883",
|
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8883",
|
||||||
walletType: Constants.watchWalletType,
|
walletType: Constants.watchWalletType,
|
||||||
|
canSend: false,
|
||||||
position: 2,
|
position: 2,
|
||||||
assets: [
|
assets: [
|
||||||
],
|
],
|
||||||
|
@ -133,6 +137,7 @@ ListModel {
|
||||||
color: "#C78F67",
|
color: "#C78F67",
|
||||||
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8884",
|
address: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8884",
|
||||||
walletType: Constants.keyWalletType,
|
walletType: Constants.keyWalletType,
|
||||||
|
canSend: true,
|
||||||
position: 4,
|
position: 4,
|
||||||
assets: [
|
assets: [
|
||||||
{
|
{
|
||||||
|
|
|
@ -38,9 +38,8 @@ QObject {
|
||||||
readonly property var nonWatchAccounts: SortFilterProxyModel {
|
readonly property var nonWatchAccounts: SortFilterProxyModel {
|
||||||
sourceModel: root.swapStore.accounts
|
sourceModel: root.swapStore.accounts
|
||||||
filters: ValueFilter {
|
filters: ValueFilter {
|
||||||
roleName: "walletType"
|
roleName: "canSend"
|
||||||
value: Constants.watchWalletType
|
value: true
|
||||||
inverted: true
|
|
||||||
}
|
}
|
||||||
sorters: [
|
sorters: [
|
||||||
RoleSorter { roleName: "currencyBalanceDouble"; sortOrder: Qt.DescendingOrder },
|
RoleSorter { roleName: "currencyBalanceDouble"; sortOrder: Qt.DescendingOrder },
|
||||||
|
|
|
@ -80,9 +80,8 @@ QtObject {
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
filters: ValueFilter {
|
filters: ValueFilter {
|
||||||
roleName: "walletType"
|
roleName: "canSend"
|
||||||
value: Constants.watchWalletType
|
value: true
|
||||||
inverted: true
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue