Downloads Documentation Community Contribute Demo






Show Sidebar
Login | Register

Changeset 5214

Show
Ignore:
Timestamp:
08/08/08 18:02:49 (5 months ago)
Author:
r0bby
Message:

groovyforms: modify this to use a groovy solution

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openmrs-modules/groovyforms/src/org/openmrs/module/groovyforms/util/GroovyFormsUtil.groovy

    r5212 r5214  
    216216    static File moveJSPIntoContextPath(String id, ServletContext context) { 
    217217        def sb = new StringBuilder() 
    218         def src = getViewFile(id).newInputStream() 
    219218        def realPath = context.getRealPath("") 
    220219        sb << realPath << "${File.separator}WEB-INF${File.separator}view${File.separator}module${File.separator}groovyforms${File.separator}forms${File.separator}$id" 
     
    224223        } 
    225224        sb << "${File.separator}form.jsp" 
    226         f = new File(sb.toString()) 
    227         def dst = f.newOutputStream() 
    228         OpenmrsUtil.copyFile src, dst 
     225        f = new File(sb.toString()) << getViewFile(id).text         
    229226        f 
    230227    }