-
Notifications
You must be signed in to change notification settings - Fork 1
PP 1474 Invoice marked as paid - Parse the new payment sta… #840
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
base: main
Are you sure you want to change the base?
PP 1474 Invoice marked as paid - Parse the new payment sta… #840
Conversation
…te object PP-1474
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request implements a payment hints feature that displays warnings when invoices are marked as paid. The feature introduces a new warning bottom sheet dialog that shows when the analyzed document contains a payment state indicating the invoice has already been paid.
- Adds a new warning system with configurable payment hints to alert users about paid invoices
- Implements a reusable bottom sheet dialog component for displaying warnings with cancel/proceed actions
- Integrates payment state analysis from document extractions to trigger appropriate warnings
Reviewed Changes
Copilot reviewed 34 out of 34 changed files in this pull request and generated 7 comments.
Show a summary per file
File | Description |
---|---|
capture-sdk/sdk/src/main/res/values/styles.xml | Adds styles for bottom sheet dialog and circular warning icon background |
capture-sdk/sdk/src/main/res/values/strings.xml | Adds German localized strings for payment warning messages |
capture-sdk/sdk/src/main/res/values-en/strings.xml | Adds English localized strings for payment warning messages |
capture-sdk/sdk/src/main/res/layout/gc_warning_bottom_sheet.xml | Main layout for warning bottom sheet with icon, title, description, and action buttons |
capture-sdk/sdk/src/main/res/layout-sw600dp/gc_warning_bottom_sheet.xml | Tablet-optimized layout variant for warning bottom sheet |
capture-sdk/sdk/src/main/res/layout-sw600dp-land/gc_warning_bottom_sheet.xml | Tablet landscape layout variant for warning bottom sheet |
capture-sdk/sdk/src/main/res/layout-land/gc_warning_bottom_sheet.xml | Phone landscape layout variant with horizontal button arrangement |
capture-sdk/sdk/src/main/res/drawable/gc_warning.xml | SVG vector drawable for warning icon |
capture-sdk/sdk/src/main/res/drawable/gc_bg_warning_circle.xml | Circular background drawable for warning icon |
capture-sdk/sdk/src/main/java/net/gini/android/capture/paymentHints/GetPaymentHintsEnabledUseCase.kt | Use case for checking if payment hints feature is enabled |
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningType.java | Enum defining warning types with associated string resources |
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningPaymentState.java | Enum for parsing and handling payment states from document analysis |
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningBottomSheet.kt | Bottom sheet dialog component for displaying warnings with adaptive layout |
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/AnalysisScreenPresenter.java | Integrates payment state checking and warning display logic into analysis flow |
capture-sdk/sdk/src/main/java/net/gini/android/capture/GiniCapture.java | Adds payment hints configuration option to main SDK class |
bank-sdk/sdk/src/main/java/net/gini/android/bank/sdk/capture/Configuration.kt | Exposes payment hints configuration in bank SDK |
bank-api-library/library/src/main/java/net/gini/android/bank/api/models/Configuration.kt | Adds payment hints field to configuration model |
Comments suppressed due to low confidence (3)
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
capture-sdk/sdk/src/main/res/layout-sw600dp/gc_warning_bottom_sheet.xml
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/res/layout-sw600dp/gc_warning_bottom_sheet.xml
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/res/layout-sw600dp/gc_warning_bottom_sheet.xml
Outdated
Show resolved
Hide resolved
...-sdk/example-app/src/main/java/net/gini/android/bank/sdk/exampleapp/ui/data/Configuration.kt
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/AnalysisFragmentImpl.java
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/res/layout/gc_warning_bottom_sheet.xml
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/AnalysisScreenPresenter.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 34 out of 34 changed files in this pull request and generated 6 comments.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningBottomSheet.kt
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/AnalysisScreenPresenter.java
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/GiniCapture.java
Outdated
Show resolved
Hide resolved
...pi-library/library/src/main/java/net/gini/android/bank/api/response/ConfigurationResponse.kt
Outdated
Show resolved
Hide resolved
...pi-library/library/src/main/java/net/gini/android/bank/api/response/ConfigurationResponse.kt
Show resolved
Hide resolved
bank-sdk/sdk/src/main/java/net/gini/android/bank/sdk/capture/Configuration.kt
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/AnalysisScreenPresenter.java
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningBottomSheet.kt
Show resolved
Hide resolved
...ure-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningPaymentState.java
Outdated
Show resolved
Hide resolved
...ure-sdk/sdk/src/main/java/net/gini/android/capture/analysis/warning/WarningPaymentState.java
Outdated
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/di/CaptureSdkIsolatedKoinContext.kt
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/di/paymentHintsModule.kt
Show resolved
Hide resolved
capture-sdk/sdk/src/main/java/net/gini/android/capture/internal/ui/FragmentImplCallback.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MozhganPeivandianSharbaf there are some comments from my side, and also there are some comments from co-pilot, Which are valid in my opinion as well, Can you please address those? also when you fix the comments of co-pilot please mark them resolve, of if some comment you think is not valid, please add the comment and then mark it as resolve. Thank you so much for great work! 👍
capture-sdk/sdk/src/main/java/net/gini/android/capture/di/CaptureSdkIsolatedKoinContext.kt
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[Request]: Can you please use the camelCase for EInvoiceModule as well in EInvoiceModule.kt ? Thanks.
2f4ee1f
to
8f57b11
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now, Thanks @MozhganPeivandianSharbaf . 👌
…or improved structure and responsiveness PP-1474
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Thank you!
Description
WarningButtomSheet
andGetPaymentHintsEnabledUseCase
for handling WarningsAnalysisFragment
AnalysisScreenPresenter
AnalysisScreenContract
AnalysisFragmentImpl
GiniCapture
Notes for reviewer
I added a sdk and server Flag for PaymentHints Flag which is one flag for all warnings and for testing the branch you can use the invoice to see paid warning