chore(@desktop/wallet): Show wallet activity (#12946)
This commit is contained in:
parent
d7614beb99
commit
0b26070833
|
@ -175,6 +175,14 @@ QtObject:
|
||||||
QtProperty[string] txHashIn:
|
QtProperty[string] txHashIn:
|
||||||
read = getTxHashIn
|
read = getTxHashIn
|
||||||
|
|
||||||
|
proc getTxHash*(self: ActivityDetails): string {.slot.} =
|
||||||
|
if self.txHashOut.len > 0:
|
||||||
|
return self.txHashOut
|
||||||
|
return self.txHashIn
|
||||||
|
|
||||||
|
QtProperty[string] txHash:
|
||||||
|
read = getTxHash
|
||||||
|
|
||||||
proc getInput*(self: ActivityDetails): string {.slot.} =
|
proc getInput*(self: ActivityDetails): string {.slot.} =
|
||||||
return self.input
|
return self.input
|
||||||
|
|
||||||
|
|
|
@ -341,16 +341,24 @@ Item {
|
||||||
TransactionDataTile {
|
TransactionDataTile {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
title: qsTr("%1 Tx hash").arg(transactionHeader.networkName)
|
title: qsTr("%1 Tx hash").arg(transactionHeader.networkName)
|
||||||
subTitle: d.isDetailsValid ? d.details.txHashOut : ""
|
subTitle: d.isDetailsValid ? d.details.txHash : ""
|
||||||
visible: !!subTitle
|
visible: !!subTitle && !transactionHeader.isMultiTransaction
|
||||||
buttonIconName: "more"
|
buttonIconName: "more"
|
||||||
onButtonClicked: addressMenu.openTxMenu(this, subTitle, [d.networkShortName])
|
onButtonClicked: addressMenu.openTxMenu(this, subTitle, [d.networkShortName])
|
||||||
}
|
}
|
||||||
|
TransactionDataTile {
|
||||||
|
width: parent.width
|
||||||
|
title: qsTr("%1 Tx hash").arg(transactionHeader.networkNameOut)
|
||||||
|
subTitle: d.isDetailsValid ? d.details.txHashOut : ""
|
||||||
|
visible: !!subTitle && transactionHeader.isMultiTransaction
|
||||||
|
buttonIconName: "more"
|
||||||
|
onButtonClicked: addressMenu.openTxMenu(this, subTitle, [d.networkShortNameOut])
|
||||||
|
}
|
||||||
TransactionDataTile {
|
TransactionDataTile {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
title: qsTr("%1 Tx hash").arg(transactionHeader.networkNameIn)
|
title: qsTr("%1 Tx hash").arg(transactionHeader.networkNameIn)
|
||||||
subTitle: d.isDetailsValid ? d.details.txHashIn : ""
|
subTitle: d.isDetailsValid ? d.details.txHashIn : ""
|
||||||
visible: !!subTitle
|
visible: !!subTitle && transactionHeader.isMultiTransaction
|
||||||
buttonIconName: "more"
|
buttonIconName: "more"
|
||||||
onButtonClicked: addressMenu.openTxMenu(this, subTitle, [d.networkShortNameIn])
|
onButtonClicked: addressMenu.openTxMenu(this, subTitle, [d.networkShortNameIn])
|
||||||
}
|
}
|
||||||
|
|
|
@ -337,12 +337,17 @@ StatusListItem {
|
||||||
if (!!detailsObj.protocol) {
|
if (!!detailsObj.protocol) {
|
||||||
details += qsTr("Using") + endl + detailsObj.protocol + endl2
|
details += qsTr("Using") + endl + detailsObj.protocol + endl2
|
||||||
}
|
}
|
||||||
if (!!detailsObj.txHashOut) {
|
if (root.isMultiTransaction) {
|
||||||
details += qsTr("%1 Tx hash").arg(root.networkName) + endl + detailsObj.txHashOut + endl2
|
if (!!detailsObj.txHashOut) {
|
||||||
}
|
details += qsTr("%1 Tx hash").arg(root.networkNameOut) + endl + detailsObj.txHashOut + endl2
|
||||||
if (!!detailsObj.txHashIn) {
|
}
|
||||||
details += qsTr("%1 Tx hash").arg(networkNameIn) + endl + detailsObj.txHashIn + endl2
|
if (!!detailsObj.txHashIn) {
|
||||||
|
details += qsTr("%1 Tx hash").arg(root.networkNameIn) + endl + detailsObj.txHashIn + endl2
|
||||||
|
}
|
||||||
|
} else if (!!detailsObj.txHash) {
|
||||||
|
details += qsTr("%1 Tx hash").arg(root.networkName) + endl + detailsObj.txHash + endl2
|
||||||
}
|
}
|
||||||
|
|
||||||
const protocolFromContractAddress = "" // TODO fill protocol contract address for 'from' network for Bridge and Swap
|
const protocolFromContractAddress = "" // TODO fill protocol contract address for 'from' network for Bridge and Swap
|
||||||
if (!!detailsObj.protocol && !!protocolFromContractAddress) {
|
if (!!detailsObj.protocol && !!protocolFromContractAddress) {
|
||||||
details += qsTr("%1 %2 contract address").arg(root.networkName).arg(detailsObj.protocol) + endl
|
details += qsTr("%1 %2 contract address").arg(root.networkName).arg(detailsObj.protocol) + endl
|
||||||
|
@ -384,10 +389,10 @@ StatusListItem {
|
||||||
}
|
}
|
||||||
details += qsTr("Nonce") + endl + detailsObj.nonce + endl2
|
details += qsTr("Nonce") + endl + detailsObj.nonce + endl2
|
||||||
if (type === Constants.TransactionType.Bridge) {
|
if (type === Constants.TransactionType.Bridge) {
|
||||||
details += qsTr("Included in Block on %1").arg(networkName) + endl
|
details += qsTr("Included in Block on %1").arg(networkNameOut) + endl
|
||||||
details += detailsObj.blockNumberOut + endl2
|
details += detailsObj.blockNumberOut + endl2
|
||||||
if (detailsObj.blockNumberIn > 0) {
|
if (detailsObj.blockNumberIn > 0) {
|
||||||
details += qsTr("Included in Block on %1").arg(networkNameOut) + endl
|
details += qsTr("Included in Block on %1").arg(networkNameIn) + endl
|
||||||
details += detailsObj.blockNumberIn + endl2
|
details += detailsObj.blockNumberIn + endl2
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -39,10 +39,7 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onVisibleChanged: {
|
Component.onCompleted: {
|
||||||
if (!visible)
|
|
||||||
return
|
|
||||||
|
|
||||||
filterPanelLoader.active = true
|
filterPanelLoader.active = true
|
||||||
if (RootStore.transactionActivityStatus.isFilterDirty) {
|
if (RootStore.transactionActivityStatus.isFilterDirty) {
|
||||||
WalletStores.RootStore.currentActivityFiltersStore.applyAllFilters()
|
WalletStores.RootStore.currentActivityFiltersStore.applyAllFilters()
|
||||||
|
|
Loading…
Reference in New Issue