This should not be necessary to hard-code.  You need to get the valid values from the server.  

See the "scriptTypes" variable on this page:

https://github.com/openmrs/openmrs-module-patientsummary/blob/master/omod/src/main/webapp/editTemplate.jsp