SPLLR90100_다중결과.xrw 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <!--
  3. * 제 목 : SPLLR90100_다중결과.xrw
  4. * 설 명 : 다중결과
  5. * 설 계 자 : (주)에이씨케이 - 조철형
  6. * 작 성 자 : (주)에이씨케이 - 조철형
  7. * 작 성 일 : 2007.06.12
  8. * 수정이력 :
  9. * 기 타 :
  10. -->
  11. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.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>다중결과</xhtml:title>
  15. <model id="model1">
  16. <instance id="instance1">
  17. <root xmlns="">
  18. <main>
  19. <TestResultList>
  20. <tclsscrnnm/>
  21. <result/>
  22. <selchk01 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  23. <result01/>
  24. <selchk02 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  25. <result02/>
  26. <selchk03 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  27. <result03/>
  28. <selchk04 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  29. <result04/>
  30. <selchk05 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  31. <result05/>
  32. <selchk06 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  33. <result06/>
  34. <selchk07 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  35. <result07/>
  36. <selchk08 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  37. <result08/>
  38. <selchk09 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  39. <result09/>
  40. <selchk10 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  41. <result10/>
  42. <selchk11 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  43. <result11/>
  44. <selchk12 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  45. <result12/>
  46. <selchk13 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  47. <result13/>
  48. <selchk14 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  49. <result14/>
  50. <selchk15 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  51. <result15/>
  52. <selchk16 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  53. <result16/>
  54. <selchk17 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  55. <result17/>
  56. <selchk18 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  57. <result18/>
  58. <selchk19 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  59. <result19/>
  60. <selchk20 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  61. <result20/>
  62. <selchk21 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  63. <result21/>
  64. <selchk22 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  65. <result22/>
  66. <selchk23 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  67. <result23/>
  68. <selchk24 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  69. <result24/>
  70. <selchk25 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  71. <result25/>
  72. <selchk26 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  73. <result26/>
  74. <selchk27 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  75. <result27/>
  76. <selchk28 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  77. <result28/>
  78. <selchk29 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  79. <result29/>
  80. <selchk30 readonly="" testcd="" rsltseq="" inptrslt="" rsltstat="" tooltip=""/>
  81. <result30/>
  82. </TestResultList>
  83. </main>
  84. <send>
  85. <data1/>
  86. </send>
  87. <init>
  88. </init>
  89. <hidden>
  90. <DJGGParm>
  91. <bcno/>
  92. <testlrgkind/>
  93. <microtestkind/>
  94. <bufDJGG/>
  95. </DJGGParm>
  96. </hidden>
  97. </root>
  98. </instance>
  99. <script type="javascript" ev:event="xforms-model-construct-done">
  100. <![CDATA[
  101. fInit();
  102. ]]>
  103. </script>
  104. <script type="javascript" src="../../../lis/commonweb/js/LLZ001.js"/>
  105. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  106. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  107. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  108. <submission id="TRLLR90101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/TestResultList"/>
  109. </model>
  110. <script type="javascript">
  111. <![CDATA[
  112. function fInit() {
  113. model.copyNode("/root/send/data1" , "/root/hidden/DJGGParm");
  114. submit("TRLLR90101" );
  115. var vMaxrstno = model.getValue("/root/main/TestResultList/maxrstno");
  116. if (parseInt(vMaxrstno) > 30) {
  117. model.setValue("/root/main/TestResultList/maxrstno", "30");
  118. vMaxrstno = 30;
  119. }
  120. for (var r = 1; r <= getNodesetCount("/root/main/TestResultList"); r++) {
  121. for (var n = 1; n <= eval(vMaxrstno); n++) {
  122. var vRstno = n.toString().getLeftPad(2 , 0);
  123. var c = (n * 2) + 2;
  124. var vTooltipText = model.getValue("/root/main/TestResultList["+r+"]/selchk" + vRstno + "/@tooltip");
  125. if (vTooltipText.getTrim() != "") {
  126. grd_resultlist.tooltipText(r,c) = vTooltipText.toString().replace("/", "\n");
  127. }
  128. // 최종보고, 중간(예비)보고는 FontColor 변경
  129. if (model.getValue("/root/main/TestResultList["+r+"]/selchk" + vRstno + "/@rsltstat") == "4") {
  130. grd_resultlist.cellstyle("background-color", r, c,r,c) = "#f3e1bf";
  131. grd_resultlist.cellstyle("color", r, c,r,c) = "#ff3300";
  132. } else if (model.getValue("/root/main/TestResultList["+r+"]/selchk" + vRstno + "/@rsltstat") == "2") {
  133. //grd_resultlist.cellstyle("background-color" , r, c,r,c) = "#f3e1bf";
  134. grd_resultlist.cellstyle("color", r, c,r,c) = "#184d8b";
  135. } else if (model.getValue("/root/main/TestResultList["+r+"]/selchk" + vRstno + "/@rsltstat") == "1") {
  136. //grd_resultlist.cellstyle("background-color" , r, c,r,c) = "#f3e1bf";
  137. grd_resultlist.cellstyle("color", r, c,r,c) = "#423a46";
  138. }
  139. /*
  140. // 없는항목 Gray로 변경
  141. if (model.getValue("/root/main/TestResultList["+r+"]/selchk" + vRstno + "/@readonly") == "true") {
  142. var color = fCOMLIS_getBackColor("GRAY");
  143. TFGridRowColor("grdGyeolGwaList", r, eval(c - 1), r, eval(c - 1), 1, color[0], color[1], color[2]);
  144. TFGridRowColor("grdGyeolGwaList", r, c, r, c, 1, color[0], color[1], color[2]);
  145. }
  146. */
  147. }
  148. }
  149. model.refresh();
  150. fColHidden(vMaxrstno);
  151. }
  152. /**
  153. * Column Hidden
  154. *
  155. */
  156. function fColHidden(pMaxrst) {
  157. for (var i = 1; i <= 30; i++) {
  158. var vCol = (eval(i) * 2) + 1;
  159. var vState = (i > eval(pMaxrst)) ? true : false;
  160. grd_resultlist.ColHidden(vCol) = vState;
  161. grd_resultlist.ColHidden(eval(vCol)+1) = vState;
  162. }
  163. }
  164. // 선택버튼 클릭
  165. function fSelect_Click() {
  166. var maxcol = eval(model.getValue("/root/main/TestResultList/maxrstno") * 2) + 2;
  167. var vSendData = "";
  168. for (c = 3; c <= maxcol; c+=2) {
  169. var vCurrRow = 1;
  170. for (r = 1; r <= grd_resultlist.rows; r++) {
  171. // 체크된 항목 검색
  172. findrow = grd_resultlist.FindRow("true", vCurrRow, c, false, false);
  173. if(findrow < 0) break;
  174. var vSelRstno = parseInt(eval(c) / 2);
  175. var vSelRstno2b = vSelRstno.toString().getLeftPad(2 , 0);
  176. var testcd = model.getValue("/root/main/TestResultList["+findrow+"]/selchk"+vSelRstno2b+"/@testcd");
  177. var inptrslt = model.getValue("/root/main/TestResultList["+findrow+"]/selchk"+vSelRstno2b+"/@inptrslt");
  178. vSendData = vSendData + testcd + "▦" + inptrslt + "▩";
  179. vCurrRow = findrow + 1;
  180. }
  181. }
  182. window.opener.model.setValue("/root/hidden/DJGGParm/bufDJGG", vSendData);
  183. window.close(); // 폼 종료
  184. }
  185. ]]>
  186. </script>
  187. </xhtml:head>
  188. <xhtml:body pagewidth="670" pageheight="470" guideline="1,1194;" style="border-color:#000000; margin-left:8; margin-top:8; margin-right:8; margin-bottom:8; ">
  189. <group id="group1" style="left:0px; top:0px; width:650px; height:440px; ">
  190. <line id="line1" class="line_1" style="x1:0px; y1:26px; x2:645px; y2:26px; "/>
  191. <caption id="caption3" class="tit_2" style="left:5px; top:11px; width:123px; height:14px; ">다중결과</caption>
  192. <datagrid id="grd_resultlist" nodeset="/root/main/TestResultList" backcoloralternate="transparent" caption="검사항목명^결과^1차^1차^2차^2차^3차^3차^4차^4차^5차^5차^6차^6차^7차^7차^8차^8차^9차^9차^10차^10차^11차^11차^12차^12차^13차^13차^14차^14차^15차^15차^16차^16차^17차^17차^18차^18차^19차^19차^20차^20차^21차^21차^22차^22차^23차^23차^24차^24차^25차^25차^26차^26차^27차^27차^28차^28차^29차^29차^30차^30차" colsep="^" colwidth="163, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50, 17, 50" dataheight="23" defaultrows="1" ellipsis="true" fixedcols="0" frozencols="2" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="23" rowsep="|" selectionmode="free" tooltip="true" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:0px; top:31px; width:645px; height:404px; ">
  193. <col ref="tclsscrnnm"/>
  194. <col ref="result"/>
  195. <col checkvalue="true,false" ref="selchk01" type="checkbox"/>
  196. <col ref="result01"/>
  197. <col checkvalue="true,false" ref="selchk02" type="checkbox"/>
  198. <col ref="result02"/>
  199. <col checkvalue="true,false" ref="selchk03" type="checkbox"/>
  200. <col ref="result03"/>
  201. <col checkvalue="true,false" ref="selchk04" type="checkbox"/>
  202. <col ref="result04"/>
  203. <col checkvalue="true,false" ref="selchk05" type="checkbox"/>
  204. <col ref="result05"/>
  205. <col checkvalue="true,false" ref="selchk06" type="checkbox"/>
  206. <col ref="result06"/>
  207. <col checkvalue="true,false" ref="selchk07" type="checkbox"/>
  208. <col ref="result07"/>
  209. <col checkvalue="true,false" ref="selchk08" type="checkbox"/>
  210. <col ref="result08"/>
  211. <col checkvalue="true,false" ref="selchk09" type="checkbox"/>
  212. <col ref="result09"/>
  213. <col checkvalue="true,false" ref="selchk10" type="checkbox"/>
  214. <col ref="result10"/>
  215. <col checkvalue="true,false" ref="selchk11" type="checkbox"/>
  216. <col ref="result11"/>
  217. <col checkvalue="true,false" ref="selchk12" type="checkbox"/>
  218. <col ref="result12"/>
  219. <col checkvalue="true,false" ref="selchk13" type="checkbox"/>
  220. <col ref="result13"/>
  221. <col checkvalue="true,false" ref="selchk14" type="checkbox"/>
  222. <col ref="result14"/>
  223. <col checkvalue="true,false" ref="selchk15" type="checkbox"/>
  224. <col ref="result15"/>
  225. <col checkvalue="true,false" ref="selchk16" type="checkbox"/>
  226. <col ref="result16"/>
  227. <col checkvalue="true,false" ref="selchk17" type="checkbox"/>
  228. <col ref="result17"/>
  229. <col checkvalue="true,false" ref="selchk18" type="checkbox"/>
  230. <col ref="result18"/>
  231. <col checkvalue="true,false" ref="selchk19" type="checkbox"/>
  232. <col ref="result19"/>
  233. <col checkvalue="true,false" ref="selchk20" type="checkbox"/>
  234. <col ref="result20"/>
  235. <col checkvalue="true,false" ref="selchk21" type="checkbox"/>
  236. <col ref="result21"/>
  237. <col checkvalue="true,false" ref="selchk22" type="checkbox"/>
  238. <col ref="result22"/>
  239. <col checkvalue="true,false" ref="selchk23" type="checkbox"/>
  240. <col ref="result23"/>
  241. <col checkvalue="true,false" ref="selchk24" type="checkbox"/>
  242. <col ref="result24"/>
  243. <col checkvalue="true,false" ref="selchk25" type="checkbox"/>
  244. <col ref="result25"/>
  245. <col checkvalue="true,false" ref="selchk26" type="checkbox"/>
  246. <col ref="result26"/>
  247. <col checkvalue="true,false" ref="selchk27" type="checkbox"/>
  248. <col ref="result27"/>
  249. <col checkvalue="true,false" ref="selchk28" type="checkbox"/>
  250. <col ref="result28"/>
  251. <col checkvalue="true,false" ref="selchk29" type="checkbox"/>
  252. <col ref="result29"/>
  253. <col checkvalue="true,false" ref="selchk30" type="checkbox"/>
  254. <col ref="result30"/>
  255. </datagrid>
  256. </group>
  257. <button id="button3" class="btn4_letter2" visibility="visible" style="left:531px; top:445px; width:56px; height:22px; ">
  258. <caption>선택</caption>
  259. <script type="javascript" ev:event="DOMActivate">
  260. <![CDATA[
  261. fSelect_Click();
  262. ]]>
  263. </script>
  264. </button>
  265. <button id="button4" class="btn4_letter2" style="left:590px; top:445px; width:56px; height:22px; ">
  266. <caption>닫기</caption>
  267. <script type="javascript" ev:event="onclick">
  268. <![CDATA[
  269. window.close();
  270. ]]>
  271. </script>
  272. </button>
  273. </xhtml:body>
  274. </xhtml:html>