-
Notifications
You must be signed in to change notification settings - Fork 77
Exchange settings #1727
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
Merged
Merged
Exchange settings #1727
Changes from 8 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
aa1580a
feat: add recipients and transactions settings to exchange settings s…
mocodesmo 83ae0f8
Merge branch 'develop' into exchange-settings
mocodesmo c0274bd
feat: add email notifications settings and enhance exchange wallet ma…
mocodesmo fc90469
feat: enhance TransactionsCubit to support exchange-only transactions
mocodesmo 3bb5dc4
feat: update ExchangeRecipientsScreen to handle recipient selection
mocodesmo ac5a128
feat: enhance updateMyRecipient and deleteDefaultWallet functionality
mocodesmo e37887b
feat: implement KYC document upload and status management
mocodesmo c8b5189
Merge branch 'develop' into exchange-settings
mocodesmo 8c412f2
feat: refactor KYC document upload to use multipart form data
mocodesmo 9f62191
feat: enhance KYC document upload and status management
mocodesmo 57ae3be
restructured reusable recipients screen, recipients bloc and how pay …
kumulynja e5a685b
remove info logs for debugging + unused gap import
kumulynja 8efe8a4
Merge pull request #1786 from SatoshiPortal/recipients-reuse-improvem…
kumulynja 91a02d5
Merge branch 'develop' into exchange-settings
i5hi cb4ef9a
fix: remove recipients router
i5hi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| import 'package:bb_mobile/core/exchange/domain/entity/file_upload.dart'; | ||
|
|
||
| /// Model for KYC document upload request | ||
| class KycUploadRequestModel { | ||
| final String fileName; | ||
| final List<int> fileBytes; | ||
| final KycDocType docType; | ||
| final KycSourceDetail sourceDetail; | ||
|
|
||
| const KycUploadRequestModel({ | ||
| required this.fileName, | ||
| required this.fileBytes, | ||
| required this.docType, | ||
| required this.sourceDetail, | ||
| }); | ||
|
|
||
| String get docTypeValue { | ||
| switch (docType) { | ||
| case KycDocType.id: | ||
| return 'ID'; | ||
| case KycDocType.proofOfAddress: | ||
| return 'PROOF_OF_ADDRESS'; | ||
| case KycDocType.other: | ||
| return 'OTHER'; | ||
| } | ||
| } | ||
|
|
||
| String get sourceDetailValue { | ||
| switch (sourceDetail) { | ||
| case KycSourceDetail.secureUpload: | ||
| return 'SECURE_UPLOAD'; | ||
| case KycSourceDetail.kyc: | ||
| return 'KYC'; | ||
| } | ||
| } | ||
| } | ||
|
|
||
| /// Enum for KYC document types | ||
| enum KycDocType { | ||
| id, | ||
| proofOfAddress, | ||
| other, | ||
| } | ||
|
|
||
| /// Enum for KYC source details | ||
| enum KycSourceDetail { | ||
| secureUpload, | ||
| kyc, | ||
| } | ||
|
|
||
| /// Model for KYC upload response | ||
| class KycUploadResponseModel { | ||
| final String? documentId; | ||
| final String? status; | ||
|
|
||
| const KycUploadResponseModel({ | ||
| this.documentId, | ||
| this.status, | ||
| }); | ||
|
|
||
| factory KycUploadResponseModel.fromJson(Map<String, dynamic> json) { | ||
| return KycUploadResponseModel( | ||
| documentId: json['documentId'] as String?, | ||
| status: json['status'] as String?, | ||
| ); | ||
| } | ||
|
|
||
| FileUploadResult toEntity() { | ||
| return FileUploadResult( | ||
| documentId: documentId, | ||
| isSuccess: status == 'SUCCESS' || documentId != null, | ||
| ); | ||
| } | ||
| } | ||
|
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.