SPLLR91300_Microscopy결과입력.xrw 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <!--
  3. * 제 목 : SPLLR91300_Microscopy결과입력.xrw
  4. * 설 명 : Microscopy결과입력
  5. * 설 계 자 : (주)에이씨케이 -
  6. * 작 성 자 : (주)에이씨케이 - 윤재한
  7. * 작 성 일 : 2007.10.19
  8. * 수정이력 :
  9. * 기 타 :
  10. -->
  11. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/css" ?>
  12. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  13. <xhtml:head>
  14. <xhtml:title>Urine Sediment Microscopy Result</xhtml:title>
  15. <model id="model1">
  16. <instance id="instance1">
  17. <root xmlns="">
  18. <main>
  19. <testlist>
  20. <testcd/>
  21. <tclsscrnm/>
  22. <reptrslt/>
  23. </testlist>
  24. <testlist2>
  25. <testcd/>
  26. <tclsscrnm/>
  27. <reptrslt/>
  28. </testlist2>
  29. <rsltcdlist>
  30. <rsltcd/>
  31. <rsltcnts/>
  32. </rsltcdlist>
  33. </main>
  34. <send>
  35. <tclscd/>
  36. <bcno/>
  37. </send>
  38. <init/>
  39. <hidden>
  40. <temp>
  41. </temp>
  42. <urine/>
  43. <bcno/>
  44. </hidden>
  45. </root>
  46. </instance>
  47. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  48. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  49. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  50. <script type="javascript" src="../../../lis/commonweb/js/LLZ001.js"/>
  51. <script type="javascript" src="../../../com/commonweb/js/numericHelper.js"/>
  52. <script type="javascript" ev:event="xforms-ready">
  53. <![CDATA[
  54. fSetInit();
  55. ]]>
  56. </script>
  57. <bind id="bind1" ref="/root/main/testlist/percent" calculate="../cnt div /root/hidden/Count/Total * 100"/>
  58. <submission id="TRLLR91301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main"/>
  59. <submission id="TRLLF00702" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/rsltcdlist"/>
  60. </model>
  61. <script type="javascript">
  62. <![CDATA[
  63. //초기화
  64. function fSetInit() {
  65. //테스트
  66. //model.setValue("/root/send/bcno", "I20R80050");
  67. submit("TRLLR91301");
  68. grd_testlist.row = 1;
  69. grd_testlist.col = 3;
  70. grd_testlist.editCell();
  71. grd_testlist2.refresh();
  72. model.refresh();
  73. fGetRslt();
  74. }
  75. //결과목록 조회
  76. function fGetRslt(ref) {
  77. if(ref=="2"){ // 두번째그리드
  78. model.makeValue("/root/send/tclscd", model.getValue("/root/main/testlist2["+ grd_testlist2.row +"]/testcd"));
  79. }else{
  80. model.makeValue("/root/send/tclscd", model.getValue("/root/main/testlist["+ grd_testlist.row +"]/testcd"));
  81. //model.setValue("/root/send/tclscd", "LUR11201"); //test
  82. }
  83. submit("TRLLF00702");
  84. model.refresh();
  85. }
  86. //결과값 넣기
  87. function fSetRslt() {
  88. var testcd = model.getValue("/root/main/rsltcdlist["+ grd_rsltlist.row +"]/tclscd");
  89. var find1 = grd_testlist.findRow(testcd, 1, 1, true, true);
  90. if(find1 < 0) {
  91. var find2 = grd_testlist.findRow(testcd, 1, 1, true, true);
  92. model.setValue("/root/main/testlist2["+ grd_testlist2.row +"]/reptrslt", model.getValue("/root/main/rsltcdlist["+ grd_rsltlist.row +"]/rsltcnts"));
  93. } else {
  94. model.setValue("/root/main/testlist["+ grd_testlist.row +"]/reptrslt", model.getValue("/root/main/rsltcdlist["+ grd_rsltlist.row +"]/rsltcnts"));
  95. }
  96. model.refresh();
  97. }
  98. //확인
  99. function fSetDiffCnt() {
  100. /*
  101. var vSendData = "";
  102. for(x=1;x<grd_TestInfoCnts.rows;x++){
  103. var tclscd = model.getValue("/root/main/testlist[" + x + "]/testcd");
  104. var orgrst = model.getValue("/root/main/testlist[" + x+ "]/percent");
  105. var count = model.getValue("/root/main/testlist[" + x+ "]/cnt");
  106. if (count.getTrim() == "" ) {//|| count.getTrim() == "0" ) {
  107. vSendData = vSendData + tclscd + "▦▩"; // Count가 0이거나 결과가 없으면 초기화
  108. } else {
  109. orgrst = fCOMLIS_RstRound(orgrst, "0", "1");
  110. if(model.getvalue("/root/main/testlist[" + x + "]/testcd") == "LHR10518"){
  111. vSendData = vSendData + tclscd + "▦" + count + "▩";
  112. }
  113. else{
  114. vSendData = vSendData + tclscd + "▦" + orgrst + "▩";
  115. }
  116. }
  117. }*/
  118. var nrbcTF = false;
  119. cnt = 1;
  120. for(i = 1; i <= grd_testlist.rows; i++) {
  121. if(model.getValue("/root/main/testlist["+ i +"]/reptrslt") != "") {
  122. model.setValue("/root/main/testlist["+ i +"]/bufinptrslt", model.getValue("/root/main/testlist["+ i +"]/reptrslt"));
  123. model.setValue("/root/main/testlist["+ i +"]/testcd2", model.getValue("/root/send/testcd"));
  124. model.makeNode("/root/hidden/abnormalresult/abnormallist["+ cnt +"]");
  125. model.copyNode("/root/hidden/abnormalresult/abnormallist["+ cnt +"]" , "/root/main/testlist["+i+"]");
  126. cnt++;
  127. nrbcTF= true;
  128. }
  129. }
  130. for(i = 1; i <= grd_testlist2.rows; i++) { // 두번째 그리드
  131. if(model.getValue("/root/main/testlist2["+ i +"]/reptrslt") != "") {
  132. model.setValue("/root/main/testlist2["+ i +"]/bufinptrslt", model.getValue("/root/main/testlist2["+ i +"]/reptrslt"));
  133. model.setValue("/root/main/testlist2["+ i +"]/testcd2", model.getValue("/root/send/testcd"));
  134. model.makeNode("/root/hidden/abnormalresult/abnormallist["+ cnt +"]");
  135. model.copyNode("/root/hidden/abnormalresult/abnormallist["+ cnt +"]" , "/root/main/testlist2["+i+"]");
  136. cnt++;
  137. nrbcTF= true;
  138. }
  139. }
  140. if(nrbcTF) {
  141. model.copyNode(opener.root.hidden.abresult , root.hidden.abnormalresult);
  142. window.close();
  143. }else {
  144. messageBox("결과 입력 된 검사가", "I004");
  145. }
  146. }
  147. // 첫째그리드 결과값 넣을때
  148. function fGetRslt2(){
  149. var Gcol = grd_testlist.col;
  150. var Grow = grd_testlist.row;
  151. if (event.keyCode==13) {
  152. var rslt = parseInt(grd_testlist.valueMatrix(Grow,Gcol));
  153. if(rslt > 0 && rslt < grd_rsltlist.rows){
  154. model.setValue("/root/main/testlist["+ grd_testlist.row +"]/reptrslt", model.getValue("/root/main/rsltcdlist["+ rslt +"]/rsltcnts"));
  155. }
  156. grd_testlist.row = Grow + 1;
  157. fGetRslt();
  158. model.refresh();
  159. }
  160. }
  161. //둘째그리드 결과값 넣을때
  162. function fGetRslt3(){
  163. var Gcol = grd_testlist2.col;
  164. var Grow = grd_testlist2.row;
  165. if (event.keyCode==13) {
  166. var rslt = parseInt(grd_testlist2.valueMatrix(Grow,Gcol));
  167. if(rslt > 0 && rslt < grd_testlist2.rows){
  168. model.setValue("/root/main/testlist2["+ grd_testlist2.row +"]/reptrslt", model.getValue("/root/main/rsltcdlist["+ rslt +"]/rsltcnts"));
  169. }
  170. grd_testlist2.row = Grow + 1;
  171. fGetRslt("2");
  172. model.refresh();
  173. }
  174. }
  175. ]]>
  176. </script>
  177. </xhtml:head>
  178. <xhtml:body pagewidth="640" pageheight="610" guideline="1,1194;" style="border-color:#000000; margin-left:8; margin-top:8; margin-right:8; margin-bottom:8; ">
  179. <group id="group1" style="left:0px; top:0px; width:616px; height:565px; ">
  180. <line id="line1" class="line_1" style="x1:0px; y1:26px; x2:232px; y2:26px; "/>
  181. <caption id="caption3" class="tit_2" style="left:5px; top:11px; width:375px; height:13px; ">검사목록</caption>
  182. <datagrid id="grd_rsltlist" nodeset="/root/main/rsltcdlist" caption="결과코드^결과값" colsep="^" colwidth="54, 56" dataheight="23" rowheader="seq" rowheight="23" rowsep="|" navindex="1" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:481px; top:31px; width:132px; height:531px; text-align:center; ">
  183. <col ref="rsltcd"/>
  184. <col ref="rsltcnts"/>
  185. <script type="javascript" ev:event="ondblclick">
  186. <![CDATA[
  187. fSetRslt();
  188. ]]>
  189. </script>
  190. </datagrid>
  191. <caption id="caption1" class="tit_2" style="left:486px; top:11px; width:85px; height:13px; ">결과목록</caption>
  192. <line id="line3" class="line_1" style="x1:481px; y1:26px; x2:613px; y2:26px; "/>
  193. <line id="line2" class="line_1" style="x1:235px; y1:26px; x2:477px; y2:26px; "/>
  194. <datagrid id="grd_testlist2" nodeset="/root/main/testlist2" caption="검사코드^검사항목명^결과값" colsep="^" colwidth="0, 170, 50" dataheight="23" extendlastcol="scroll" rowheader="seq" rowheight="23" rowsep="|" selectionmode="free" navindex="1" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:235px; top:31px; width:242px; height:531px; text-align:center; ">
  195. <col ref="testcd"/>
  196. <col ref="tclsscrnm" style="text-align:left; "/>
  197. <col ref="reptrslt" type="input"/>
  198. <script type="javascript" ev:event="onclick">
  199. <![CDATA[
  200. if(grd_testlist2.isCell(event.target) && grd_testlist2.row >= grd_testlist2.fixedRows ){
  201. //if(grd_testlist.col != 3) {
  202. fGetRslt("2");
  203. //alert(model.getValue("/root/main/testlist["+grd_testlist.row+"]/reptrslt"));
  204. //}
  205. }
  206. ]]>
  207. </script>
  208. <script type="javascript" ev:event="onkeypress">
  209. <![CDATA[
  210. if(grd_testlist2.col == 3) {
  211. fGetRslt3();
  212. }
  213. ]]>
  214. </script>
  215. </datagrid>
  216. <datagrid id="grd_testlist" nodeset="/root/main/testlist" caption="검사코드^검사항목명^결과값" colsep="^" colwidth="0, 160, 50" dataheight="23" extendlastcol="scroll" rowheader="seq" rowheight="23" rowsep="|" selectionmode="free" navindex="1" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:0px; top:31px; width:232px; height:531px; text-align:center; ">
  217. <col ref="testcd"/>
  218. <col ref="tclsscrnm" style="text-align:left; "/>
  219. <col ref="reptrslt" type="input"/>
  220. <script type="javascript" ev:event="onclick">
  221. <![CDATA[
  222. if(grd_testlist.isCell(event.target) && grd_testlist.row >= grd_testlist.fixedRows ){
  223. //if(grd_testlist.col != 3) {
  224. fGetRslt();
  225. //alert(model.getValue("/root/main/testlist["+grd_testlist.row+"]/reptrslt"));
  226. //}
  227. }
  228. ]]>
  229. </script>
  230. <script type="javascript" ev:event="onkeypress">
  231. <![CDATA[
  232. if(grd_testlist.col == 3) {
  233. fGetRslt2();
  234. }
  235. ]]>
  236. </script>
  237. </datagrid>
  238. </group>
  239. <group id="group3" style="left:0px; top:565px; width:615px; height:27px; ">
  240. <button id="btn_cnfm" class="btn4_letter2" visibility="visible" style="left:227px; top:3px; width:56px; height:22px; ">
  241. <caption>확인</caption>
  242. <script type="javascript" ev:event="DOMActivate">
  243. <![CDATA[
  244. fSetDiffCnt();
  245. ]]>
  246. </script>
  247. </button>
  248. <button id="btn_close" class="btn4_letter2" style="left:353px; top:3px; width:56px; height:22px; ">
  249. <caption>닫기</caption>
  250. <script type="javascript" ev:event="DOMActivate">
  251. <![CDATA[
  252. window.close();
  253. ]]>
  254. </script>
  255. </button>
  256. <button id="btn_init" class="btn4_letter3" style="left:284px; top:3px; width:68px; height:22px; ">
  257. <caption>초기화</caption>
  258. <script type="javascript" ev:event="DOMActivate">
  259. <![CDATA[
  260. fSetInit();
  261. ]]>
  262. </script>
  263. </button>
  264. </group>
  265. </xhtml:body>
  266. </xhtml:html>