SPZSU10102_사용자부서전체조회.xrw 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. <?xml version="1.0" encoding="UTF-8"?>
  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. <list>
  11. <userlist/>
  12. </list>
  13. <item>
  14. <temp/>
  15. </item>
  16. </main>
  17. <send>
  18. <searchitem/>
  19. <flag/>
  20. <instcd/>
  21. <searchitem_dutplceinst/>
  22. <searchitem_dutplce/>
  23. <flag_dutplceinst/>
  24. <flag_dutplce/>
  25. </send>
  26. <init>
  27. <searchitem/>
  28. <flag>
  29. <lable>사용자ID</lable>
  30. <value>userid</value>
  31. </flag>
  32. <flag>
  33. <lable>사용자명</lable>
  34. <value>usernm</value>
  35. </flag>
  36. <instflag>
  37. <lable>근무지기관코드</lable>
  38. <value>dutplceinstcd</value>
  39. </instflag>
  40. <instflag>
  41. <lable>근무지기관명</lable>
  42. <value>dutplceinstnm</value>
  43. </instflag>
  44. <deptflag>
  45. <lable>근무지코드</lable>
  46. <value>dutplcecd</value>
  47. </deptflag>
  48. <deptflag>
  49. <lable>근무지명</lable>
  50. <value>dutplcenm</value>
  51. </deptflag>
  52. <searchitem_dutplceinst/>
  53. <searchitem_dutplce/>
  54. <namesearch/>
  55. </init>
  56. </root>
  57. </instance>
  58. <script ev:event="xforms-ready" type="javascript">
  59. <![CDATA[
  60. fInitialize();
  61. ]]>
  62. </script>
  63. <submission id="TRZSU10104" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/list"/>
  64. </model>
  65. <script src="../../../com/commonweb/js/common.js" type="javascript"/>
  66. <script type="javascript">
  67. <![CDATA[
  68. /*
  69. 초기화 작업을 합니다.
  70. */
  71. function fInitialize(){
  72. model.removeNodeset("/root/main/list/userlist");
  73. rdo_dutplceinst.select(0);
  74. rdo_dutplce.select(0);
  75. rdo_user.select(0);
  76. model.refresh();
  77. }
  78. /*
  79. 버튼 컨트롤들을 클릭했을때 공통으로 타는 함수입니다.
  80. control : "search" 는 조회 버튼 클릭
  81. "init"은 신규 버튼 클릭
  82. "save"는 저장 버튼 클릭
  83. grid : 그리드 컨트롤을 넘겨줍니다.
  84. param : 기타 param을 넘겨줍니다.
  85. */
  86. function fClicked(control, grid, param){
  87. if ("search" == control){
  88. fSearchClick(grid, param);
  89. model.resetInstanceNode("/root/send");
  90. } else if ("init" == control){
  91. model.reset();
  92. } else {
  93. messageBox("처리를 수행","E002");
  94. }
  95. model.refresh();
  96. }
  97. /*
  98. 조회버튼 클릭 타는 함수입니다.
  99. grid.explorerbar = "sortshow" sort설정합니다.
  100. ipt_usercdnm_flag는 검색조건의 사용자코드 or 사용자명입니다.
  101. rdo_user은 사용자코드 or 사용자명 선택 라디오 버튼입니다.
  102. submit을 날립니다.
  103. .
  104. */
  105. function fSearchClick(grid,param){
  106. grid.explorerbar = "sortshow";
  107. model.removeNodeset("/root/main/list/userlist");
  108. grid.rebuild();
  109. model.resetInstanceNode("/root/send");
  110. model.setValue("/root/send/searchitem", ipt_search_item.currentText);
  111. model.setValue("/root/send/searchitem_dutplceinst", ipt_dutplceinstcd.currentText);
  112. model.setValue("/root/send/searchitem_dutplce", ipt_dutplcecd.currentText);
  113. model.setValue("/root/send/flag", rdo_user.value);
  114. model.setValue("/root/send/flag_dutplceinst", rdo_dutplceinst.value);
  115. model.setValue("/root/send/flag_dutplce", rdo_dutplce.value);
  116. //if (ipt_search_item.currentText == "" || ipt_dutplceinstcd.currentText == "" || ipt_dutplcecd.currentText == ""){
  117. if ( ipt_dutplceinstcd.currentText == "" || ipt_dutplcecd.currentText == ""){
  118. var rtn = messageBox("검색조건을 최소한 하나 ", "C001");
  119. } else {
  120. submit("TRZSU10104");
  121. }
  122. }
  123. function fResetNode(node, destinationelement){
  124. // model.setValue(node + "/" + destinationelement, "");
  125. alert(model.elementName("/root/main/item"));
  126. }
  127. /*
  128. model.getValue(); 를 함수로 만들었습니다.
  129. param1 : node는 grid의 xPath입니다.
  130. param2 : row는 grid에서 선택한 row값입니다.
  131. param3 : element는 getvalue할 해당 element 명입니다.
  132. 해당 getvalue값을 return 해줍니다.
  133. return 하지 않으면 해당값을 가져올 수 없습니다.
  134. */
  135. function fGetValue(node, row, element) {
  136. var rtnValue = model.getValue(node + "[" + row + "]/" + element);
  137. return rtnValue;
  138. }
  139. /*
  140. model.setValue();를 함수로 만들었습니다.
  141. param1 : node는 setvalue할 컨트롤의 xPath입니다.
  142. param2 : destinationelement는 setvalue할 element명 입니다.
  143. param3 : sourceelement는 setvalue할 값입니다.
  144. */
  145. function fSetValue(node, destinationelement, sourceelement) {
  146. model.setValue(node + "/" + destinationelement, sourceelement);
  147. }
  148. ]]>
  149. </script>
  150. </xhtml:head>
  151. <xhtml:body pagewidth="605" pageheight="435" style="border-color:#c7a3cf; ">
  152. <group id="group5" scroll="auto" style="left:0px; top:13px; width:605px; height:420px; border-color:#c7a3cf; border-style:solid; ">
  153. <group id="group2" style="left:0px; top:10px; width:603px; height:85px; vertical-align:top; ">
  154. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:603px; height:85px; background-color:#fffbf2; border-color:#ffd799; "/>
  155. <caption id="caption1" class="search_name" style="left:15px; top:9px; width:117px; height:17px; ">검색조건 :</caption>
  156. <line id="line1" style="x1:525px; y1:7px; x2:525px; y2:76px; border-color:#ffe4bb; border-left-style:solid; "/>
  157. <button id="btn_search" class="btn1_letter2" style="left:534px; top:29px; width:56px; height:22px; ">
  158. <caption>조회</caption>
  159. <script ev:event="DOMActivate" type="javascript">
  160. <![CDATA[
  161. var param = ipt_search_item.currentText;
  162. fClicked("search", grd_userlist);
  163. ]]>
  164. </script>
  165. </button>
  166. <input id="ipt_search_item" ref="/root/init/searchitem" class="input_s_essential" style="left:330px; top:59px; width:122px; height:19px; ">
  167. <script ev:event="onkeypress" type="javascript">
  168. <![CDATA[
  169. if("13" == event.keyCode){
  170. btn_search.dispatch("DOMActivate");
  171. //fClicked("search", grd_userbaseinfo, param);
  172. }
  173. ]]>
  174. </script>
  175. </input>
  176. <select1 id="rdo_user" ref="/root/init" class="s" overflow="visible" appearance="full" cellspacing="37" cols="2" style="left:116px; top:59px; width:13px; height:13px; background-color:transparent; border-style:none; ">
  177. <choices>
  178. <itemset nodeset="/root/init/flag">
  179. <label ref="lable"/>
  180. <value ref="value"/>
  181. </itemset>
  182. </choices>
  183. </select1>
  184. <input id="ipt_dutplceinstcd" ref="/root/init/searchitem_dutplceinst" class="input_s_essential" style="left:330px; top:5px; width:122px; height:19px; ">
  185. <script ev:event="onkeypress" type="javascript">
  186. <![CDATA[
  187. if("13" == event.keyCode){
  188. btn_search.dispatch("DOMActivate");
  189. //fClicked("search", grd_userbaseinfo, param);
  190. }
  191. ]]>
  192. </script>
  193. </input>
  194. <input id="ipt_dutplcecd" ref="/root/init/searchitem_dutplce" class="input_s_essential" style="left:330px; top:32px; width:122px; height:19px; ">
  195. <script ev:event="onkeypress" type="javascript">
  196. <![CDATA[
  197. if("13" == event.keyCode){
  198. btn_search.dispatch("DOMActivate");
  199. //fClicked("search", grd_userbaseinfo, param);
  200. }
  201. ]]>
  202. </script>
  203. </input>
  204. <select1 id="rdo_dutplce" ref="/root/init/deptflag" class="s" overflow="visible" appearance="full" cellspacing="24" cols="2" style="left:116px; top:32px; width:13px; height:13px; background-color:transparent; border-style:none; ">
  205. <choices>
  206. <itemset nodeset="/root/init/deptflag">
  207. <label ref="lable"/>
  208. <value ref="value"/>
  209. </itemset>
  210. </choices>
  211. </select1>
  212. <select1 id="rdo_dutplceinst" ref="/root/init/instflag" class="s" overflow="visible" appearance="full" cols="2" style="left:116px; top:5px; width:13px; height:13px; background-color:transparent; border-style:none; ">
  213. <choices>
  214. <itemset nodeset="/root/init/instflag">
  215. <label ref="lable"/>
  216. <value ref="value"/>
  217. </itemset>
  218. </choices>
  219. </select1>
  220. <select id="chk_namesearch" ref="/root/init/namesearch" overflow="visible" appearance="full" style="left:15px; top:30px; width:100px; height:20px; border-style:none; ">
  221. <choices>
  222. <item>
  223. <label>"명"검색</label>
  224. <value>name</value>
  225. </item>
  226. </choices>
  227. <script ev:event="xforms-select" type="javascript">
  228. <![CDATA[
  229. rdo_dutplceinst.select(1);
  230. rdo_dutplce.select(1);
  231. rdo_user.select(1);
  232. ]]>
  233. </script>
  234. </select>
  235. </group>
  236. <caption id="caption9" class="tit_2" style="left:0px; top:103px; width:111px; height:13px; vertical-align:middle; margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">사용자조회</caption>
  237. <line id="line12" class="line_1" style="x1:0px; y1:119px; x2:603px; y2:119px; "/>
  238. <datagrid id="grd_userlist" nodeset="/root/main/list/userlist" caption="사용자ID^사용자명^소속기관명^소속기관코드^소속부서명^소속부서코드^근무지기관명^근무지기관코드^근무지명^근무지코드" colwidth="100,100,100,100,100,100,100,100,100" dataheight="25" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="update" rowheight="32" style="left:0px; top:125px; width:603px; height:293px; ">
  239. <col ref="userid"/>
  240. <col ref="usernm"/>
  241. <col ref="posinstnm"/>
  242. <col ref="posinstcd"/>
  243. <col ref="posdeptnm"/>
  244. <col ref="posdeptcd"/>
  245. <col ref="dutplceinstnm"/>
  246. <col ref="dutplceinstcd"/>
  247. <col ref="dutplcenm"/>
  248. <col ref="dutplcecd"/>
  249. <script ev:event="ondblclick" type="javascript">
  250. <![CDATA[
  251. var iRow = grd_userlist.row;
  252. var iParam="";
  253. var iNode = "/root/main/list/userlist";
  254. var iParam_userid = fGetValue(iNode, iRow, "userid");
  255. var iParam_usernm = fGetValue(iNode, iRow, "usernm");
  256. var iParam_posinstnm = fGetValue(iNode, iRow, "posinstnm");
  257. var iParam_posinstcd = fGetValue(iNode, iRow, "posinstcd");
  258. var iParam_posdeptnm = fGetValue(iNode, iRow, "posdeptnm");
  259. var iParam_posdeptcd = fGetValue(iNode, iRow, "posdeptcd");
  260. var iParam_dutplceinstcd = fGetValue(iNode, iRow, "dutplceinstcd");
  261. var iParam_dutplceinstnm = fGetValue(iNode, iRow, "dutplceinstnm");
  262. var iParam_dutplcecd = fGetValue(iNode, iRow, "dutplcecd");
  263. var iParam_dutplcenm = fGetValue(iNode, iRow, "dutplcenm");
  264. iParam = iParam_userid+"|"+iParam_usernm+"|"+iParam_posinstnm+"|"+iParam_posinstcd+"|"
  265. +iParam_posdeptnm+"|"+iParam_posdeptcd+"|"+iParam_dutplceinstcd+"|"+iParam_dutplceinstnm+"|"+iParam_dutplcecd+"|"+iParam_dutplcenm;
  266. if ( checkOpener() ) {
  267. opener.javascript.setParameter("SPZSU10101_", iParam);
  268. } else {
  269. var rtn = messageBox("상위화면을 찾을 수", "E001");
  270. }
  271. window.close();
  272. ]]>
  273. </script>
  274. </datagrid>
  275. </group>
  276. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:603px; height:13px; ">사용자조회</caption>
  277. </xhtml:body>
  278. </xhtml:html>