SPPMC02500_환자조회.xrw 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/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. <patinfo>
  11. <patinfolist/>
  12. </patinfo>
  13. </main>
  14. <send>
  15. <srchcond/>
  16. <pid/>
  17. <hngnm/>
  18. <rrgstno1/>
  19. <rrgstno2/>
  20. <acptdd/>
  21. <inhospyn/>
  22. <hiddenflag/>
  23. </send>
  24. <init>
  25. <P0350list>
  26. <P0350>
  27. <cdnm/>
  28. <cdid/>
  29. </P0350>
  30. </P0350list>
  31. <orddeptcd>
  32. <orddeptcdlist>
  33. <cd/>
  34. <nm/>
  35. </orddeptcdlist>
  36. </orddeptcd>
  37. <orddrid>
  38. <orddridlist>
  39. <cd/>
  40. <nm/>
  41. <dp/>
  42. <sp/>
  43. </orddridlist>
  44. </orddrid>
  45. </init>
  46. <hidden>
  47. <uid>
  48. <myself/>
  49. <opener/>
  50. </uid>
  51. <tmp/>
  52. </hidden>
  53. </root>
  54. </instance>
  55. <submission id="TRPAM00101" mediatype="application/x-www-form-urlencoded" method="post" replace="instance" resultref="/root/hidden/tmp"/>
  56. <submission id="TRZBC00101" mediatype="application/x-www-form-urlencoded" method="post" replace="instance"/>
  57. <submission id="TRPMC02500" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/patinfo"/>
  58. </model>
  59. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  60. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  61. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  62. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  63. <script type="javascript" src="../../../pam/pamcomnweb/js/PAM.js"/>
  64. <script type="javascript" ev:event="xforms-ready">
  65. <![CDATA[
  66. zbcfGetCodeList(new Array("P0350"), new Array("/root/init/P0350list"));
  67. //진료과코드 진료의사ID 조회
  68. pamGetDeptCDDrIDList();
  69. //플래그 초기화!
  70. opener.model.makeNode("/root/main/popupendflag");
  71. opener.model.setValue("/root/main/popupendflag", "cancel");
  72. var sp = opener.document.url.split("/");
  73. var nsp = sp[sp.length-1].split(".")[0].substr(0,10);
  74. // pamcomnweb/pam.js 추가이력 20100224 JHP SPPMC02500_환자조회 원무쪽과 원무이외의쪽 구분하는 구분 변수 var PatRefPamFlag 전역변수
  75. PatRefPamFlag = nsp.substr(0,3);
  76. if(PatRefPamFlag == "SMP" || PatRefPamFlag == "SPP"){
  77. grd_patinfo.visible = true;
  78. grd_patinfo2.visible= false;
  79. }else{
  80. grd_patinfo.visible = false;
  81. grd_patinfo2.visible= true;
  82. }
  83. if( getNodesetCount("/root/send/srchcond") > 0 ){
  84. if( model.getValue("/root/send/checkfnexam") != "1" ){
  85. //조회조건에서 '예약일시'를 제거한다.
  86. cmb_cond.choices.itemset.attribute("nodeset") = "/root/init/P0350list/P0350[cdid != '5' ]";
  87. }
  88. if( model.getValue("/root/send/srchcond") == '' || model.getValue("/root/send/srchcond") == '-' ){
  89. model.setValue("/root/send/srchcond", "4");
  90. }
  91. fChangeSearchCondition(model.getValue("/root/send/srchcond"));
  92. model.refresh();
  93. //값이 부모창에서 입력되었을 경우 조회한다.
  94. if(model.getValue("/root/send/srchcond") != '5' && fInputValueCheckXformsReady()){
  95. //if( fInputValueCheckXformsReady()){
  96. if( submit("TRPMC02500")){
  97. if(PatRefPamFlag == "SMP" || PatRefPamFlag == "SPP"){
  98. if( grd_patinfo.rows == 2 ){
  99. if( model.getValue("/root/send/autoflag").toUpperCase() == "Y" ){ //조회 내역이 1건일 경우 자동 화면 닫기
  100. model.setFocus("grd_patinfo");
  101. btn_confirm.dispatch("DOMActivate");
  102. window.close();
  103. }
  104. }
  105. if( grd_patinfo.rows > 1 ){
  106. model.setFocus("grd_patinfo");
  107. }else{
  108. if( model.getValue("/root/send/autoflag").toUpperCase() == "NON" ){ //조회 내역이 없을 경우 자동 화면 닫기
  109. //model.setFocus("grd_patinfo");
  110. btn_cancel.dispatch("DOMActivate");
  111. //window.close();
  112. }
  113. fChangeSearchCondition( cmb_cond.value );
  114. }
  115. }else{
  116. if( grd_patinfo2.rows == 2 ){
  117. if( model.getValue("/root/send/autoflag").toUpperCase() == "Y" ){ //조회 내역이 1건일 경우 자동 화면 닫기
  118. model.setFocus("grd_patinfo2");
  119. btn_confirm.dispatch("DOMActivate");
  120. window.close();
  121. }
  122. }
  123. if( grd_patinfo2.rows > 1 ){
  124. model.setFocus("grd_patinfo2");
  125. }else{
  126. if( model.getValue("/root/send/autoflag").toUpperCase() == "NON" ){ //조회 내역이 없을 경우 자동 화면 닫기
  127. //model.setFocus("grd_patinfo");
  128. btn_cancel.dispatch("DOMActivate");
  129. //window.close();
  130. }
  131. fChangeSearchCondition( cmb_cond.value );
  132. }
  133. }
  134. }
  135. }
  136. }else{
  137. //조회조건에서 '예약일시'를 제거한다.
  138. cmb_cond.choices.itemset.attribute("nodeset") = "/root/init/P0350list/P0350[cdid != '5' ]";
  139. model.makeNode("/root/send/srchcond");
  140. model.makeNode("/root/send/pid");
  141. model.makeNode("/root/send/hngnm");
  142. model.makeNode("/root/send/rrgstno1");
  143. model.makeNode("/root/send/rrgstno2");
  144. model.makeNode("/root/send/acptdd");
  145. model.refresh();
  146. }
  147. //진료일 오늘 날짜 디폴트 세팅
  148. model.makeNode("/root/send/acptdd");
  149. model.setValue("/root/send/acptdd", getCurrentDate() );
  150. model.makeNode("/root/send/inhospyn");
  151. model.setValue("/root/send/inhospyn", "N" );
  152. model.refresh();
  153. ]]>
  154. </script>
  155. <script type="javascript">
  156. <![CDATA[
  157. /*
  158. * 창 생성시 부모창으로 부터 받은 입력값의 유효범위 체크
  159. */
  160. function fInputValueCheckXformsReady(){
  161. var cond = model.getValue("/root/send/srchcond");
  162. switch(cond){
  163. case '1':
  164. //환자등록번호 체크
  165. if(ipt_pid.currentText.length == 0){
  166. return (false);
  167. }else{
  168. if(ipt_pid.currentText.length >= 1){
  169. model.setValue("/root/send/pid", ipt_pid.currentText);
  170. return (true);
  171. }else{
  172. messageBox("환자등록번호를 정확히", "C001");
  173. model.setFocus("ipt_pid");
  174. return (false);
  175. }
  176. }
  177. break;
  178. case '2':
  179. //환자이름 체크
  180. if(ipt_hngnm.currentText.length == 0){
  181. return (false);
  182. }else{
  183. if(ipt_hngnm.currentText.length >= 2){
  184. model.setValue("/root/send/hngnm", ipt_hngnm.currentText);
  185. return (true);
  186. }else{
  187. messageBox("환자이름을 2자리 이상", "C001");
  188. model.setFocus("ipt_hngnm");
  189. return (false);
  190. }
  191. }
  192. break;
  193. case '3':
  194. //환자 주민번호 체크
  195. if(ipt_rrgstno1.currentText.length == 0 && ipt_rrgstno2.currentText.length == 0){
  196. return (false);
  197. }else{
  198. if(ipt_rrgstno1.currentText.length >= 4 && ipt_rrgstno2.currentText.length >= 1){
  199. model.setValue("/root/send/rrgstno1", ipt_rrgstno1.currentText);
  200. model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  201. return (true);
  202. }else{
  203. if(ipt_rrgstno1.currentText.length < 4){
  204. messageBox("환자 주민번호 앞자리를 4자리 이상", "C001");
  205. model.setFocus("ipt_rrgstno1");
  206. return (false);
  207. }
  208. if(ipt_rrgstno2.currentText.length < 1){
  209. messageBox("환자 주민번호 뒷자리를 1자리 이상", "C001");
  210. model.setFocus("ipt_rrgstno2");
  211. return (false);
  212. }
  213. messageBox("환자 주민번호를", "C001");
  214. model.setFocus("ipt_rrgstno1");
  215. return (false);
  216. }
  217. }
  218. break;
  219. case '4':
  220. //환자명+주민번호 체크
  221. if(ipt_hngnm.currentText.length == 0 && ipt_rrgstno1.currentText.length == 0){
  222. return (false);
  223. }
  224. if(ipt_hngnm.currentText.length != 0 && ipt_rrgstno1.currentText.length != 0){
  225. //환자이름 체크
  226. if(ipt_hngnm.currentText.length >= 2){
  227. model.setValue("/root/send/hngnm", ipt_hngnm.currentText);
  228. }else{
  229. messageBox("환자이름을 2자리 이상", "C001");
  230. model.setFocus("ipt_hngnm");
  231. return (false);
  232. }
  233. //환자 주민번호 체크
  234. if(ipt_rrgstno1.currentText.length >= 4){
  235. model.setValue("/root/send/rrgstno1", ipt_rrgstno1.currentText);
  236. model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  237. }else{
  238. if(ipt_rrgstno1.currentText.length < 4){
  239. messageBox("환자 주민번호 앞자리를 4자리 이상", "C001");
  240. model.setFocus("ipt_rrgstno1");
  241. return (false);
  242. }
  243. }
  244. return (true);
  245. }else{
  246. if(ipt_hngnm.currentText.length != 0 && ipt_rrgstno1.currentText.length == 0){
  247. //환자명 조회로 변경
  248. model.setValue("/root/send/srchcond", "2");
  249. fChangeSearchCondition("2")
  250. if(ipt_hngnm.currentText.length >= 2){
  251. model.setValue("/root/send/hngnm", ipt_hngnm.currentText);
  252. }else{
  253. messageBox("환자이름을 2자리 이상", "C001");
  254. model.setFocus("ipt_hngnm");
  255. return (false);
  256. }
  257. return (true);
  258. }else if(ipt_hngnm.currentText.length == 0){
  259. //주민번호 조회로 변경
  260. model.setValue("/root/send/srchcond", "3");
  261. fChangeSearchCondition("3")
  262. if(ipt_rrgstno1.currentText.length >= 4 && ipt_rrgstno2.currentText.length >= 1){
  263. model.setValue("/root/send/rrgstno1", ipt_rrgstno1.currentText);
  264. model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  265. }else{
  266. if(ipt_rrgstno1.currentText.length < 4){
  267. messageBox("환자 주민번호 앞자리를 4자리 이상", "C001");
  268. model.setFocus("ipt_rrgstno1");
  269. return (false);
  270. }
  271. if(ipt_rrgstno2.currentText.length < 1){
  272. messageBox("환자 주민번호 뒷자리를 1자리 이상", "C001");
  273. model.setFocus("ipt_rrgstno2");
  274. return (false);
  275. }
  276. messageBox("환자 주민번호를", "C001");
  277. model.setFocus("ipt_rrgstno1");
  278. return (false);
  279. }
  280. return (true);
  281. }
  282. }
  283. break;
  284. case '5':
  285. //예약일자 유효성 체크
  286. if(isValidDateTime( model.getValue("/root/send/acptdd"), "YYYYMMDD")){
  287. model.setValue("/root/send/acptdd", model.getValue("/root/send/acptdd"));
  288. //model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  289. return (true);
  290. }else{
  291. // messageBox("예약일자를 정확히", "C001");
  292. return (false);
  293. }
  294. break;
  295. default :
  296. model.setFocus("cmb_cond");
  297. return( false );
  298. break;
  299. }
  300. }
  301. /*
  302. * 입력값의 유효범위 체크
  303. */
  304. function fInputValueCheck(){
  305. var cond = model.getValue("/root/send/srchcond");
  306. switch(cond){
  307. case '1':
  308. //환자등록번호 체크
  309. if(ipt_pid.currentText.length >= 1 ){
  310. model.setValue("/root/send/pid", ipt_pid.currentText);
  311. return (true);
  312. }else{
  313. messageBox("환자등록번호를 정확히", "C001");
  314. model.setFocus("ipt_pid");
  315. return (false);
  316. }
  317. break;
  318. case '2':
  319. //환자이름 체크
  320. if( ipt_hngnm.currentText.length >= 2 ){
  321. model.setValue("/root/send/hngnm", ipt_hngnm.currentText);
  322. return (true);
  323. }else{
  324. messageBox("환자이름을 2자리 이상", "C001");
  325. model.setFocus("ipt_hngnm");
  326. return (false);
  327. }
  328. break;
  329. case '3':
  330. //환자 주민번호 체크
  331. if( ipt_rrgstno1.currentText.length >= 4 && ipt_rrgstno2.currentText.length >= 1){
  332. model.setValue("/root/send/rrgstno1", ipt_rrgstno1.currentText);
  333. model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  334. return (true);
  335. }else{
  336. if(ipt_rrgstno1.currentText.length < 4){
  337. messageBox("환자 주민번호 앞자리를 4자리 이상", "C001");
  338. model.setFocus("ipt_rrgstno1");
  339. return (false);
  340. }
  341. if(ipt_rrgstno2.currentText.length < 1){
  342. messageBox("환자 주민번호 뒷자리를 1자리 이상", "C001");
  343. model.setFocus("ipt_rrgstno2");
  344. return (false);
  345. }
  346. messageBox("환자 주민번호를", "C001");
  347. model.setFocus("ipt_rrgstno1");
  348. return (false);
  349. }
  350. break;
  351. case '4':
  352. //환자이름 유효성 체크. 환자 주민번호 체크
  353. //환자이름 체크
  354. if(ipt_hngnm.currentText.length >= 2){
  355. model.setValue("/root/send/hngnm", ipt_hngnm.currentText);
  356. }else{
  357. messageBox("환자이름을 2자리 이상", "C001");
  358. model.setFocus("ipt_hngnm");
  359. return (false);
  360. }
  361. //환자 주민번호 체크
  362. if( ipt_rrgstno1.currentText.length >= 4 ){
  363. model.setValue("/root/send/rrgstno1", ipt_rrgstno1.currentText);
  364. model.setValue("/root/send/rrgstno2", ipt_rrgstno2.currentText);
  365. }else{
  366. if(ipt_rrgstno1.currentText.length < 4){
  367. messageBox("환자 주민번호 앞자리를 4자리 이상", "C001");
  368. model.setFocus("ipt_rrgstno1");
  369. return (false);
  370. }
  371. }
  372. return( true );
  373. break;
  374. case '5':
  375. //예약일자 유효성 체크
  376. model.refresh();
  377. if(isValidDateTime( model.getValue("/root/send/acptdd"), "YYYYMMDD")){
  378. return (true);
  379. }else{
  380. messageBox("예약일자를 정확히", "C001");
  381. return (false);
  382. }
  383. break;
  384. default :
  385. messageBox("검색조건이 정확히 선택되지 않았습니다. 확인 후 다시 시도해 주십시요.", "E999", "");
  386. model.setFocus("cmb_cond");
  387. return( false );
  388. break;
  389. }
  390. }
  391. //조회 조건에 맞는 input 컨트롤을 세팅해 준다.
  392. function fChangeSearchCondition(cond){
  393. switch(cond){
  394. case '1':
  395. model.makeNode("/root/send/pid");
  396. ipt_pid.attribute("visibility") = "visible";
  397. ipt_pid.attribute("left") = "219px";
  398. ipt_pid.attribute("top") = "8px";
  399. ipt_hngnm.attribute("visibility") = "hidden";
  400. ipt_rrgstno1.attribute("visibility") = "hidden";
  401. ipt_rrgstno2.attribute("visibility") = "hidden";
  402. ipt_acptdd.attribute("visibility") = "hidden";
  403. model.setFocus("ipt_pid");
  404. break;
  405. case '2':
  406. model.makeNode("/root/send/hngnm");
  407. ipt_hngnm.attribute("visibility") = "visible";
  408. ipt_hngnm.attribute("left") = "219px";
  409. ipt_hngnm.attribute("top") = "8px";
  410. ipt_pid.attribute("visibility") = "hidden";
  411. ipt_rrgstno1.attribute("visibility") = "hidden";
  412. ipt_rrgstno2.attribute("visibility") = "hidden";
  413. ipt_acptdd.attribute("visibility") = "hidden";
  414. model.setFocus("ipt_hngnm");
  415. break;
  416. case '3':
  417. model.makeNode("/root/send/rrgstno1");
  418. model.makeNode("/root/send/rrgstno2");
  419. ipt_rrgstno1.attribute("visibility") = "visible";
  420. ipt_rrgstno2.attribute("visibility") = "visible";
  421. ipt_rrgstno1.attribute("left") = "219px";
  422. ipt_rrgstno1.attribute("top") = "8px";
  423. ipt_rrgstno2.attribute("left") = "307px";
  424. ipt_rrgstno2.attribute("top") = "8px";
  425. ipt_hngnm.attribute("visibility") = "hidden";
  426. ipt_pid.attribute("visibility") = "hidden";
  427. ipt_acptdd.attribute("visibility") = "hidden";
  428. model.setFocus("ipt_rrgstno1");
  429. break;
  430. case '4':
  431. //model.makeNode("/root/send/pid");
  432. model.makeNode("/root/send/hngnm");
  433. model.makeNode("/root/send/rrgstno1");
  434. model.makeNode("/root/send/rrgstno2");
  435. ipt_hngnm.attribute("visibility") = "visible";
  436. ipt_hngnm.attribute("left") = "219px";
  437. ipt_hngnm.attribute("top") = "8px";
  438. ipt_pid.attribute("visibility") = "hidden";
  439. ipt_rrgstno1.attribute("visibility") = "visible";
  440. ipt_rrgstno1.attribute("left") = "352px";
  441. ipt_rrgstno1.attribute("top") = "8px";
  442. ipt_rrgstno2.attribute("visibility") = "visible";
  443. ipt_rrgstno2.attribute("left") = "440px";
  444. ipt_rrgstno2.attribute("top") = "8px";
  445. ipt_acptdd.attribute("visibility") = "hidden";
  446. model.setFocus("ipt_hngnm");
  447. break;
  448. case '5':
  449. model.makeNode("/root/send/acptdd");
  450. ipt_acptdd.attribute("visibility") = "visible";
  451. ipt_acptdd.attribute("left") = "219px";
  452. ipt_acptdd.attribute("top") = "8px";
  453. ipt_hngnm.attribute("visibility") = "hidden";
  454. ipt_pid.attribute("visibility") = "hidden";
  455. ipt_rrgstno1.attribute("visibility") = "hidden";
  456. ipt_rrgstno2.attribute("visibility") = "hidden";
  457. //진료일 오늘 날짜 디폴트 세팅
  458. model.makeNode("/root/send/acptdd");
  459. model.setValue("/root/send/acptdd", getCurrentDate() );
  460. model.setFocus("ipt_acptdd");
  461. break;
  462. default :
  463. //messageBox("검색조건이 정확히 선택되지 않았습니다. 확인 후 다시 시도해 주십시요.", "E999", "");
  464. break;
  465. }
  466. }
  467. ]]>
  468. </script>
  469. </xhtml:head>
  470. <xhtml:body pagewidth="634" pageheight="343" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  471. <group id="group3" scroll="auto" style="left:0px; top:0px; width:618px; height:316px; ">
  472. <datagrid id="grd_patinfo2" nodeset="/root/main/patinfo/patinfolist" class="datagrid2" caption="등록번호^합번^기관코드^환자성명^영문이름^한문이름^주민등록번호^주민등록번호^주민등록번호^최근보험유형^집전화번호^휴대전화번호^최근내원일^최근내원과^외래미수금^퇴원미수금^생년월일^성별^나이^합본등록번호^기타전화번호1^기타전화번호2^sms전송승인 여부^이메일 계정^우편번호^우편번호^우편번호순서^주소^상세주소^혈액형^RH혈액형^외국인여부^국적^여권번호^추천여부^추천인ID^추천인명^추천인관계^VIP여부^VIP비고^종교코드^세례명^성당명^사망여부^사망시각^사망일자^사망시간^내원사유^동물여부^원외예외사유코드^재원여부^장애인여부^특이/문제환자^당일퇴원여부^참고사항^최초등록자ID^최초등록일시^최종수정자ID^최종수정일시^pidflag" colsep="^" colwidth="60, 18, 100, 65, 65, 65, 50, 50, 50, 100, 85, 100, 100, 100, 100, 100, 75, 100, 100, 100, 100, 100, 120, 100, 50, 50, 100, 250, 250, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 119, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100" dataheight="23" defaultrows="2" explorerbar="sortshow" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheight="23" rowsep="|" navindex="7" style="left:0px; top:65px; width:617px; height:250px; ">
  473. <col ref="pid"/>
  474. <col ref="bindyn"/>
  475. <col ref="instcd" visibility="hidden"/>
  476. <col ref="hngnm"/>
  477. <col ref="engnm" visibility="hidden"/>
  478. <col ref="chinm" visibility="hidden"/>
  479. <col ref="rrgstno1"/>
  480. <col ref="rrgstno2" visibility="hidden"/>
  481. <col ref="rrgstno3"/>
  482. <col ref="lastinsukind"/>
  483. <col ref="hometel" visibility="hidden"/>
  484. <col ref="mpphontel" visibility="hidden"/>
  485. <col ref="lastorddd" format="yyyy-mm-dd"/>
  486. <col disabled="true" ref="lastorddeptcd" type="combo">
  487. <choices>
  488. <itemset nodeset="/root/init/orddeptcd/orddeptcdlist">
  489. <label ref="nm"/>
  490. <value ref="cd"/>
  491. </itemset>
  492. </choices>
  493. </col>
  494. <col ref="outuncoamt" visibility="hidden"/>
  495. <col ref="dschuncoamt" visibility="hidden"/>
  496. <col ref="brthdd" visibility="hidden" format="yyyy-mm-dd"/>
  497. <col ref="sex" visibility="hidden"/>
  498. <col ref="age" visibility="hidden"/>
  499. <col ref="bindpid" visibility="hidden"/>
  500. <col ref="etctel1" visibility="hidden"/>
  501. <col ref="etctel2" visibility="hidden"/>
  502. <col ref="smsaprvyn" visibility="hidden"/>
  503. <col ref="email" visibility="hidden"/>
  504. <col ref="zipcd1" visibility="hidden"/>
  505. <col ref="zipcd2" visibility="hidden"/>
  506. <col ref="zipcdseq" visibility="hidden"/>
  507. <col ref="addr"/>
  508. <col ref="detladdr" visibility="hidden"/>
  509. <col ref="btype" visibility="hidden"/>
  510. <col ref="rh" visibility="hidden"/>
  511. <col ref="forgeryn" visibility="hidden"/>
  512. <col ref="nati" visibility="hidden"/>
  513. <col ref="psptno" visibility="hidden"/>
  514. <col ref="recmyn" visibility="hidden"/>
  515. <col ref="recmerid" visibility="hidden"/>
  516. <col ref="recmernm" visibility="hidden"/>
  517. <col ref="recmerrela" visibility="hidden"/>
  518. <col ref="vipyn" visibility="hidden"/>
  519. <col ref="viprem" visibility="hidden"/>
  520. <col ref="religncd" visibility="hidden"/>
  521. <col ref="baptnm" visibility="hidden"/>
  522. <col ref="chchnm" visibility="hidden"/>
  523. <col ref="dethyn" visibility="hidden"/>
  524. <col ref="dethdt" visibility="hidden"/>
  525. <col ref="dethdd" visibility="hidden"/>
  526. <col ref="dethtm" visibility="hidden"/>
  527. <col ref="chosresn" visibility="hidden"/>
  528. <col ref="animyn" visibility="hidden"/>
  529. <col ref="exptresncd" visibility="hidden"/>
  530. <col ref="inhospyn" visibility="hidden"/>
  531. <col ref="handicapryn" visibility="hidden"/>
  532. <col ref="patspcfyn" visibility="hidden"/>
  533. <col ref="tdaydsch" visibility="hidden"/>
  534. <col ref="remfact" visibility="hidden"/>
  535. <col ref="acptdd" visibility="hidden"/>
  536. <col ref="acptno" visibility="hidden"/>
  537. <col ref="lastupdtrid" visibility="hidden"/>
  538. <col ref="lastupdtdt" visibility="hidden"/>
  539. <col ref="pidflag" visibility="hidden"/>
  540. <col ref="hngnm2" visibility="hidden"/>
  541. <script type="javascript" ev:event="ondblclick">
  542. <![CDATA[
  543. if(checkOpener()){
  544. // row = grd_patinfo.row;
  545. // if(row > 0){
  546. // if(getNodesetCount("/root/main/patinfo/patinfolist") > 0){
  547. // opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo.getNode(row));
  548. // opener.model.makeNode("/root/main/popupendflag");
  549. // opener.model.setValue("/root/main/popupendflag", "ok");
  550. // opener.model.refresh();
  551. // window.close();
  552. // }
  553. // }
  554. if(isDataCell()){
  555. btn_confirm.dispatch("DOMActivate");
  556. }
  557. }else{
  558. messageBox("상위화면이 변경되어 데이터를 가져올 수", "I004");
  559. }
  560. ]]>
  561. </script>
  562. <script type="javascript" ev:event="onclick">
  563. <![CDATA[
  564. /*
  565. if(checkOpener()){
  566. row = grd_patinfo.row;
  567. if(row > 0){
  568. if(getNodesetCount("/root/main/patinfo/patinfolist") > 1){
  569. opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo.getNode(row));
  570. opener.model.refresh();
  571. }
  572. }
  573. }else{
  574. messageBox("상위화면이 변경되어 데이터를 가져올 수", "I004");
  575. }
  576. */
  577. ]]>
  578. </script>
  579. <script type="javascript" ev:event="onkeypress">
  580. <![CDATA[
  581. if( event.keyCode == 13 ){
  582. btn_confirm.dispatch("DOMActivate");
  583. }
  584. ]]>
  585. </script>
  586. </datagrid>
  587. <group id="group2" style="left:0px; top:0px; width:618px; height:35px; ">
  588. <shape id="roundrect1" appearance="roundrect" style="left:0px; top:0px; width:617px; height:35px; "/>
  589. <caption id="caption2" class="search_name" style="left:15px; top:8px; width:86px; height:17px; ">검색조건 :</caption>
  590. <button id="btn_search" class="btn1_letter2" navindex="6" style="left:545px; top:7px; width:56px; height:22px; ">
  591. <caption>조회</caption>
  592. <script type="javascript" ev:event="DOMActivate">
  593. <![CDATA[
  594. if(fInputValueCheck()){
  595. // 2017/09/05 환자 조회시 function 조회 안하도록 수정(속도개선)
  596. model.makeValue("/root/send/functionyn", "N");
  597. // 2017/09/05 환자 조회시 function 조회 안하도록 수정(속도개선)
  598. // 주민번호 검색 - 전화예약환자 예외처리용
  599. if (ipt_rrgstno1.currentText.length == 6 && ipt_rrgstno2.currentText.length == 7) {
  600. model.makeValue("/root/send/hiddenflag", "");
  601. } else {
  602. model.makeValue("/root/send/hiddenflag", "Y");
  603. }
  604. if(submit("TRPMC02500")){
  605. if(PatRefPamFlag == "SMP" || PatRefPamFlag == "SPP"){
  606. if(grd_patinfo.rows > 1){
  607. grd_patinfo.row = 1;
  608. model.setFocus("grd_patinfo");
  609. }else{
  610. fChangeSearchCondition(cmb_cond.value);
  611. }
  612. }else{
  613. if(grd_patinfo2.rows > 1){
  614. grd_patinfo2.row = 1;
  615. model.setFocus("grd_patinfo2");
  616. }else{
  617. fChangeSearchCondition(cmb_cond.value);
  618. }
  619. }
  620. }
  621. }
  622. ]]>
  623. </script>
  624. </button>
  625. <line id="line13" class="line_4" style="x1:529px; y1:7px; x2:529px; y2:29px; border-color:#ffe4bb; "/>
  626. <input id="ipt_hngnm" ref="/root/send/hngnm" class="input_search" navindex="1" visibility="hidden" autonext="false" imemode="hangul" style="left:224px; top:8px; width:130px; height:19px; ">
  627. <script type="javascript" ev:event="onkeypress">
  628. <![CDATA[
  629. inputEnterKey("btn_search", "DOMActivate");
  630. ]]>
  631. </script>
  632. </input>
  633. <input id="ipt_rrgstno1" ref="/root/send/rrgstno1" class="input_search" navindex="2" visibility="hidden" format="999999" style="left:247px; top:8px; width:85px; height:19px; ">
  634. <script type="javascript" ev:event="onkeypress">
  635. <![CDATA[
  636. inputEnterKey("btn_search", "DOMActivate");
  637. ]]>
  638. </script>
  639. </input>
  640. <select1 id="cmb_cond" ref="/root/send/srchcond" class="combo_search" navindex="10" appearance="minimal" style="left:106px; top:8px; width:110px; height:19px; ">
  641. <choices>
  642. <itemset nodeset="/root/init/P0350list/P0350">
  643. <label ref="cdnm"/>
  644. <value ref="cdid"/>
  645. </itemset>
  646. </choices>
  647. <script type="javascript" ev:event="xforms-value-changed">
  648. <![CDATA[
  649. var cond = model.getValue("/root/send/srchcond");
  650. fChangeSearchCondition(cond);
  651. ]]>
  652. </script>
  653. </select1>
  654. <input id="ipt_rrgstno2" ref="/root/send/rrgstno2" class="input_search" navindex="3" visibility="hidden" autonext="false" format="9999999" style="left:285px; top:8px; width:85px; height:19px; ">
  655. <script type="javascript" ev:event="onkeypress">
  656. <![CDATA[
  657. inputEnterKey("btn_search", "DOMActivate");
  658. ]]>
  659. </script>
  660. </input>
  661. <input id="ipt_pid" ref="/root/send/pid" class="input_search" navindex="4" visibility="hidden" autonext="false" style="left:325px; top:8px; width:130px; height:19px; ">
  662. <script type="javascript" ev:event="onkeypress">
  663. <![CDATA[
  664. inputEnterKey("btn_search", "DOMActivate");
  665. ]]>
  666. </script>
  667. </input>
  668. <input id="ipt_acptdd" ref="/root/send/acptdd" class="input_search" navindex="5" visibility="hidden" autonext="false" inputtype="date" style="left:390px; top:8px; width:130px; height:19px; ">
  669. <script type="javascript" ev:event="onkeypress">
  670. <![CDATA[
  671. inputEnterKey("btn_search", "DOMActivate");
  672. ]]>
  673. </script>
  674. </input>
  675. </group>
  676. <caption id="caption1" class="tit_2" style="left:5px; top:45px; width:95px; height:14px; ">인적사항</caption>
  677. <line id="line1" class="line_1" style="x1:0px; y1:60px; x2:617px; y2:60px; "/>
  678. <datagrid id="grd_patinfo" nodeset="/root/main/patinfo/patinfolist" class="datagrid2" caption="등록번호^합번^기관코드^환자성명^영문이름^한문이름^주민등록번호^주민등록번호^주민등록번호^최근보험유형^집전화번호^휴대전화번호^최근내원일^최근내원과^외래미수금^퇴원미수금^생년월일^성별^나이^합본등록번호^기타전화번호1^기타전화번호2^sms전송승인 여부^이메일 계정^우편번호^우편번호^우편번호순서^주소^상세주소^혈액형^RH혈액형^외국인여부^국적^여권번호^추천여부^추천인ID^추천인명^추천인관계^VIP여부^VIP비고^종교코드^세례명^성당명^사망여부^사망시각^사망일자^사망시간^내원사유^동물여부^원외예외사유코드^재원여부^장애인여부^특이/문제환자^당일퇴원여부^참고사항^최초등록자ID^최초등록일시^최종수정자ID^최종수정일시^pidflag^caption1^caption2^caption3" colsep="^" colwidth="60, 18, 100, 65, 65, 65, 50, 50, 50, 100, 85, 100, 100, 100, 100, 100, 75, 100, 100, 100, 100, 100, 120, 100, 50, 50, 100, 250, 250, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 119, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100" dataheight="23" defaultrows="2" explorerbar="sortshow" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheight="23" rowsep="|" navindex="7" style="left:0px; top:65px; width:617px; height:250px; ">
  679. <col ref="pid"/>
  680. <col ref="bindyn"/>
  681. <col ref="instcd" visibility="hidden"/>
  682. <col ref="hngnm"/>
  683. <col ref="engnm" visibility="hidden"/>
  684. <col ref="chinm" visibility="hidden"/>
  685. <col ref="rrgstno1"/>
  686. <col ref="rrgstno2" visibility="hidden"/>
  687. <col ref="rrgstno3"/>
  688. <col ref="lastinsukind"/>
  689. <col ref="hometel"/>
  690. <col ref="mpphontel"/>
  691. <col ref="lastorddd" format="yyyy-mm-dd"/>
  692. <col disabled="true" ref="lastorddeptcd" type="combo">
  693. <choices>
  694. <itemset nodeset="/root/init/orddeptcd/orddeptcdlist">
  695. <label ref="nm"/>
  696. <value ref="cd"/>
  697. </itemset>
  698. </choices>
  699. </col>
  700. <col ref="outuncoamt" visibility="hidden"/>
  701. <col ref="dschuncoamt" visibility="hidden"/>
  702. <col ref="brthdd" visibility="hidden" format="yyyy-mm-dd"/>
  703. <col ref="sex" visibility="hidden"/>
  704. <col ref="age" visibility="hidden"/>
  705. <col ref="bindpid" visibility="hidden"/>
  706. <col ref="etctel1" visibility="hidden"/>
  707. <col ref="etctel2" visibility="hidden"/>
  708. <col ref="smsaprvyn" visibility="hidden"/>
  709. <col ref="email" visibility="hidden"/>
  710. <col ref="zipcd1" visibility="hidden"/>
  711. <col ref="zipcd2" visibility="hidden"/>
  712. <col ref="zipcdseq" visibility="hidden"/>
  713. <col ref="addr"/>
  714. <col ref="detladdr"/>
  715. <col ref="btype" visibility="hidden"/>
  716. <col ref="rh" visibility="hidden"/>
  717. <col ref="forgeryn" visibility="hidden"/>
  718. <col ref="nati" visibility="hidden"/>
  719. <col ref="psptno" visibility="hidden"/>
  720. <col ref="recmyn" visibility="hidden"/>
  721. <col ref="recmerid" visibility="hidden"/>
  722. <col ref="recmernm" visibility="hidden"/>
  723. <col ref="recmerrela" visibility="hidden"/>
  724. <col ref="vipyn" visibility="hidden"/>
  725. <col ref="viprem" visibility="hidden"/>
  726. <col ref="religncd" visibility="hidden"/>
  727. <col ref="baptnm" visibility="hidden"/>
  728. <col ref="chchnm" visibility="hidden"/>
  729. <col ref="dethyn" visibility="hidden"/>
  730. <col ref="dethdt" visibility="hidden"/>
  731. <col ref="dethdd" visibility="hidden"/>
  732. <col ref="dethtm" visibility="hidden"/>
  733. <col ref="chosresn" visibility="hidden"/>
  734. <col ref="animyn" visibility="hidden"/>
  735. <col ref="exptresncd" visibility="hidden"/>
  736. <col ref="inhospyn" visibility="hidden"/>
  737. <col ref="handicapryn" visibility="hidden"/>
  738. <col ref="patspcfyn" visibility="hidden"/>
  739. <col ref="tdaydsch" visibility="hidden"/>
  740. <col ref="remfact" visibility="hidden"/>
  741. <col ref="acptdd" visibility="hidden"/>
  742. <col ref="acptno" visibility="hidden"/>
  743. <col ref="lastupdtrid" visibility="hidden"/>
  744. <col ref="lastupdtdt" visibility="hidden"/>
  745. <col ref="pidflag" visibility="hidden"/>
  746. <col ref="hngnm2" visibility="hidden"/>
  747. <col ref="scanyn" visibility="hidden"/>
  748. <col ref="carnum" visibility="hidden"/>
  749. <col ref="spifscanyn" visibility="hidden"/>
  750. <script type="javascript" ev:event="ondblclick">
  751. <![CDATA[
  752. if ( checkOpener() ) {
  753. // row = grd_patinfo.row;
  754. // if(row > 0){
  755. // if(getNodesetCount("/root/main/patinfo/patinfolist") > 0){
  756. // opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo.getNode(row));
  757. // opener.model.makeNode("/root/main/popupendflag");
  758. // opener.model.setValue("/root/main/popupendflag", "ok");
  759. // opener.model.refresh();
  760. // window.close();
  761. // }
  762. // }
  763. if(model.getValue("/root/send/worktype").toUpperCase() == 'PAM' ){
  764. var hngnm = grd_patinfo.valueMatrix(grd_patinfo.row, grd_patinfo.colRef("hngnm"));
  765. var rrgstno1 = grd_patinfo.valueMatrix(grd_patinfo.row, grd_patinfo.colRef("rrgstno1"));
  766. var cnt = getNodesetCount("/root/main/patinfo/patinfolist[hngnm='"+ hngnm + "' and rrgstno1='" + rrgstno1 + "']");
  767. if(parseInt(cnt)>1){
  768. messageBox("동명이인이 있으니 인적정보(주소, 전화번호 등)를 확인하여\n주시기 바랍니다", "I");
  769. }
  770. if(isDataCell()){
  771. btn_confirm.dispatch("DOMActivate");
  772. }
  773. }else{
  774. if(isDataCell()){
  775. btn_confirm.dispatch("DOMActivate");
  776. }
  777. }
  778. }else{
  779. messageBox("상위화면이 변경되어 데이터를 가져올 수", "I004");
  780. }
  781. ]]>
  782. </script>
  783. <script type="javascript" ev:event="onclick">
  784. <![CDATA[
  785. /*
  786. if(checkOpener()){
  787. row = grd_patinfo.row;
  788. if(row > 0){
  789. if(getNodesetCount("/root/main/patinfo/patinfolist") > 1){
  790. opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo.getNode( row ));
  791. opener.model.refresh();
  792. }
  793. }
  794. }else{
  795. messageBox("상위화면이 변경되어 데이터를 가져올 수", "I004");
  796. }
  797. */
  798. ]]>
  799. </script>
  800. <script type="javascript" ev:event="onkeypress">
  801. <![CDATA[
  802. if( event.keyCode == 13 ){
  803. btn_confirm.dispatch("DOMActivate");
  804. }
  805. ]]>
  806. </script>
  807. <script type="javascript" ev:event="onaftersort">
  808. <![CDATA[
  809. grd_patinfo.gridToInstance();
  810. ]]>
  811. </script>
  812. </datagrid>
  813. <!-- 수정이력 20100223 JHP 여의도 기준 다른팀에서 작업하기 싫어서 원무팀에 넘긴 일정임 원무팀에서 본 화면 열때는 원래대로 다른 팀 화면에서 열때는 하단의 그리드 보여지도록 수정함.-->
  814. <caption id="caption3" style="left:550px; top:40px; width:50px; height:20px; ">재원여부</caption>
  815. <bool id="bl_inhospyn" checkvalue="Y,N" ref="/root/send/inhospyn" style="left:527px; top:39px; width:20px; height:20px; "/>
  816. </group>
  817. <group id="group1" scroll="auto" style="left:0px; top:316px; width:618px; height:27px; ">
  818. <button id="btn_confirm" class="btn4_letter2" navindex="8" style="left:502px; top:5px; width:56px; height:22px; ">
  819. <caption>확인</caption>
  820. <script type="javascript" ev:event="DOMActivate">
  821. <![CDATA[
  822. if(checkOpener()){
  823. if(PatRefPamFlag == "SMP" || PatRefPamFlag == "SPP"){
  824. row = grd_patinfo.row;
  825. }else{
  826. row = grd_patinfo2.row;
  827. }
  828. opener.model.makeNode("/root/main/popupendflag");
  829. opener.model.setValue("/root/main/popupendflag", "cancel");
  830. if(row > 0){
  831. if(getNodesetCount("/root/main/patinfo/patinfolist") > 0){
  832. //합번된 등록번호 메세지 처리
  833. var sPid = model.getValue("/root/main/patinfo/patinfolist[" + row + "]/pid");
  834. var sHngnm = model.getValue("/root/main/patinfo/patinfolist[" + row + "]/hngnm");
  835. var sBindPid = model.getValue("/root/main/patinfo/patinfolist[" + row + "]/bindpid");
  836. if (!isNull(sPid)) {
  837. model.makeValue("/root/send/srchcond", "1");
  838. model.makeValue("/root/send/pid", sPid);
  839. model.makeValue("/root/send/hiddenflag", "");
  840. submit("TRPMC02500")
  841. row = 1;
  842. }
  843. if( sBindPid != '' && sBindPid != '-' && sBindPid != ' '){
  844. var retValue = messageBox(sPid + "(" + sHngnm + ") 환자의 등록번호가 [ " + sBindPid + " ] 로 합번 되었습니다. 합번된 등록번호로 재조회 하시겠습니까?", "Q999", "");
  845. if( retValue == '6' ){
  846. try{
  847. model.resetInstanceNode("/root/send");
  848. model.setValue("/root/send/srchcond", "1");
  849. fChangeSearchCondition( '1' );
  850. model.setValue("/root/send/pid", sBindPid);
  851. model.refresh();
  852. btn_search.dispatch("DOMActivate");
  853. }catch(e){
  854. return false;
  855. }
  856. }
  857. return false;
  858. }
  859. if(PatRefPamFlag == "SMP" || PatRefPamFlag == "SPP"){
  860. opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo.getNode( row ));
  861. }else{
  862. opener.model.copyNode("/root/main/patinfo/patinfolist", grd_patinfo2.getNode( row ));
  863. }
  864. opener.model.makeNode("/root/main/popupendflag");
  865. opener.model.setValue("/root/main/popupendflag", "ok");
  866. }
  867. //else{
  868. // opener.model.setValue("/root/main/popupendflag", "cancel");
  869. //}
  870. //opener.model.refresh();
  871. //window.close();
  872. }else {
  873. //opener.model.setValue("/root/main/popupendflag", "cancel");
  874. messageBox("행이 정확히 선택되지", "E007");
  875. //opener.model.refresh();
  876. //window.close();
  877. }
  878. } else {
  879. messageBox("상위화면이 변경되어 데이터를 가져올 수", "I004");
  880. //opener.model.setValue("/root/main/popupendflag", "cancel");
  881. //opener.model.refresh();
  882. //window.close();
  883. }
  884. opener.model.refresh();
  885. window.close();
  886. ]]>
  887. </script>
  888. </button>
  889. <button id="btn_cancel" class="btn4_letter2" navindex="9" style="left:561px; top:5px; width:56px; height:22px; ">
  890. <caption>취소</caption>
  891. <script type="javascript" ev:event="DOMActivate">
  892. <![CDATA[
  893. opener.model.makeNode("/root/main/popupendflag");
  894. opener.model.setValue("/root/main/popupendflag", "cancel");
  895. window.close();
  896. ]]>
  897. </script>
  898. </button>
  899. <line id="line32" class="line_6" style="x1:0px; y1:0px; x2:618px; y2:0px; "/>
  900. </group>
  901. </xhtml:body>
  902. </xhtml:html>