-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate some calls to FHIR and GraphQL (#86)
* Github Action: manual build * Update activity_about.xml * Updated java version in github actions * github actions: Changes cache from maven to gradle * Revert "OTC-745 Implemented claim 2-way sync" * Migrate some calls to FHIR and GraphQL (WIP) The new implementation relies on OkHttp and Apollo. OkHttp was added because the current implementation relies on Apache HTTP client, which is not supported anymore since Android 6 (API 23). A version supports Android 23+, but Apache does not officially maintain it. Also, OkHttp is the current standard and comes with lots of benefits like, among other things, the logger, automatic support for GZip, and a strong security focus. Apollo is in its version 2 as version 3+ requires Kotlin Coroutines. Also, the plan is that some new endpoints or extensions could be added to the FHIR API to remove the dependency on GraphQL. Everything is hidden behind use cases to impact as less as possible the current code base. Also, migrate to AndroidX because of Apollo's dependencies. The versions of the AndroidX have been kept back to avoid conflicts and upgrades. * Moving the claim creation to FHIR (WIP) This depends on a modification of the backend which would allow to pass a reference with an OpenIMIS Code rather than a UUID. There is still an open question about the "REJECTED" status to be solved. OMT-339 * Moving GetControls to GraphQL Deleting `ToRestApi` and removing Apache HTTP dependencies. Adding a way to change the "Login/Logout" button automatically on login. This depends on a new module migrating the controls to GraphQL that has not yet been merged. OMT-339 * Improve "Add claim" UI * PR comments * Fix issues after first review * Detect "REJECTED" status Based on the method `build_fhir_total_list` in the Python code, if there is no total, the claim is rejected. * Fix error message when Insuree is not found --------- Co-authored-by: Dragos DOBRE <[email protected]> Co-authored-by: Eric Darchis <[email protected]> Co-authored-by: malinowskikam <[email protected]> Co-authored-by: Kamil Malinowski <[email protected]> Co-authored-by: Patrick Delcroix <[email protected]>
- Loading branch information
1 parent
436f2f6
commit ae0015e
Showing
124 changed files
with
14,143 additions
and
3,099 deletions.
There are no files selected for viewing
This file contains 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 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 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 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
80 changes: 80 additions & 0 deletions
80
claimManagement/src/main/graphql/org.openimis.imisclaim/GetClaims.graphql
This file contains 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,80 @@ | ||
query GetClaims($claim_administrator_code: String, $status_claim: Int, $visit_date_from: Date, $visit_date_to: Date, $processed_date_from: Date, $processed_date_to: Date) { | ||
claims( | ||
admin_Code: $claim_administrator_code | ||
status: $status_claim | ||
dateClaimed_Gte: $visit_date_from | ||
dateClaimed_Lte: $visit_date_to | ||
dateProcessed_Lte: $processed_date_to | ||
dateProcessed_Gte: $processed_date_from | ||
) { | ||
totalCount | ||
edges { | ||
node { | ||
uuid | ||
code | ||
healthFacility { | ||
code | ||
name | ||
} | ||
insuree { | ||
chfId | ||
lastName | ||
otherNames | ||
} | ||
icd { | ||
name | ||
} | ||
icd1 { | ||
name | ||
} | ||
icd2 { | ||
name | ||
} | ||
icd3 { | ||
name | ||
} | ||
icd4 { | ||
name | ||
} | ||
dateClaimed | ||
dateFrom | ||
dateTo | ||
validityFrom | ||
validityTo | ||
visitType | ||
status | ||
claimed | ||
approved | ||
adjustment | ||
explanation | ||
guaranteeId | ||
services { | ||
qtyProvided | ||
qtyApproved | ||
priceAdjusted | ||
priceValuated | ||
explanation | ||
justification | ||
service { | ||
code | ||
name | ||
price | ||
} | ||
} | ||
items { | ||
qtyProvided | ||
qtyApproved | ||
priceAdjusted | ||
priceValuated | ||
explanation | ||
justification | ||
item { | ||
code | ||
name | ||
price | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
claimManagement/src/main/graphql/org.openimis.imisclaim/GetControls.graphql
This file contains 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,11 @@ | ||
query GetControls { | ||
control{ | ||
edges{ | ||
node{ | ||
name | ||
usage | ||
adjustability | ||
} | ||
} | ||
} | ||
} |
63 changes: 63 additions & 0 deletions
63
claimManagement/src/main/graphql/org.openimis.imisclaim/GetInsureeInquire.graphql
This file contains 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,63 @@ | ||
query GetInsureeInquire($chfId: String) { | ||
insurees( | ||
chfId: $chfId | ||
) { | ||
edges { | ||
node { | ||
chfId | ||
lastName | ||
otherNames | ||
dob | ||
gender { | ||
gender | ||
} | ||
photos { | ||
folder | ||
filename | ||
photo | ||
} | ||
insureePolicies { | ||
edges { | ||
node { | ||
policy { | ||
product { | ||
name | ||
code | ||
ceiling | ||
ceilingIp | ||
ceilingOp | ||
deductible | ||
deductibleIp | ||
deductibleOp | ||
maxNoAntenatal | ||
maxAmountAntenatal | ||
maxNoSurgery | ||
maxAmountSurgery | ||
maxNoConsultation | ||
maxAmountConsultation | ||
maxNoDelivery | ||
maxAmountDelivery | ||
maxNoHospitalization | ||
maxAmountHospitalization | ||
maxMembers | ||
maxNoVisits | ||
maxInstallments | ||
maxCeilingPolicy | ||
maxCeilingPolicyIp | ||
maxCeilingPolicyOp | ||
maxPolicyExtraMember | ||
maxPolicyExtraMemberIp | ||
maxPolicyExtraMemberOp | ||
} | ||
enrollDate | ||
expiryDate | ||
status | ||
value | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
claimManagement/src/main/graphql/org.openimis.imisclaim/GetPaymentList.graphql
This file contains 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,38 @@ | ||
query GetPaymentList($claim_administrator_code: String) { | ||
claimAdmins(code: $claim_administrator_code) { | ||
edges { | ||
node { | ||
code | ||
healthFacility { | ||
code | ||
servicesPricelist { | ||
details { | ||
edges { | ||
node { | ||
service { | ||
code | ||
name | ||
price | ||
} | ||
} | ||
} | ||
} | ||
} | ||
itemsPricelist { | ||
details { | ||
edges { | ||
node { | ||
item { | ||
code | ||
name | ||
price | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.