SPAEA00200_치료실별치료사관리.xrw 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <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">
  4. <xhtml:head>
  5. <xhtml:title>치료실별치료사관리</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <list1>
  11. <item>
  12. <basecd/>
  13. <basecdflagdesc/>
  14. </item>
  15. </list1>
  16. <list2>
  17. <item>
  18. <check/>
  19. <sortno/>
  20. <basecd/>
  21. <basecdflagdesc/>
  22. <excudd/>
  23. </item>
  24. </list2>
  25. </main>
  26. <send>
  27. <excuroomcd/>
  28. <req>
  29. <data/>
  30. </req>
  31. <globalinstance>
  32. <instance1/>
  33. </globalinstance>
  34. <curerid/>
  35. <startdate/>
  36. </send>
  37. <init>
  38. <curerlist>
  39. <curernm/>
  40. </curerlist>
  41. </init>
  42. <hidden>
  43. <item/>
  44. </hidden>
  45. <temp>
  46. </temp>
  47. <popdata>
  48. <execrid/>
  49. <excuroomcd/>
  50. <excudd/>
  51. </popdata>
  52. <hidden1>
  53. <popupmenu>
  54. <menu>
  55. <label>검사/치료실변경</label>
  56. <func>ExcuroomFunc</func>
  57. </menu>
  58. </popupmenu>
  59. </hidden1>
  60. </root>
  61. </instance>
  62. <submission id="TRAEA00201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/list1"/>
  63. <submission id="TRAEA00202" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/list2"/>
  64. <submission id="TRAEA00203" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/curerlist"/>
  65. <submission id="TXAEA00201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp"/>
  66. <script type="javascript" ev:event="xforms-ready">
  67. <![CDATA[
  68. aezfSetSuppDeptcd();
  69. model.removeNodeset("/root/main/list1/item");
  70. model.removeNodeset("/root/main/list2/item");
  71. model.setValue("/root/send/startdate", getCurrentDate());
  72. submit("TRAEA00203");
  73. btn_sea.dispatch("DOMActivate");
  74. ]]>
  75. </script>
  76. </model>
  77. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  78. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  79. <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
  80. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  81. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  82. <script type="javascript">
  83. <![CDATA[
  84. function readfunc() {
  85. model.setValue("/root/send/excuroomcd", model.getValue("/root/main/list1/item[" + grd_cureroomlist.row + "]/basecd"));
  86. model.removeNodeset("/root/main/list2/item");
  87. if (submit("TRAEA00202")){
  88. model.setValue("/root/send/excuroomcd", "");
  89. if (grd_curerlist.rows > 1){
  90. for (var i = 1; i < grd_curerlist.rows; i ++){
  91. model.setValue("/root/main/list2/item[" + i + "]/basecdflagdesc", model.getValue("/root/main/list2/item[" + i + "]/basecd"));
  92. }
  93. }
  94. }
  95. model.refresh();
  96. }
  97. function datacheck(){
  98. for (var i = 1; i < grd_curerlist.rows; i++){
  99. var schk = model.getValue("/root/main/list2/item[" + i + "]/check");
  100. if (schk == "Y"){
  101. var sexcudd = model.getValue("/root/main/list2/item[" + i + "]/excudd");
  102. if (sexcudd == ""){
  103. messageBox(i + "번째행의 시행일은 필수 입력항목입니다.", "E999", "");
  104. return false;
  105. }
  106. var sbasecd = model.getValue("/root/main/list2/item[" + i + "]/basecd");
  107. if (sbasecd == ""){
  108. messageBox(i + "번째행의 이름은 필수 선택항목입니다.", "E999", "");
  109. return false;
  110. }
  111. }
  112. }
  113. for (var i = 1; i < grd_curerlist.rows - 1; i++){
  114. var sbasecd = model.getValue("/root/main/list2/item[" + i + "]/basecd");
  115. for (var j = 1; j < grd_curerlist.rows; j++){
  116. sbasecd1 = model.getValue("/root/main/list2/item[" + j + "]/basecd");
  117. if (i != j){
  118. if (sbasecd == sbasecd1){
  119. messageBox(j + "번째에서 중복된 자료가 존재합니다", "E999", "");
  120. return false;
  121. }
  122. }
  123. }
  124. }
  125. }
  126. function ExcuroomFunc(){
  127. var sexcudd = model.getValue("/root/main/list2/item[" + grd_curerlist.row + "]/excudd");
  128. if (sexcudd == ""){
  129. messageBox("시행일자를 저장한 후 작업하시기 바랍니다.", "E999", "");
  130. return;
  131. }
  132. if (isValidDateTime(sexcudd, "YYYYMMDD") == false){
  133. messageBox("날짜 형식이 잘못 입력되었습니다.", "E999", "");
  134. return;
  135. }
  136. model.setValue("/root/popdata/excuroomcd", model.getValue("/root/main/list1/item[" + grd_cureroomlist.row + "]/basecd"));
  137. model.setValue("/root/popdata/execrid", model.getValue("/root/main/list2/item[" + grd_curerlist.row + "]/basecd"));
  138. model.setValue("/root/popdata/excudd", model.getValue("/root/main/list2/item[" + grd_curerlist.row + "]/excudd"));
  139. modal("SPAER02100", "", "200", "200", "SPAER02100","/root/popdata","/root/popdata");
  140. readfunc();
  141. }
  142. ]]>
  143. </script>
  144. </xhtml:head>
  145. <xhtml:body guideline="1,1195;2,466;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  146. <group id="group1" style="left:0px; top:0px; width:580px; height:13px; ">
  147. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:235px; height:14px; background-image:../../../com/commonweb/images/tit_bullet1.gif; ">검사/치료실별 근무자관리</caption>
  148. </group>
  149. <group id="group3" scroll="auto" style="left:0px; top:13px; width:695px; height:442px; ">
  150. <group id="grp_btn" scroll="auto" style="left:0px; top:415px; width:680px; height:27px; ">
  151. <button id="btn_save" class="btn4_letter2" disable.background-image="../../../com/commonweb/images/dis_btn4_letter2.gif" style="left:616px; top:3px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn4_letter2.gif; ">
  152. <caption>저장</caption>
  153. <script type="javascript" ev:event="DOMActivate">
  154. <![CDATA[
  155. if (datacheck() == false){
  156. return;
  157. }
  158. model.setValue("/root/send/req/data",grd_curerlist.getUpdateData());
  159. model.setValue("/root/send/excuroomcd", model.getValue("/root/main/list1/item[" + grd_cureroomlist.row + "]/basecd"));
  160. submit("TXAEA00201", false);
  161. //model.setValue("/root/send/excuroomcd", "");
  162. model.removeNodeset("/root/main/list2/item");
  163. model.refresh();
  164. readfunc();
  165. ]]>
  166. </script>
  167. <script type="javascript" ev:event="DOMFocusIn">
  168. <![CDATA[
  169. checkKeyColumn("grd_curerlist");
  170. ]]>
  171. </script>
  172. </button>
  173. </group>
  174. <group id="group2" style="left:0px; top:7px; width:690px; height:35px; vertical-align:top; ">
  175. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:683px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  176. <line id="line13" style="x1:599px; y1:7px; x2:599px; y2:29px; border-color:#ffe4bb; border-left-style:solid; "/>
  177. <button id="btn_sea" class="btn1_letter2" style="left:615px; top:7px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn1_letter2.gif; ">
  178. <caption>조회</caption>
  179. <script type="javascript" ev:event="DOMActivate">
  180. <![CDATA[
  181. submit("TRAEA00201");
  182. ]]>
  183. </script>
  184. </button>
  185. <caption id="caption3" class="search_name" style="left:11px; top:8px; width:106px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">검사/치료실 :</caption>
  186. <input id="input2" ref="/root/send/excuroomcd" class="input_search" style="left:122px; top:8px; width:130px; height:19px; ">
  187. <script type="javascript" ev:event="onkeydown">
  188. <![CDATA[
  189. inputEnterKey("btn_sea","DOMActivate");
  190. ]]>
  191. </script>
  192. </input>
  193. <input id="ipt_acptdd" ref="/root/send/startdate" class="input_default" editable="false" inputtype="date" style="left:403px; top:7px; width:102px; height:19px; text-align:center; "/>
  194. <caption id="caption4" class="search_name" style="left:326px; top:9px; width:74px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">시행일:</caption>
  195. </group>
  196. <caption id="caption1" class="tit_2" style="left:5px; top:53px; width:120px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">검사/치료실 현황</caption>
  197. <line id="line1" class="line_1" style="x1:0px; y1:69px; x2:290px; y2:70px; "/>
  198. <caption id="caption2" class="tit_2" style="left:300px; top:53px; width:133px; height:14px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">근무자 현황</caption>
  199. <line id="line2" class="line_1" style="x1:295px; y1:69px; x2:681px; y2:69px; "/>
  200. <button id="btn_grdadd" class="btn2_letter3" disable.background-image="../../../com/commonweb/images/dis_btn2_letter3.gif" style="left:566px; top:48px; width:53px; height:19px; background-image:../../../com/commonweb/images/btn2_letter3.gif; ">
  201. <caption>행추가</caption>
  202. <script type="javascript" ev:event="DOMActivate">
  203. <![CDATA[
  204. grd_curerlist.addRow();
  205. var irow = grd_curerlist.row - 1;
  206. var ino = grd_curerlist.valueMatrix(irow, 2);
  207. if (irow == 0){
  208. ino = 1;
  209. }else{
  210. ino = parseFloat(ino) + 1;
  211. }
  212. model.setValue("/root/main/list2/item[" + grd_curerlist.row + "]/sortno", ino);
  213. model.refresh();
  214. ]]>
  215. </script>
  216. </button>
  217. <button id="btn_grddel" class="btn2_letter3" disable.background-image="../../../com/commonweb/images/dis_btn2_letter3.gif" style="left:626px; top:48px; width:53px; height:19px; background-image:../../../com/commonweb/images/btn2_letter3.gif; ">
  218. <caption>행삭제</caption>
  219. <script type="javascript" ev:event="DOMActivate">
  220. <![CDATA[
  221. //deleteSelectedRows(grd_curerlist, true);
  222. grd_curerlist.deleteRow(grd_curerlist.row);
  223. /*
  224. var row = grd_curerlist.row;
  225. grd_curerlist.addStatus(row, "delete");
  226. grd_curerlist.cellStyle("background-image", grd_curerlist.row, 0) = "../../../com/commonweb/images/icon_d.gif";
  227. */
  228. ]]>
  229. </script>
  230. </button>
  231. <datagrid id="grd_curerlist" nodeset="/root/main/list2/item" caption="^No^이름^사번^시행일" colsep="^" colwidth="33, 39, 92, 85, 96" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:296px; top:73px; width:384px; height:338px; ">
  232. <col checkvalue="Y,N" ref="check" type="checkbox"/>
  233. <col ref="sortno" type="input" format="99" style="text-align:center; "/>
  234. <col disabled="true" ref="basecd" type="combo" _key="true">
  235. <choices>
  236. <itemset nodeset="/root/init/curerlist">
  237. <label ref="curernm"/>
  238. <value ref="curerid"/>
  239. </itemset>
  240. </choices>
  241. </col>
  242. <col ref="basecdflagdesc" style="text-align:center; "/>
  243. <col ref="excudd" type="inputdate" style="text-align:center; "/>
  244. <script type="javascript" ev:event="xforms-value-changed">
  245. <![CDATA[
  246. //if (isDataCell()) {
  247. var colidx = grd_curerlist.col;
  248. if (grd_curerlist.colAttribute(colidx, "ref") == "check"){
  249. if (model.getValue("/root/main/list2/item[" + grd_curerlist.row + "]/check") == "Y"){
  250. model.setValue("/root/main/list2/item[" + grd_curerlist.row + "]/excudd", model.getValue("/root/send/startdate"));
  251. }
  252. }
  253. if (grd_curerlist.colAttribute(colidx, "ref") == "basecd"){
  254. model.setValue("/root/main/list2/item[" + grd_curerlist.row + "]/basecdflagdesc", model.getValue("/root/main/list2/item[" + grd_curerlist.row + "]/basecd"));
  255. }
  256. //}
  257. model.refresh();
  258. ]]>
  259. </script>
  260. <script type="javascript" ev:event="DOMFocusOut">
  261. <![CDATA[
  262. initPopupMenu();
  263. ]]>
  264. </script>
  265. <script type="javascript" ev:event="onmousedown">
  266. <![CDATA[
  267. setPopupMenu("grd_curerlist", false, "/root/hidden1/popupmenu/menu", "label", "func");
  268. ]]>
  269. </script>
  270. </datagrid>
  271. </group>
  272. <datagrid id="grd_cureroomlist" nodeset="/root/main/list1/item" caption="코드^검사/치료실" colsep="^" colwidth="71, 202" mergecellsfixedrows="bycolrec" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:0px; top:85px; width:291px; height:338px; ">
  273. <col ref="basecd"/>
  274. <col ref="basecdflagdesc"/>
  275. <script type="javascript" ev:event="ondblclick">
  276. <![CDATA[
  277. /*
  278. model.setValue("/root/send/excuroomcd", model.getValue("/root/main/list1/item[" + grd_cureroomlist.row + "]/basecd"));
  279. submit("TRAEA00202", false);
  280. model.setValue("/root/send/excuroomcd", "");
  281. model.refresh();
  282. grd_curerlist.isReadOnly(grd_curerlist.topRow,2, grd_curerlist.bottomRow, 2) = true;
  283. */
  284. ]]>
  285. </script>
  286. <script type="javascript" ev:event="onclick">
  287. <![CDATA[
  288. readfunc();
  289. ]]>
  290. </script>
  291. </datagrid>
  292. </xhtml:body>
  293. </xhtml:html>