fix: issue with prop updating

This commit is contained in:
Sérgio Salgado 2021-06-23 15:03:20 +01:00 committed by Josh Harvey
parent 2463ead863
commit e05e44f468
2 changed files with 21 additions and 19 deletions

View file

@ -285,18 +285,6 @@ const DetailsRow = ({ it: tx, timezone }) => {
) : (
errorElements
)}
</div>
<div>
<Label>Other actions</Label>
<div className={classes.otherActionsGroup}>
<ActionButton
color="primary"
Icon={Download}
InverseIcon={DownloadInverseIcon}
className={classes.downloadRawLogs}
onClick={() => downloadRawLogs(tx, timezone)}>
Download raw logs
</ActionButton>
{tx.txClass === 'cashOut' && getStatus(tx) !== 'Cancelled' && (
<ActionButton
color="primary"
@ -312,6 +300,18 @@ const DetailsRow = ({ it: tx, timezone }) => {
</ActionButton>
)}
</div>
<div>
<Label>Other actions</Label>
<div className={classes.otherActionsGroup}>
<ActionButton
color="primary"
Icon={Download}
InverseIcon={DownloadInverseIcon}
className={classes.downloadRawLogs}
onClick={() => downloadRawLogs(tx, timezone)}>
Download raw logs
</ActionButton>
</div>
</div>
</div>
<ConfirmDialog
@ -322,12 +322,12 @@ const DetailsRow = ({ it: tx, timezone }) => {
message={`The user will not be able to redeem the cash, even if they subsequently send the required coins. If they've already sent you coins, you'll need to reconcile this transaction with them manually.`}
onConfirmed={() => {
setErrorMessage(null)
setAction({ command: null })
cancelCashOutTransaction({
variables: {
id: tx.id
}
})
setAction({ command: null })
}}
onDissmised={() => {
setAction({ command: null })
@ -338,4 +338,4 @@ const DetailsRow = ({ it: tx, timezone }) => {
)
}
export default memo(DetailsRow, (prev, next) => prev.id === next.id)
export default memo(DetailsRow)

View file

@ -78,11 +78,13 @@ export default {
width: 180
},
cancelTransaction: {
width: 160,
marginLeft: 8
width: 160
},
status: {
width: 230
width: 230,
'& > button': {
marginTop: 20
}
},
transactionId: {
width: 280