Skip to content

Conversation

Syn-McJ
Copy link
Member

@Syn-McJ Syn-McJ commented Feb 21, 2023

Issue being fixed or feature implemented

Because we request CrowdNode withdrawals in percentage from the total balance, the amount user requested can be different from the received amount.
We want to reflect this in UI as a confirmation dialog showing the final amount.

What was done?

  • UI for the confirmation dialog. On ios 16+ it is a bottom sheet with variable height.
  • Calculating the final amount the user will receive.
  • Some fixes.

How Has This Been Tested?

QA

Breaking Changes

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

@Syn-McJ Syn-McJ requested a review from tikhop February 21, 2023 10:34
@Syn-McJ Syn-McJ self-assigned this Feb 21, 2023
@@ -127,7 +127,6 @@ public final class CrowdNode {
init() {
masternodeAPY = DWEnvironment.sharedInstance().apy.doubleValue
crowdnodeAPY = masternodeAPY * 0.85
accountAddress = prefs.crowdNodeAccountAddress ?? "" // Restore from user default
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 seems to be causing some problems. When we change the network, sometimes the saved address sticks for some reason and we get the wrong state for CrowdNode.

I figure we can get the saved address from the FullCrowdNodeSignUpTxSet directly and keep the normal restoring logic in here to avoid issues.

@Syn-McJ Syn-McJ changed the title Feature/crowdnode withdrawal confirmation feat(crowdnode): Withdrawal confirmation dialog Feb 21, 2023
Copy link
Contributor

@tikhop tikhop left a comment

Choose a reason for hiding this comment

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

Approved

@Syn-McJ Syn-McJ merged commit 40abb05 into dashpay:feature/crowdnode Feb 21, 2023
@Syn-McJ Syn-McJ deleted the feature/crowdnode-withdrawal-confirmation branch February 21, 2023 12:10
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