SMPMB02600_의사약어관리.xrw 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383
  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. <AbbrList>
  11. <check/>
  12. <orddept/>
  13. <userid/>
  14. <usernm/>
  15. <doctabbr/>
  16. <licnsno/>
  17. <specordyn/>
  18. <lastupdtrid/>
  19. </AbbrList>
  20. </main>
  21. <send>
  22. <choisflag/>
  23. <orddeptcd/>
  24. <usernm/>
  25. <userid/>
  26. <updatedata/>
  27. </send>
  28. <init>
  29. <P0037list>
  30. <P0037>
  31. <cdnm/>
  32. <cdid/>
  33. </P0037>
  34. </P0037list>
  35. <orddeptcd>
  36. <orddeptcdlist>
  37. <cd/>
  38. <nm/>
  39. </orddeptcdlist>
  40. </orddeptcd>
  41. <orddrid>
  42. <orddridlist>
  43. <cd/>
  44. <nm/>
  45. <dp/>
  46. <sp/>
  47. </orddridlist>
  48. </orddrid>
  49. <P0316list>
  50. <P0316>
  51. <cdnm/>
  52. <cdid/>
  53. </P0316>
  54. </P0316list>
  55. </init>
  56. <hidden>
  57. <tmp/>
  58. </hidden>
  59. <temp/>
  60. </root>
  61. </instance>
  62. <script type="javascript" ev:event="xforms-ready">
  63. <![CDATA[
  64. pamGetDeptCDDrIDList();
  65. model.refresh();
  66. ]]>
  67. </script>
  68. <submission id="TRZBC00101" mediatype="application/x-www-form-urlencoded" method="post" replace="instance"/>
  69. <submission id="TRPAM00101" mediatype="application/x-www-form-urlencoded" method="post" replace="instance" resultref="/root/hidden/tmp"/>
  70. <submission id="TRPMB02601" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main"/>
  71. <submission id="TXPMB02602" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/updatedata"/>
  72. <submission id="TXPMB02603" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/updatedata"/>
  73. <submission id="TXPMB02604" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/updatedata"/>
  74. </model>
  75. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  76. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  77. <script type="javascript" src="../../../pam/pamcomnweb/js/PAM.js"/>
  78. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  79. <script type="javascript">
  80. <![CDATA[
  81. function fChoiValue(choiflag){
  82. //진료과별/의사명/의사ID
  83. if (choiflag == '1' ) {
  84. cmb_orddeptcd.attribute("left") = "235px";
  85. cmb_orddeptcd.visible = true;
  86. ipt_usernm.visible = false;
  87. ipt_userid.visible = false;
  88. model.setValue("/root/send/usernm", "");
  89. model.setValue("/root/send/userid", "");
  90. } else if (choiflag == '2') {
  91. ipt_usernm.attribute("left") = "235px";
  92. cmb_orddeptcd.visible = false;
  93. ipt_usernm.visible = true;
  94. ipt_userid.visible = false;
  95. model.setValue("/root/send/orddeptcd", "");
  96. model.setValue("/root/send/userid", "");
  97. model.setFocus("ipt_usernm");
  98. } else if (choiflag == '3') {
  99. ipt_userid.attribute("left") = "235px";
  100. cmb_orddeptcd.visible = false;
  101. ipt_usernm.visible = false;
  102. ipt_userid.visible = true;
  103. model.setValue("/root/send/orddeptcd", "");
  104. model.setValue("/root/send/usernm", "");
  105. model.setFocus("ipt_userid");
  106. }
  107. }//fChoiValue() end
  108. ]]>
  109. </script>
  110. </xhtml:head>
  111. <xhtml:body guideline="1,1136;2,49;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  112. <group id="group1" style="left:0px; top:0px; width:800px; height:13px; ">
  113. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:254px; height:14px; ">의사약어관리</caption>
  114. </group>
  115. <group id="group3" scroll="auto" style="left:0px; top:13px; width:800px; height:662px; ">
  116. <group id="group4" style="left:0px; top:10px; width:800px; height:35px; vertical-align:top; ">
  117. <shape id="roundrect3" class="roundrect_search" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:800px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  118. <button id="btn_search" class="btn1_letter2" navindex="5" style="left:732px; top:7px; width:56px; height:22px; ">
  119. <caption>조회</caption>
  120. <script type="javascript" ev:event="DOMActivate">
  121. <![CDATA[
  122. var choiflag = model.getValue("/root/send/choisflag");
  123. if(choiflag == '1' && cmb_orddeptcd.value == ""){
  124. messageBox("진료과를 선택하지","E007");
  125. return false;
  126. }else if(choiflag == '2' && ipt_usernm.value =="" ){
  127. messageBox("의사명을 입력하지","E007");
  128. return false;
  129. }else if(choiflag == '3' && ipt_userid.value =="" ){
  130. messageBox("의사ID을 입력하지","E007");
  131. return false;
  132. }else{
  133. submit("TRPMB02601");
  134. }// if end
  135. ]]>
  136. </script>
  137. </button>
  138. <line id="line2" class="line_4" style="x1:716px; y1:7px; x2:716px; y2:29px; border-color:#ffe4bb; border-left-style:solid; "/>
  139. <select1 id="cmb_orddeptcd" ref="/root/send/orddeptcd" class="combo_search" navindex="2" visibility="hidden" appearance="minimal" style="left:235px; top:7px; width:198px; height:19px; ">
  140. <choices>
  141. <itemset nodeset="/root/init/orddeptcd/orddeptcdlist">
  142. <label ref="nm"/>
  143. <value ref="cd"/>
  144. </itemset>
  145. </choices>
  146. </select1>
  147. <caption id="caption2" class="search_name" style="left:15px; top:8px; width:86px; height:17px; ">구분 :</caption>
  148. <input id="ipt_usernm" ref="/root/send/usernm" navindex="3" visibility="hidden" style="left:245px; top:7px; width:198px; height:19px; ">
  149. <script type="javascript" ev:event="onkeypress">
  150. <![CDATA[
  151. inputEnterKey("btn_search", "DOMActivate");
  152. ]]>
  153. </script>
  154. </input>
  155. <input id="ipt_userid" ref="/root/send/userid" navindex="4" visibility="hidden" style="left:255px; top:7px; width:198px; height:19px; ">
  156. <script type="javascript" ev:event="onkeypress">
  157. <![CDATA[
  158. inputEnterKey("btn_search", "DOMActivate");
  159. ]]>
  160. </script>
  161. </input>
  162. </group>
  163. <caption id="caption4" class="tit_2" style="left:6px; top:55px; width:139px; height:13px; ">의사약어관리</caption>
  164. <line id="line3" class="line_1" style="x1:0px; y1:70px; x2:800px; y2:70px; "/>
  165. <datagrid id="grd_doctabbrlist" nodeset="/root/main/AbbrList" caption="체크^진료과/진료과약어명^의사ID^의사명^의사약어^의사면허번호^선택진료여부^최종수정자ID" colsep="^" colwidth="47, 140, 85, 98, 108, 107, 111, 100" dataheight="25" defaultrows="2" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowsep="|" style="left:0px; top:75px; width:800px; height:581px; vertical-align:middle; ">
  166. <col checkvalue="true,false" ref="check" type="checkbox"/>
  167. <col ref="orddept" type="output" style="text-align:center; vertical-align:middle; "/>
  168. <col ref="userid" type="output" style="text-align:center; vertical-align:middle; "/>
  169. <col ref="usernm" type="output" style="text-align:center; vertical-align:middle; "/>
  170. <col imemode="disabled" ref="doctabbr" type="input" maxlength="5" style="text-align:center; vertical-align:middle; "/>
  171. <col ref="licnsno" type="output" style="text-align:center; vertical-align:middle; "/>
  172. <col ref="specordyn" type="output" style="text-align:center; vertical-align:middle; "/>
  173. <col ref="lastupdtrid" type="output" style="text-align:center; vertical-align:middle; "/>
  174. <script type="javascript" ev:event="xforms-value-changed">
  175. <![CDATA[
  176. var col = grd_doctabbrlist.col;
  177. var row = grd_doctabbrlist.row;
  178. var title = grd_doctabbrlist.labelMatrix(0,col);
  179. // //체크박스 자동체크
  180. // if(title == "의사약어"){
  181. // model.setValue("/root/main/AbbrList["+row+"]/check","true");
  182. // }else{
  183. // model.setValue("/root/main/AbbrList["+row+"]/check","false");
  184. // }// if end
  185. //의사약어 대문자로 변환
  186. if(title == "의사약어"){
  187. var tempabbr = model.getValue("/root/main/AbbrList["+row+"]/doctabbr");
  188. model.resetInstanceNode("/root/main/AbbrList["+row+"]/doctabbr");
  189. model.setValue("/root/main/AbbrList["+row+"]/doctabbr", tempabbr.toUpperCase());
  190. model.refresh();
  191. }// if end
  192. ]]>
  193. </script>
  194. <script type="javascript" ev:event="ondblclick">
  195. <![CDATA[
  196. var col = grd_doctabbrlist.col;
  197. var row = grd_doctabbrlist.row;
  198. var title = grd_doctabbrlist.labelMatrix(0,col);
  199. if(title == "의사약어" && model.getValue("root/main/AbbrListt["+row+"]/doctabbr") != null){
  200. btn_save.disabled = "true";
  201. btn_update.disabled = "false";
  202. }else{
  203. btn_save.disabled = "false";
  204. btn_update.disabled = "true";
  205. }// if end
  206. ]]>
  207. </script>
  208. </datagrid>
  209. </group>
  210. <group id="group2" scroll="auto" style="left:0px; top:675px; width:800px; height:27px; ">
  211. <line id="line32" class="line_6" style="x1:0px; y1:0px; x2:800px; y2:0px; "/>
  212. </group>
  213. <select1 id="cmb_choiflag" ref="/root/send/choisflag" class="combo_s_essential" navindex="1" appearance="minimal" style="left:80px; top:30px; width:150px; height:19px; ">
  214. <choices>
  215. <item>
  216. <label>진료과별</label>
  217. <value>1</value>
  218. </item>
  219. <item>
  220. <label>의사명</label>
  221. <value>2</value>
  222. </item>
  223. <item>
  224. <label>의사ID</label>
  225. <value>3</value>
  226. </item>
  227. </choices>
  228. <script type="javascript" ev:event="xforms-select">
  229. <![CDATA[
  230. var choiflag = model.getValue("/root/send/choisflag");
  231. //검색조건
  232. fChoiValue(choiflag);
  233. ]]>
  234. </script>
  235. </select1>
  236. <button id="btn_update" class="btn4_letter2" navindex="7" visibility="hidden" style="left:571px; top:680px; width:56px; height:22px; ">
  237. <caption>수정</caption>
  238. <script type="javascript" ev:event="DOMActivate">
  239. <![CDATA[
  240. //체크된 데이터만 가져온다.
  241. var nodeList = instance1.selectNodes("/root/main/AbbrList[check='true']");
  242. var rCSV = getNodeListCSV(nodeList);
  243. if( rCSV == "" || rCSV == null || rCSV == undefined){
  244. //messageBox("미예약 항목이 선택되지 않았습니다.", "E999", "");
  245. messageBox("수정할 항목이 선택되지", "E007");
  246. return false;
  247. }// if end
  248. if(messageBox("수정된 내용을 반영하시겠습니까?", "Q999") != 6) return false;
  249. model.resetInstanceNode("/root/send/updatedata");
  250. //model.setValue("/root/send/updatedata/datalist", rCSV);
  251. setCSVToNode("/root/temp", rCSV);
  252. instance1.selectSingleNode("/root/temp").xml;
  253. model.copyNode("/root/send/updatedata", "/root/temp");
  254. if(submit("TXPMB02602")){
  255. //정상적으로 처리되었습니다.
  256. messageBox("정상적으로 ","I001");
  257. var rows = grd_doctabbrlist.rows;
  258. var fixedRows = grd_doctabbrlist.fixedRows;
  259. var dataRows = rows - fixedRows;
  260. for (var i = dataRows ; i>0; i--){
  261. if (model.getValue("/root/main/AbbrList["+i+"]/check") == "true"){
  262. model.setValue("/root/main/AbbrList["+i+"]/check","false");
  263. }
  264. }//for end
  265. model.removenode("/root/temp");
  266. model.makeNode("/root/temp");
  267. }//if end
  268. model.refresh();
  269. ]]>
  270. </script>
  271. </button>
  272. <button id="btn_save" class="btn4_letter4" navindex="6" visibility="hidden" style="left:489px; top:680px; width:80px; height:22px; ">
  273. <caption>신규저장</caption>
  274. <script type="javascript" ev:event="DOMActivate">
  275. <![CDATA[
  276. //체크된 데이터만 가져온다.
  277. var nodeList = instance1.selectNodes("/root/main/AbbrList[check='true']");
  278. var rCSV = getNodeListCSV(nodeList);
  279. if( rCSV == "" || rCSV == null || rCSV == undefined){
  280. //messageBox("미예약 항목이 선택되지 않았습니다.", "E999", "");
  281. messageBox("신규입력할 항목이 선택되지", "E007");
  282. return false;
  283. }// if end
  284. if(messageBox("신규입력된 내용을 반영하시겠습니까?", "Q999") != 6) return false;
  285. model.resetInstanceNode("/root/send/updatedata");
  286. //model.setValue("/root/send/updatedata/datalist", rCSV);
  287. setCSVToNode("/root/temp", rCSV);
  288. instance1.selectSingleNode("/root/temp").xml;
  289. model.copyNode("/root/send/updatedata", "/root/temp");
  290. if(submit("TXPMB02603")){
  291. //정상적으로 처리되었습니다.
  292. messageBox("정상적으로 ","I001");
  293. var rows = grd_doctabbrlist.rows;
  294. var fixedRows = grd_doctabbrlist.fixedRows;
  295. var dataRows = rows - fixedRows;
  296. for (var i = dataRows ; i>0; i--){
  297. if (model.getValue("/root/main/AbbrList["+i+"]/check") == "true"){
  298. model.setValue("/root/main/AbbrList["+i+"]/check","false");
  299. }
  300. }//for end
  301. model.removenode("/root/temp");
  302. model.makeNode("/root/temp");
  303. }//if end
  304. model.refresh();
  305. ]]>
  306. </script>
  307. </button>
  308. <button id="btn_clear" class="btn4_letter3" navindex="8" style="left:729px; top:680px; width:68px; height:22px; ">
  309. <caption>초기화</caption>
  310. <script type="javascript" ev:event="DOMActivate">
  311. <![CDATA[
  312. //화면 초기화
  313. model.resetInstanceNode("/root/main/AbbrList");
  314. model.resetInstanceNode("/root/send");
  315. model.resetInstanceNode("/root/temp");
  316. model.resetInstanceNode("/root/hidden");
  317. model.refresh();
  318. ]]>
  319. </script>
  320. </button>
  321. <button id="button1" class="btn4_letter2" navindex="7" visibility="visible" style="left:673px; top:680px; width:56px; height:22px; ">
  322. <caption>저장</caption>
  323. <script type="javascript" ev:event="DOMActivate">
  324. <![CDATA[
  325. //체크된 데이터만 가져온다.
  326. var nodeList = instance1.selectNodes("/root/main/AbbrList[check='true']");
  327. var rCSV = getNodeListCSV(nodeList);
  328. if( rCSV == "" || rCSV == null || rCSV == undefined){
  329. //messageBox("미예약 항목이 선택되지 않았습니다.", "E999", "");
  330. messageBox("수정할 항목이 선택되지", "E007");
  331. return false;
  332. }// if end
  333. if(messageBox("선택한 내용을 반영하시겠습니까?", "Q999") != 6) return false;
  334. model.resetInstanceNode("/root/send/updatedata");
  335. //model.setValue("/root/send/updatedata/datalist", rCSV);
  336. setCSVToNode("/root/temp", rCSV);
  337. instance1.selectSingleNode("/root/temp").xml;
  338. model.copyNode("/root/send/updatedata", "/root/temp");
  339. if(submit("TXPMB02604")){
  340. //정상적으로 처리되었습니다.
  341. messageBox("정상적으로 ","I001");
  342. var rows = grd_doctabbrlist.rows;
  343. var fixedRows = grd_doctabbrlist.fixedRows;
  344. var dataRows = rows - fixedRows;
  345. for (var i = dataRows ; i>0; i--){
  346. if (model.getValue("/root/main/AbbrList["+i+"]/check") == "true"){
  347. model.setValue("/root/main/AbbrList["+i+"]/check","false");
  348. }
  349. }//for end
  350. model.removenode("/root/temp");
  351. model.makeNode("/root/temp");
  352. submit("TRPMB02601");
  353. }//if end
  354. model.refresh();
  355. ]]>
  356. </script>
  357. </button>
  358. </xhtml:body>
  359. </xhtml:html>