Downloads Documentation Community Contribute Demo






Show Sidebar
Login | Register

Changeset 4886

Show
Ignore:
Timestamp:
07/09/08 19:25:54 (6 months ago)
Author:
bwolfe
Message:

Fixing new patient form controller data persistence when an error is submitted

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openmrs/trunk/src/web/org/openmrs/web/controller/patient/NewPatientFormController.java

    r4873 r4886  
    566566                                model.put(getCommandName(), new ShortPatientModel(patient)); 
    567567                                 
     568                                // evict from session so that nothing temporarily added here is saved 
     569                                Context.evictFromSession(patient); 
     570                                 
    568571                                return this.showForm(request, response, errors, model); 
    569572                                //return new ModelAndView(new RedirectView(getFormView())); 
     
    655658                Map<String, Object> map = new HashMap<String, Object>(); 
    656659                 
    657                 // the list of identifiers to display  
    658                 Set<PatientIdentifier> identifiers = new TreeSet<PatientIdentifier>(); 
     660                // the list of identifiers to display 
     661                // this is a hashset so that the comparison is one with .equals() instead of .compareTo 
     662                Set<PatientIdentifier> identifiers = new HashSet<PatientIdentifier>(); 
    659663                 
    660664                Patient patient = null;