[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openmrs-svn
Subject:    [30987] openmrs-modules/chica/branches/cerner/web: Electronic PWS updates.
From:       svn-noreply () openmrs ! org
Date:       2014-11-03 21:36:21
Message-ID: 20141103213622.03BB2401A1 () openmrs ! osuosl ! org
[Download RAW message or body]

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[30987] openmrs-modules/chica/branches/cerner/web: Electronic PWS \
updates.</title> </head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: \
verdana,arial,helvetica,sans-serif; font-size: 10pt;  } #msg dl a { font-weight: \
bold} #msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: \
bold; } #msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: \
6px; } #logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em \
0; } #logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg \
h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; } \
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; \
} #logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: \
-1.5em; padding-left: 1.5em; } #logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em \
1em 0 1em; background: white;} #logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid \
#fa0; border-bottom: 1px solid #fa0; background: #fff; } #logmsg table th { \
text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted \
#fa0; } #logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: \
0.2em 0.5em; } #logmsg table thead th { text-align: center; border-bottom: 1px solid \
#fa0; } #logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: \
6px; } #patch { width: 100%; }
#patch h4 {font-family: \
verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
 #patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, \
#patch .copfile {border:1px solid #ccc;margin:10px 0;} #patch ins \
{background:#dfd;text-decoration:none;display:block;padding:0 10px;} #patch del \
{background:#fdd;text-decoration:none;display:block;padding:0 10px;} #patch .lines, \
                .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd>30987</dd>
<dt>Author</dt> <dd>sjmckee</dd>
<dt>Date</dt> <dd>2014-11-03 21:36:21 +0000 (Mon, 03 Nov 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Electronic PWS updates.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#openmrsmoduleschicabranchescernerwebmoduleforcePrintJITsjsp">openmrs-modules/chica/branches/cerner/web/module/forcePrintJITs.jsp</a></li>
 <li><a href="#openmrsmoduleschicabranchescernerwebmoduleresourcesforcePrintJITscss">o \
penmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.css</a></li> \
<li><a href="#openmrsmoduleschicabranchescernerwebmoduleresourcesforcePrintJITsjs">ope \
nmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.js</a></li> \
<li><a href="#openmrsmoduleschicabranchescernerwebsrcorgopenmrsmodulechicawebChicaMobi \
leServletjava">openmrs-modules/chica/branches/cerner/web/src/org/openmrs/module/chica/web/ChicaMobileServlet.java</a></li>
 </ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="openmrsmoduleschicabranchescernerwebmoduleforcePrintJITsjsp"></a>
<div class="modfile"><h4>Modified: \
openmrs-modules/chica/branches/cerner/web/module/forcePrintJITs.jsp (30986 => \
30987)</h4> <pre class="diff"><span>
<span class="info">--- \
openmrs-modules/chica/branches/cerner/web/module/forcePrintJITs.jsp	2014-11-03 \
                19:41:26 UTC (rev 30986)
+++ openmrs-modules/chica/branches/cerner/web/module/forcePrintJITs.jsp	2014-11-03 \
21:36:21 UTC (rev 30987) </span><span class="lines">@@ -13,38 +13,40 @@
</span><span class="cx"> &lt;title&gt;Force Print Handouts&lt;/title&gt;	
</span><span class="cx"> &lt;/head&gt;
</span><span class="cx"> &lt;body&gt;
</span><del>-	&lt;form&gt;
-		 &lt;div id=&quot;formsLoading&quot;&gt;
-             &lt;span id=&quot;formsLoadingPanel&quot;&gt;&lt;img \
src=&quot;/openmrs/moduleResources/chica/images/ajax-loader.gif&quot;/&gt;Loading \
                forms...&lt;/span&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;formsServerError&quot;&gt;
-             &lt;div id=&quot;formsServerErrorText&quot; \
                class=&quot;ui-state-error&quot;&gt;&lt;/div&gt;
-             &lt;br/&gt;&lt;br/&gt;&lt;a href=&quot;#&quot; \
id=&quot;retryButton&quot; class=&quot;icon-button ui-state-default \
                ui-corner-all&quot;&gt;Retry&lt;/a&gt;
-             &lt;a href=&quot;#&quot; id=&quot;retryCloseButton&quot; \
                class=&quot;icon-button ui-state-default \
                ui-corner-all&quot;&gt;Close&lt;/a&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;formsContainer&quot;&gt;
-             &lt;fieldset&gt;
-                 &lt;label for=&quot;forms&quot;&gt;Select a form&lt;/label&gt;
-                 &lt;select name=&quot;forms&quot; \
                id=&quot;forms&quot;&gt;&lt;/select&gt;
-             &lt;/fieldset&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;buttonPanel&quot;&gt;
-             &lt;a href=&quot;#&quot; id=&quot;createButton&quot; \
                class=&quot;icon-button ui-state-default \
                ui-corner-all&quot;&gt;Create&lt;/a&gt;
-             &lt;a href=&quot;#&quot; id=&quot;closeButton&quot; \
                class=&quot;icon-button ui-state-default \
                ui-corner-all&quot;&gt;Close&lt;/a&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;frameContainer&quot;&gt;
-            &lt;iframe id=&quot;formFrame&quot; src=&quot;&quot; \
                frameBorder=&quot;0&quot; seamless&gt;&lt;/iframe&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;frameLoading&quot;&gt;
-            &lt;span id=&quot;frameLoadingPanel&quot;&gt;&lt;img \
src=&quot;/openmrs/moduleResources/chica/images/ajax-loader.gif&quot;/&gt;Creating \
                form...&lt;/span&gt;
-         &lt;/div&gt;
-         &lt;div id=&quot;frameError&quot;&gt;
-            &lt;div id=&quot;frameServerErrorText&quot; \
                class=&quot;ui-state-error&quot;&gt;&lt;/div&gt;
-         &lt;/div&gt;
-         &lt;input type=&quot;hidden&quot; value=&quot;${patientId}&quot; \
                id=&quot;patientId&quot; /&gt;
-         &lt;input type=&quot;hidden&quot; value=&quot;${sessionId}&quot; \
                id=&quot;sessionId&quot; /&gt;
-         &lt;input type=&quot;hidden&quot; value=&quot;${locationId}&quot; \
                id=&quot;locationId&quot; /&gt;
-         &lt;input type=&quot;hidden&quot; value=&quot;${locationTagId}&quot; \
                id=&quot;locationTagId&quot; /&gt;
-	&lt;/form&gt;
</del><ins>+    &lt;div id=&quot;content&quot;&gt;
+		&lt;form&gt;
+			 &lt;div id=&quot;formsLoading&quot;&gt;
+	             &lt;span id=&quot;formsLoadingPanel&quot;&gt;&lt;img \
src=&quot;/openmrs/moduleResources/chica/images/ajax-loader.gif&quot;/&gt;Loading \
forms...&lt;/span&gt; +	         &lt;/div&gt;
+	         &lt;div id=&quot;formsServerError&quot;&gt;
+	             &lt;div id=&quot;formsServerErrorText&quot; \
class=&quot;ui-state-error&quot;&gt;&lt;/div&gt; +	             \
&lt;br/&gt;&lt;br/&gt;&lt;a href=&quot;#&quot; id=&quot;retryButton&quot; \
class=&quot;icon-button ui-state-default ui-corner-all&quot;&gt;Retry&lt;/a&gt; +	    \
&lt;a href=&quot;#&quot; id=&quot;retryCloseButton&quot; class=&quot;icon-button \
ui-state-default ui-corner-all&quot;&gt;Close&lt;/a&gt; +	         &lt;/div&gt;
+	         &lt;div id=&quot;formsContainer&quot;&gt;
+	             &lt;fieldset&gt;
+	                 &lt;label for=&quot;forms&quot;&gt;Select a form&lt;/label&gt;
+	                 &lt;select name=&quot;forms&quot; \
id=&quot;forms&quot;&gt;&lt;/select&gt; +	             &lt;/fieldset&gt;
+	         &lt;/div&gt;
+	         &lt;div id=&quot;buttonPanel&quot;&gt;
+	             &lt;a href=&quot;#&quot; id=&quot;createButton&quot; \
class=&quot;icon-button ui-state-default ui-corner-all&quot;&gt;Create&lt;/a&gt; +	   \
&lt;a href=&quot;#&quot; id=&quot;closeButton&quot; class=&quot;icon-button \
ui-state-default ui-corner-all&quot;&gt;Close&lt;/a&gt; +	         &lt;/div&gt;
+	         &lt;div id=&quot;frameContainer&quot;&gt;
+	            &lt;iframe id=&quot;formFrame&quot; src=&quot;&quot; \
frameBorder=&quot;0&quot; seamless \
onload=&quot;iframeLoaded()&quot;&gt;&lt;/iframe&gt; +	         &lt;/div&gt;
+	         &lt;div id=&quot;frameLoading&quot;&gt;
+	            &lt;span id=&quot;frameLoadingPanel&quot;&gt;&lt;img \
src=&quot;/openmrs/moduleResources/chica/images/ajax-loader.gif&quot;/&gt;Creating \
form...&lt;/span&gt; +	         &lt;/div&gt;
+	         &lt;div id=&quot;frameError&quot;&gt;
+	            &lt;div id=&quot;frameServerErrorText&quot; \
class=&quot;ui-state-error&quot;&gt;&lt;/div&gt; +	         &lt;/div&gt;
+	         &lt;input type=&quot;hidden&quot; value=&quot;${patientId}&quot; \
id=&quot;patientId&quot; /&gt; +	         &lt;input type=&quot;hidden&quot; \
value=&quot;${sessionId}&quot; id=&quot;sessionId&quot; /&gt; +	         &lt;input \
type=&quot;hidden&quot; value=&quot;${locationId}&quot; id=&quot;locationId&quot; \
/&gt; +	         &lt;input type=&quot;hidden&quot; value=&quot;${locationTagId}&quot; \
id=&quot;locationTagId&quot; /&gt; +		&lt;/form&gt;
+	&lt;/div&gt;
</ins><span class="cx"> &lt;/body&gt;
</span><span class="cx"> &lt;/page&gt;
</span></span></pre></div>
<a id="openmrsmoduleschicabranchescernerwebmoduleresourcesforcePrintJITscss"></a>
<div class="modfile"><h4>Modified: \
openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.css (30986 \
=> 30987)</h4> <pre class="diff"><span>
<span class="info">--- \
openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.css	2014-11-03 \
                19:41:26 UTC (rev 30986)
+++ openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.css	2014-11-03 \
21:36:21 UTC (rev 30987) </span><span class="lines">@@ -1,3 +1,19 @@
</span><ins>+#content {
+    background-color: #F5FBEF;
+    width: 80%;
+    display: block;
+    margin-left: auto;
+    margin-right: auto;
+    text-align: center;
+    padding: 20px;
+    box-shadow: 10px 10px 5px #2E2E2E;
+    -webkit-box-shadow: 10px 10px 5px #2E2E2E;
+    -moz-box-shadow: 10px 10px 5px #2E2E2E;
+    border-radius: 10px;
+    -webkit-border-radius: 10px;
+    -moz-border-radius: 10px;
+}
+
</ins><span class="cx"> #formsLoading {
</span><span class="cx">     text-align: center;
</span><span class="cx">     margin: 0 auto;
</span><span class="lines">@@ -43,7 +59,8 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> body {
</span><del>-	background-color:#F5FBEF;
</del><ins>+    font-size:14px;
+    background: #b24926;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> iframe {
</span></span></pre></div>
<a id="openmrsmoduleschicabranchescernerwebmoduleresourcesforcePrintJITsjs"></a>
<div class="modfile"><h4>Modified: \
openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.js (30986 \
=> 30987)</h4> <pre class="diff"><span>
<span class="info">--- \
openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.js	2014-11-03 \
                19:41:26 UTC (rev 30986)
+++ openmrs-modules/chica/branches/cerner/web/module/resources/forcePrintJITs.js	2014-11-03 \
21:36:21 UTC (rev 30987) </span><span class="lines">@@ -1,11 +1,18 @@
</span><ins>+var isIE = true;
</ins><span class="cx"> $(document).ready(function () {
</span><ins>+	isIE = checkForIE();
</ins><span class="cx"> 	$(window).resize(function() {
</span><span class="cx"> 		// Update the iframe height
</span><del>-		$(&quot;#formFrame&quot;).height($(window).height() - 200);
</del><ins>+		$(&quot;#formFrame&quot;).height($(window).height() - 220);
</ins><span class="cx"> 	});
</span><span class="cx"> 	
</span><span class="cx"> 	setSize();
</span><del>-
</del><ins>+	
+	$(&quot;#formFrame&quot;).on(&quot;load&quot;, function () {
+		$(&quot;#frameLoading&quot;).hide();
+		$(&quot;#frameContainer&quot;).show();
+    });
+	
</ins><span class="cx"> 	$(&quot;#createButton&quot;).button({ disabled: true });
</span><span class="cx"> 	$(&quot;#closeButton&quot;).button();
</span><span class="cx"> 	$(&quot;#retryCloseButton&quot;).button();
</span><span class="lines">@@ -33,6 +40,21 @@
</span><span class="cx"> 	loadForms();
</span><span class="cx"> });
</span><span class="cx"> 
</span><ins>+function checkForIE() {
+    var ua = window.navigator.userAgent;
+    var msie = ua.indexOf(&quot;MSIE &quot;);
+
+    if (msie &gt; 0 || !!navigator.userAgent.match(/Trident.*rv\:11\./))      // If \
Internet Explorer, return version number +        return true;
+    else                 // If another browser, return 0
+        return false;
+}
+
+function iframeLoaded() {
+	$(&quot;#frameLoading&quot;).hide();
+	$(&quot;#frameContainer&quot;).show();
+}
+
</ins><span class="cx"> function setSize() {
</span><span class="cx"> 	window.resizeTo($(window).width() * 0.95,$(window).height() \
* 0.95); </span><span class="cx"> }
</span><span class="lines">@@ -115,10 +137,10 @@
</span><span class="cx"> 		&quot;#view=fit&amp;navpanes=0&quot;;
</span><span class="cx"> 	var url = \
&quot;/openmrs/moduleServlet/chica/chicaMobile?&quot;; </span><span class="cx"> 	
</span><del>-	$('#formFrame').load(function(){
-		$(&quot;#frameLoading&quot;).hide();
-		$(&quot;#frameContainer&quot;).show();
-	});
</del><ins>+	$('#formFrame').attr(&quot;src&quot;, url + action);
</ins><span class="cx"> 	
</span><del>-	$('#formFrame').attr(&quot;src&quot;, url + action);
</del><ins>+	// IE doesn't fire the onload event for the iframe.
+	if (isIE) {
+		setTimeout(iframeLoaded, 2000);
+	}
</ins><span class="cx"> }
</span></span></pre></div>
<a id="openmrsmoduleschicabranchescernerwebsrcorgopenmrsmodulechicawebChicaMobileServletjava"></a>
 <div class="modfile"><h4>Modified: \
openmrs-modules/chica/branches/cerner/web/src/org/openmrs/module/chica/web/ChicaMobileServlet.java \
(30986 => 30987)</h4> <pre class="diff"><span>
<span class="info">--- \
openmrs-modules/chica/branches/cerner/web/src/org/openmrs/module/chica/web/ChicaMobileServlet.java	2014-11-03 \
                19:41:26 UTC (rev 30986)
+++ openmrs-modules/chica/branches/cerner/web/src/org/openmrs/module/chica/web/ChicaMobileServlet.java	2014-11-03 \
21:36:21 UTC (rev 30987) </span><span class="lines">@@ -846,31 +846,35 @@
</span><span class="cx"> 			}
</span><span class="cx"> 		}
</span><span class="cx"> 		
</span><ins>+		if (location == null) {
+			String message = &quot;Location not found: &quot; + locationString;
+			log.error(message);
+			throw new IllegalArgumentException(message);
+		}
+		
</ins><span class="cx"> 		String locationTags = \
request.getParameter(&quot;locationTagId&quot;); </span><span class="cx"> 		Integer \
locationId = null; </span><span class="cx"> 		Integer locationTagId = null;
</span><del>-		if (location != null) {
-			locationId = location.getLocationId();
-			if (locationTags != null &amp;&amp; locationTags.trim().length() &gt; 0) {
-				try {
-					locationTagId = Integer.parseInt(locationTags);
-				} catch (NumberFormatException e) {
-					String message = &quot;Invalid locationTagId parameter: &quot; + locationTags;
-					log.error(message);
-					throw new IllegalArgumentException(message);
-				}
-			} else {
-				locationTags = user.getUserProperty(&quot;locationTags&quot;);
-				if (locationTags != null) {
-					StringTokenizer tokenizer = new StringTokenizer(locationTags, &quot;,&quot;);
-					while (tokenizer.hasMoreTokens()) {
-						String locationTagName = tokenizer.nextToken();
-						locationTagName = locationTagName.trim();
-						Set&lt;LocationTag&gt; tags = location.getTags();
-						for (LocationTag tag : tags) {
-							if (tag.getName().equalsIgnoreCase(locationTagName)) {
-								locationTagId = tag.getLocationTagId();
-							}
</del><ins>+		locationId = location.getLocationId();
+		if (locationTags != null &amp;&amp; locationTags.trim().length() &gt; 0) {
+			try {
+				locationTagId = Integer.parseInt(locationTags);
+			} catch (NumberFormatException e) {
+				String message = &quot;Invalid locationTagId parameter: &quot; + locationTags;
+				log.error(message);
+				throw new IllegalArgumentException(message);
+			}
+		} else {
+			locationTags = user.getUserProperty(&quot;locationTags&quot;);
+			if (locationTags != null) {
+				StringTokenizer tokenizer = new StringTokenizer(locationTags, &quot;,&quot;);
+				while (tokenizer.hasMoreTokens()) {
+					String locationTagName = tokenizer.nextToken();
+					locationTagName = locationTagName.trim();
+					Set&lt;LocationTag&gt; tags = location.getTags();
+					for (LocationTag tag : tags) {
+						if (tag.getName().equalsIgnoreCase(locationTagName)) {
+							locationTagId = tag.getLocationTagId();
</ins><span class="cx"> 						}
</span><span class="cx"> 					}
</span><span class="cx"> 				}
</span><span class="lines">@@ -918,22 +922,43 @@
</span><span class="cx"> 		// Check the output type
</span><span class="cx"> 		FormAttributeValue fav = \
chirdlutilbackportsService.getFormAttributeValue( </span><span class="cx"> 			formId, \
&quot;outputType&quot;, locationTagId, locationId); </span><del>-		if (fav != null \
&amp;&amp; fav.getValue() != null &amp;&amp; \
fav.getValue().contains(&quot;pdf&quot;)) { </del><ins>+		if (fav == null || \
fav.getValue() == null || fav.getValue().trim().length() == 0) { \
+			response.setContentType(&quot;text/xml&quot;); \
+			response.setHeader(&quot;Cache-Control&quot;, &quot;no-cache&quot;); \
+			PrintWriter pw = response.getWriter(); +			String message = &quot;&lt;span&gt;No \
outputType attribute set for form: &quot; + formName +  +					&quot;.  Request cannot \
be completed.&lt;/span&gt;&quot;;  +			log.error(message);
+			pw.write(message);
+			return;
+		}
+		
+		String[] outputTypes = fav.getValue().split(&quot;,&quot;);
+		String firstOutputType = outputTypes[0];
+		if (&quot;pdf&quot;.equalsIgnoreCase(firstOutputType)) {
</ins><span class="cx"> 			String formInstanceTag = result.toString();
</span><span class="cx"> 			locatePatientJITs(response, formInstanceTag);
</span><del>-		} else if (fav != null &amp;&amp; fav.getValue() != null &amp;&amp; \
fav.getValue().contains(&quot;teleformXML&quot;)) { </del><ins>+		} else if \
(&quot;teleformXML&quot;.equalsIgnoreCase(firstOutputType)) { </ins><span class="cx"> \
response.setContentType(&quot;text/xml&quot;); </span><span class="cx"> \
response.setHeader(&quot;Cache-Control&quot;, &quot;no-cache&quot;); </span><span \
class="cx"> 			PrintWriter pw = response.getWriter(); \
</span><del>-			FormAttributeValue attributeValue = \
chirdlutilbackportsService.getFormAttributeValue(form.getFormId(), \
                &quot;displayName&quot;,
-			    locationTagId, locationId);
</del><ins>+			FormAttributeValue attributeValue = \
chirdlutilbackportsService.getFormAttributeValue(form.getFormId(),  \
+				&quot;displayName&quot;, locationTagId, locationId); </ins><span class="cx"> \
if (attributeValue != null &amp;&amp; attributeValue.getValue() != null &amp;&amp; \
attributeValue.getValue().length() &gt; 0) { </span><span class="cx"> 				formName = \
attributeValue.getValue(); </span><span class="cx"> 			}
</span><span class="cx"> 			
</span><span class="cx"> 			String resultMessage = formName + &quot; successfully \
sent to the printer.&quot;; </span><del>-			map.put(&quot;resultMessage&quot;, \
resultMessage); </del><span class="cx"> 			pw.write(&quot;&lt;span&gt;&quot; + \
resultMessage + &quot;&lt;/span&gt;&quot;); </span><ins>+		} else {
+			response.setContentType(&quot;text/xml&quot;);
+			response.setHeader(&quot;Cache-Control&quot;, &quot;no-cache&quot;);
+			PrintWriter pw = response.getWriter();
+			String message = &quot;&lt;span&gt;Invalid outputType attribute '&quot; + \
firstOutputType + &quot;' found for form: &quot; + formName +  \
+					&quot;&lt;/span&gt;&quot;; +			log.error(message);
+			pw.write(message);
+			return;
</ins><span class="cx"> 		}
</span><span class="cx"> 	}
</span><span class="cx"> }
</span></span></pre>
</div>
</div>

</body>
</html>

<p></p>

-- <br />
-- OpenMRS Subversion Commits: <a \
href="http://go.openmrs.org/svn">http://go.openmrs.org/svn</a><br /> Posting is not \
                allowed - please join dev@openmrs.org for discussion.<br />
Unsubscribe: svn+unsubscribe@openmrs.org<br />

<p></p>

To unsubscribe from this group and stop receiving emails from it, send an email to <a \
href="mailto:svn+unsubscribe@openmrs.org">svn+unsubscribe@openmrs.org</a>.<br />


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic