Package org.openmrs.module.htmlformentry.widget

Examples of org.openmrs.module.htmlformentry.widget.RemoteJsonAutocompleteWidget


                        else {
                valueWidget = new ConceptSearchAutocompleteWidget(conceptAnswers, cptClasses);
                        }
                    } else if (parameters.get("answerDrugs") != null) {
                        // we support searching through all drugs via AJAX
                        RemoteJsonAutocompleteWidget widget = new RemoteJsonAutocompleteWidget("/" + WebConstants.WEBAPP_NAME + "/module/htmlformentry/drugSearch.form");
                        widget.setValueTemplate("Drug:{{id}}");
                        if (parameters.get("displayTemplate") != null) {
                            widget.setDisplayTemplate(parameters.get("displayTemplate"));
                        } else {
                            widget.setDisplayTemplate("{{name}}");
                        }
                        if (existingObs != null && existingObs.getValueDrug() != null) {
                            widget.setInitialValue(new Option(existingObs.getValueDrug().getName(), existingObs.getValueDrug().getDrugId().toString(), true));
                        }
                        valueWidget = widget;

                    } else {
                  // Show Radio Buttons if specified, otherwise default to Drop
View Full Code Here

TOP

Related Classes of org.openmrs.module.htmlformentry.widget.RemoteJsonAutocompleteWidget

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.