Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core,ui: add confirmation for currently waiting swap #805

Merged
merged 2 commits into from
Nov 9, 2020

Conversation

buck54321
Copy link
Member

Add confirmation count to match cards on the order details page, for matches in MakerSwapCast or TakerSwapCast. It's a bigger job than it sounds like, because 1) we weren't tracking confirmation count on our own swaps yet, and 2) I didn't think we should add the count unless it updated live, so the count, match status, and various coin ID links will update live now.

There are just a few more pieces needed to make the whole page update live. Will save the rest for another PR.

client/core/notification.go Outdated Show resolved Hide resolved
client/core/types.go Outdated Show resolved Hide resolved
client/core/types.go Outdated Show resolved Hide resolved
client/core/types.go Show resolved Hide resolved
@@ -188,7 +273,7 @@ type Order struct {
Cancelling bool `json:"cancelling"`
Canceled bool `json:"canceled"`
FeesPaid *FeeBreakdown `json:"feesPaid"`
FundingCoins []dex.Bytes `json:"fundingCoins"`
FundingCoins []*Coin `json:"fundingCoins"`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This and the the Match changes rule out 0.1.x unfortunately, which is no big deal as we'll move on to 0.2.0 right away.

client/core/trade.go Outdated Show resolved Hide resolved
@chappjc chappjc added this to the 0.2.0 milestone Nov 2, 2020
@chappjc
Copy link
Member

chappjc commented Nov 7, 2020

Bump, but no rush. Just wanted to make sure this PR doesn't get lost.

@@ -56,6 +63,26 @@ func (c *Core) notify(n Notification) {
c.noteMtx.RUnlock()
}

// updateCoreMatch performs a targeted update of a match in the User struct.
func (c *Core) updateCoreMatch(n *MatchNote) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function and the way it's called from the notification feed might be a model for a solution to #379.

Copy link
Member

@chappjc chappjc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Working flawlessly.

@chappjc chappjc merged commit ecbfebd into decred:master Nov 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants