-
Notifications
You must be signed in to change notification settings - Fork 43
Release 3.8.0 to main #171
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?
Changes from all commits
db1c562
0c3b09a
c7a52a4
cce05f3
2ad699b
64e89b8
39debc2
cbe8fe2
0590a0c
8b862a8
1cf6c07
c32deba
a6818d4
3703ac6
6bdd822
58f3d5c
c16275a
a137f00
e96a152
ef58275
452b809
0f4f378
b46f369
08e5d8c
cb67c59
7022cc4
c8e7c94
b20c801
1daa411
9e1fa0a
8a9b68a
46e4911
2c13c3b
4340aed
af82844
1de7c5b
6f23596
1c2ba64
9d7ded3
f9471c8
26f29a8
25a0486
0021215
692679b
3ceef0a
59c5ef7
553a6c6
9fa1857
b95b68e
bc39ce1
f46b693
3162f66
c1e2e2d
853ec97
52caaa1
d75ed23
028e1b7
6258dae
5367efa
ee77095
c3e95f2
effbfcc
8d83a9a
3b7dd52
1d8dbe7
1801efe
594ab59
ec021c4
5a83005
32db7e1
a90fe13
59dbd6c
dc2ad36
107d6a9
f1ec971
ad138d7
40924cb
83b6046
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -22,7 +22,9 @@ | |
| package com.iemr.common.identity.repo.rmnch; | ||
|
|
||
| import java.math.BigInteger; | ||
| import java.util.List; | ||
|
|
||
| import io.swagger.v3.oas.annotations.info.License; | ||
| import org.springframework.data.jpa.repository.Query; | ||
| import org.springframework.data.repository.CrudRepository; | ||
| import org.springframework.data.repository.query.Param; | ||
|
|
@@ -35,8 +37,16 @@ public interface RMNCHBenDetailsRepo extends CrudRepository<RMNCHMBeneficiarydet | |
| @Query(" SELECT t FROM RMNCHMBeneficiarydetail t WHERE t.id = :vanSerialNo AND t.VanID = :vanID") | ||
| public RMNCHMBeneficiarydetail getByIdAndVanID(@Param("vanSerialNo") BigInteger vanSerialNo, | ||
| @Param("vanID") int vanID); | ||
|
|
||
| @Query(" SELECT t FROM RMNCHMBeneficiarydetail t WHERE t.id = " + | ||
| "(SELECT m.benDetailsId from RMNCHMBeneficiarymapping m where m.benRegId = :beneficiaryRegID)") | ||
| public RMNCHMBeneficiarydetail getByBenRegID(@Param("beneficiaryRegID") BigInteger beneficiaryRegID); | ||
|
|
||
| @Query(""" | ||
| SELECT t | ||
| FROM RMNCHMBeneficiarydetail t | ||
| WHERE t.id IN ( | ||
| SELECT m.benDetailsId | ||
| FROM RMNCHMBeneficiarymapping m | ||
| WHERE m.benRegId = :beneficiaryRegID | ||
| ) | ||
| """) | ||
| List<RMNCHMBeneficiarydetail> getByBenRegID( | ||
| @Param("beneficiaryRegID") BigInteger beneficiaryRegID); | ||
|
Comment on lines
+40
to
+51
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ποΈ Data Integrity & Integration | π Major | β‘ Quick win π§© Analysis chainπ Script executed: #!/bin/bash
set -euo pipefail
printf '\n== repo file ==\n'
sed -n '1,140p' src/main/java/com/iemr/common/identity/repo/rmnch/RMNCHBenDetailsRepo.java
printf '\n== usages ==\n'
rg -n "getByBenRegID\\(" src/main/java
printf '\n== service excerpt ==\n'
sed -n '140,230p' src/main/java/com/iemr/common/identity/service/impl/RmnchDataSyncServiceImpl.java
printf '\n== related entities ==\n'
rg -n "class RMNCHMBeneficiary(mapping|detail)|`@Table`|`@OrderBy`|`@OneToMany`|`@ManyToOne`" src/main/java/com/iemr/common/identity -g '*.java'Repository: PSMRI/Identity-API Length of output: 2763 π Script executed: #!/bin/bash
set -euo pipefail
printf '\n== service excerpt ==\n'
sed -n '160,210p' src/main/java/com/iemr/common/identity/service/rmnch/RmnchDataSyncServiceImpl.java
printf '\n== mapping entity ==\n'
sed -n '1,240p' src/main/java/com/iemr/common/identity/data/rmnch/RMNCHMBeneficiarymapping.java
printf '\n== detail entity ==\n'
sed -n '1,240p' src/main/java/com/iemr/common/identity/data/rmnch/RMNCHMBeneficiarydetail.java
printf '\n== repo/entity references ==\n'
rg -n "benRegId|benDetailsId|`@Id`|`@OneToMany`|`@ManyToOne`|`@JoinColumn`|`@OrderBy`|`@UniqueConstraint`|unique = true" src/main/java/com/iemr/common/identity/data/rmnch src/main/java/com/iemr/common/identity/service/rmnch -g '*.java'Repository: PSMRI/Identity-API Length of output: 12835 π Script executed: #!/bin/bash
set -euo pipefail
printf '\n== benDetailsId usages ==\n'
rg -n "setBenDetailsId|getBenDetailsId|benDetailsId" src/main/java -g '*.java'
printf '\n== benRegId usages ==\n'
rg -n "setBenRegId|getBenRegId|benRegId" src/main/java -g '*.java'
printf '\n== ddl/schema hints ==\n'
rg -n "i_beneficiarymapping|beneficiarymapping|BenDetailsId|BenRegId|unique constraint|UNIQUE" . -g '*.{sql,java,xml,yml,yaml,properties}'Repository: PSMRI/Identity-API Length of output: 50374 π Script executed: #!/bin/bash
set -euo pipefail
printf '\n== DDL / migration hits ==\n'
rg -n "i_beneficiarymapping|i_beneficiarydetails|BenRegId|BenDetailsId|UNIQUE|unique" src/main/resources src/main/java -g '*.{sql,xml,yml,yaml,properties,java}' | head -n 200
printf '\n== RMNCH detail-related repos ==\n'
sed -n '1,120p' src/main/java/com/iemr/common/identity/repo/rmnch/RMNCHBeneficiaryDetailsRmnchRepo.java
printf '\n== mapping-repo methods near benRegId ==\n'
sed -n '35,120p' src/main/java/com/iemr/common/identity/repo/rmnch/RMNCHMBenRegIdMapRepo.javaRepository: PSMRI/Identity-API Length of output: 32316 Make the first beneficiary detail selection deterministic. π€ Prompt for AI Agents |
||
| } | ||
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.
π Maintainability & Code Quality | π Major | β‘ Quick win
Likely typo in endpoint path and missing Swagger
@Operationannotation./getRmnchDataByBenRedIDlooks like a typo of "BenRegID" (the service method underneath isgetRmnchDataByBenID, and the domain concept isbenRegIDthroughout the file). Since this is a brand-new endpoint, fixing the name now avoids baking a typo into the public API surface. Also, every other endpoint here carries an@Operationsummary for Swagger docs; this one doesn't.As per coding guidelines,
**/controller/**/*.java: "Use SpringDoc OpenAPI (Swagger UI) for API documentation accessible at/swagger-ui.html".π Committable suggestion
π€ Prompt for AI Agents
Source: Coding guidelines