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

Add option to see orders of all coins in the order panel [WIP] #377

Closed
wants to merge 7 commits into from

Conversation

Zkffkah
Copy link

@Zkffkah Zkffkah commented May 28, 2019

This pr resolve #373.
Add a tab in the orders panel to toggle options for showing orders for all coins.

Copy link
Member

@badgerwithagun badgerwithagun left a comment

Choose a reason for hiding this comment

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

Looks fantastic. Just reformatting and one small performance change and this can be merged.

Thank you!

orko-ui/src/containers/OrdersContainer.js Outdated Show resolved Hide resolved
orko-ui/src/containers/OpenOrdersContainer.js Outdated Show resolved Hide resolved
@Zkffkah
Copy link
Author

Zkffkah commented May 29, 2019

I think we should add exchange and name column to the orders panel too?

@badgerwithagun
Copy link
Member

Yeah. Only when showing all orders.

@Zkffkah
Copy link
Author

Zkffkah commented May 29, 2019

While digging the subscribe and update problem, I notice a bug in the coins panel. When you switch ticker, like currently in ltc and click btc, there will be three history change trigger (btc -> ltc -> btc)and result in three resubscribe. Are you aware of that?

@badgerwithagun
Copy link
Member

I wasn't, no. Can you post a screenshot from the browser web dev panel showing the messages?

@Zkffkah
Copy link
Author

Zkffkah commented May 30, 2019

Here I switch from ltc to eos.
A
B
Also, there is a redundant coin in the subscribedCoins.
C

@Zkffkah
Copy link
Author

Zkffkah commented May 30, 2019

We need to move dispatch out of history.listen to solve this. Maybe a middleware?

@Zkffkah
Copy link
Author

Zkffkah commented May 30, 2019

For the all orders update problem, maybe we subscribe order update for all subscribed coins like the ticker and move the order state out to a separate reducer like ticker too?

@badgerwithagun
Copy link
Member

Just to let you know: I will be busy for the next few days so may not have a chance to look at this until I have some home PC time.

Looks interesting though - I think I may have seem symptoms of this issue in other places.

@badgerwithagun
Copy link
Member

Hey @lowwor - can we move the subscribe issue to a separate issue/PR and discuss there? Would make it easier to tackle one thing per PR.

@Zkffkah
Copy link
Author

Zkffkah commented Jun 8, 2019

Yeah, see #394.

@badgerwithagun
Copy link
Member

Great, thanks. How's it going with this one? Can I help?

@Zkffkah
Copy link
Author

Zkffkah commented Jun 11, 2019

Yeah, I am thinking of one situation, what if we delete the ticker in the ticker panel, then all orders may not include the deleted ones.

function orderDecorate(order, exchanges) {
return {
...order,
exchangeMeta: exchanges.find(e => e.code === order.coin.exchange)
Copy link
Member

Choose a reason for hiding this comment

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

I'd do this find once and pass it to both decorate methods.

Copy link
Author

Choose a reason for hiding this comment

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

Yeah, but for all coins' order, still need to find for each order, so I just left it there.

@badgerwithagun
Copy link
Member

Not sure what you mean. Could you clarify?

@Zkffkah
Copy link
Author

Zkffkah commented Jun 12, 2019

If we have orders of the deleted ticker, then we may not subscribe to the deleted ticker, so we would not get the orders of the deleted ticker. But this is a problem we already have even without this pr. Maybe we skip it here.

@badgerwithagun badgerwithagun changed the title Add option to see orders of all coins in the order panel Add option to see orders of all coins in the order panel [WIP] Jul 5, 2019
@Zkffkah
Copy link
Author

Zkffkah commented Oct 28, 2019

I will close this for now since we are in the refactor process. I will check back when we are stable again.

@Zkffkah Zkffkah closed this Oct 28, 2019
@badgerwithagun
Copy link
Member

@all-contributors add lowwor for code

@allcontributors
Copy link
Contributor

@badgerwithagun

I've put up a pull request to add @lowwor! 🎉

@badgerwithagun
Copy link
Member

@all-contributors add lowwor for userTesting

@allcontributors
Copy link
Contributor

@badgerwithagun

I've updated the pull request to add @lowwor! 🎉

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.

Add option to see orders of all coins in the order panel
2 participants