SMMMI00920_당직중복조회.xfdl 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMMMI00920" position="absolute 0 0 1100 500" titletext="당직 중복 조회" oninit="SMMMI00920_oninit" onload="SMMMI00920_onload">
  5. <Layouts>
  6. <Layout>
  7. <Grid id="grd_workduplist" taborder="3" binddataset="ds_workduplist" useinputpanel="false" selecttype="multiarea" cellsizingtype="col" autofittype="none" oncelldblclick="grp_right_grd_workschelist_oncelldblclick" position="absolute 0 27 1100 500" anchor="all">
  8. <Formats>
  9. <Format id="default">
  10. <Columns>
  11. <Column size="70"/>
  12. <Column size="50"/>
  13. <Column size="40"/>
  14. <Column size="100"/>
  15. <Column size="60"/>
  16. <Column size="60"/>
  17. <Column size="100"/>
  18. <Column size="100"/>
  19. <Column size="55"/>
  20. <Column size="55"/>
  21. <Column size="55"/>
  22. <Column size="55"/>
  23. <Column size="55"/>
  24. <Column size="55"/>
  25. <Column size="55"/>
  26. <Column size="55"/>
  27. <Column size="55"/>
  28. <Column size="55"/>
  29. <Column size="55"/>
  30. <Column size="55"/>
  31. <Column size="55"/>
  32. <Column size="55"/>
  33. <Column size="55"/>
  34. <Column size="55"/>
  35. <Column size="40"/>
  36. <Column size="40"/>
  37. <Column size="40"/>
  38. <Column size="40"/>
  39. </Columns>
  40. <Rows>
  41. <Row size="24" band="head"/>
  42. <Row size="22"/>
  43. </Rows>
  44. <Band id="head">
  45. <Cell text="일자"/>
  46. <Cell col="1" text="요일"/>
  47. <Cell col="2" text="근무"/>
  48. <Cell col="3" text="부서"/>
  49. <Cell col="4" text="사번" taborder="undefined"/>
  50. <Cell col="5" text="성명" taborder="undefined"/>
  51. <Cell col="6" text="근무시작"/>
  52. <Cell col="7" text="근무종료"/>
  53. <Cell col="8" text="권역외상"/>
  54. <Cell col="9" text="심혈관"/>
  55. <Cell col="10" text="뇌혈관"/>
  56. <Cell col="11" text="TICU"/>
  57. <Cell col="12" text="EICU"/>
  58. <Cell col="13" text="MICU"/>
  59. <Cell col="14" text="CCU"/>
  60. <Cell col="15" text="SU"/>
  61. <Cell col="16" text="NSICU"/>
  62. <Cell col="17" text="SICU"/>
  63. <Cell col="18" text="CICU"/>
  64. <Cell col="19" text="NICU"/>
  65. <Cell col="20" text="NICU"/>
  66. <Cell col="21" text="PICU"/>
  67. <Cell col="22" text="ICU"/>
  68. <Cell col="23" text="W63"/>
  69. <Cell col="24" text="내신"/>
  70. <Cell col="25" text="외심"/>
  71. <Cell col="26" text="심뇌"/>
  72. <Cell col="27" text="W45"/>
  73. </Band>
  74. <Band id="body">
  75. <Cell displaytype="date" text="bind:workdd"/>
  76. <Cell col="1" text="bind:datenm"/>
  77. <Cell col="2" text="bind:dutycd"/>
  78. <Cell col="3" text="bind:deptnm"/>
  79. <Cell col="4" displaytype="normal" text="bind:userid" calendardisplaynulltype="none"/>
  80. <Cell col="5" text="bind:usernm"/>
  81. <Cell col="6" displaytype="normal" text="bind:fromdt" mask="##-## ##:##"/>
  82. <Cell col="7" displaytype="normal" text="bind:todt" mask="##-## ##:##"/>
  83. <Cell col="8" style="align:center middle;" text="bind:traumayn"/>
  84. <Cell col="9" text="bind:c01yn"/>
  85. <Cell col="10" text="bind:c02yn"/>
  86. <Cell col="11" style="align:center middle;" text="bind:ticuyn"/>
  87. <Cell col="12" style="align:center middle;" text="bind:eicuyn"/>
  88. <Cell col="13" style="align:center middle;" text="bind:micuyn"/>
  89. <Cell col="14" style="align:center middle;" text="bind:ccuyn"/>
  90. <Cell col="15" style="align:center middle;" text="bind:suyn"/>
  91. <Cell col="16" style="align:center middle;" text="bind:nsicuyn"/>
  92. <Cell col="17" style="align:center middle;" text="bind:sicuyn"/>
  93. <Cell col="18" style="align:center middle;" text="bind:cicuyn"/>
  94. <Cell col="19" style="align:center middle;" text="bind:nicuyn"/>
  95. <Cell col="20" text="bind:nicu032yn"/>
  96. <Cell col="21" text="bind:picu032yn"/>
  97. <Cell col="22" text="bind:icu032yn"/>
  98. <Cell col="23" text="bind:w63032yn"/>
  99. <Cell col="24" text="bind:a13yn"/>
  100. <Cell col="25" text="bind:a14yn"/>
  101. <Cell col="26" text="bind:a15yn"/>
  102. <Cell col="27" text="bind:w45032yn"/>
  103. </Band>
  104. </Format>
  105. </Formats>
  106. </Grid>
  107. <Static id="cpt_worktitle" text="당직중복 조회" class="tit_2" position="absolute 0 5 323 21" anchor="left top"/>
  108. <Shape id="line3" class="line_10" position="absolute 0 18 1100 30" anchor="left top right"/>
  109. <Button id="btn_excel" taborder="4" text="Excel" onclick="btn_excel_onclick" class="btn7" position="absolute 1037 1 1100 21" anchor="top right"/>
  110. </Layout>
  111. </Layouts>
  112. <Objects>
  113. <Dataset id="ds_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  114. <ColumnInfo>
  115. <Column id="flag" type="STRING" size="256"/>
  116. <Column id="superyn" type="STRING" size="256"/>
  117. <Column id="authyn" type="STRING" size="256"/>
  118. <Column id="basedd" type="STRING" size="256"/>
  119. <Column id="authdeptcd" type="STRING" size="256"/>
  120. <Column id="workcd" type="STRING" size="256"/>
  121. <Column id="worktype" type="STRING" size="256"/>
  122. <Column id="orddeptcd" type="STRING" size="256"/>
  123. <Column id="appuseryn" type="STRING" size="256"/>
  124. <Column id="instcd" type="STRING" size="256"/>
  125. </ColumnInfo>
  126. <Rows>
  127. <Row/>
  128. </Rows>
  129. </Dataset>
  130. <Dataset id="ds_workduplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  131. <ColumnInfo>
  132. <Column id="instcd" type="STRING" size="256" sumtext="당직일자"/>
  133. <Column id="workdd" type="STRING" size="256" sumtext="당직일자"/>
  134. <Column id="datenm" type="STRING" size="256" sumtext="당직일자"/>
  135. <Column id="dutycd" type="STRING" size="256" sumtext="당직일자"/>
  136. <Column id="deptcd" type="STRING" size="256" sumtext="당직일자"/>
  137. <Column id="deptnm" type="STRING" size="256" sumtext="당직일자"/>
  138. <Column id="userid" type="STRING" size="256" sumtext="당직일자"/>
  139. <Column id="usernm" type="STRING" size="256" sumtext="요일"/>
  140. <Column id="fromdt" type="STRING" size="256" sumtext="당직 시작시간"/>
  141. <Column id="todt" type="STRING" size="256" sumtext="당직 종료시간"/>
  142. <Column id="traumayn" type="STRING" size="256" sumtext="권역외상"/>
  143. <Column id="c01yn" type="STRING" size="256" sumtext="심혈관"/>
  144. <Column id="c02yn" type="STRING" size="256" sumtext="뇌혈관"/>
  145. <Column id="ticuyn" type="STRING" size="256" sumtext="TICU"/>
  146. <Column id="micuyn" type="STRING" size="256" sumtext="MICU"/>
  147. <Column id="eicuyn" type="STRING" size="256" sumtext="EICU"/>
  148. <Column id="ccuyn" type="STRING" size="256" sumtext="CCU"/>
  149. <Column id="suyn" type="STRING" size="256" sumtext="SU"/>
  150. <Column id="nsicuyn" type="STRING" size="256" sumtext="NSICU"/>
  151. <Column id="sicuyn" type="STRING" size="256" sumtext="SICU"/>
  152. <Column id="cicuyn" type="STRING" size="256" sumtext="CICU"/>
  153. <Column id="nicuyn" type="STRING" size="256" sumtext="NICU"/>
  154. <Column id="nicu032yn" type="STRING" size="256" sumtext="칠곡NICU"/>
  155. <Column id="picu032yn" type="STRING" size="256" sumtext="칠곡PICU"/>
  156. <Column id="icu032yn" type="STRING" size="256" sumtext="칠곡ICU"/>
  157. <Column id="w63032yn" type="STRING" size="256" sumtext="칠곡63병동"/>
  158. <Column id="a13yn" type="STRING" size="256" sumtext="내과신경외과"/>
  159. <Column id="a14yn" type="STRING" size="256" sumtext="외과심혈관외과"/>
  160. <Column id="a15yn" type="STRING" size="256" sumtext="심뇌혈관응급치료실"/>
  161. <Column id="w45032yn" type="STRING" size="256" sumtext="칠곡45병동"/>
  162. </ColumnInfo>
  163. </Dataset>
  164. </Objects>
  165. <Bind>
  166. <BindItem id="item2" compid="group3.group4.cmb_orddeptcd" propid="value" datasetid="ds_cond" columnid="orddeptcd"/>
  167. <BindItem id="item3" compid="group3.group1.cpt_worktitle" propid="text" datasetid="ds_main_titleinfo" columnid="worktitle"/>
  168. <BindItem id="item10" compid="group3.group4.ipt_srchdd" propid="value" datasetid="ds_cond" columnid="srchdd"/>
  169. <BindItem id="item1" compid="SMMMI00920" propid="text" datasetid="ds_cond" columnid="srchdd"/>
  170. </Bind>
  171. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  172. * System Name : 경대 의료정보시스템
  173. * Job Name :
  174. * Creator : 엄영만
  175. * Make Date : 2018-05-21
  176. * Description :
  177. ****************************************************************************************/
  178. //=======================================================================================
  179. // Lib Include
  180. //---------------------------------------------------------------------------------------
  181. include "com_commonxp::comm_main.xjs";
  182. include "emr_prcpmngtxp::MMOCommon.xjs";
  183. include "emr_prcpmngtxp::MMO001.xjs";
  184. //=======================================================================================
  185. // Global Form Variable
  186. //---------------------------------------------------------------------------------------
  187. //이전 셀의 행,열 인덱스를 저장하는 변수
  188. var col = -1;
  189. var row = -1;
  190. var arErrorCode = new HashArray();
  191. //=======================================================================================
  192. // Function
  193. //---------------------------------------------------------------------------------------
  194. //=======================================================================================
  195. // Event
  196. //---------------------------------------------------------------------------------------
  197. function SMMMI00920_oninit(obj:Form, e:InitEventInfo)
  198. {
  199. frmf_initForm(obj); //폼 초기화
  200. grdf_initGrid(grd_workduplist);
  201. }
  202. function SMMMI00920_onload(obj:Form, e:LoadEventInfo)
  203. {
  204. grdf_setToolTipBind(grd_workduplist);
  205. ds_cond.copyData(arg_cond);
  206. ds_cond.addColumn("instcd", "string", "256");
  207. ds_cond.setColumn(0, "instcd", sysf_getUserInfo("dutplceinstcd"));
  208. setOrderInfoOfCol(grd_workduplist); // 컬럼 설정
  209. fgetWorkDupList();
  210. }
  211. function setOrderInfoOfCol(grid:Grid){
  212. var refdata = "";
  213. var sizedata = "";
  214. var frozencol = "todt";
  215. if(sysf_getUserInfo("dutplceinstcd") == "031") {
  216. refdata = "workdd^datenm^dutycd^deptnm^userid^usernm^fromdt^todt^traumayn^c01yn^c02yn^ticuyn^eicuyn^micuyn^ccuyn^suyn^nsicuyn^sicuyn^cicuyn^nicuyn^nicu032yn^picu032yn^icu032yn^w63032yn^a13yn^a14yn^a15yn^w45032yn";
  217. sizedata = "70^50^40^100^60^60^100^100^55^55^55^55^55^55^55^55^55^55^55^55^0^0^0^0^55^55^55^0";
  218. } else if(sysf_getUserInfo("dutplceinstcd") == "032") {
  219. refdata = "workdd^datenm^dutycd^deptnm^userid^usernm^fromdt^todt^traumayn^c01yn^c02yn^ticuyn^eicuyn^micuyn^ccuyn^suyn^nsicuyn^sicuyn^cicuyn^nicuyn^nicu032yn^picu032yn^icu032yn^w63032yn^a13yn^a14yn^a15yn^w45032yn";
  220. sizedata = "70^50^40^100^60^60^100^100^0^0^0^0^0^0^0^0^0^0^0^0^55^55^55^55^0^0^0^55";
  221. }
  222. if(utlf_isNull(refdata) || utlf_isNull(sizedata)) return;
  223. var refarr = refdata.split("^");
  224. var sizearr = sizedata.split("^");
  225. var nFrozenCols = grid.getBindCellIndex("body", frozencol);
  226. var oGridDataSet = eval(grid.binddataset);
  227. grid.enableevent = false;
  228. grid.enableredraw = false;
  229. //try {
  230. if(!utlf_isNull(nFrozenCols)) {
  231. for(var i = oGridDataSet.colcount - 1; i >= 0; i--) {
  232. if(i <= nFrozenCols)
  233. grid.setFormatColProperty(i, "band", "body");
  234. }
  235. }
  236. for(var i = 1; i < grid.getFormatColCount(); i++) {
  237. grid.setFormatColProperty(i, "size", 0);
  238. }
  239. for(var i = 0; i < refarr.length; i++) {
  240. var nCol = i;
  241. var colText = refarr[i];
  242. var col = grid.getBindCellIndex("body", colText);
  243. if(col == -1) continue;
  244. if(i != col) {
  245. var headText = grid.getCellProperty("head", col, "text");
  246. var bodyText = new Array();
  247. for(var j = 0; j < gridProperty.length; j++) {
  248. var cellval = grid.getCellProperty("body", col, gridProperty[j]);
  249. bodyText[j] = cellval;
  250. }
  251. grid.deleteContentsCol(col);
  252. nCol = grid.insertContentsCol(i);
  253. grid.setCellProperty("head", nCol, "text", headText);
  254. for(var j = 0; j < gridProperty.length; j++) {
  255. if(!utlf_isNull(bodyText[j])) {
  256. grid.setCellProperty("body", nCol, gridProperty[j], bodyText[j]);
  257. }
  258. }
  259. }
  260. grid.setFormatColProperty(nCol, "size", sizearr[i]);
  261. grid.setFormatColProperty(nCol, "band", "body");
  262. }
  263. if(!utlf_isNull(nFrozenCols)) {
  264. for(var i = 0; i < oGridDataSet.colcount; i++) {
  265. if(i <= nFrozenCols)
  266. grid.setFormatColProperty(i, "band", "left");
  267. else
  268. break;
  269. }
  270. }
  271. //} finally {
  272. grid.enableevent = true;
  273. grid.enableredraw = true;
  274. //}
  275. }
  276. function fgetWorkDupList() {
  277. var sWorkCd = ds_cond.getColumn(0, "workcd");
  278. var sWorkType = ds_cond.getColumn(0, "worktype");
  279. var sOrdDeptCd = ds_cond.getColumn(0, "orddeptcd");
  280. if(utlf_isNull(sWorkCd) || sWorkCd == "-"){
  281. sysf_messageBox("선택된 당직이 없습니다.", "E999");
  282. this.close();
  283. return;
  284. }
  285. if(sWorkType == "D" && (utlf_isNull(sOrdDeptCd) || sOrdDeptCd == "-")){
  286. sysf_messageBox("선택된 진료과가 없습니다.", "E999");
  287. this.close();
  288. return;
  289. }
  290. var oParam = {};
  291. oParam.id = "TRMMI00911";
  292. oParam.service = "prcpinfoapp.PrcpInfoEtcMngt";
  293. oParam.method = "reqGetWorkDupList";
  294. oParam.inds = "req=ds_cond";
  295. oParam.outds = "ds_workduplist=result";
  296. oParam.async = false;
  297. oParam.callback = "cf_TRMMI00911";
  298. tranf_submit(oParam);
  299. if( arErrorCode.pop("TRMMI00911") < 0 ){
  300. sysf_messageBox("당직 중복 조회를 실패하였습니다.", "E999");
  301. return false;
  302. }
  303. }
  304. function cf_TRMMI00911(sSvcId, nErrorCode, sErrorMsg) {
  305. arErrorCode.push(sSvcId, nErrorCode);
  306. }
  307. function btn_excel_onclick(obj:Button, e:ClickEventInfo)
  308. {
  309. grdf_exportExcel(grd_workduplist, "당직 중복 조회", "당직중복", false, null, "user", true);
  310. }
  311. function SMMMI00920_onmouseenter(obj:Form, e:MouseEventInfo)
  312. {
  313. }
  314. ]]></Script>
  315. </Form>
  316. </FDL>