dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #22595
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 10900: Not allow to enroll the enroll-one-time program many times in Enrollment form
------------------------------------------------------------
revno: 10900
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2013-05-21 09:30:31 +0700
message:
Not allow to enroll the enroll-one-time program many times in Enrollment form
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/ProgramEnrollmentSelectAction.java
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/ProgramEnrollmentSelectAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/ProgramEnrollmentSelectAction.java 2013-05-15 09:14:57 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/ProgramEnrollmentSelectAction.java 2013-05-21 02:30:31 +0000
@@ -120,6 +120,7 @@
programs.addAll( programService.getProgramsByDisplayOnAllOrgunit( false, orgunit ) );
programs.retainAll( programService.getProgramsByCurrentUser() );
programs.removeAll( programService.getPrograms( Program.SINGLE_EVENT_WITHOUT_REGISTRATION ) );
+ programs.removeAll( patient.getPrograms() );
Collection<ProgramInstance> programInstances = programInstanceService.getProgramInstances( patient, ProgramInstance.STATUS_ACTIVE );