Back cdr : Endpoint to get total of validated payments - #1028
Open
Bombefire wants to merge 14 commits into
Open
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1028 +/- ##
===========================================
- Coverage 84.99% 51.36% -33.63%
===========================================
Files 220 220
Lines 16273 16291 +18
===========================================
- Hits 13831 8368 -5463
- Misses 2442 7923 +5481 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Luhmos
reviewed
Aug 16, 2026
armanddidierjean
force-pushed
the
total-purchase
branch
from
August 26, 2026 20:11
cfd70c4 to
dfd85eb
Compare
armanddidierjean
requested changes
Aug 26, 2026
| ) | ||
| total = result.scalar() | ||
|
|
||
| return total // 100 if total is not None else 0 |
Contributor
Author
There was a problem hiding this comment.
The total is stocked in cents in the db, if this is what you meant
| async def get_payment_total_by_type( | ||
| db: AsyncSession, | ||
| cdr_year: int, | ||
| ) -> list[schemas_cdr.PaymentBase]: |
Member
There was a problem hiding this comment.
A dedicated schema would be great
Co-authored-by: Armand Didierjean <95971503+armanddidierjean@users.noreply.github.com>
Co-authored-by: Armand Didierjean <95971503+armanddidierjean@users.noreply.github.com>
Co-authored-by: Armand Didierjean <95971503+armanddidierjean@users.noreply.github.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Summary
Adding the endpoint for Enceladus to have the total payment done in the CDR and have the total of purchase that have been validated by the sellers.
...
Issues/PR dependencies
A futur PR in Enceladus will come to make use of this endepoint
Issues to be resolved
Required PRs
Changes Made
Additional Notes
Classification
Type of Change
Impact & Scope
Testing
Documentation
"Docstrings#Inline comments