SMLLF00900_참조검사코드관리.xrw 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <!--
  3. * 제 목 : SMLLF00900_참조검사코드관리.xrw
  4. * 설 명 : 참조검사코드관리
  5. * 설 계 자 : (주)에이씨케이 - 윤재한
  6. * 작 성 자 : (주)에이씨케이 -
  7. * 작 성 일 : 2007. 07. 27
  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/>
  15. <model id="model1">
  16. <instance id="instance1">
  17. <root>
  18. <main>
  19. <gettestitem>
  20. <tclscd/>
  21. <tclsnm/>
  22. <spccd/>
  23. <tclskind/>
  24. </gettestitem>
  25. <gettestlist>
  26. <choi/>
  27. <tclscd/>
  28. <tclsnm/>
  29. <spccd/>
  30. </gettestlist>
  31. <getreftestlist>
  32. <reftclscd/>
  33. <tclsnm/>
  34. <refspccd/>
  35. </getreftestlist>
  36. </main>
  37. <send>
  38. <lrgcd/>
  39. <mdlcd/>
  40. <codeflag/>
  41. <reftestdata/>
  42. <testflag/>
  43. <tclscd/>
  44. <spccd/>
  45. <userdeptflagcd/>
  46. </send>
  47. <init>
  48. </init>
  49. <hidden>
  50. <ref>
  51. <lrgcd>00</lrgcd>
  52. <mdlcd>
  53. <cd>00</cd>
  54. <nm/>
  55. </mdlcd>
  56. <testlrgcd>00</testlrgcd>
  57. <testmdlcd>
  58. <cd>00</cd>
  59. <nm/>
  60. </testmdlcd>
  61. </ref>
  62. </hidden>
  63. </root>
  64. </instance>
  65. <script type="javascript" ev:event="xforms-ready">
  66. <![CDATA[
  67. // 초기정보 조회
  68. model.setValue("/root/send/codeflag", "0104|0102|0000|"); //0104 대분류 | 0102 중분류
  69. submit("TRLZZ00101");
  70. //검사목록 조회
  71. fTestList();
  72. model.removeNodeset("/root/main/gettestitem");
  73. grd_TestItem.refresh();
  74. model.removeNodeset("/root/main/getreftestlist");
  75. grd_RefTestList.refresh();
  76. model.refresh();
  77. ]]>
  78. </script>
  79. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  80. <submission id="TRLZZ00101" ref="/root/send" method="post" mediatype="application/x-www-form-urlencoded" replace="instance" resultref="/root/LB0111"/>
  81. <submission id="TRLLF00901" ref="/root/send" method="post" mediatype="application/x-www-form-urlencoded" replace="instance" resultref="/root/main/gettestitem"/>
  82. <submission id="TRLLF00902" ref="/root/send" method="post" mediatype="application/x-www-form-urlencoded" replace="instance" resultref="/root/main/getreftestlist"/>
  83. <submission id="TXLLF00901" ref="/root/send" method="post" mediatype="application/x-www-form-urlencoded" replace="instance"/>
  84. <submission id="TRLLF01701" ref="/root/send" method="post" mediatype="application/x-www-form-urlencoded" replace="instance" resultref="/root/main/gettestlist"/>
  85. </model>
  86. <script type="javascript">
  87. <![CDATA[
  88. //중분류 초기정보 조회
  89. function fSetLrgCd(){
  90. var etc = model.getvalue("/root/hidden/ref/lrgcd");
  91. if(etc == "00"){
  92. cmb_MdlCd.choices.itemset.attribute("nodeset") = "/root/init/LB0102";
  93. model.setValue("/root/hidden/ref/mdlcd/cd" , "00");
  94. }
  95. else{
  96. model.setValue("/root/hidden/ref/mdlcd/cd" , "00");
  97. cmb_MdlCd.choices.itemset.attribute("nodeset") = "/root/init/LB0102[cd= '00' or etc01='"+ etc +"']";
  98. }
  99. cmb_MdlCd.refresh();
  100. fTestList();
  101. }
  102. //중분류 초기정보 조회
  103. function fSetTestLrgCd(){
  104. var lrg = model.getvalue("/root/hidden/ref/testlrgcd");
  105. if(lrg == "00"){
  106. cmb_TestMdlCd.choices.itemset.attribute("nodeset") = "/root/init/LB0102";
  107. model.setValue("/root/hidden/ref/testmdlcd/cd" , "00");
  108. }
  109. else{
  110. model.setValue("/root/hidden/ref/testmdlcd/cd" , "00");
  111. cmb_TestMdlCd.choices.itemset.attribute("nodeset") = "/root/init/LB0102[cd= '00' or etc01='"+ lrg +"']";
  112. }
  113. cmb_TestMdlCd.refresh();
  114. }
  115. //초기시 검사목록 조회
  116. function fTestList() {
  117. model.setValue("/root/send/mdlcd", model.getValue("/root/hidden/ref/mdlcd/cd"));
  118. model.setValue("/root/send/lrgcd", model.getValue("/root/hidden/ref/lrgcd"));
  119. model.setValue("/root/send/userdeptflagcd", model.getValue("/root/init/LB0000/nm"));
  120. submit("TRLLF01701");
  121. }
  122. //참조검사목록 행삭제
  123. function fDelRefTestListRow() {
  124. //grd_RefTestList.rowStatus(grd_RefTestList.row) = 1;
  125. grd_RefTestList.deleteRow(grd_RefTestList.row);
  126. //for(i = 1; i < grd_RefTestList.rows; i++) {
  127. // grd_RefTestList.rowStatus(i) = 1;
  128. //}
  129. }
  130. //검사항목 조회
  131. function fGetTestItem() {
  132. model.setValue("/root/send/mdlcd", model.getValue("/root/hidden/ref/testmdlcd/cd"));
  133. model.setValue("/root/send/lrgcd", model.getValue("/root/hidden/ref/testlrgcd"));
  134. model.setValue("/root/send/userdeptflagcd", model.getValue("/root/init/LB0000/nm"));
  135. submit("TRLLF00901");
  136. model.removeNodeset("/root/main/getreftestlist");
  137. grd_RefTestList.refresh();
  138. grd_TestItem.refresh();
  139. }
  140. //참조검사목록 조회
  141. function fGetRefTestList() {
  142. model.setValue("/root/send/tclscd", model.getValue("/root/main/gettestitem["+ grd_TestItem.row +"]/tclscd"));
  143. model.setValue("/root/send/spccd", model.getValue("/root/main/gettestitem["+ grd_TestItem.row +"]/spccd"));
  144. model.setValue("/root/send/userdeptflagcd", model.getValue("/root/init/LB0000/nm"));
  145. submit("TRLLF00902");
  146. }
  147. //참조검사목록으로 올리기
  148. function fSetRefTestList() {
  149. var row = grd_RefTestList.rows;
  150. var bfcheck = 0;
  151. for(i=1; i< grd_TestList.rows; i++){
  152. var fcheck = grd_TestList.findRow("Y", i, 1, false, true);
  153. if(fcheck == -1 ) {
  154. break;
  155. }
  156. i = fcheck;
  157. if(fcheck > bfcheck){
  158. var tcd= model.getValue("/root/main/gettestlist["+fcheck+"]/tclscd");
  159. var trow = grd_RefTestList.findRow(tcd, 1, 1, false, true);
  160. if(trow > 0){
  161. alert("이미 선택된 코드입니다.");
  162. } else {
  163. grd_RefTestList.addRow(false);
  164. model.makeNode("/root/main/getreftestlist["+row+"]/reftclscd");
  165. model.makeNode("/root/main/getreftestlist["+row+"]/tclsnm");
  166. model.makeNode("/root/main/getreftestlist["+row+"]/refspccd");
  167. model.setValue("/root/main/getreftestlist["+row+"]/reftclscd", model.getValue("/root/main/gettestlist["+fcheck+"]/tclscd"));
  168. model.setValue("/root/main/getreftestlist["+row+"]/tclsnm", model.getValue("/root/main/gettestlist["+fcheck+"]/tclsnm"));
  169. model.setValue("/root/main/getreftestlist["+row+"]/refspccd", model.getValue("/root/main/gettestlist["+fcheck+"]/spccd"));
  170. row++;
  171. }
  172. }
  173. bfcheck = fcheck;
  174. }
  175. grd_RefTestList.refresh();
  176. //for(i = 1; i < grd_RefTestList.rows; i++) {
  177. // grd_RefTestList.rowStatus(i) = 1;
  178. //}
  179. }
  180. //저장
  181. function fSaveRefTestList() {
  182. if(grd_RefTestList.rows == 1) {
  183. model.setValue("/root/send/testflag", "0");
  184. } else {
  185. model.setValue("/root/send/testflag", "1");
  186. for(i = 1; i < grd_RefTestList.rows; i++) {
  187. grd_RefTestList.rowStatus(i) = 1;
  188. }
  189. }
  190. model.setValue("/root/send/reftestdata", grd_RefTestList.getUpdateDataAll("i"));
  191. model.setValue("/root/send/tclscd", model.getValue("/root/main/gettestitem[" + grd_TestItem.row + "]/tclscd"));
  192. model.setValue("/root/send/spccd", model.getValue("/root/main/gettestitem[" + grd_TestItem.row + "]/spccd"));
  193. submit("TXLLF00901");
  194. fGetTestItem();
  195. model.removeNodeset("/root/main/getreftestlist");
  196. grd_RefTestList.refresh();
  197. }
  198. ]]>
  199. </script>
  200. </xhtml:head>
  201. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  202. <group id="group3" scroll="auto" style="left:0px; top:40px; width:1195px; height:744; ">
  203. <line id="line1" class="line_1" style="x1:0px; y1:70px; x2:565px; y2:70px; "/>
  204. <caption id="caption1" class="tit_2" style="left:5px; top:55px; width:80px; height:13px; ">검사항목</caption>
  205. <caption id="caption3" class="tit_2" style="left:570px; top:435px; width:110px; height:13px; ">검사목록</caption>
  206. <line id="line2" class="line_1" style="x1:570px; y1:450px; x2:1190px; y2:450px; "/>
  207. <group id="group1" style="left:0px; top:10px; width:1195px; height:35px; ">
  208. <shape id="roundrect2" class="roundrect_search" appearance="roundrect" style="left:0px; top:0px; width:1194px; height:35px; "/>
  209. <line id="line3" class="line_4" style="x1:1108px; y1:7px; x2:1108px; y2:29px; "/>
  210. <button id="button3" class="btn1_letter2" style="left:1123px; top:7px; width:56px; height:22px; ">
  211. <caption>조회</caption>
  212. <script type="javascript" ev:event="onclick">
  213. <![CDATA[
  214. fGetTestItem();
  215. ]]>
  216. </script>
  217. </button>
  218. <select1 id="cmb_TestMdlCd" ref="/root/hidden/ref/testmdlcd/cd" class="combo_s_essential" appearance="minimal" itemcount="10" style="left:309px; top:8px; width:198px; height:19px; ">
  219. <choices>
  220. <itemset nodeset="/root/init/LB0102">
  221. <label ref="nm"/>
  222. <value ref="cd"/>
  223. </itemset>
  224. </choices>
  225. <script type="javascript" ev:event="xforms-value-changed">
  226. <![CDATA[
  227. fGetTestItem();
  228. ]]>
  229. </script>
  230. </select1>
  231. <caption id="caption5" class="search_name" style="left:15px; top:9px; width:90px; height:17px; ">검사분류 :</caption>
  232. <select1 id="cmb_TestLrgCd" ref="/root/hidden/ref/testlrgcd" class="combo_s_essential" appearance="minimal" itemcount="10" style="left:108px; top:8px; width:198px; height:19px; ">
  233. <choices>
  234. <itemset nodeset="/root/init/LB0104">
  235. <label ref="nm"/>
  236. <value ref="cd"/>
  237. </itemset>
  238. </choices>
  239. <script type="javascript" ev:event="xforms-value-changed">
  240. <![CDATA[
  241. fSetTestLrgCd();
  242. ]]>
  243. </script>
  244. </select1>
  245. </group>
  246. <caption id="caption2" class="tit_2" style="left:570px; top:55px; width:110px; height:13px; ">참조검사목록</caption>
  247. <line id="line4" class="line_1" style="x1:570px; y1:70px; x2:1190px; y2:70px; "/>
  248. <button id="button104" class="icon_top" style="left:860px; top:398px; width:26px; height:19px; ">
  249. <caption/>
  250. <script type="javascript" ev:event="DOMActivate">
  251. <![CDATA[
  252. //선택검사목록
  253. fSetRefTestList();
  254. ]]>
  255. </script>
  256. </button>
  257. <select1 id="cmb_MdlCd" ref="/root/hidden/ref/mdlcd/cd" class="combo_s_essential" appearance="minimal" itemcount="10" style="left:992px; top:429px; width:198px; height:19px; ">
  258. <choices>
  259. <itemset nodeset="/root/init/LB0102">
  260. <label ref="nm"/>
  261. <value ref="cd"/>
  262. </itemset>
  263. </choices>
  264. <script type="javascript" ev:event="xforms-value-changed">
  265. <![CDATA[
  266. fTestList();
  267. ]]>
  268. </script>
  269. </select1>
  270. <caption id="caption4" class="search_name" style="left:698px; top:429px; width:90px; height:17px; ">검사분류 :</caption>
  271. <select1 id="cmb_LrgCd" ref="/root/hidden/ref/lrgcd" class="combo_s_essential" appearance="minimal" itemcount="10" style="left:791px; top:429px; width:198px; height:19px; ">
  272. <choices>
  273. <itemset nodeset="/root/init/LB0104">
  274. <label ref="nm"/>
  275. <value ref="cd"/>
  276. </itemset>
  277. </choices>
  278. <script type="javascript" ev:event="xforms-value-changed">
  279. <![CDATA[
  280. fSetLrgCd();
  281. ]]>
  282. </script>
  283. </select1>
  284. <datagrid id="grd_RefTestList" nodeset="/root/main/getreftestlist" caption="검사코드^검사명" colwidth="82, 457" dataheight="23" defaultrows="1" explorerbar="sortshow" rowheader="seq" rowheight="32" rowsep="|" colsep="^" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:570px; top:75px; width:620px; height:308px; ">
  285. <col ref="reftclscd" style="text-align:center; "/>
  286. <col ref="tclsnm"/>
  287. <script type="javascript" ev:event="onaftersort">
  288. <![CDATA[
  289. grd_RefTestList.gridToInstance();
  290. ]]>
  291. </script>
  292. </datagrid>
  293. <datagrid id="grd_TestList" nodeset="/root/main/gettestlist" overflow="scroll" scroll="autovscroll" caption="^검사코드^검사명" colwidth="26, 82, 411" dataheight="23" defaultrows="1" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowheight="23" rowsep="|" colsep="^" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:570px; top:455px; width:620px; height:276px; ">
  294. <col ref="choi" type="checkbox" checkvalue="Y,N"/>
  295. <col ref="tclscd" style="text-align:center; "/>
  296. <col ref="tclsnm"/>
  297. <script type="javascript" ev:event="onaftersort">
  298. <![CDATA[
  299. grd_TestList.gridToInstance();
  300. ]]>
  301. </script>
  302. </datagrid>
  303. <button id="button2" class="btn2_letter3" style="left:1135px; top:49px; width:53px; height:19px; ">
  304. <caption>행삭제</caption>
  305. <script type="javascript" ev:event="DOMActivate">
  306. <![CDATA[
  307. fDelRefTestListRow();
  308. ]]>
  309. </script>
  310. </button>
  311. <datagrid id="grd_TestItem" nodeset="/root/main/gettestitem" caption="검사코드^검사명^검사코드구분" colwidth="82, 286, 100" dataheight="23" defaultrows="1" explorerbar="sortshow" rowheader="update" rowheight="23" rowsep="|" colsep="^" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:0px; top:75px; width:565px; height:667px; ">
  312. <col ref="tclscd" style="text-align:center; "/>
  313. <col ref="tclsnm"/>
  314. <col ref="tclskind"/>
  315. <script type="javascript" ev:event="onclick">
  316. <![CDATA[
  317. fGetRefTestList();
  318. ]]>
  319. </script>
  320. <script type="javascript" ev:event="onaftersort">
  321. <![CDATA[
  322. grd_TestItem.gridToInstance();
  323. ]]>
  324. </script>
  325. </datagrid>
  326. </group>
  327. <group id="group4" scroll="auto" style="left:0px; top:13px; width:1195px; height:27px; ">
  328. <button id="button5" class="btn4_letter3" style="left:1127px; top:3px; width:68px; height:22px; ">
  329. <caption>초기화</caption>
  330. <script type="javascript" ev:event="onclick">
  331. <![CDATA[
  332. model.reset();
  333. ]]>
  334. </script>
  335. </button>
  336. <button id="button11" class="btn4_letter2" style="left:1068px; top:3px; width:56px; height:22px; ">
  337. <caption>저장</caption>
  338. <script type="javascript" ev:event="DOMActivate">
  339. <![CDATA[
  340. fSaveRefTestList();
  341. ]]>
  342. </script>
  343. </button>
  344. <line id="line17" class="line_6" style="x1:0px; y1:25px; x2:1194px; y2:25px; "/>
  345. </group>
  346. <group id="group2" style="left:0px; top:0px; width:1195px; height:13px; ">
  347. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">참조검사코드관리</caption>
  348. </group>
  349. </xhtml:body>
  350. </xhtml:html>