SMPMI03600_VIP재원환자조회.xfdl 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMPMI03600" position="absolute 0 0 1196 787" titletext="VIP재원환자조회" onload="SMPMI03600_onload">
  5. <Layouts>
  6. <Layout>
  7. <Static id="caption6" text="VIP재원환자조회" class="tit_1" position="absolute 0 0 160 25"/>
  8. <Div id="div" taborder="1" position="absolute 0 25 1194 60" class="div_SA" anchor="left top right">
  9. <Layouts>
  10. <Layout width="1194" height="35">
  11. <Edit id="ipt_text" taborder="1" class="input_search" visible="false" position="absolute 435 8 550 27" anchor="default" onkeydown="div_ipt_text_onkeydown"/>
  12. <Button id="button1" taborder="2" text="조회" class="btn1" position="absolute 1123 6 1179 28" anchor="top right" onclick="div_button1_onclick"/>
  13. <Shape id="line2" linetype="vertical" class="line_4" position="absolute 1105 6 1111 28" anchor="top right"/>
  14. <Static id="caption17" text="조회일자 :" class="search_name" position="absolute 5 9 91 26" anchor="default"/>
  15. <Static id="caption3" text="조회항목 :" class="search_name" position="absolute 215 9 301 26" anchor="default"/>
  16. <Combo id="cmb_srchcond" taborder="3" codecolumn="codecolumn" datacolumn="datacolumn" class="combo_search" position="absolute 302 8 417 27" anchor="default" onitemchanged="div_cmb_srchcond_onitemchanged">
  17. <Dataset id="innerdataset">
  18. <ColumnInfo>
  19. <Column id="codecolumn"/>
  20. <Column id="datacolumn"/>
  21. </ColumnInfo>
  22. <Rows>
  23. <Row>
  24. <Col id="codecolumn">1</Col>
  25. <Col id="datacolumn">전체</Col>
  26. </Row>
  27. <Row>
  28. <Col id="codecolumn">2</Col>
  29. <Col id="datacolumn">환자번호</Col>
  30. </Row>
  31. <Row>
  32. <Col id="codecolumn">4</Col>
  33. <Col id="datacolumn">진료과</Col>
  34. </Row>
  35. <Row>
  36. <Col id="codecolumn">5</Col>
  37. <Col id="datacolumn">병동</Col>
  38. </Row>
  39. </Rows>
  40. </Dataset>
  41. </Combo>
  42. <Calendar id="ipt_infromdd" taborder="4" class="input_search" position="absolute 87 8 187 27" anchor="default" autoselect="true" autoskip="true" dateformat="yyyy-MM-dd" value="null"/>
  43. <Combo id="cmb_sex" taborder="5" codecolumn="codecolumn" datacolumn="datacolumn" class="combo_search" visible="false" position="absolute 435 8 550 27" anchor="default">
  44. <Dataset id="innerdataset">
  45. <ColumnInfo>
  46. <Column id="codecolumn"/>
  47. <Column id="datacolumn"/>
  48. </ColumnInfo>
  49. <Rows>
  50. <Row>
  51. <Col id="codecolumn">M</Col>
  52. <Col id="datacolumn">남</Col>
  53. </Row>
  54. <Row>
  55. <Col id="codecolumn">F</Col>
  56. <Col id="datacolumn">여</Col>
  57. </Row>
  58. </Rows>
  59. </Dataset>
  60. </Combo>
  61. <Combo id="cmb_orddeptcd" taborder="6" innerdataset="@ds_hidden_init_orddeptcd" codecolumn="cd" datacolumn="nm" class="combo_search" visible="false" position="absolute 435 8 550 27" anchor="default"/>
  62. <Combo id="cmb_wardcd" taborder="7" innerdataset="ds_hidden_init_wardcd" codecolumn="cd" datacolumn="nm" class="combo_search" visible="false" position="absolute 435 8 550 27" anchor="default"/>
  63. <Combo id="cmb_disccd" taborder="8" innerdataset="@ds_hidden_init_disccd" codecolumn="cd" datacolumn="nm" class="combo_search" visible="false" position="absolute 435 8 550 27" anchor="default"/>
  64. <Edit id="ipt_pid" taborder="9" class="input_default" position="absolute 826 8 903 27" anchor="default" onkeydown="div_ipt_pid_onkeydown"/>
  65. <Edit id="opt_hngnm" taborder="10" readonly="true" position="absolute 905 8 970 27" anchor="default" style="background:URL('theme://images/bg_edit_D.png') stretch 5,5;"/>
  66. <Button id="btn_pid" taborder="11" class="icon_search" position="absolute 1077 9 1093 25" anchor="default" onclick="div_btn_pid_onclick"/>
  67. <Static id="caption1" text="등록번호 :" class="search_name" position="absolute 749 9 835 26" anchor="default"/>
  68. <Edit id="opt_rrgstno1" taborder="12" readonly="true" position="absolute 972 8 1018 27" anchor="default" style="background:URL('theme://images/bg_edit_D.png') stretch 5,5;"/>
  69. <Edit id="opt_rrgstno2" taborder="13" readonly="true" position="absolute 1020 8 1072 27" anchor="default" style="background:URL('theme://images/bg_edit_D.png') stretch 5,5;"/>
  70. <CheckBox id="checkbox1" taborder="14" position="absolute 570 10 638 25" anchor="default" falsevalue="N" truevalue="Y" text="응급제외"/>
  71. <CheckBox id="checkbox2" taborder="15" position="absolute 645 10 741 25" anchor="default" falsevalue="N" truevalue="Y" text="당일입원 제외"/>
  72. </Layout>
  73. </Layouts>
  74. </Div>
  75. <Static id="caption2" text="VIP재원환자내역" class="tit_2" position="absolute 0 67 124 83"/>
  76. <Shape id="line1" linetype="horizontal" class="line_1" position="absolute 0 83 1194 89" style="strokepen:3 solid #33bbbbff;" anchor="left top right"/>
  77. <Button id="button3" taborder="2" text="엑셀저장" class="btn7" position="absolute 1119 64 1194 83" onclick="button3_onclick" anchor="top right"/>
  78. <Grid id="grd_vipinpatspec" class="datagrid2" taborder="3" binddataset="ds_main_vipinpatlist" useinputpanel="false" position="absolute 0 88 1194 757" anchor="all">
  79. <Formats>
  80. <Format id="default">
  81. <Columns>
  82. <Column size="25" band="left"/>
  83. <Column size="69"/>
  84. <Column size="80"/>
  85. <Column size="78"/>
  86. <Column size="80"/>
  87. <Column size="68"/>
  88. <Column size="35"/>
  89. <Column size="35"/>
  90. <Column size="100"/>
  91. <Column size="66"/>
  92. <Column size="71"/>
  93. <Column size="242"/>
  94. <Column size="259"/>
  95. <Column size="57"/>
  96. <Column size="66"/>
  97. </Columns>
  98. <Rows>
  99. <Row size="30" band="head"/>
  100. <Row size="24"/>
  101. </Rows>
  102. <Band id="head">
  103. <Cell/>
  104. <Cell col="1" text="환자번호"/>
  105. <Cell col="2" text="입원일자"/>
  106. <Cell col="3" text="환자성명"/>
  107. <Cell col="4" text="사생활보호"/>
  108. <Cell col="5" text="동년도입원&#10;횟수(전체)"/>
  109. <Cell col="6" text="성별"/>
  110. <Cell col="7" text="나이"/>
  111. <Cell col="8" text="진료과"/>
  112. <Cell col="9" text="담당교수"/>
  113. <Cell col="10" text="병실"/>
  114. <Cell col="11" text="상 병 명"/>
  115. <Cell col="12" text="VIP내용"/>
  116. <Cell col="13" text="계정"/>
  117. <Cell col="14" text="종교"/>
  118. </Band>
  119. <Band id="body">
  120. <Cell celltype="head" expr="expr:currow + 1"/>
  121. <Cell col="1" style="align:center middle;" text="bind:pid" enable="false"/>
  122. <Cell col="2" displaytype="date" style="align:center middle;" text="bind:indd" mask="yyyy-MM-dd" calendardisplaynulltype="none" enable="false"/>
  123. <Cell col="3" style="align:center middle;" text="bind:hngnm" enable="false"/>
  124. <Cell col="4" style="align:center middle;color:red;color2:red;" text="bind:privacyyn" enable="false"/>
  125. <Cell col="5" style="align:center middle;" text="bind:incnt" enable="false"/>
  126. <Cell col="6" style="align:center middle;" text="bind:sex" enable="false"/>
  127. <Cell col="7" style="align:center middle;" text="bind:age" enable="false"/>
  128. <Cell col="8" style="align:left middle;" text="bind:depthngnm" enable="false"/>
  129. <Cell col="9" style="align:left middle;" text="bind:orddrnm" enable="false"/>
  130. <Cell col="10" style="align:left middle;" text="bind:roomcd" enable="false"/>
  131. <Cell col="11" style="align:left middle;" text="bind:diagnosisnm" enable="false"/>
  132. <Cell col="12" displaytype="text" edittype="text" style="align:left middle;" class="gridinput" text="bind:vipcnts"/>
  133. <Cell col="13" style="align:left middle;" text="bind:disccd" enable="false"/>
  134. <Cell col="14" text="bind:religncd"/>
  135. </Band>
  136. </Format>
  137. </Formats>
  138. </Grid>
  139. <Button id="button4" taborder="4" text="출력" class="btn6" position="absolute 1063 64 1114 83" onclick="button4_onclick" anchor="top right"/>
  140. <Button id="button5" taborder="5" text="미리보기" class="btn2" position="absolute 994 64 1058 83" onclick="button5_onclick" anchor="top right"/>
  141. <Div id="grp_report" taborder="6" visible="false" position="absolute 865 66 930 81"/>
  142. <Button id="button2" taborder="7" text="초기화" class="btn4" position="absolute 1126 761 1194 783" onclick="button2_onclick" anchor="right bottom"/>
  143. <Shape id="line32" class="line_6" position="absolute 0 756 1195 762" anchor="left right bottom"/>
  144. <Button id="button6" taborder="8" text="저장" class="btn4" position="absolute 1068 761 1124 783" onclick="button6_onclick" anchor="right bottom"/>
  145. </Layout>
  146. </Layouts>
  147. <Objects>
  148. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  149. <ColumnInfo>
  150. <Column id="srchcond" type="STRING" size="256"/>
  151. <Column id="fromdd" type="STRING" size="256"/>
  152. <Column id="todd" type="STRING" size="256"/>
  153. <Column id="data1" type="STRING" size="256"/>
  154. <Column id="sess_posinstcd" type="STRING" size="256"/>
  155. <Column id="erexptyn" type="STRING" size="256"/>
  156. <Column id="tdayinexptyn" type="STRING" size="256"/>
  157. <Column id="data2" type="STRING" size="256"/>
  158. </ColumnInfo>
  159. <Rows>
  160. <Row>
  161. <Col id="srchcond"/>
  162. <Col id="fromdd"/>
  163. <Col id="todd"/>
  164. <Col id="data1"/>
  165. <Col id="sess_posinstcd"/>
  166. <Col id="erexptyn"/>
  167. <Col id="tdayinexptyn"/>
  168. <Col id="data2"/>
  169. </Row>
  170. </Rows>
  171. </Dataset>
  172. <Dataset id="ds_init_P0149list" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  173. <Dataset id="ds_init_P0016list" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  174. <Dataset id="ds_hidden_init_disccd" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  175. <ColumnInfo>
  176. <Column id="cd" type="STRING" size="256"/>
  177. <Column id="nm" type="STRING" size="256"/>
  178. </ColumnInfo>
  179. </Dataset>
  180. <Dataset id="ds_hidden_init_insukind" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  181. <ColumnInfo>
  182. <Column id="cd" type="STRING" size="256"/>
  183. <Column id="nm" type="STRING" size="256"/>
  184. </ColumnInfo>
  185. </Dataset>
  186. <Dataset id="ds_hidden_init_suppkind" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  187. <ColumnInfo>
  188. <Column id="cd" type="STRING" size="256"/>
  189. <Column id="nm" type="STRING" size="256"/>
  190. <Column id="up" type="STRING" size="256"/>
  191. <Column id="io" type="STRING" size="256"/>
  192. </ColumnInfo>
  193. </Dataset>
  194. <Dataset id="ds_hidden_init_orddeptcd" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  195. <ColumnInfo>
  196. <Column id="cd" type="STRING" size="256"/>
  197. <Column id="nm" type="STRING" size="256"/>
  198. </ColumnInfo>
  199. </Dataset>
  200. <Dataset id="ds_hidden_init_orddrid" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  201. <ColumnInfo>
  202. <Column id="cd" type="STRING" size="256"/>
  203. <Column id="nm" type="STRING" size="256"/>
  204. <Column id="dp" type="STRING" size="256"/>
  205. </ColumnInfo>
  206. </Dataset>
  207. <Dataset id="ds_hidden_init_flag" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  208. <ColumnInfo>
  209. <Column id="prestdd" type="STRING" size="256"/>
  210. <Column id="mskindflag" type="STRING" size="256"/>
  211. </ColumnInfo>
  212. </Dataset>
  213. <Dataset id="ds_source" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  214. <ColumnInfo>
  215. <Column id="srchcond" type="STRING" size="256"/>
  216. <Column id="pid" type="STRING" size="256"/>
  217. <Column id="hngnm" type="STRING" size="256"/>
  218. <Column id="rrgstno1" type="STRING" size="256"/>
  219. <Column id="rrgstno2" type="STRING" size="256"/>
  220. </ColumnInfo>
  221. <Rows>
  222. <Row>
  223. <Col id="srchcond"/>
  224. <Col id="pid"/>
  225. <Col id="hngnm"/>
  226. <Col id="rrgstno1"/>
  227. <Col id="rrgstno2"/>
  228. </Row>
  229. </Rows>
  230. </Dataset>
  231. <Dataset id="ds_main_vipinpatlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  232. <ColumnInfo>
  233. <Column id="pid" type="STRING" size="256" sumtext="환자번호"/>
  234. <Column id="indd" type="STRING" size="256" sumtext="입원일자"/>
  235. <Column id="hngnm" type="STRING" size="256" sumtext="환자성명"/>
  236. <Column id="privacyyn" type="STRING" size="256" sumtext="사생활보호"/>
  237. <Column id="incnt" type="STRING" size="256" sumtext="입원횟수"/>
  238. <Column id="sex" type="STRING" size="256" sumtext="성별"/>
  239. <Column id="age" type="STRING" size="256" sumtext="나이"/>
  240. <Column id="depthngnm" type="STRING" size="256" sumtext="진료과명"/>
  241. <Column id="orddrnm" type="STRING" size="256" sumtext="담당교수명"/>
  242. <Column id="roomcd" type="STRING" size="256" sumtext="병실"/>
  243. <Column id="diagnosisnm" type="STRING" size="256" sumtext="상병명"/>
  244. <Column id="vipcnts" type="STRING" size="256" sumtext="VIP내용"/>
  245. <Column id="disccd" type="STRING" size="256" sumtext="할인계정"/>
  246. <Column id="religncd" type="STRING" size="256" sumtext="종교"/>
  247. </ColumnInfo>
  248. </Dataset>
  249. <Dataset id="ds_hidden_printtype" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
  250. </Objects>
  251. <Bind>
  252. <BindItem id="item0" compid="div.ipt_infromdd" propid="value" datasetid="ds_send" columnid="fromdd"/>
  253. <BindItem id="item1" compid="div.cmb_srchcond" propid="value" datasetid="ds_send" columnid="srchcond"/>
  254. <BindItem id="item2" compid="div.ipt_text" propid="value" datasetid="ds_send" columnid=""/>
  255. <BindItem id="item3" compid="div.cmb_sex" propid="value" datasetid="ds_send" columnid=""/>
  256. <BindItem id="item4" compid="div.cmb_orddeptcd" propid="value" datasetid="ds_send" columnid=""/>
  257. <BindItem id="item5" compid="div.cmb_wardcd" propid="value" datasetid="ds_send" columnid=""/>
  258. <BindItem id="item6" compid="div.cmb_disccd" propid="value" datasetid="ds_send" columnid=""/>
  259. <BindItem id="item7" compid="div.checkbox2" propid="value" datasetid="ds_send" columnid="tdayinexptyn"/>
  260. <BindItem id="item8" compid="div.checkbox1" propid="value" datasetid="ds_send" columnid="erexptyn"/>
  261. <BindItem id="item9" compid="div.opt_rrgstno2" propid="value" datasetid="ds_patinfolist" columnid=""/>
  262. <BindItem id="item10" compid="div.opt_rrgstno1" propid="value" datasetid="ds_patinfolist" columnid=""/>
  263. <BindItem id="item11" compid="div.opt_hngnm" propid="value" datasetid="ds_patinfolist" columnid=""/>
  264. <BindItem id="item12" compid="div.ipt_pid" propid="value" datasetid="ds_patinfolist" columnid="pid"/>
  265. </Bind>
  266. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  267. * System Name :
  268. * Job Name :
  269. * Creator :
  270. * Make Date : 2016-05-24
  271. * Description :
  272. *---------------------------------------------------------------------------------------
  273. * Modify Date Modifier Modify Description
  274. *---------------------------------------------------------------------------------------
  275. * 2016-05-24 Live Converter TF->XP
  276. *
  277. *---------------------------------------------------------------------------------------
  278. ****************************************************************************************/
  279. //=======================================================================================
  280. // Lib Include
  281. //---------------------------------------------------------------------------------------
  282. include 'com_commonxp::comm_main.xjs';
  283. var arErrorCode = new HashArray();
  284. //=======================================================================================
  285. // Local methods
  286. //---------------------------------------------------------------------------------------
  287. /**
  288. * [fSelectRefItem description]
  289. * @param {[type]} refitem [description]
  290. * @return {[type]} [description]
  291. */
  292. function fSelectRefItem(refitem) {
  293. // 1. 전체 2.환자번호 4.진료과 5.병동
  294. ds_send.setColumn(0, "data1", "");
  295. if (refitem == '1') {
  296. div.caption1.visible = false;
  297. div.ipt_pid.visible = false;
  298. div.opt_hngnm.visible = false;
  299. div.opt_rrgstno1.visible = false;
  300. div.opt_rrgstno2.visible = false;
  301. div.btn_pid.visible = false;
  302. div.ipt_text.visible = false;
  303. div.cmb_orddeptcd.visible = false;
  304. div.cmb_wardcd.visible = false;
  305. div.cmb_disccd.visible = false;
  306. div.cmb_sex.visible = false;
  307. }
  308. else if (refitem == '2') {
  309. div.caption1.visible = true;
  310. div.ipt_pid.visible = true;
  311. div.opt_hngnm.visible = true;
  312. div.opt_rrgstno1.visible = true;
  313. div.opt_rrgstno2.visible = true;
  314. div.btn_pid.visible = true;
  315. div.ipt_text.visible = true;
  316. div.cmb_orddeptcd.visible = false;
  317. div.cmb_wardcd.visible = false;
  318. div.cmb_disccd.visible = false;
  319. div.cmb_sex.visible = false;
  320. model.setFocus("ipt_text");
  321. }
  322. else if (refitem == '4') {
  323. div.caption1.visible = false;
  324. div.ipt_pid.visible = false;
  325. div.opt_hngnm.visible = false;
  326. div.opt_rrgstno1.visible = false;
  327. div.opt_rrgstno2.visible = false;
  328. div.btn_pid.visible = false;
  329. div.ipt_text.visible = false;
  330. div.cmb_orddeptcd.visible = true;
  331. div.cmb_wardcd.visible = false;
  332. div.cmb_disccd.visible = false;
  333. div.cmb_sex.visible = false;
  334. }
  335. else if (refitem == '5') {
  336. div.caption1.visible = false;
  337. div.ipt_pid.visible = false;
  338. div.opt_hngnm.visible = false;
  339. div.opt_rrgstno1.visible = false;
  340. div.opt_rrgstno2.visible = false;
  341. div.btn_pid.visible = false;
  342. div.ipt_text.visible = false;
  343. div.cmb_orddeptcd.visible = false;
  344. div.cmb_wardcd.visible = true;
  345. div.cmb_disccd.visible = false;
  346. div.cmb_sex.visible = false;
  347. }
  348. }
  349. /**
  350. * [fInitialize description]
  351. * @return {[type]} [description]
  352. */
  353. function fInitialize() {
  354. // model.resetInstanceNode("/root/main/vipinptlist/vipinddschspec");
  355. ds_send.clearData();
  356. ds_send.addRow();
  357. ds_main_vipinpatlist.clearData();
  358. ds_send.setColumn(0, "fromdd", utlf_getCurrentDate());
  359. ds_send.setColumn(0, "todd", utlf_getCurrentDate());
  360. ds_send.setColumn(0, "srchcond", "1");
  361. fSelectRefItem("1")
  362. }
  363. /**
  364. * [fPrint description]
  365. * @param {[type]} pCond [description]
  366. * @return {[type]} [description]
  367. */
  368. function fPrint(pCond) {
  369. var sPrintYN = "print=";
  370. var sAutoCloseYN = "false";
  371. var sViewYN = "";
  372. if (pCond == "PREVIEW") {
  373. sPrintYN += "0";
  374. // sAutoCloseYN = "false";
  375. sViewYN = "";
  376. }
  377. if (pCond == "PRINT") {
  378. sPrintYN += "1";
  379. sAutoCloseYN = "false";
  380. // sViewYN = "grp_report";
  381. }
  382. sPrintYN += ';'
  383. var iCount = ds_main_vipinpatlist.rowcount;
  384. if (iCount > 0) {
  385. var sPrintFromdd = String(ds_send.getColumn(0, "fromdd"));
  386. var sPrinttodd = ds_send.getColumn(0, "todd");
  387. sPrintFromdd = sPrintFromdd.substr(0, 4) + "-" + sPrintFromdd.substr(4, 2) + "-" + sPrintFromdd.substr(6, 4);
  388. dsf_makeValue(ds_hidden_printtype, "printkind", 'string', "VIP재원");
  389. dsf_makeValue(ds_hidden_printtype, "printfromdd", 'string', sPrintFromdd);
  390. dsf_makeValue(ds_hidden_printtype, "printtodd", 'string', sPrinttodd);
  391. var objDOM = rptf_createDOM(); // DOM 객체 설정
  392. rptf_setNodeListToDOM(objDOM, "root/main/vipinpatlist/vipinpatspec" , ds_main_vipinpatlist);
  393. rptf_setNodeListToDOM(objDOM, "root/hidden/printtype" , ds_hidden_printtype);
  394. var option = "open=1;save=1;directprint=1;printdialog=0;zoom=0";
  395. option += sPrintYN;
  396. rptf_exeReportPreview30(["RPPMI03601"],[{ xml_data_XML1 : objDOM.documentElement.source }], option);
  397. }
  398. else {
  399. sysf_messageBox("출력할 내용이 없습니다!!", "I");
  400. }
  401. }
  402. /**
  403. * submit 후 호출 될 공통 콜백
  404. * @param {[type]} sSvcId [description]
  405. * @param {[type]} nErrorCode [description]
  406. * @param {[type]} sErrorMsg [description]
  407. * @return {Function} [description]
  408. */
  409. function callback(sSvcId, nErrorCode, sErrorMsg){
  410. arErrorCode.push(sSvcId, nErrorCode);
  411. }
  412. //=======================================================================================
  413. // Events
  414. //---------------------------------------------------------------------------------------
  415. /**
  416. * onload 이벤트 발생 시 호출
  417. * @param {[type]} obj:Form [description]
  418. * @param {[type]} e:LoadEventInfo [description]
  419. */
  420. function SMPMI03600_onload(obj: Form, e: LoadEventInfo) {
  421. frmf_initForm(obj);
  422. appf_getCodeList([
  423. { dsNm: 'ds_init_P0149list', cdGrpId: 'P0149' },
  424. { dsNm: 'ds_init_P0016list', cdGrpId: 'P0016' }
  425. ]);
  426. // dsf_createDsRow('ds_send_data4', [
  427. // { col: 'sess_posinstcd', type: 'string', size: 256, val: ds_hidden_session.getColumn(0, 'sess_posinstcd') },
  428. // { col: 'ioflag', type: 'string', size: 256, val: '' },
  429. // { col: 'dridsorttype', type: 'string', size: 256, val: '' }
  430. // ], false);
  431. var oParam = {};
  432. oParam.id = "TRPMI00106";
  433. oParam.service = "pamcomnapp.PamComn";
  434. oParam.method = "reqGetComCD";
  435. oParam.inds = "req=ds_send";
  436. oParam.outds = "ds_hidden_init_disccd=disccd ds_hidden_init_insukind=insukind ds_hidden_init_suppkind=suppkind "
  437. + "ds_hidden_init_orddeptcd=orddeptcd ds_hidden_init_orddrid=orddrid ds_hidden_init_flag=flag";
  438. oParam.async = false;
  439. tranf_submit(oParam);
  440. ds_send.setColumn(0, "fromdd", utlf_getCurrentDate());
  441. ds_send.setColumn(0, "todd", '99991231');
  442. ds_send.setColumn(0, "srchcond", "1");
  443. div.caption1.visible = false;
  444. div.ipt_pid.visible = false;
  445. div.opt_hngnm.visible = false;
  446. div.opt_rrgstno1.visible = false;
  447. div.opt_rrgstno2.visible = false;
  448. div.btn_pid.visible = false;
  449. }
  450. /**
  451. * [div_cmb_srchcond_onitemchanged description]
  452. * @param {[type]} obj: Combo [description]
  453. * @param {[type]} e: ItemChangeEventInfo [description]
  454. * @return {[type]} [description]
  455. */
  456. function div_cmb_srchcond_onitemchanged(obj: Combo, e: ItemChangeEventInfo) {
  457. fSelectRefItem(ds_send.getColumn(0, 'srchcond'));
  458. }
  459. /**
  460. * ipt_text 키보드 입력 이벤트
  461. * @param {[type]} obj: Edit [description]
  462. * @param {[type]} e: KeyEventInfo [description]
  463. * @return {[type]} [description]
  464. */
  465. function div_ipt_text_onkeydown(obj: Edit, e: KeyEventInfo) {
  466. if (e.keycode == 13) {
  467. obj.updateToDataset();
  468. div.button1.click();
  469. }
  470. }
  471. /**
  472. * 등록번호 ipt_pid 키보드 입력 이벤트
  473. * @param {[type]} obj: Edit [description]
  474. * @param {[type]} e: KeyEventInfo [description]
  475. * @return {[type]} [description]
  476. */
  477. function div_ipt_pid_onkeydown(obj: Edit, e: KeyEventInfo) {
  478. if (e.keycode == 8) {
  479. ds_send.clearData();
  480. ds_send.addRow();
  481. fInitialize();
  482. }
  483. if (e.keycode == 13) {
  484. obj.updateToDataset();
  485. vcheck_pid = utlf_transNullToEmpty(ds_patinfolist.getColumn(0, 'pid'));
  486. //환자번호 null체크
  487. if (vcheck_pid == "" || vcheck_pid == " " || vcheck_pid == "-") {
  488. sysf_messageBox("환자등록번호가 입력되지", "E007");
  489. return;
  490. }
  491. //환자번호 조건으로 인적정보 조회
  492. ds_source.setColumn(0, "srchcond", "1");
  493. ds_source.setColumn(0, "pid", vcheck_pid);
  494. //환자기본정보 node clear
  495. ds_patinfolist.clearData();
  496. dsf_createDsRow('ds_req', [
  497. { col: 'srchcond', type: 'string', size: 256, val: '' },
  498. { col: 'checkfnexam', type: 'string', size: 256, val: '' },
  499. { col: 'pid', type: 'string', size: 256, val: '' },
  500. { col: 'hngnm', type: 'string', size: 256, val: '' },
  501. { col: 'rrgstno1', type: 'string', size: 256, val: '' },
  502. { col: 'rrgstno2', type: 'string', size: 256, val: '' },
  503. { col: 'acptdd', type: 'string', size: 256, val: '' },
  504. { col: 'instcd', type: 'string', size: 256, val: '' },
  505. { col: 'insukind', type: 'string', size: 256, val: '' },
  506. { col: 'inhospyn', type: 'string', size: 256, val: '' }
  507. ], false);
  508. ds_req.copyRow(0, ds_source, 0);
  509. dsf_setTypeFormat(ds_req, "srchcond:INT^checkfnexam:INT");
  510. var oParam = {};
  511. oParam.id = "TRPMC02500";
  512. oParam.service = "patinfomngtapp.PatBaseInfo";
  513. oParam.method = "reqGetPatInfo";
  514. oParam.inds = "req=ds_req";
  515. oParam.outds = "ds_patinfolist=patinfolist";
  516. oParam.async = false;
  517. oParam.callback = "callback";
  518. tranf_submit(oParam);
  519. //환자등록번호 체크
  520. if (arErrorCode.pop("TRPMC02500") > -1) {
  521. var vcheck_pid = utlf_transNullToEmpty(ds_patinfolist.getColumn(0, "pid"));
  522. if (vcheck_pid == "" || vcheck_pid == " " || vcheck_pid == "-") {
  523. //조회내역 체크
  524. sysf_messageBox("존재하지 않는 등록번호", "E008"); //E008=입니다
  525. fInitialize();
  526. return;
  527. }
  528. //조회되는 항목들 clear
  529. // model.resetInstanceNode("/root/main/baseinfo");
  530. ds_send.setColumn(0, "data1", ds_patinfolist.getColumn(0, "pid"));
  531. div.button1.click();
  532. }
  533. else {
  534. sysf_messageBox("존재하지 않는 등록번호", "E008"); //E008=입니다
  535. div.ipt_pid.setFocus();
  536. return;
  537. }
  538. }
  539. }
  540. /**
  541. * 등록번호 검색 아이콘 클릭 이벤트
  542. * @param {[type]} obj: Button [description]
  543. * @param {[type]} e: ClickEventInfo [description]
  544. * @return {[type]} [description]
  545. */
  546. function div_btn_pid_onclick(obj: Button, e: ClickEventInfo) {
  547. frmf_modal("SPPMC02500", "SPPMC02500", { arg_ds_sed: ds_send }, "", "", "", "", "", "", "", "", "", "M");
  548. }
  549. /**
  550. * 조회 버튼 클릭 이벤트
  551. * @param {[type]} obj: Button [description]
  552. * @param {[type]} e: ClickEventInfo [description]
  553. * @return {[type]} [description]
  554. */
  555. function div_button1_onclick(obj: Button, e: ClickEventInfo) {
  556. var sCond = ds_send.getColumn(0, "indschacptstat");
  557. ds_main_vipinpatlist.clearData();
  558. dsf_createDsRow('ds_req', [
  559. { col: 'srchcond', type: 'string', size: 256, val: '' },
  560. { col: 'data1', type: 'string', size: 256, val: '' },
  561. { col: 'fromdd', type: 'string', size: 256, val: '' },
  562. { col: 'todd', type: 'string', size: 256, val: '' },
  563. { col: 'erexptyn', type: 'string', size: 256, val: '' },
  564. { col: 'tdayinexptyn', type: 'string', size: 256, val: '' }
  565. ], false);
  566. ds_req.copyRow(0, ds_send, 0);
  567. var oParam = {};
  568. oParam.id = "TRPMI03601";
  569. oParam.service = "ipatmngtapp.IPatRef";
  570. oParam.method = "reqGetVipInPatRef";
  571. oParam.inds = "req=ds_req";
  572. oParam.outds = "ds_main_vipinpatlist=vipinpatspec";
  573. oParam.async = false;
  574. if (sCond == "2" || sCond == "3" || sCond == "7") {
  575. var sText = ds_send.getColumn(0, "data1");
  576. if (!utlf_isNull(sText)) {
  577. tranf_submit(oParam);
  578. if (ds_main_vipinpatlist.rowcount == 0) {
  579. sysf_messageBox("조회 결과가 없습니다.", "I");
  580. }
  581. }
  582. else {
  583. sysf_messageBox("검색할 단어를 입력하십시오!", "I");
  584. div.ipt_text.setFocus();
  585. }
  586. }
  587. else {
  588. tranf_submit(oParam);
  589. if (ds_main_vipinpatlist.rowcount == 0) {
  590. sysf_messageBox("조회 결과가 없습니다.", "I");
  591. }
  592. }
  593. }
  594. /**
  595. * 미리보기 버튼 클릭 이벤트
  596. * @param {[type]} obj:Button [description]
  597. * @param {[type]} e:ClickEventInfo [description]
  598. * @return {[type]} [description]
  599. */
  600. function button5_onclick(obj: Button, e: ClickEventInfo) {
  601. fPrint("PREVIEW");
  602. }
  603. /**
  604. * 출력 버튼 클릭 이벤트
  605. * @param {[type]} obj: Button [description]
  606. * @param {[type]} e: ClickEventInfo [description]
  607. * @return {[type]} [description]
  608. */
  609. function button4_onclick(obj: Button, e: ClickEventInfo) {
  610. fPrint("PRINT");
  611. }
  612. /**
  613. * 엑셀저장 버튼 클릭 이벤트
  614. * @param {[type]} obj: Button [description]
  615. * @param {[type]} e: ClickEventInfo [description]
  616. * @return {[type]} [description]
  617. */
  618. function button3_onclick(obj: Button, e: ClickEventInfo) {
  619. grdf_exportExcel(grd_vipinpatspec, "", "SheetName");
  620. }
  621. /**
  622. * 저장 버튼 클릭 이벤트
  623. * @param {[type]} obj: Button [description]
  624. * @param {[type]} e: ClickEventInfo [description]
  625. * @return {[type]} [description]
  626. */
  627. function button6_onclick(obj: Button, e: ClickEventInfo) {
  628. dsf_createDs('ds_req');
  629. var updated = grdf_getGridUpdateData(grd_vipinpatspec, "all");
  630. ds_req.setColumn(0, "data2", updated);
  631. ds_req.updateColID('vipcnts', 'disccdrem');
  632. dsf_createDs('ds_res');
  633. var oParam = {};
  634. oParam.id = "TXPMI03601";
  635. oParam.service = "ipatmngtapp.IPatRef";
  636. oParam.method = "reqSetDiscCdRem";
  637. oParam.inds = "req=ds_req";
  638. oParam.outds = "ds_res=result";
  639. oParam.async = false;
  640. oParam.callback = "callback";
  641. tranf_submit(oParam);
  642. if (arErrorCode.pop("TXPMI03601") > -1) {
  643. // 재조회
  644. div.button1.click();
  645. }
  646. }
  647. /**
  648. * 초기화 버튼 클릭 이벤트
  649. * @param {[type]} obj: Button [description]
  650. * @param {[type]} e: ClickEventInfo [description]
  651. * @return {[type]} [description]
  652. */
  653. function button2_onclick(obj: Button, e: ClickEventInfo) {
  654. fInitialize();
  655. }
  656. ]]></Script>
  657. </Form>
  658. </FDL>