SPMMR05010_NSTCONSULT대상환자.xfdl 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPMMR05010" position="absolute 0 0 1100 900" titletext="환자명단(NRS)" oninit="SPMMR05010_oninit" onload="SPMMR05010_onload">
  5. <Layouts>
  6. <Layout>
  7. <Static position="absolute 5 9 100 24" id="caption1" class="tit_2"/>
  8. <Shape position="absolute 0 40 1090 46" linetype="horizontal" id="line1" class="line_10"/>
  9. <Grid position="absolute 0 45 1088 886" id="grd_pathistlist" binddataset="ds_main_result_pathistlist" oncelldblclick="grd_pathistlist_oncelldblclick" autofittype="col">
  10. <Formats>
  11. <Format id="default">
  12. <Columns>
  13. <Column size="24"/>
  14. <Column size="60"/>
  15. <Column size="60"/>
  16. <Column size="0"/>
  17. <Column size="30"/>
  18. <Column size="30"/>
  19. <Column size="87"/>
  20. <Column size="45"/>
  21. <Column size="55"/>
  22. <Column size="50"/>
  23. <Column size="75"/>
  24. <Column size="30"/>
  25. <Column size="55"/>
  26. <Column size="55"/>
  27. <Column size="80"/>
  28. <Column size="65"/>
  29. <Column size="65"/>
  30. <Column size="40"/>
  31. <Column size="40"/>
  32. <Column size="45"/>
  33. <Column size="35"/>
  34. <Column size="35"/>
  35. <Column size="0"/>
  36. <Column size="0"/>
  37. <Column size="0"/>
  38. </Columns>
  39. <Rows>
  40. <Row size="24" band="head"/>
  41. <Row size="24"/>
  42. </Rows>
  43. <Band id="head">
  44. <Cell/>
  45. <Cell col="1" text="등록번호"/>
  46. <Cell col="2" text="환자명"/>
  47. <Cell col="3" text="상태"/>
  48. <Cell col="4" text="성별"/>
  49. <Cell col="5" text="나이"/>
  50. <Cell col="6" text="진료과"/>
  51. <Cell col="7" text="병실"/>
  52. <Cell col="8" text="담당교수"/>
  53. <Cell col="9" text="담당의"/>
  54. <Cell col="10" text="입원일"/>
  55. <Cell col="11" text="NRS"/>
  56. <Cell col="12" text="요청여부"/>
  57. <Cell col="13" text="의뢰여부"/>
  58. <Cell col="14" text="의뢰일"/>
  59. <Cell col="15" text="검색결과"/>
  60. <Cell col="16" text="이전결과"/>
  61. <Cell col="17" text="PIBW"/>
  62. <Cell col="18" text="ALB"/>
  63. <Cell col="19" text="TLC"/>
  64. <Cell col="20" text="EN"/>
  65. <Cell col="21" text="PN"/>
  66. <Cell col="22" text="indschacptstat"/>
  67. <Cell col="23" text="ordtype"/>
  68. <Cell col="24" text="cretno"/>
  69. </Band>
  70. <Band id="body">
  71. <Cell celltype="head" expr="expr:currow + 1"/>
  72. <Cell col="1" text="bind:pid"/>
  73. <Cell col="2" text="bind:hngnm"/>
  74. <Cell col="3" text="bind:indschacptstat"/>
  75. <Cell col="4" text="bind:sex"/>
  76. <Cell col="5" text="bind:age"/>
  77. <Cell col="6" style="align:left top;padding:4 2 2 2;" text="bind:orddeptnm" wordwrap="word"/>
  78. <Cell col="7" style="align:left;" text="bind:roomcd"/>
  79. <Cell col="8" text="bind:medispclnm"/>
  80. <Cell col="9" text="bind:atdoctnm"/>
  81. <Cell col="10" displaytype="date" text="bind:indd" calendardisplaynulltype="none"/>
  82. <Cell col="11" text="bind:nrsscore"/>
  83. <Cell col="12" text="bind:nstreqyn"/>
  84. <Cell col="13" text="bind:cnstyn"/>
  85. <Cell col="14" displaytype="date" text="bind:reqdd" combodisplaynulltype="none" calendardisplaynulltype="none"/>
  86. <Cell col="15" text="bind:srchrslt"/>
  87. <Cell col="16" text="bind:presrchrslt"/>
  88. <Cell col="17" text="bind:pibw"/>
  89. <Cell col="18" text="bind:alb"/>
  90. <Cell col="19" text="bind:tlc"/>
  91. <Cell col="20" text="bind:en"/>
  92. <Cell col="21" text="bind:pn"/>
  93. <Cell col="22" text="bind:indschacptstat"/>
  94. <Cell col="23" text="bind:ordtype"/>
  95. <Cell col="24" text="bind:cretno"/>
  96. </Band>
  97. </Format>
  98. </Formats>
  99. </Grid>
  100. <Shape position="absolute 0 0 1090 40" id="roundrect2" type="roundrectangle"/>
  101. <Combo position="absolute 215 10 365 29" id="cmb_deptcd" class="combo_search" innerdataset="@ds_init_orddeptlist_dept" datacolumn="depthngnm" codecolumn="deptcd"/>
  102. <Combo position="absolute 370 10 460 29" id="cmb_wardcd" class="combo_search" innerdataset="@ds_init_wardcdlsit_dept" datacolumn="depthngnm" codecolumn="deptcd"/>
  103. <Static text="검색결과" position="absolute 486 10 556 27" id="caption16" class="search_name"/>
  104. <Button position="absolute 1018 10 1083 32" id="btn_searh" class="btn2" text="요청취소" onclick="btn_searh_onclick"/>
  105. <Button position="absolute 958 10 1014 32" id="button1" class="btn2" text="요청" onclick="button1_onclick"/>
  106. <Button position="absolute 898 10 954 32" id="button2" class="btn1" text="조회" onclick="button2_onclick"/>
  107. <Radio position="absolute 13 12 105 32" id="rdo_flag" columncount="-1" innerdataset="@ds_init_flag" datacolumn="nm" codecolumn="cd" rowcount="-1" onitemchanged="rdo_flag_onitemchanged"/>
  108. <Calendar position="absolute 108 12 195 31" id="ipt_dschdd" enable="false"/>
  109. <Combo position="absolute 560 10 660 29" id="cmb_srchrslt" innerdataset="@ds_init_srchrslt_A0058" datacolumn="cdnm" codecolumn="cdid"/>
  110. <Button id="button13" taborder="1" text="엑셀" onclick="button13_onclick" class="btn7" position="absolute 830 10 886 32"/>
  111. </Layout>
  112. </Layouts>
  113. <Objects>
  114. <Dataset id="ds_main_result_pathistlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  115. <Dataset id="ds_main_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  116. <ColumnInfo>
  117. <Column id="flag" type="STRING" size="256"/>
  118. <Column id="orddeptcd" type="STRING" size="256"/>
  119. <Column id="wardcd" type="STRING" size="256"/>
  120. <Column id="dschdd" type="STRING" size="256"/>
  121. <Column id="srchrslt" type="STRING" size="256"/>
  122. </ColumnInfo>
  123. <Rows>
  124. <Row>
  125. <Col id="flag"/>
  126. <Col id="orddeptcd"/>
  127. <Col id="wardcd"/>
  128. <Col id="dschdd"/>
  129. <Col id="srchrslt"/>
  130. </Row>
  131. </Rows>
  132. </Dataset>
  133. <Dataset id="ds_send_reqdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  134. <Dataset id="ds_send_savedata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  135. <Dataset id="ds_init_flag" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  136. <ColumnInfo>
  137. <Column id="cd" type="STRING" size="256"/>
  138. <Column id="nm" type="STRING" size="256"/>
  139. </ColumnInfo>
  140. <Rows>
  141. <Row>
  142. <Col id="cd">A</Col>
  143. <Col id="nm">재원</Col>
  144. </Row>
  145. <Row>
  146. <Col id="cd">D</Col>
  147. <Col id="nm">퇴원</Col>
  148. </Row>
  149. </Rows>
  150. </Dataset>
  151. <Dataset id="ds_init_srchrslt" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  152. <Dataset id="ds_init_wardcdlsit_dept" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  153. <Dataset id="ds_init_orddeptlist_dept" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  154. <Dataset id="ds_init_srchrslt_A0058" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  155. </Objects>
  156. <Bind>
  157. <BindItem id="item0" compid="rdo_flag" propid="value" datasetid="ds_main_cond" columnid="flag"/>
  158. <BindItem id="item1" compid="ipt_dschdd" propid="value" datasetid="ds_main_cond" columnid="dschdd"/>
  159. <BindItem id="item2" compid="cmb_deptcd" propid="value" datasetid="ds_main_cond" columnid="orddeptcd"/>
  160. <BindItem id="item3" compid="cmb_wardcd" propid="value" datasetid="ds_main_cond" columnid="wardcd"/>
  161. <BindItem id="item4" compid="cmb_srchrslt" propid="value" datasetid="ds_main_cond" columnid="srchrslt"/>
  162. </Bind>
  163. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  164. * System Name :
  165. * Job Name :
  166. * Creator :
  167. * Make Date : 2015-11-13
  168. * Description :
  169. *---------------------------------------------------------------------------------------
  170. * Modify Date Modifier Modify Description
  171. *---------------------------------------------------------------------------------------
  172. * 2015-11-13 Live Converter TF->XP
  173. *
  174. *---------------------------------------------------------------------------------------
  175. ****************************************************************************************/
  176. include "com_commonxp::comm_main.xjs";
  177. var arErrorCode = new HashArray();
  178. function SPMMR05010_oninit(obj:Form, e:InitEventInfo)
  179. {
  180. frmf_initForm(obj); //폼 초기화
  181. }
  182. function SPMMR05010_onload(obj:Form, e:LoadEventInfo)
  183. {
  184. fInitialize();
  185. grdf_initGrid(grd_pathistlist);
  186. }
  187. /**
  188. * @desc : 화면 초기화
  189. * @id :
  190. * @event :
  191. * @return : void
  192. * @authur : 이윤주
  193. */
  194. function fInitialize()
  195. {
  196. appf_getDeptCodeList(sysf_getUserInfo("dutplceinstcd"),"orduseyn","W","depthngnm","asc", "", "", "","ds_init_wardcdlsit_dept");// 병동정보
  197. appf_getDeptCodeList(sysf_getUserInfo("dutplceinstcd"),"orduseyn","D","depthngnm","asc", "", "", "","ds_init_orddeptlist_dept");
  198. var arrParam = [{dsNm: "ds_init_srchrslt_A0058", cdGrpId: "A0058"}]
  199. appf_getCodeList(arrParam);
  200. frmf_addComboItem("cmb_deptcd", "전체", "-");
  201. frmf_addComboItem("cmb_wardcd", "전체", "-");
  202. frmf_addComboItem("cmb_srchrslt", "전체", "-");
  203. ds_main_cond.setColumn(0, "orddeptcd","-");
  204. var jobkindcd = sysf_getUserInfo("jobkindcd");
  205. if (utlf_transNullToEmpty(jobkindcd).substr(0,2) == "03") {
  206. ds_main_cond.setColumn(0, "orddeptcd", sysf_getUserInfo("dutplcecd"));
  207. }
  208. ds_main_cond.setColumn(0, "wardcd","-");
  209. ds_main_cond.setColumn(0, "srchrslt","-");
  210. ds_main_cond.setColumn(0, "flag","A");
  211. }
  212. function grd_pathistlist_oncelldblclick(obj:Grid, e:GridClickEventInfo)
  213. {
  214. var selectedrow = ds_main_result_pathistlist.rowposition;
  215. if (selectedrow < 0) {
  216. return;
  217. }
  218. var pid = ds_main_result_pathistlist.getColumn(selectedrow, "pid");
  219. var orddd = ds_main_result_pathistlist.getColumn(selectedrow, "indd");
  220. var cretno = ds_main_result_pathistlist.getColumn(selectedrow, "cretno");
  221. var prcpgenrflag = ds_main_result_pathistlist.getColumn(selectedrow, "ordtype");
  222. if(prcpgenrflag!="E"){
  223. prcpgenrflag = "I";
  224. }
  225. var instcd = sysf_getUserInfo("dutplceinstcd");
  226. var param = prcpgenrflag + "▦" +
  227. pid + "▦" +
  228. orddd + "▦" +
  229. cretno + "▦" +
  230. instcd + "▦";
  231. //frmf_setParameter("condparam", param);
  232. //modal("SPMMO08900", 1, 0, 0, "", "", "", "left:0; right:0; width:0; height:0; sysmenu:hidden; caption:hidden; min:hidden, max:hidden;");
  233. appf_initPatientInfo(param); //상단정보 셋팅
  234. fCnstReq();
  235. }
  236. function fCnstReq() {
  237. var selectedrow = ds_main_result_pathistlist.rowposition;
  238. if (selectedrow < 0) {
  239. return;
  240. }
  241. var nurreqyn = ds_main_result_pathistlist.getColumn(selectedrow, "nurreqyn");
  242. var pid = ds_main_result_pathistlist.getColumn(selectedrow, "pid");
  243. var hngnm = ds_main_result_pathistlist.getColumn(selectedrow, "hngnm");
  244. var orddd = ds_main_result_pathistlist.getColumn(selectedrow, "indd");
  245. var cretno = ds_main_result_pathistlist.getColumn(selectedrow, "cretno");
  246. var ordtype = ds_main_result_pathistlist.getColumn(selectedrow, "ordtype");
  247. var indschacptstat = ds_main_result_pathistlist.getColumn(selectedrow, "indschacptstat");
  248. if (indschacptstat != "A") {
  249. sysf_messageBox("재원중의 환자가 아니라 요청 불가합니다","I");
  250. return;
  251. }
  252. if ( nurreqyn == "Y") {
  253. sysf_messageBox("이미 요청되었습니다","I");
  254. return;
  255. }
  256. if( "6" != sysf_messageBox(pid+" "+ hngnm+" 영양검색결과 영양불량위험군으로 \n영양집중지원대상자 입니다.\n NST로 의뢰하시기 바랍니다.(T.본원: 5206 / 칠곡: 2594)", "Q999")) {
  257. return;
  258. }
  259. dsf_makeValue(ds_send_savedata, "pid", "string", pid);
  260. dsf_makeValue(ds_send_savedata, "orddd", "string", orddd);
  261. dsf_makeValue(ds_send_savedata, "cretno", "string", cretno);
  262. dsf_makeValue(ds_send_savedata, "ordtype", "string", ordtype);
  263. dsf_makeValue(ds_send_savedata, "nurreqyn", "string", "Y");
  264. var oParam = {};
  265. oParam.id = "TXMMR05010";
  266. oParam.service = "medirecapp.ExtnMediRec";
  267. oParam.method = "reqSetNSTReq";
  268. oParam.inds = "req=ds_send_savedata";
  269. oParam.outds = "";
  270. oParam.async = false;
  271. oParam.callback = "cf_TXMMR05010";
  272. tranf_submit(oParam);
  273. if(arErrorCode.pop("TXMMR05010") > -1){
  274. ds_main_result_pathistlist.setColumn(selectedrow, "nstreqyn", "Y");
  275. }
  276. }
  277. function cf_TXMMR05010(sSvcId, nErrorCode, sErrorMsg) {
  278. arErrorCode.push(sSvcId, nErrorCode);
  279. }
  280. function btn_searh_onclick(obj:Button, e:ClickEventInfo)
  281. {
  282. fCnstCnclReq();
  283. }
  284. function fCnstCnclReq() {
  285. var selectedrow = ds_main_result_pathistlist.rowposition;
  286. if (selectedrow < 0) {
  287. return;
  288. }
  289. var nurreqyn = ds_main_result_pathistlist.getColumn(selectedrow, "nurreqyn");
  290. var pid = ds_main_result_pathistlist.getColumn(selectedrow, "pid");
  291. var hngnm = ds_main_result_pathistlist.getColumn(selectedrow, "hngnm");
  292. var orddd = ds_main_result_pathistlist.getColumn(selectedrow, "indd");
  293. var cretno = ds_main_result_pathistlist.getColumn(selectedrow, "cretno");
  294. var ordtype = ds_main_result_pathistlist.getColumn(selectedrow, "ordtype");
  295. var indschacptstat = ds_main_result_pathistlist.getColumn(selectedrow, "indschacptstat");
  296. if (indschacptstat != "A") {
  297. sysf_messageBox("재원중의 환자가 아니라 요청 취소 불가합니다","I");
  298. return;
  299. }
  300. if ( nurreqyn == "N") {
  301. sysf_messageBox("이미 요청 취소 되었습니다","I");
  302. return;
  303. }
  304. if( "6" != sysf_messageBox(pid+" "+ hngnm+" 요청 취소하시겠습니까?", "Q999")) {
  305. return;
  306. }
  307. dsf_makeValue(ds_send_savedata, "pid", "string", pid);
  308. dsf_makeValue(ds_send_savedata, "orddd", "string", orddd);
  309. dsf_makeValue(ds_send_savedata, "cretno", "string", cretno);
  310. dsf_makeValue(ds_send_savedata, "ordtype", "string", ordtype);
  311. dsf_makeValue(ds_send_savedata, "nurreqyn", "string", "N");
  312. var oParam = {};
  313. oParam.id = "TXMMR05010";
  314. oParam.service = "medirecapp.ExtnMediRec";
  315. oParam.method = "reqSetNSTReq";
  316. oParam.inds = "req=ds_send_savedata";
  317. oParam.outds = "";
  318. oParam.async = false;
  319. oParam.callback = "cf_TXMMR05010";
  320. tranf_submit(oParam);
  321. if(arErrorCode.pop("TXMMR05010") > -1){
  322. ds_main_result_pathistlist.setColumn(selectedrow, "nstreqyn", "N");
  323. }
  324. }
  325. function button1_onclick(obj:Button, e:ClickEventInfo)
  326. {
  327. fCnstReq();
  328. }
  329. function button2_onclick(obj:Button, e:ClickEventInfo)
  330. {
  331. fSearch();
  332. }
  333. function fSearch() {
  334. var oParam = {};
  335. oParam.id = "TRMMR05010";
  336. oParam.service = "medirecapp.ExtnMediRec";
  337. oParam.method = "reqGetNRSList";
  338. oParam.inds = "req=ds_main_cond";
  339. oParam.outds = "ds_main_result_pathistlist=pathistlist";
  340. oParam.async = false;
  341. tranf_submit(oParam);
  342. }
  343. function rdo_flag_onitemchanged(obj:Radio, e:ItemChangeEventInfo)
  344. {
  345. var flag = ds_main_cond.getColumn(0, "flag");
  346. ipt_dschdd.enable = false;
  347. if ( flag == "D" ) {
  348. ipt_dschdd.enable = true;
  349. }
  350. }
  351. function button13_onclick(obj:Button, e:ClickEventInfo)
  352. {
  353. grdf_exportExcel(grd_pathistlist, "환자명단(NRS)", "SheetName", false, "", "user", false);
  354. }
  355. ]]></Script>
  356. </Form>
  357. </FDL>