SMAEA01900_치료예약.xrw 86 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  4. <xhtml:head>
  5. <xhtml:title>재활치료예약</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <rehbprcplist>
  11. <rehbprcp>
  12. <pid/>
  13. <hngnm/>
  14. <roomcd/>
  15. <depthngnm/>
  16. <deptcd/>
  17. <ioflag/>
  18. <orddd/>
  19. <orddrid/>
  20. <orddrnm/>
  21. <prcpgenrflag/>
  22. <rrgstno1/>
  23. <rrgstno2/>
  24. <rsrvyn/>
  25. <sex/>
  26. <aftrcptinfo/>
  27. </rehbprcp>
  28. </rehbprcplist>
  29. <patinfo>
  30. <patinfolist>
  31. <hngnm/>
  32. </patinfolist>
  33. </patinfo>
  34. <rsrvposstmlist>
  35. <rsrvposstm>
  36. <rsrvtm/>
  37. <count/>
  38. </rsrvposstm>
  39. </rsrvposstmlist>
  40. <rehbprcpsubinfolist>
  41. <rehbprcpsubinfo>
  42. <check/>
  43. <lvl/>
  44. <prcpdd/>
  45. <prcpnm/>
  46. <prcpdayno/>
  47. <rmnddayno/>
  48. <prcptims/>
  49. <rehbprcpcurefreqflagnm/>
  50. <rsrvdd/>
  51. <rsrvtm/>
  52. <curoom/>
  53. <curoomcd/>
  54. <curer/>
  55. <curerid/>
  56. <orddrnm/>
  57. <orddrrsrvyn/>
  58. <execprcpuniqno/>
  59. <prcpgenrflag/>
  60. <prcpkindcd/>
  61. <excupartcd/>
  62. <orddd/>
  63. <orddeptcd/>
  64. <orddrid/>
  65. <prcpcd/>
  66. <pid/>
  67. <prcpno/>
  68. <centcd/>
  69. </rehbprcpsubinfo>
  70. <rsrvprescond>
  71. <rsrvday/>
  72. </rsrvprescond>
  73. <isolinfo>
  74. <isoldispcd/>
  75. </isolinfo>
  76. </rehbprcpsubinfolist>
  77. <baseconfinfo>
  78. <baseconflist>
  79. <basedd/>
  80. <basecnt/>
  81. </baseconflist>
  82. </baseconfinfo>
  83. <rsrvlist>
  84. <execprcpuniqno/>
  85. <pid/>
  86. <hngnm/>
  87. <rsrvdt/>
  88. <excuroomnm/>
  89. <prcpnm/>
  90. <examgoal/>
  91. <logoimg/>
  92. <rsrvtm/>
  93. </rsrvlist>
  94. <excrlist>
  95. <excrinfo>
  96. <execrid/>
  97. <excuroomcd/>
  98. </excrinfo>
  99. </excrlist>
  100. <codelist/>
  101. </main>
  102. <send>
  103. <fromdd/>
  104. <todd/>
  105. <excuroomcd/>
  106. <pid/>
  107. <ioflag/>
  108. <deptcd/>
  109. <rsrvflag/>
  110. <subinfopid/>
  111. <req>
  112. <data/>
  113. <flag/>
  114. </req>
  115. <rsrvposstmcheck>
  116. <rsrvtm/>
  117. <curoomcd/>
  118. </rsrvposstmcheck>
  119. <globalinstance>
  120. <instance1/>
  121. </globalinstance>
  122. <rsrvdd/>
  123. <retroomcd/>
  124. <hngnm/>
  125. <sex/>
  126. <orddeptcd/>
  127. <popdata>
  128. <pid/>
  129. <hngnm/>
  130. <sex/>
  131. </popdata>
  132. <satdayflag/>
  133. <prcprem/>
  134. <rsrvpaper>
  135. <fromdd/>
  136. <todd/>
  137. <pid/>
  138. <basesuppdeptcd/>
  139. </rsrvpaper>
  140. <grupcdid/>
  141. <jciyn/>
  142. <searchflag>false</searchflag>
  143. <centcd/>
  144. </send>
  145. <senda>
  146. <pid/>
  147. <ioflag/>
  148. </senda>
  149. <init>
  150. <excuroomlist>
  151. <excuroom>
  152. <basecd/>
  153. <basecdflagdesc/>
  154. </excuroom>
  155. </excuroomlist>
  156. <curerprescondlist>
  157. <curerprescond>
  158. <userid/>
  159. <usernm/>
  160. </curerprescond>
  161. <rsrvcalendar>
  162. <rsrvdd/>
  163. <count/>
  164. </rsrvcalendar>
  165. </curerprescondlist>
  166. <calen/>
  167. <battm/>
  168. <treeflag>true</treeflag>
  169. <autocheck/>
  170. <calenlist>
  171. <calendinfo>
  172. <basedd/>
  173. <dutflag/>
  174. </calendinfo>
  175. </calenlist>
  176. <cmb_info/>
  177. <baseinfo>
  178. <initautoroom/>
  179. <initsuppdeptcd/>
  180. </baseinfo>
  181. </init>
  182. <hidden>
  183. <calendar>
  184. <year/>
  185. <month/>
  186. <weeklist>
  187. <list>
  188. <sun/>
  189. <mon/>
  190. <tue/>
  191. <wed/>
  192. <thu/>
  193. <fri/>
  194. <sat/>
  195. <sun_memo/>
  196. <mon_memo/>
  197. <tue_memo/>
  198. <wed_memo/>
  199. <thu_memo/>
  200. <fri_memo/>
  201. <sat_memo/>
  202. </list>
  203. </weeklist>
  204. </calendar>
  205. <popmenu>
  206. <rsrvlist>
  207. <item>
  208. <name>예약지출력</name>
  209. <func>fexeRsrvReport</func>
  210. </item>
  211. </rsrvlist>
  212. <jcilist>
  213. <item>
  214. <name>예약지출력</name>
  215. <func>fexeRsrvReport</func>
  216. </item>
  217. <item>
  218. <name>다학제간</name>
  219. <func>fPateduSync</func>
  220. </item>
  221. <item>
  222. <name>CarePlan</name>
  223. <func>fCarePlanSync</func>
  224. </item>
  225. </jcilist>
  226. </popmenu>
  227. <boolcontrol>
  228. <bool/>
  229. </boolcontrol>
  230. <isolinfo>
  231. <isoldata/>
  232. </isolinfo>
  233. <diaginfo/>
  234. </hidden>
  235. <temp>
  236. <count/>
  237. <rsrvyddlist>
  238. <date>
  239. <yyyymmdd/>
  240. </date>
  241. </rsrvyddlist>
  242. <progressnote>
  243. <list>
  244. <cretno/>
  245. <ioflag/>
  246. <orddrid/>
  247. </list>
  248. </progressnote>
  249. </temp>
  250. </root>
  251. </instance>
  252. <script type="javascript" ev:event="xforms-ready">
  253. <![CDATA[
  254. aezfSetSuppDeptcd();
  255. if(checkOpener()){
  256. var deptcd = opener.javascript.getParameter("SMAEA01900_Param_doctorYn");
  257. if (deptcd == "Y") {
  258. model.setValue("/root/send/globalinstance/instance1", "2220000000");
  259. }
  260. }
  261. initCalendar();
  262. fCalendar();
  263. model.removeNodeset("/root/main/rehbprcplist/rehbprcp");
  264. model.removeNodeset("/root/main/rsrvposstmlist/rsrvposstm");
  265. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  266. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  267. model.removeNodeset("/root/init/curerprescondlist/curerprescond");
  268. model.removeNodeset("/root/temp/rsrvyddlist/date");
  269. /*
  270. //start
  271. //2012.10.29 by kya 로그인한 사람의 센터코드 가져오기
  272. var centcd = getUserInfo("ordsupdeptcd");
  273. //alert(centcd);
  274. model.setValue("/root/send/centcd",centcd);
  275. //end
  276. */
  277. model.setValue("/root/send/ioflag","I");
  278. model.setValue("/root/send/fromdd",getCurrentDate());//getCurrentDate().toDate().getAddDate(-1,"M").getDateFormat("YYYYMMDD"));
  279. model.setValue("/root/send/todd",getCurrentDate());
  280. model.refresh();
  281. submit("TRAEA01901", false);
  282. submit("TRAEA01201", false);
  283. model.setFocus("ipt_pid");
  284. //grd_prcpsubinfo.fixedcellcheckbox(0,0) =true;
  285. cmb_excuroom.select(0);
  286. //bool1.attribute("checkvalue") = true;
  287. //20101004 주석처리 예약일자자동생성조회 안되게(불필요한 조회안하게) - 박재영
  288. //model.setValue("/root/init/autocheck", "true");
  289. /*
  290. submit("TRAER00110"); //콤보조회
  291. var gv_exeuroomcd = getGlobalVariable("gv_exeuroomcd", "A");
  292. if (gv_exeuroomcd != ""){
  293. model.setValue("/root/send/retroomcd", gv_exeuroomcd);
  294. }else{
  295. if (getNodesetCount("/root/main/excrlist/excrinfo") > 0){
  296. model.setValue("/root/send/retroomcd", model.getValue("/root/main/excrlist/excrinfo/excuroomcd"));
  297. setGlobalVariable("gv_exeuroomcd", model.getValue("/root/send/retroomcd"), "A");
  298. }
  299. }
  300. */
  301. astGetComboList( new Array("A520", "A530"), new Array("/root/init/baseinfo/initautoroom", "/root/init/baseinfo/initsuppdeptcd") );
  302. submit("TRAAA00001", false);
  303. model.removeNodeset("/root/init/baseinfo/initautoroom/A520[" + 1 + "]");
  304. model.removeNodeset("/root/init/baseinfo/initsuppdeptcd/A530[" + 1 + "]");
  305. if (model.getValue("/root/senda/pid") != ""){
  306. //btn_sea.dispatch("DOMActivate");
  307. model.setValue("/root/send/pid", model.getValue("/root/senda/pid"));
  308. if (model.getValue("/root/senda/ioflag") == "I"){
  309. btn_iprcp.selected= true;
  310. }else{
  311. button1.selected= true;
  312. }
  313. button3.dispatch("DOMActivate");
  314. }
  315. // JCI 적용 여부
  316. model.setValue("/root/send/grupcdid","JCI01");
  317. model.removenode("/root/main/codelist");
  318. if (submit("TRAEB00010")) {
  319. var cnt = getNodesetCount("/root/main/codelist/item");
  320. if (cnt > 0) {
  321. var jciyn = model.getValue("/root/main/codelist/item[1]/cdid");
  322. model.setValue("/root/send/jciyn", jciyn);
  323. if (jciyn == "Y") {
  324. btn_patedu.visible = true;
  325. btn_careplan.visible = true;
  326. } else {
  327. btn_patedu.visible = false;
  328. btn_careplan.visible = false;
  329. }
  330. } else {
  331. btn_patedu.visible = false;
  332. btn_careplan.visible = false;
  333. }
  334. }
  335. model.refresh();
  336. ]]>
  337. </script>
  338. <submission id="TRAEA01901" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/excuroomlist"/>
  339. <submission id="TRAEA01902" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/init/curerprescondlist"/>
  340. <submission id="TRAEA01903" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/rehbprcplist"/>
  341. <submission id="TRAEA01904" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/rsrvposstmlist"/>
  342. <submission id="TRAEA01905" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/rehprcpsubinfolist"/>
  343. <submission id="TRAEA01907" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/baseconfinfo"/>
  344. <submission id="TXAEA01901" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp"/>
  345. <submission id="TRAER00109" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp/progressnote"/>
  346. <submission id="TRAEA02012" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/init/calenlist"/>
  347. <submission id="TRAEA01201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/globalinstance/instance1" resultref="/root/init/cmb_info"/>
  348. <submission id="TRAEA01210" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/rsrvpaper" resultref="/root/main/rsrvlist"/>
  349. <submission id="TRAER00110" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/excrlist"/>
  350. <submission id="TRAAA00001"/>
  351. <submission id="TRMNC00999" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send_diaginfo" replace="instance" resultref="/root/hidden/diaginfo"/>
  352. <submission id="TRAEB00010" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/codelist"/>
  353. </model>
  354. <script type="javascript">
  355. <![CDATA[
  356. function initCalendar() {
  357. var curDate = getCurrentDate().toDate();
  358. model.setValue("/root/hidden/calendar/year", curDate.getDateFormat('YYYY'));
  359. model.setValue("/root/hidden/calendar/month", curDate.getDateFormat('MM'));
  360. model.refresh();
  361. setCalendar(curDate);
  362. }
  363. function setCalendar(dateObj) {
  364. // 그리드 초기화
  365. model.removeNodeset("/root/hidden/calendar/weeklist/list");
  366. model.removeNodeset("/root/init/curerprescondlist/rsrvcalendar");
  367. //grd_calendar.rebuild()
  368. dateObj.setDate(1);
  369. var startDay = dateObj.getDay();
  370. var days = dateObj.getMonthDay();
  371. var rows = Math.ceil( ( startDay + days ) / 7 );
  372. for( var i = 0; i < rows; i++ )
  373. grd_calendar.addRow(false);
  374. grd_calendar.rebuild();
  375. var rowIndex = grd_calendar.fixedRows;
  376. var colIndex = startDay;
  377. for( var i = 1; i <= days; i++ ) {
  378. grd_calendar.valueMatrix(rowIndex, colIndex) = i;
  379. grd_calendar.valueMatrix(rowIndex, colIndex + 7) = "0/0";
  380. colIndex++;
  381. if( colIndex == 7 ) {
  382. colIndex = 0;
  383. rowIndex++;
  384. }
  385. }
  386. model.setValue("/root/send/rsrvdd",model.getValue("/root/hidden/calendar/year")+model.getValue("/root/hidden/calendar/month")+"01");
  387. //fCalendar();
  388. //setRsrvPresCondByMonth();
  389. }
  390. function fCalendar(){
  391. if (submit("TRAEA02012")){
  392. var isMonth = model.getValue("/root/hidden/calendar/month");
  393. var isYear = model.getValue("/root/hidden/calendar/year");
  394. var isDate = (isYear+isMonth+1).toDate();
  395. var startDay = isDate.getDay();
  396. for (var i = 1; i < datagrid3.rows; i++) {
  397. var dd = model.getValue("/root/init/calenlist/calendinfo[" + i + "]/basedd");
  398. var colidx = dd.toDate().getDay();
  399. var rowidx = Math.ceil( ( startDay + Number(dd.substr(6,2)) ) / 7 );
  400. //var rowidx = Math.ceil( ( startDay + Number(dd.substr(6,2)) ) / 7 );
  401. //alert("i==" + i + "==dutflag==" + model.getValue("/root/init/calenlist/calendinfo[" + i + "]/dutflag"));
  402. if (model.getValue("/root/init/calenlist/calendinfo[" + i + "]/dutflag") == "8"){
  403. grd_calendar.cellstyle("color", rowidx, colidx, rowidx, colidx) = "red";
  404. }else if (model.getValue("/root/init/calenlist/calendinfo[" + i + "]/dutflag") == "4"){
  405. grd_calendar.cellstyle("color", rowidx, colidx, rowidx, colidx) = "blue";
  406. }else{
  407. grd_calendar.cellstyle("color", rowidx, colidx, rowidx, colidx) = "black";
  408. }
  409. }
  410. grd_calendar.refresh();
  411. }
  412. }
  413. function setCellColor(gridObj) {
  414. var calRow = gridObj.row;
  415. var calCol = gridObj.col;
  416. var calCol2 = 0;
  417. if (getStringLength(model.getValue("/root/send/rsrvdd")) == 8) {
  418. if (gridObj.cellStyle("background-color", calRow, calCol) == "#daa7d9") {
  419. gridObj.cellStyle("background-color", calRow, calCol) = "#ffffff";
  420. var index = grd_temp2.findRow(model.getValue("/root/send/rsrvdd"), 0, 1, true, true);
  421. grd_temp2.row = index;
  422. deleteSelectedRows(grd_temp2,false);
  423. } else {
  424. gridObj.cellStyle("background-color", calRow, calCol) = "#daa7d9";
  425. grd_temp2.addRow(false);
  426. model.setValue("/root/temp/rsrvyddlist/date[" + grd_temp2.row + "]/yyyymmdd",model.getValue("/root/send/rsrvdd"));
  427. }
  428. }
  429. if( calCol < 7 )
  430. calCol2 = calCol + 7;
  431. else
  432. calCol2 = calCol - 7;
  433. gridObj.cellStyle("background-color", calRow, calCol2) = gridObj.cellStyle("background-color", calRow, calCol);
  434. model.refresh();
  435. }
  436. /* @group : 치료예약(재활)
  437. * @ver : 2007.05.18
  438. * @by : 이선경
  439. * @-----------------------------------
  440. * @type : function
  441. * @access : public
  442. * @desc : calendar 에서 선택한 년월일(YYYYMMDD)를 기준으로 예약시간대와 가용현황을 조회한다.
  443. */
  444. function getRsrvPossTm(gridObj) {
  445. if(model.getValue("/root/send/ioflag") == "") {
  446. messageBox("입원,외래중","C002");
  447. return;
  448. } else if(model.getValue("/root/send/excuroomcd") == "") {
  449. messageBox("치료실","C002");
  450. return;
  451. } else {
  452. //model.removeNodeset("");
  453. var calRow = gridObj.row;
  454. var calCol = gridObj.col;
  455. if( calCol >= 7 )
  456. calCol -= 7;
  457. var yyyy = model.getValue("/root/hidden/calendar/year");
  458. var mm = model.getValue("/root/hidden/calendar/month");
  459. var dd = model.getValue("/root/hidden/calendar/weeklist/list[" + calRow + "]/" + gridObj.colAttribute(calCol, "ref"));
  460. if (getStringLength(dd) == 1) {
  461. dd = "0" + dd;
  462. }
  463. model.setValue("/root/send/rsrvdd", yyyy + mm + dd);
  464. //model.refresh(); //20101001 주석
  465. if (getStringLength(model.getValue("/root/send/rsrvdd")) == 8) {
  466. //20101001 조건에따른 조회여부 수정 - 박재영
  467. if(model.getValue("/root/send/searchflag") == "true"){ //스켸쥴부분
  468. submit("TRAEA01904");
  469. //setCellColor(grd_calendar);
  470. }
  471. if(model.getValue("/root/init/autocheck") == "true"){ //예약일자 자동생성부분
  472. model.removeNodeset("/root/main/baseconfinfo/baseconflist");
  473. submit("TRAEA01907");
  474. setDelRsrvPresCondByMonth();
  475. }else{
  476. setCellColor(grd_calendar);
  477. }
  478. }
  479. //setCellColor(grd_calendar);
  480. }
  481. }
  482. /* @group : 치료예약(재활)
  483. * @ver : 2010.10.04
  484. * @by : 이선경
  485. * @-----------------------------------
  486. * @type : function
  487. * @access : public
  488. * @desc : 달력에 일자별로 가용현황을 보여준다.
  489. */
  490. function setDelRsrvPresCondByMonth() {
  491. grd_calendar.rebuildStyle();
  492. if(model.getValue("/root/init/autocheck") == "true"){ //예약일자 자동생성부분
  493. model.removeNodeset("/root/temp/rsrvyddlist/date");
  494. model.refresh();
  495. grd_temp2.addRow(false);
  496. model.setValue("/root/temp/rsrvyddlist/date/yyyymmdd",model.getValue("/root/send/rsrvdd"));
  497. }
  498. //예약일자선택에 해당 일자가 있으면 선택했을 때 색으로 표시
  499. for (var k = 1; k < grd_temp2.rows; k++) {
  500. var dd = model.getValue("/root/temp/rsrvyddlist/date[" + k + "]/yyyymmdd");
  501. var curDate = dd.substr(6,2);
  502. if (model.getValue("/root/hidden/calendar/month") == dd.substr(4, 2) ) {
  503. var curWeek = dd.toDate().getDayOfWeek("E").toLowerCase();
  504. var calRow = -1;
  505. var calCol = -1;
  506. if(curDate.substr(0,1) == "0") {
  507. curDate = curDate.substr(1,1);
  508. }
  509. switch (curWeek) {
  510. case "sun":
  511. calCol = 0;
  512. break;
  513. case "mon":
  514. calCol = 1;
  515. break;
  516. case "tue":
  517. calCol = 2;
  518. break;
  519. case "wed":
  520. calCol = 3;
  521. break;
  522. case "thu":
  523. calCol = 4;
  524. break;
  525. case "fri":
  526. calCol = 5;
  527. break;
  528. case "sat":
  529. calCol = 6;
  530. break;
  531. default:
  532. break;
  533. }
  534. for(var i = 1 ; i < grd_calendar.rows; i++ ) {
  535. //alert(model.getValue("/root/hidden/calendar/weeklist/list["+i+"]/"+curWeek) + "########" + curDate);
  536. if(model.getValue("/root/hidden/calendar/weeklist/list["+i+"]/"+curWeek) == curDate ) {
  537. calRow = i;
  538. }
  539. }
  540. var tmpCalCol;
  541. if( calCol < 7 )
  542. tmpCalCol = calCol + 7;
  543. else
  544. tmpCalCol = calCol - 7;
  545. //alert(calRow + "///" + calCol + "///" + tmpCalCol);
  546. grd_calendar.cellStyle("background-color", calRow, calCol) = "#daa7d9";
  547. grd_calendar.cellStyle("background-color", calRow, tmpCalCol) = "#daa7d9";
  548. }
  549. }
  550. }
  551. /* @group : 치료예약(재활)
  552. * @ver : 2007.05.18
  553. * @by : 이선경
  554. * @-----------------------------------
  555. * @type : function
  556. * @access : public
  557. * @desc : 달력에 일자별로 가용현황을 보여준다.
  558. */
  559. function setRsrvPresCondByMonth() {
  560. grd_calendar.rebuildStyle();
  561. //예약일자선택에 해당 일자가 있으면 선택했을 때 색으로 표시
  562. for (var k = 1; k < grd_temp2.rows; k++) {
  563. var dd = model.getValue("/root/temp/rsrvyddlist/date[" + k + "]/yyyymmdd");
  564. var curDate = dd.substr(6,2);
  565. if (model.getValue("/root/hidden/calendar/month") == dd.substr(4, 2) ) {
  566. var curWeek = dd.toDate().getDayOfWeek("E").toLowerCase();
  567. var calRow = -1;
  568. var calCol = -1;
  569. if(curDate.substr(0,1) == "0") {
  570. curDate = curDate.substr(1,1);
  571. }
  572. switch (curWeek) {
  573. case "sun":
  574. calCol = 0;
  575. break;
  576. case "mon":
  577. calCol = 1;
  578. break;
  579. case "tue":
  580. calCol = 2;
  581. break;
  582. case "wed":
  583. calCol = 3;
  584. break;
  585. case "thu":
  586. calCol = 4;
  587. break;
  588. case "fri":
  589. calCol = 5;
  590. break;
  591. case "sat":
  592. calCol = 6;
  593. break;
  594. default:
  595. break;
  596. }
  597. for(var i = 1 ; i < grd_calendar.rows; i++ ) {
  598. //alert(model.getValue("/root/hidden/calendar/weeklist/list["+i+"]/"+curWeek) + "########" + curDate);
  599. if(model.getValue("/root/hidden/calendar/weeklist/list["+i+"]/"+curWeek) == curDate ) {
  600. calRow = i;
  601. }
  602. }
  603. var tmpCalCol;
  604. if( calCol < 7 )
  605. tmpCalCol = calCol + 7;
  606. else
  607. tmpCalCol = calCol - 7;
  608. //alert(calRow + "///" + calCol + "///" + tmpCalCol);
  609. grd_calendar.cellStyle("background-color", calRow, calCol) = "#daa7d9";
  610. grd_calendar.cellStyle("background-color", calRow, tmpCalCol) = "#daa7d9";
  611. }
  612. }
  613. var curerid = grd_curer.valueMatrix(grd_curer.selectedRow(0), grd_curer.colRef("userid"));
  614. var curerrow = grd_curer.selectedRow(0);
  615. submit("TRAEA01902");
  616. model.removeNodeset("/root/main/baseconfinfo/baseconflist");
  617. submit("TRAEA01907");
  618. //20101001 조건에따른 조회여부 수정 - 박재영
  619. if(model.getValue("/root/send/searchflag") == "false"){
  620. //예약가용현황조회"/root/send/searchflag" 참조
  621. submit("TRAEA01904");
  622. }
  623. if (curerid != "") {
  624. var new_curerid = grd_curer.valueMatrix(curerrow, grd_curer.colRef("userid"));
  625. if (new_curerid == curerid) {
  626. grd_curer.row = curerrow;
  627. grd_curer.select(curerrow, grd_curer.colRef("usernm")) = true;
  628. }
  629. }
  630. var isMonth = model.getValue("/root/hidden/calendar/month");
  631. var isYear = model.getValue("/root/hidden/calendar/year");
  632. var isDate = (isYear+isMonth+1).toDate();
  633. var startDay = isDate.getDay();
  634. for (var i = 1; i < grd_temp.rows; i++) {
  635. var dd = model.getValue("/root/init/curerprescondlist/rsrvcalendar[" + i + "]/rsrvdd");
  636. var colidx = dd.toDate().getDay();
  637. var rowidx = Math.ceil( ( startDay + Number(dd.substr(6,2)) ) / 7 );
  638. grd_calendar.valueMatrix(rowidx, colidx+7) = model.getValue("/root/init/curerprescondlist/rsrvcalendar[" + i + "]/count");
  639. }
  640. fCalendar(isDate);
  641. }
  642. /* @group : 치료예약(재활)
  643. * @ver : 2007.05.31
  644. * @by : 이선경
  645. * @-----------------------------------
  646. * @type : function
  647. * @access : public
  648. * @desc : 예약, 수정, 취소 버튼의 click 이벤트 처리
  649. */
  650. function exeRsrvTransaction(str) {
  651. for (var i = 0; i < grd_prcpsubinfo.rows; i++) {
  652. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check") == "Y") {
  653. if ((str == "rsrv" || str == "upd") && (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/mig") == "Y")){
  654. messageBox("마이그레이션 자료는 예약변경이 불가능합니다. DC처리한 후 신규처방으로 처리하시기 바랍니다. \n 수납팀에 문의하시기 바랍니다.", "E999", "");
  655. return;
  656. }
  657. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/prcpdd",getRemoveFormatter(model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/prcpdd")));
  658. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd",getRemoveFormatter(model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd")));
  659. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm", model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm"));
  660. }
  661. }
  662. var nodeList = instance1.selectNodes("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[check='Y'and lvl='2']");
  663. var rCSV = getNodeListCSV(nodeList);
  664. //alert(rCSV);
  665. if ( rCSV == null ) {
  666. messageBox("처방내역을 ","C002");
  667. return "0";
  668. }
  669. var row = grd_rehbprcp.row;
  670. if (model.getValue("/root/main/rehbprcplist/rehbprcp[" + row + "]/ioflag") == "O"){
  671. var pid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + row + "]/pid");
  672. var orddd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + row + "]/orddd");
  673. var orddeptcd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + row + "]/orddeptcd");
  674. var orddrid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + row + "]/orddrid");
  675. /* 진료일 정보를 이용하여 이전 진단명이 존재 외래수진이력 조회 진단명이 없을 경우 */
  676. setParameter("preDiagCond", "Etc▦" + pid +"▦"+ orddd +"▦" + orddeptcd + "▦" + orddrid + "▦/root/hidden");
  677. fFindDiagInfo();
  678. if (model.getValue("/root/hidden/diaginfo/ordinfo/pid") != "") {
  679. var orddd_old = model.getValue("/root/hidden/diaginfo/ordinfo/orddd");
  680. var cretno_old = model.getValue("/root/hidden/diaginfo/ordinfo/cretno");
  681. var genrflagcd_old = "";
  682. var orddeptcd_old = model.getValue("/root/hidden/diaginfo/ordinfo/orddeptcd");
  683. var copyflag = "Y";
  684. for (var i =1; i < grd_prcpsubinfo.rows; i++) {
  685. var check = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check");
  686. var lvl = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/lvl");
  687. if (check == "Y" && lvl == "2" ) {
  688. model.makeValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/orddd_old", orddd_old);
  689. model.makeValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/cretno_old", cretno_old);
  690. model.makeValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/genrflagcd_old", model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/ioflag"));
  691. model.makeValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/orddeptcd_old", orddeptcd_old);
  692. model.makeValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/copyflag", copyflag);
  693. }
  694. }
  695. nodeList = instance1.selectNodes("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[check='Y'and lvl='2']");
  696. rCSV = getNodeListCSV(nodeList);
  697. }
  698. }
  699. model.setValue("/root/send/req/data", rCSV);
  700. model.setValue("/root/send/req/flag", str);
  701. //노드 초기화 : 결과 메세지가 계속 누적되는 오류 수정
  702. model.removeNodeset("/root/count");
  703. model.makeNode("/root/count");
  704. if (submit("TXAEA01901")){
  705. //model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  706. //model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  707. model.removeNodeset("/root/main/rehbprcpsubinfolist");
  708. model.refresh();
  709. // 미수납 건이 존재하면 경고메시지 출력, 20081208, 장준원
  710. if ( model.getValue("/root/count/rtn_message") != "-" && model.getValue("/root/count/rtn_message") != "" ) {
  711. messageBox(model.getValue("/root/count/rtn_message"),"I999");
  712. //alert(model.getValue("/root/temp/count/rtn_message"));
  713. }
  714. submit("TRAEA01905");
  715. //setTree(grd_prcpsubinfo, 1, 3, false);
  716. var flag = model.getValue("/root/init/treeflag");
  717. if (flag == "true") {
  718. setTree(grd_prcpsubinfo, 1, 3, true);
  719. } else {
  720. setTree(grd_prcpsubinfo, 1, 3, false);
  721. }
  722. //getRsrvPossTm(grd_calendar);
  723. grd_curer.select(grd_curer.selectedRow(0), grd_curer.colRef("usernm")) = false;
  724. //grd_calendar.rebuildStyle();
  725. getCurerPresCond();
  726. }
  727. }
  728. /* @group : 치료예약(재활)
  729. * @ver : 2007.05.31
  730. * @by : 이선경
  731. * @-----------------------------------
  732. * @type : function
  733. * @access : public
  734. * @desc : 해당 치료실의 치료사와 한달동안의 예약현황을 조회한다.
  735. */
  736. function getCurerPresCond() {
  737. model.removeNodeset("/root/main/rsrvposstmlist/rsrvposstm");
  738. model.setValue("/root/send/excuroomcd", model.getValue("/root/init/excuroomlist/excuroom[" + grd_excuroom.row + "]/basecd"));
  739. model.setValue("/root/send/rsrvdd", model.getValue("/root/hidden/calendar/year")+model.getValue("/root/hidden/calendar/month")+"01");
  740. setCalendar(model.getValue("/root/send/rsrvdd").toDate());
  741. //grd_calendar.rebuildStyle();
  742. //model.removeNodeset("/root/temp/rsrvyddlist/date");
  743. setRsrvPresCondByMonth();
  744. }
  745. function fsetRsrvYN() {
  746. model.setValue("/root/send/prcprem","");
  747. for(var i = 1; i < grd_rehbprcp.rows; i ++) {
  748. grd_rehbprcp.rowStyle(i, "data", "background-color") = "#ffffff"; //흰색깔
  749. if(model.getValue("/root/main/rehbprcplist/rehbprcp[" + i + "]/rsrvyn") == "Y") { //예약인경우
  750. grd_rehbprcp.rowstyle(i ,"data","color") = "#FF8C00"; //글자색을 주황색으로 표시
  751. }
  752. }
  753. //2013.02.19 by kya 진료비후불제 색깔 노란색으로 표시
  754. aezfSetRowStyle("grd_rehbprcp" , "15" , "V" , "aftrcptinfo" );
  755. model.refresh();
  756. }
  757. function fexeRsrvReport() {
  758. model.setValue("/root/send/popdata/pid",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row+ "]/pid"));
  759. model.setValue("/root/send/popdata/hngnm",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row+ "]/hngnm"));
  760. model.setValue("/root/send/popdata/sex",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row+ "]/sex"));
  761. modal("SPAEA01901", "", "", "" ,"SPAEA01901", "/root/send/popdata","/root/send/popdata");
  762. model.refresh();
  763. }
  764. /* @group : 치료예약(재활)
  765. * @ver : 2010.03.08
  766. * @by : 김건기
  767. * @-----------------------------------
  768. * @type : function
  769. * @access : public
  770. * @desc : 다학제간 환자 교육 연동
  771. */
  772. function fPateduSync() {
  773. var pid = "";
  774. var orddd = "";
  775. var cretno = "";
  776. var educd = "";
  777. var educnts = "";
  778. if (grd_rehbprcp.row > 0) {
  779. pid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid");
  780. orddd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/orddd");
  781. cretno = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/cretno");
  782. }
  783. setParameter("SPMRJ00200_pid", pid); // 수진키 필수
  784. setParameter("SPMRJ00200_orddd", orddd); // 수진키 필수
  785. setParameter("SPMRJ00200_cretno", cretno); // 수진키 필수
  786. setParameter("SPMRJ00200_educd", educd); // 교육항목 옵션
  787. setParameter("SPMRJ00200_educnts", educnts); // 교육내용 옵션
  788. modal("SPMRJ00200");
  789. }
  790. /* @group : 치료예약(재활)
  791. * @ver : 2010.03.08
  792. * @by : 김건기
  793. * @-----------------------------------
  794. * @type : function
  795. * @access : public
  796. * @desc : Care Plan 연동
  797. */
  798. function fCarePlanSync() {
  799. var pid = "";
  800. var orddd = "";
  801. var cretno = "";
  802. var hngnm = "";
  803. var ioflag = "";
  804. if (grd_rehbprcp.row > 0) {
  805. pid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid");
  806. orddd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/orddd");
  807. cretno = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/cretno");
  808. hngnm = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/hngnm");
  809. ioflag = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/ioflag");
  810. }
  811. setParameter("SMMRJ00100_pid", pid); // 수진키 필수
  812. setParameter("SMMRJ00100_orddd", orddd); // 수진키 필수
  813. setParameter("SMMRJ00100_cretno", cretno); // 수진키 필수
  814. setParameter("SMMRJ00100_hngnm", hngnm); // 수진키 필수
  815. setParameter("SMMRJ00100_ioflag", ioflag); // 수진키 필수
  816. modal("SMMRJ00100");
  817. }
  818. ]]>
  819. </script>
  820. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  821. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  822. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  823. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  824. <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
  825. <script type="javascript" src="../../../ast/examcureweb/js/combolist.js"/>
  826. <script type="javascript" src="../../../emr/carecomweb/js/CareCom.js"/>
  827. </xhtml:head>
  828. <xhtml:body guideline="1,1195;1,1195;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  829. <datagrid id="grd_prcpsubinfo" nodeset="/root/main/rehbprcpsubinfolist/rehbprcpsubinfo" caption="^level^처방일자^치료명^전체일^남은일^횟수^빈도^예약일자^시간^치료실^curoomcd^치료사^curerid^처방의^가예약^execprcpuniqno^prcpgenrflag^prcpkindcd^excupartcd^orddd^orddeptcd^orddrid^prcpcd^pid^actorddd^mig" colsep="^" colwidth="37, 30, 67, 213, 42, 42, 30, 50, 67, 35, 75, 100, 55, 70, 55, 42, 80, 80, 80, 80, 80, 80, 80, 80, 61, 100, 100" ellipsis="true" mergecellsfixedrows="bycolrec" rowsep="|" tooltip="true" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:295px; top:85px; width:752px; height:270px; ">
  830. <col checkvalue="Y,N" ref="check" type="checkbox"/>
  831. <col ref="lvl" visibility="hidden"/>
  832. <col ref="prcpdd" format="yyyy-mm-dd"/>
  833. <col ref="prcpnm"/>
  834. <col ref="prcpdayno"/>
  835. <col ref="rmnddayno"/>
  836. <col ref="prcptims"/>
  837. <col ref="rehbprcpcurefreqflagnm"/>
  838. <col ref="rsrvdd" type="input" format="yyyy-mm-dd"/>
  839. <col ref="rsrvtm" type="input" format="hh:nn"/>
  840. <col ref="curoom"/>
  841. <col ref="curoomcd" visibility="hidden" style="left:671px; top:23px; width:100px; height:23px; "/>
  842. <col ref="curer" style="left:700px; top:23px; width:100px; height:23px; "/>
  843. <col ref="curerid" visibility="hidden"/>
  844. <col ref="orddrnm"/>
  845. <col ref="orddrrsrvyn"/>
  846. <col ref="execprcpuniqno" visibility="hidden"/>
  847. <col ref="prcpgenrflag" visibility="hidden"/>
  848. <col ref="prcpkindcd" visibility="hidden"/>
  849. <col ref="excupartcd" visibility="hidden"/>
  850. <col ref="orddd" visibility="hidden"/>
  851. <col ref="orddeptcd" visibility="hidden"/>
  852. <col ref="orddrid" visibility="hidden"/>
  853. <col ref="prcpcd" visibility="hidden"/>
  854. <col ref="pid" visibility="hidden"/>
  855. <col ref="actorddd" visibility="hidden"/>
  856. <col ref="mig" visibility="hidden"/>
  857. <col ref="centcd" visibility="hidden"/>
  858. <script type="javascript" ev:event="onclick">
  859. <![CDATA[
  860. if( isDataCell() ){
  861. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + grd_prcpsubinfo.row + "]/lvl") == 1) {
  862. var check = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + grd_prcpsubinfo.row + "]/check");
  863. var prcpremfact = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo["+ grd_prcpsubinfo.row +"]/prcpdelivefact");
  864. tar_prcpremfact.value = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo["+ grd_prcpsubinfo.row +"]/prcpdelivefact");
  865. if (model.getValue("/root/init/baseinfo/initautoroom/A520[" + 1 + "]/cdid") == "Y"){
  866. irow = grd_prcpsubinfo.row + 1;
  867. var sroomcd = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + irow + "]/curoomcd");
  868. //model.setValue("/root/init/excuroomlist/excuroom/basecd", model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + irow + "]/curoomcd"));
  869. var krow = grd_excuroom.findRow(sroomcd, 1, grd_excuroom.colRef("basecd"), false, false);
  870. grd_excuroom.row = krow;
  871. //grd_excuroom.dispatch("onclick");
  872. model.removeNodeset("/root/temp/rsrvyddlist/date");
  873. getCurerPresCond();
  874. }
  875. for (var i = grd_prcpsubinfo.row + 1; i < grd_prcpsubinfo.rows; i++) {
  876. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/lvl") == 2) {
  877. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check", check);
  878. } else {
  879. return;
  880. }
  881. }
  882. } else {
  883. var colidx = grd_prcpsubinfo.col; //선택한 cell의 값
  884. //20101001 예약일자,시간 직접입력 가능하게 수정 - 박재영
  885. if(grd_prcpsubinfo.colAttribute(colidx, "ref") != "rsrvdd" && grd_prcpsubinfo.colAttribute(colidx, "ref") != "rsrvtm"){
  886. var curoom = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + grd_prcpsubinfo.row + "]/curoom");
  887. var curer = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + grd_prcpsubinfo.row + "]/curer");
  888. grd_excuroom.row = grd_excuroom.findRow(curoom);
  889. getCurerPresCond();
  890. grd_curer.row = grd_curer.findRow(curer);
  891. model.refresh();
  892. }
  893. }
  894. /*if (btn_bfrsrv.selected == true && model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + grd_prcpsubinfo.row + "]/check") == "N") {
  895. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("rsrvdd")) ="";
  896. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("rsrvtm")) ="";
  897. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("curoom")) ="";
  898. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("curoomcd")) ="";
  899. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("curer")) ="";
  900. grd_prcpsubinfo.valueMatrix(grd_prcpsubinfo.row, grd_prcpsubinfo.colRef("curerid")) ="";
  901. }*/
  902. }
  903. ]]>
  904. </script>
  905. </datagrid>
  906. <shape id="roundrect2" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:20px; width:1195px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
  907. <caption id="caption19" class="tit_1" style="left:0px; top:0px; width:106px; height:14px; background-image:../../../com/commonweb/images/tit_bullet1.gif; ">치료예약</caption>
  908. <caption id="caption5" class="search_name" style="left:8px; top:30px; width:112px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">조회기준일자 :</caption>
  909. <caption id="caption3" class="search_name" style="left:360px; top:30px; width:86px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">등록번호 :</caption>
  910. <line id="line2" class="line_1" style="x1:0; y1:81px; x2:281px; y2:81px; "/>
  911. <line id="line1" class="line_1" style="x1:295px; y1:81px; x2:1047px; y2:81px; "/>
  912. <caption id="caption22" class="tit_2" style="left:-113px; top:468px; width:138px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">환자이력</caption>
  913. <caption id="caption1" class="tit_2" style="left:295px; top:423px; width:87px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">치료실</caption>
  914. <line id="line4" class="line_1" style="x1:293px; y1:440px; x2:479px; y2:440px; "/>
  915. <line id="line5" class="line_1" style="x1:485px; y1:440px; x2:615px; y2:440px; "/>
  916. <caption id="caption4" class="tit_2" style="left:488px; top:423px; width:82px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">치료사</caption>
  917. <caption id="caption6" class="tit_2" style="left:1055px; top:579px; width:95px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">예약일자선택</caption>
  918. <line id="line6" class="line_1" style="x1:1055px; y1:595px; x2:1195px; y2:595px; "/>
  919. <caption id="caption7" class="tit_2" style="left:1055px; top:65px; width:95px; height:14px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">예약가용현황</caption>
  920. <line id="line7" class="line_1" style="x1:1055px; y1:80px; x2:1195px; y2:80px; "/>
  921. <button id="button61" class="icon_search" style="left:553px; top:30px; width:16px; height:16px; background-image:../../../com/commonweb/images/icon_search.gif; ">
  922. <caption/>
  923. <script type="javascript" ev:event="DOMActivate">
  924. <![CDATA[
  925. modal("SPPMC02500", "", "200", "200", "SPPMC02500","/root/send/pid","/root/main/send");
  926. //model.setValue("/root/hidden/source/hngnm", model.getValue("/root/main/patinfo/patinfolist/hngnm"));
  927. model.setValue("/root/send/pid", model.getValue("/root/main/patinfo/patinfolist/pid"));
  928. model.refresh();
  929. ]]>
  930. </script>
  931. </button>
  932. <button id="btn_sea" class="btn1_letter2" navindex="4" style="left:1130px; top:26px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn1_letter2.gif; ">
  933. <caption>조회</caption>
  934. <script type="javascript" ev:event="DOMActivate">
  935. <![CDATA[
  936. if(ipt_fromdd.value > ipt_todd.value){
  937. messageBox("조회시작일자가 조회종료일자보다 큽니다. 다시","C002");
  938. }
  939. if(model.getValue("/root/send/ioflag") =="") {
  940. model.setValue("/root/send/ioflag","I");
  941. btn_iprcp.selected= true;
  942. }
  943. grd_rehbprcp.rebuildStyle();
  944. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  945. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  946. submit("TRAEA01903");
  947. fsetRsrvYN();
  948. ]]>
  949. </script>
  950. </button>
  951. <button id="btn_can" class="btn4_letter2" disable.background-image="../../../com/commonweb/images/dis_btn4_letter2.gif" style="left:1139px; top:758px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn4_letter2.gif; ">
  952. <caption>취소</caption>
  953. <script type="javascript" ev:event="DOMActivate">
  954. <![CDATA[
  955. //2011.03.24 취소시 메세지 처리
  956. var message = messageBox("해당 예약을","Q007");
  957. if ( message == 6 ) {
  958. exeRsrvTransaction("cncl");
  959. }
  960. ]]>
  961. </script>
  962. </button>
  963. <group id="grp_calendar" scroll="auto" style="left:620px; top:440px; width:430px; height:40px; ">
  964. <shape id="rectangle1" class="calendar_header" appearance="rectangle" style="left:0px; top:0px; width:430px; height:40px; "/>
  965. <button id="button32" class="icon_next_year" style="left:300px; top:12px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_next_y.gif; ">
  966. <caption/>
  967. <script type="javascript" ev:event="DOMActivate">
  968. <![CDATA[
  969. var isMonth = model.getValue("/root/hidden/calendar/month");
  970. var isYear = model.getValue("/root/hidden/calendar/year");
  971. var isDate = (isYear+isMonth+1).toDate().getAddDate(1,'Y');
  972. model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
  973. model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
  974. model.refresh();
  975. if(model.getValue("/root/send/excuroomcd") == "") {
  976. messageBox("치료실","C002");
  977. return;
  978. }
  979. setCalendar(isDate);
  980. getCurerPresCond();
  981. ]]>
  982. </script>
  983. </button>
  984. <button id="btn_premonth" class="icon_pre_month" style="left:143px; top:12px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_pre_m.gif; ">
  985. <caption/>
  986. <script type="javascript" ev:event="DOMActivate">
  987. <![CDATA[
  988. var isMonth = model.getValue("/root/hidden/calendar/month");
  989. var isYear = model.getValue("/root/hidden/calendar/year");
  990. var isDate = (isYear+isMonth+1).toDate().getAddDate(-1,'M');
  991. model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
  992. model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
  993. model.refresh();
  994. if(model.getValue("/root/send/excuroomcd") == "") {
  995. messageBox("치료실","C002");
  996. return;
  997. }
  998. setCalendar(isDate);
  999. getCurerPresCond();
  1000. ]]>
  1001. </script>
  1002. </button>
  1003. <button id="button34" class="icon_next_month" style="left:281px; top:12px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_next_m.gif; ">
  1004. <caption/>
  1005. <script type="javascript" ev:event="DOMActivate">
  1006. <![CDATA[
  1007. var isMonth = model.getValue("/root/hidden/calendar/month");
  1008. var isYear = model.getValue("/root/hidden/calendar/year");
  1009. var isDate = (isYear+isMonth+1).toDate().getAddDate(1,'M');
  1010. model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
  1011. model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
  1012. model.refresh();
  1013. if(model.getValue("/root/send/excuroomcd") == "") {
  1014. messageBox("치료실","C002");
  1015. return;
  1016. }
  1017. setCalendar(isDate);
  1018. getCurerPresCond();
  1019. ]]>
  1020. </script>
  1021. </button>
  1022. <output id="opt_year" ref="/root/hidden/calendar/year" class="calendar_output" style="left:170px; top:9px; width:30px; height:19px; "/>
  1023. <output id="opt_month" ref="/root/hidden/calendar/month" class="calendar_output" style="left:220px; top:9px; width:30px; height:19px; "/>
  1024. <caption id="caption2" class="calendar_output" style="left:200px; top:9px; width:20px; height:19px; ">년</caption>
  1025. <caption id="caption8" class="calendar_output" style="left:250px; top:9px; width:20px; height:19px; ">월</caption>
  1026. <button id="button2" class="icon_pre_year" style="left:125px; top:12px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_pre_y.gif; ">
  1027. <caption/>
  1028. <script type="javascript" ev:event="DOMActivate">
  1029. <![CDATA[
  1030. var isMonth = model.getValue("/root/hidden/calendar/month");
  1031. var isYear = model.getValue("/root/hidden/calendar/year");
  1032. var isDate = (isYear+isMonth+1).toDate().getAddDate(-1,'Y');
  1033. model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
  1034. model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
  1035. model.refresh();
  1036. if(model.getValue("/root/send/excuroomcd") == "") {
  1037. messageBox("치료실","C002");
  1038. return;
  1039. }
  1040. setCalendar(isDate);
  1041. getCurerPresCond();
  1042. ]]>
  1043. </script>
  1044. </button>
  1045. </group>
  1046. <multilinegrid id="grd_calendar" nodeset="/root/hidden/calendar/weeklist/list" class="gridcalendar" autoresize="true" caption="일^월^화^수^목^금^토" colsep="^" colwidth="61, 61, 61, 61, 61, 61, 61" dataheight="20" focuscolor="transparent" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" mergecellsfixedrows="bycolrec" style="left:620px; top:480px; width:430px; height:275px; ">
  1047. <row>
  1048. <col class="color_sun" ref="sun" style="border-bottom-width:0px; "/>
  1049. <col ref="mon" style="border-bottom-width:0px; "/>
  1050. <col ref="tue" style="border-bottom-width:0px; "/>
  1051. <col ref="wed" style="border-bottom-width:0px; "/>
  1052. <col ref="thu" style="border-bottom-width:0px; "/>
  1053. <col ref="fri" style="border-bottom-width:0px; "/>
  1054. <col class="color_sat" ref="sat" style="border-bottom-width:0px; "/>
  1055. </row>
  1056. <row>
  1057. <col ref="sun_memo" type="input" style="border-top-width:0px; "/>
  1058. <col ref="mon_memo" type="input" style="border-top-width:0px; "/>
  1059. <col ref="tue_memo" type="input" style="border-top-width:0px; "/>
  1060. <col ref="wed_memo" type="input" style="border-top-width:0px; "/>
  1061. <col ref="thu_memo" type="input" style="border-top-width:0px; "/>
  1062. <col ref="fri_memo" type="input" style="border-top-width:0px; "/>
  1063. <col ref="sat_memo" type="input" style="border-top-width:0px; "/>
  1064. </row>
  1065. <script type="javascript" ev:event="onclick">
  1066. <![CDATA[
  1067. getRsrvPossTm(grd_calendar);
  1068. ]]>
  1069. </script>
  1070. <script type="javascript" ev:event="onrowchanged">
  1071. <![CDATA[
  1072. //setCellColor(grd_calendar);
  1073. ]]>
  1074. </script>
  1075. <script type="javascript" ev:event="oncolchanged">
  1076. <![CDATA[
  1077. //setCellColor(grd_calendar);
  1078. ]]>
  1079. </script>
  1080. </multilinegrid>
  1081. <datagrid id="grd_excuroom" nodeset="/root/init/excuroomlist/excuroom" visibility="visible" overflow="hidden" caption="치료실^caption1" colsep="^" colwidth="185, 100" mergecellsfixedrows="bycolrec" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:293px; top:444px; width:186px; height:310; ">
  1082. <col ref="basecdflagdesc"/>
  1083. <col ref="basecd" visibility="hidden"/>
  1084. <script type="javascript" ev:event="onclick">
  1085. <![CDATA[
  1086. if( isDataCell() ){
  1087. model.removeNodeset("/root/temp/rsrvyddlist/date");
  1088. //grd_calendar.rebuildStyle();
  1089. getCurerPresCond();
  1090. }
  1091. ]]>
  1092. </script>
  1093. </datagrid>
  1094. <datagrid id="grd_curer" nodeset="/root/init/curerprescondlist/curerprescond" visibility="visible" overflow="hidden" caption="치료사^caption1" colsep="^" colwidth="129, 100" mergecellsfixedrows="bycolrec" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:485px; top:444px; width:130px; height:310px; ">
  1095. <col ref="usernm"/>
  1096. <col ref="userid" visibility="hidden"/>
  1097. </datagrid>
  1098. <input id="ipt_pid" ref="/root/send/pid" class="input_search" navindex="3" style="left:450px; top:28px; width:100px; height:19px; ">
  1099. <script type="javascript" ev:event="onkeydown">
  1100. <![CDATA[
  1101. inputEnterKey("btn_sea","DOMActivate");
  1102. ]]>
  1103. </script>
  1104. </input>
  1105. <input id="ipt_fromdd" ref="/root/send/fromdd" class="input_search" navindex="1" inputtype="date" style="left:123px; top:28px; width:90px; height:19px; "/>
  1106. <input id="ipt_todd" ref="/root/send/todd" class="input_search" navindex="2" inputtype="date" style="left:218px; top:28px; width:90px; height:19px; "/>
  1107. <button id="btn_iprcp" class="btn_sw" group="tab1" selected="true" select.background-image="../../../com/commonweb/images/tab_show.gif" style="left:0px; top:59px; width:45px; height:22px; background-image:../../../com/commonweb/images/tab_hide.gif; ">
  1108. <caption>입원</caption>
  1109. <toggle case="case1" ev:event="onclick"/>
  1110. <script type="javascript" ev:event="DOMActivate">
  1111. <![CDATA[
  1112. //감염정보
  1113. model.makeValue("/root/hidden/isolinfo/isoldata", "");
  1114. grd_rehbprcp.rebuildStyle();
  1115. model.setValue("/root/send/ioflag","I");
  1116. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  1117. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  1118. //20160526 속도개선
  1119. if (model.getValue("/root/send/pid") == "" ) {
  1120. //if( ipt_todd.value - ipt_fromdd.value ){
  1121. //messageBox("조회시작일자가 조회종료일자보다 큽니다. 다시","C002");
  1122. if (( ipt_todd.value - ipt_fromdd.value) > 7 ) {
  1123. messageBox("등록번호 없이는 일주일이내만 조회됩니다. 다시","C002");
  1124. return
  1125. }
  1126. }
  1127. submit("TRAEA01903");
  1128. fsetRsrvYN();
  1129. ]]>
  1130. </script>
  1131. </button>
  1132. <button id="btn_bfrsrv" class="btn_sw" group="tab2" selected="true" select.background-image="../../../com/commonweb/images/tab_show.gif" style="left:295px; top:59px; width:72px; height:22px; background-image:../../../com/commonweb/images/tab_hide.gif; ">
  1133. <caption>미예약처방</caption>
  1134. <toggle case="case1" ev:event="onclick"/>
  1135. <script type="javascript" ev:event="DOMActivate">
  1136. <![CDATA[
  1137. model.setValue("/root/send/rsrvflag","bf");
  1138. model.removeNodeset("/root/main/rehbprcpsubinfolist");
  1139. model.refresh();
  1140. model.setValue("/root/send/subinfopid",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"));
  1141. model.setValue("/root/send/deptcd",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/deptcd"));
  1142. model.setValue("/root/send/ioflag",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/ioflag"));
  1143. if (model.getValue("/root/send/ioflag") == ""){
  1144. return;
  1145. }
  1146. submit("TRAEA01905");
  1147. // 아웃라인바(setTree 초기화)
  1148. setCollapsed(setCollapsed, false);
  1149. grd_prcpsubinfo.outlinebar = 0;
  1150. for(var k = 1; k < grd_prcpsubinfo.rows; k++) {
  1151. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + k + "]/lvl") == 1) {
  1152. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) == "") {
  1153. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curoom"));
  1154. }
  1155. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) == "") {
  1156. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curer"));
  1157. }
  1158. }
  1159. }
  1160. // sort
  1161. //grd_prcpsubinfo.colSort(grd_prcpsubinfo.colRef("prcpdd")) = "asc";
  1162. //grd_prcpsubinfo.sort(grd_prcpsubinfo.fixedRows, grd_prcpsubinfo.fixedCols, grd_prcpsubinfo.rows - 1, grd_prcpsubinfo.cols- 1) = "usersort";
  1163. //grd_prcpsubinfo.gridToInstance();
  1164. // setTree
  1165. var flag = model.getValue("/root/init/treeflag");
  1166. if (flag == "true") {
  1167. setTree(grd_prcpsubinfo, 1, 3, true);
  1168. } else {
  1169. setTree(grd_prcpsubinfo, 1, 3, false);
  1170. }
  1171. btn_upd.disabled = true;
  1172. btn_can.disabled = true;
  1173. ]]>
  1174. </script>
  1175. </button>
  1176. <button id="btn_allrsrv" class="btn_sw" group="tab2" selected="false" select.background-image="../../../com/commonweb/images/tab_show.gif" style="left:367px; top:59px; width:72px; height:22px; background-image:../../../com/commonweb/images/tab_hide.gif; ">
  1177. <caption>전체처방</caption>
  1178. <toggle case="case1" ev:event="onclick"/>
  1179. <script type="javascript" ev:event="DOMActivate">
  1180. <![CDATA[
  1181. model.setValue("/root/send/rsrvflag","all");
  1182. model.removeNodeset("/root/main/rehbprcpsubinfolist");
  1183. model.refresh();
  1184. if (model.getValue("/root/send/ioflag") == ""){
  1185. return;
  1186. }
  1187. submit("TRAEA01905");
  1188. // 아웃라인바(setTree 초기화)
  1189. setCollapsed(setCollapsed, false);
  1190. grd_prcpsubinfo.outlinebar = 0;
  1191. for(var k = 1; k < grd_prcpsubinfo.rows; k++) {
  1192. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + k + "]/lvl") == 1) {
  1193. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) == "") {
  1194. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curoom"));
  1195. }
  1196. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) == "") {
  1197. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curer"));
  1198. }
  1199. }
  1200. }
  1201. // sort
  1202. //grd_prcpsubinfo.colSort(grd_prcpsubinfo.colRef("prcpdd")) = "asc";
  1203. //grd_prcpsubinfo.sort(grd_prcpsubinfo.fixedRows, grd_prcpsubinfo.fixedCols, grd_prcpsubinfo.rows - 1, grd_prcpsubinfo.cols- 1) = "usersort";
  1204. //grd_prcpsubinfo.gridToInstance();
  1205. // setTree
  1206. var flag = model.getValue("/root/init/treeflag");
  1207. if (flag == "true") {
  1208. setTree(grd_prcpsubinfo, 1, 3, true);
  1209. } else {
  1210. setTree(grd_prcpsubinfo, 1, 3, false);
  1211. }
  1212. //btn_rsrv.disabled = true;
  1213. btn_upd.disabled = false;
  1214. btn_can.disabled = false;
  1215. ]]>
  1216. </script>
  1217. </button>
  1218. <datagrid id="grd_rsrvposstm" nodeset="/root/main/rsrvposstmlist/rsrvposstm" caption="시간^가용" colsep="^" colwidth="50, 53" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:1055px; top:85px; width:140px; height:330px; ">
  1219. <col ref="rsrvtm" format="hh:nn"/>
  1220. <col ref="count" style="text-align:center; "/>
  1221. <script type="javascript" ev:event="onclick">
  1222. <![CDATA[
  1223. if( isDataCell() ){
  1224. var nodeList = instance1.selectNodes("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[check='Y']");
  1225. var rCSV = getNodeListCSV(nodeList);
  1226. if (rCSV == null) {
  1227. messageBox("처방내역을 ","C002");
  1228. return "0";
  1229. }
  1230. var rsrvtm = model.getValue("/root/main/rsrvposstmlist/rsrvposstm[" + grd_rsrvposstm.row + "]/count");
  1231. var str = rsrvtm.split("/");
  1232. if (str[0] == str[1]) {
  1233. messageBox("가용인원을 ","E003");
  1234. return;
  1235. }
  1236. if (grd_curer.row < 1) {
  1237. messageBox("치료사를 " ,"C002");
  1238. return;
  1239. }
  1240. var curoom = model.getValue("/root/init/excuroomlist/excuroom[" + grd_excuroom.row + "]/basecdflagdesc");
  1241. var curoomcd = model.getValue("/root/init/excuroomlist/excuroom[" + grd_excuroom.row + "]/basecd");
  1242. var curer = model.getValue("/root/init/curerprescondlist/curerprescond[" + grd_curer.row + "]/usernm");
  1243. var curerid = model.getValue("/root/init/curerprescondlist/curerprescond[" + grd_curer.row + "]/userid");
  1244. var rsrvyyyymmdd = "";
  1245. var rsrvtm = model.getValue("/root/main/rsrvposstmlist/rsrvposstm[" + grd_rsrvposstm.row + "]/rsrvtm");
  1246. var idx = grd_temp2.topRow;
  1247. grd_temp2.sort(1, 1, grd_temp2.bottomRow, 1) = "asc";
  1248. grd_temp2.gridToInstance();
  1249. var k = 0;
  1250. var k1 = 0;
  1251. var k2 = 0;
  1252. var irow = 0;
  1253. var sdd = "";
  1254. var sdd1 = "";
  1255. var sdd2 = "";
  1256. for (var i = 0; i < grd_prcpsubinfo.rows; i++) {
  1257. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check") == "Y") {
  1258. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/lvl") == 2) {
  1259. if (model.getValue("/root/init/autocheck") == "true") { //예약일자 자동 생성
  1260. k = k + 1;
  1261. if (parseFloat(k) > parseFloat(k1)){
  1262. irow = irow + 1;
  1263. sdd = model.getValue("/root/main/baseconfinfo/baseconflist[" + irow + "]/basedd");
  1264. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd", sdd);
  1265. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm", rsrvtm);
  1266. k = 1;
  1267. }else{
  1268. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd", sdd);
  1269. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm", rsrvtm);
  1270. }
  1271. /*
  1272. if ( model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/ioflag") == "I") {
  1273. //입원은 처방일자와 동일
  1274. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd", model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/prcpdd"));
  1275. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm",rsrvtm);
  1276. } else {
  1277. //외래는 actorddd와 동일
  1278. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd", model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/actorddd"));
  1279. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm",rsrvtm);
  1280. }
  1281. */
  1282. } else {
  1283. rsrvyyyymmdd = model.getValue("/root/temp/rsrvyddlist/date[" + idx + "]/yyyymmdd");
  1284. if (rsrvyyyymmdd == "") {
  1285. //2010.11.29 수동예약시 선택한 일만큼 예약함 - 박재영
  1286. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check","N");
  1287. //messageBox("선택과 예약일자의 수가", "E004");
  1288. //return;
  1289. }else if (rsrvyyyymmdd < getCurrentDate()) {
  1290. messageBox("과거일자로 예약" ,"E001");
  1291. return;
  1292. }else{
  1293. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd",rsrvyyyymmdd);
  1294. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm",rsrvtm);
  1295. }
  1296. //2010.11.29 수동예약시 선택한 일만큼 예약함 else문으로 포함시킴 - 박재영
  1297. //model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvdd",rsrvyyyymmdd);
  1298. //model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/rsrvtm",rsrvtm);
  1299. if (idx == grd_temp2.bottomRow) {
  1300. //2010.11.29 수동예약시 선택한 일만큼 예약함. idx = grd_temp2.topRow;주석처리 - 박재영
  1301. //idx = grd_temp2.topRow;
  1302. idx += 1;
  1303. }else {
  1304. idx += 1;
  1305. }
  1306. }
  1307. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/curoom", curoom);
  1308. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/curoomcd", curoomcd);
  1309. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/curerid", curerid);
  1310. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/curer", curer);
  1311. } else if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/lvl") == 1) {
  1312. idx = grd_temp2.topRow;
  1313. k2 = model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/prcptims");
  1314. k1 = k2;
  1315. irow = 1;
  1316. k = 0;
  1317. sdd = model.getValue("/root/main/baseconfinfo/baseconflist[" + irow + "]/basedd");
  1318. }
  1319. }
  1320. }
  1321. model.refresh();
  1322. //btn_rsrv.disabled = false;
  1323. }
  1324. ]]>
  1325. </script>
  1326. </datagrid>
  1327. <datagrid id="grd_temp" nodeset="/root/init/curerprescondlist/rsrvcalendar" visibility="hidden" caption="일자(dd)^가용현황^caption3" colsep="^" colwidth="76, 62" mergecellsfixedrows="bycolrec" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:700px; top:570px; width:150px; height:170px; ">
  1328. <col ref="rsrvdd"/>
  1329. <col ref="count"/>
  1330. </datagrid>
  1331. <datagrid id="grd_rehbprcp" nodeset="/root/main/rehbprcplist/rehbprcp" caption="등록번호^환자명^병실^진료과^caption1^caption2^caption3^caption4^caption5^caption6^caption7^caption8^caption9^caption10^나이" colsep="^" colwidth="66, 67, 42, 67, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100" ellipsis="true" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" tooltip="true" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:0; top:85px; width:280px; height:669px; ">
  1332. <col ref="pid"/>
  1333. <col ref="hngnm"/>
  1334. <col ref="roomcd"/>
  1335. <col ref="depthngnm"/>
  1336. <col ref="deptcd" visibility="hidden"/>
  1337. <col ref="ioflag" visibility="hidden"/>
  1338. <col ref="orddd" visibility="hidden"/>
  1339. <col ref="orddrid" visibility="hidden"/>
  1340. <col ref="orddrnm" visibility="hidden"/>
  1341. <col ref="prcpgenrflag" visibility="hidden"/>
  1342. <col ref="rrgstno1" visibility="hidden"/>
  1343. <col ref="rrgstno2" visibility="hidden"/>
  1344. <col ref="rsrvyn" visibility="hidden"/>
  1345. <col ref="sex" visibility="hidden"/>
  1346. <col ref="age" visibility="hidden"/>
  1347. <col ref="aftrcptinfo" visibility="hidden"/>
  1348. <script type="javascript" ev:event="onclick">
  1349. <![CDATA[
  1350. if( isDataCell() ){
  1351. model.removeNodeset("/root/main/rehbprcpsubinfolist");
  1352. model.setValue("/root/send/prcprem","");
  1353. model.refresh();
  1354. if (grd_rehbprcp.isCell(event.target) && grd_rehbprcp.row >= grd_rehbprcp.fixedRows) {
  1355. model.setValue("/root/send/subinfopid",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"));
  1356. model.setValue("/root/send/deptcd",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/deptcd"));
  1357. model.setValue("/root/send/ioflag",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/ioflag"));
  1358. //setGlobalVariable("gv_pid", model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"), "A");
  1359. if (model.getValue("/root/send/rsrvflag") == "" ) {
  1360. model.setValue("/root/send/rsrvflag","bf");
  1361. }
  1362. if (model.getValue("/root/send/subinfopid") != "" && model.getValue("/root/send/deptcd") != "") {
  1363. submit("TRAEA01905",false);
  1364. model.setValue("/root/send/pid", "");
  1365. model.refresh();
  1366. // 아웃라인바(setTree 초기화)
  1367. setCollapsed(setCollapsed, false);
  1368. grd_prcpsubinfo.outlinebar = 0;
  1369. for(var k = 1; k < grd_prcpsubinfo.rows; k++) {
  1370. if (model.getValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + k + "]/lvl") == 1) {
  1371. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) == "") {
  1372. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curoom")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curoom"));
  1373. }
  1374. if(grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) == "") {
  1375. grd_prcpsubinfo.valueMatrix(k, grd_prcpsubinfo.colRef("curer")) = grd_prcpsubinfo.valueMatrix(k+1, grd_prcpsubinfo.colRef("curer"));
  1376. }
  1377. //20101001 예약일자,시간 직접입력 가능하게 수정 - 박재영
  1378. grd_prcpsubinfo.isReadOnly(k, 8, k, 9) =true;
  1379. }
  1380. }
  1381. // sort
  1382. //grd_prcpsubinfo.colSort(grd_prcpsubinfo.colRef("prcpdd")) = "asc";
  1383. //grd_prcpsubinfo.sort(grd_prcpsubinfo.fixedRows, grd_prcpsubinfo.fixedCols, grd_prcpsubinfo.rows - 1, grd_prcpsubinfo.cols- 1) = "usersort";
  1384. //grd_prcpsubinfo.gridToInstance();
  1385. // setTree
  1386. var flag = model.getValue("/root/init/treeflag");
  1387. if (flag == "true") {
  1388. setTree(grd_prcpsubinfo, 1, 3, true);
  1389. } else {
  1390. setTree(grd_prcpsubinfo, 1, 3, false);
  1391. }
  1392. model.setValue("/root/hidden/boolcontrol/bool", "");
  1393. }
  1394. }
  1395. //환자Comment 환자정보 조회
  1396. model.makeValue("/root/hidden/isolinfo/isoldata", "");
  1397. if (model.getValue("/root/main/rehbprcpsubinfolist/isolinfo/isoldispcd") != "") {
  1398. model.setValue("/root/hidden/isolinfo/isoldata", "확인");
  1399. }
  1400. //2011.1.3 c y w 환자예약중 다른환자 선택시 선택되어있던 예약일시 제거
  1401. model.removeNodeset("/root/temp/rsrvyddlist/date");
  1402. setDelRsrvPresCondByMonth();
  1403. model.refresh();
  1404. //btn_rsrv.disabled = true;
  1405. }
  1406. ]]>
  1407. </script>
  1408. <script type="javascript" ev:event="onaftersort">
  1409. <![CDATA[
  1410. grd_rehbprcp.gridToInstance();
  1411. ]]>
  1412. </script>
  1413. <script type="javascript" ev:event="DOMFocusOut">
  1414. <![CDATA[
  1415. initPopupMenu();
  1416. ]]>
  1417. </script>
  1418. <script type="javascript" ev:event="onmousedown">
  1419. <![CDATA[
  1420. if (event.button == 3) { // 3 : 오른쪽 버튼
  1421. if (grd_rehbprcp.isCell(event.target) && grd_rehbprcp.mouseRow >= grd_rehbprcp.fixedrows) {
  1422. // 2010.03.08 JCI 관련 다학제간/Care plan 연동 메뉴 추가 김건기
  1423. var jciyn = model.getValue("/root/send/jciyn");
  1424. if (jciyn == "Y") {
  1425. setPopupMenu("grd_rehbprcp", false, "/root/hidden/popmenu/jcilist/item", "name", "func");
  1426. } else {
  1427. setPopupMenu("grd_rehbprcp", false, "/root/hidden/popmenu/rsrvlist/item", "name", "func");
  1428. }
  1429. }
  1430. }
  1431. ]]>
  1432. </script>
  1433. </datagrid>
  1434. <datagrid id="grd_rsrvprescond" nodeset="/root/main/rehbprcpsubinfolist/rsrvprescond" caption="예약일자" colsep="^" colwidth="101" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:1055px; top:442px; width:140px; height:135px; ">
  1435. <col ref="rsrvday" format="yyyy-mm-dd"/>
  1436. </datagrid>
  1437. <button id="btn_rsrv" class="btn4_letter2" disable.background-image="../../../com/commonweb/images/dis_btn4_letter2.gif" style="left:1027px; top:758px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn4_letter2.gif; ">
  1438. <caption>예약</caption>
  1439. <script type="javascript" ev:event="DOMActivate">
  1440. <![CDATA[
  1441. exeRsrvTransaction("rsrv");
  1442. ]]>
  1443. </script>
  1444. </button>
  1445. <button id="btn_upd" class="btn4_letter2" disable.background-image="../../../com/commonweb/images/dis_btn4_letter2.gif" style="left:1083px; top:758px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn4_letter2.gif; ">
  1446. <caption>수정</caption>
  1447. <script type="javascript" ev:event="DOMActivate">
  1448. <![CDATA[
  1449. exeRsrvTransaction("upd");
  1450. ]]>
  1451. </script>
  1452. </button>
  1453. <bool id="bool1" checkvalue="true" ref="/root/init/autocheck" style="left:915px; top:421px; width:35px; height:20px; ">
  1454. <script type="javascript" ev:event="onclick">
  1455. <![CDATA[
  1456. // var gg = model.getValue("/root/init/autocheck");
  1457. // messageBox(gg);
  1458. // getCurerPresCond() ;
  1459. ]]>
  1460. </script>
  1461. <script type="javascript" ev:event="xforms-value-changed">
  1462. <![CDATA[
  1463. var autocheck = model.getValue("/root/init/autocheck");
  1464. if(autocheck == "true"){
  1465. model.removeNodeset("/root/temp/rsrvyddlist/date");
  1466. getCurerPresCond() ;
  1467. }
  1468. ]]>
  1469. </script>
  1470. </bool>
  1471. <caption id="caption9" style="left:945px; top:421px; width:102px; height:20px; ">예약일자 자동생성</caption>
  1472. <button id="btn_prt" class="btn6_letter6" style="left:327px; top:758px; width:104px; height:22px; ">
  1473. <caption>OCR서식출력</caption>
  1474. <script type="javascript" ev:event="DOMActivate">
  1475. <![CDATA[
  1476. aezfOcrListPrint("/root/main/rehbprcplist/rehbprcp", grd_rehbprcp.row, "pid", "orddd", "deptcd", "depthngnm", "orddrid", "orddrnm", "prcpgenrflag", "hngnm", "roomcd", "rrgstno1", "rrgstno2", "cretno");
  1477. ]]>
  1478. </script>
  1479. </button>
  1480. <datagrid id="grd_temp2" nodeset="/root/temp/rsrvyddlist/date" visibility="visible" caption="예약일자선택" colsep="^" colwidth="99" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:1055px; top:600px; width:140px; height:154px; ">
  1481. <col ref="yyyymmdd"/>
  1482. <script type="javascript" ev:event="onclick">
  1483. <![CDATA[
  1484. //20101004 클릭시 예약일자 삭제(달력포함) - 박재영
  1485. if( isDataCell() ){
  1486. deleteSelectedRows(grd_temp2,false);
  1487. setDelRsrvPresCondByMonth();
  1488. }
  1489. ]]>
  1490. </script>
  1491. </datagrid>
  1492. <output id="opt_patnm" ref="/root/main/patinfo/patinfolist/hngnm" class="output_fix" style="left:575px; top:29px; width:117px; height:19px; "/>
  1493. <select1 id="radio1" ref="/root/init/treeflag" appearance="full" cols="2" overflow="visible" style="left:443px; top:63px; width:175px; height:20px; border-style:none; ">
  1494. <choices>
  1495. <item>
  1496. <label>통합적 보기</label>
  1497. <value>true</value>
  1498. </item>
  1499. <item>
  1500. <label>세부적 보기</label>
  1501. <value>false</value>
  1502. </item>
  1503. </choices>
  1504. <script type="javascript" ev:event="xforms-value-changed">
  1505. <![CDATA[
  1506. var flag = model.getValue("/root/init/treeflag");
  1507. if (flag == "true") {
  1508. setTree(grd_prcpsubinfo, 1, 3, true);
  1509. } else {
  1510. setTree(grd_prcpsubinfo, 1, 3, false);
  1511. }
  1512. ]]>
  1513. </script>
  1514. </select1>
  1515. <caption id="caption10" class="tit_2" style="left:1055px; top:423px; width:82px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">예약현황</caption>
  1516. <line id="line3" class="line_1" style="x1:1055px; y1:439px; x2:1195px; y2:439px; "/>
  1517. <button id="button1" class="btn_sw" group="tab1" selected="false" select.background-image="../../../com/commonweb/images/tab_show.gif" style="left:45px; top:59px; width:45px; height:22px; background-image:../../../com/commonweb/images/tab_hide.gif; ">
  1518. <caption>외래</caption>
  1519. <toggle case="case1" ev:event="onclick"/>
  1520. <script type="javascript" ev:event="DOMActivate">
  1521. <![CDATA[
  1522. //감염정보
  1523. model.makeValue("/root/hidden/isolinfo/isoldata", "");
  1524. grd_rehbprcp.rebuildStyle();
  1525. model.setValue("/root/send/ioflag","O");
  1526. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  1527. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  1528. //20160526 속도개선
  1529. if (model.getValue("/root/send/pid") == "" ) {
  1530. //if( ipt_todd.value - ipt_fromdd.value ){
  1531. //messageBox("조회시작일자가 조회종료일자보다 큽니다. 다시","C002");
  1532. if (( ipt_todd.value - ipt_fromdd.value) > 7 ) {
  1533. messageBox("등록번호 없이는 일주일이내만 조회됩니다. 다시","C002");
  1534. return
  1535. }
  1536. }
  1537. submit("TRAEA01903");
  1538. fsetRsrvYN();
  1539. ]]>
  1540. </script>
  1541. </button>
  1542. <button id="button3" class="btn_sw" group="tab1" selected="false" select.background-image="../../../com/commonweb/images/tab_show.gif" style="left:90px; top:59px; width:45px; height:22px; background-image:../../../com/commonweb/images/tab_hide.gif; ">
  1543. <caption>전체</caption>
  1544. <toggle case="case1" ev:event="onclick"/>
  1545. <script type="javascript" ev:event="DOMActivate">
  1546. <![CDATA[
  1547. //감염정보
  1548. model.makeValue("/root/hidden/isolinfo/isoldata", "");
  1549. grd_rehbprcp.rebuildStyle();
  1550. model.setValue("/root/send/ioflag","");
  1551. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  1552. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  1553. //20160526 속도개선
  1554. if (model.getValue("/root/send/pid") == "" ) {
  1555. //if( ipt_todd.value - ipt_fromdd.value ){
  1556. //messageBox("조회시작일자가 조회종료일자보다 큽니다. 다시","C002");
  1557. if (( ipt_todd.value - ipt_fromdd.value) > 7 ) {
  1558. messageBox("등록번호 없이는 일주일이내만 조회됩니다. 다시","C002");
  1559. return
  1560. }
  1561. }
  1562. submit("TRAEA01903");
  1563. fsetRsrvYN();
  1564. ]]>
  1565. </script>
  1566. </button>
  1567. <button id="button4" class="btn3_letter7" style="left:0px; top:758px; width:128px; height:22px; ">
  1568. <caption>ProgressNote</caption>
  1569. <script type="javascript" ev:event="DOMActivate">
  1570. <![CDATA[
  1571. var pid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid");
  1572. var orddd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/orddd");
  1573. var cretno = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/cretno");
  1574. var ioflag = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/ioflag");
  1575. var orddeptcd = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/deptcd");
  1576. var orddrid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/orddrid");
  1577. var patnm = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/hngnm");
  1578. var age = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/age");
  1579. var sex = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/sex");
  1580. //var suppdeptcd = model.getValue("/root/send/globalinstance/instance1");
  1581. var suppdeptcd = model.getValue("/root/init/baseinfo/initsuppdeptcd/A530[" + 1 + "]/cdid");
  1582. // alert(pid+ "." +orddd+ "." +cretno+ "." +ioflag+ "." +orddeptcd+ "." +orddrid);
  1583. model.setValue("/root/send/pid",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid")); //progress note 호출시 pid로 넘겨야함
  1584. model.setValue("/root/send/orddeptcd",model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/deptcd"));
  1585. // 퇴원 후 제증명 발급을 위해 외래등록한 경우 외래 수진이력을 재 조회해서
  1586. // Progress Note에 외래 수진이력 넘기는 오류가 발생하여 주석처리함. 2009.07.17 김건기
  1587. // if(ioflag == "I") {
  1588. // submit("TRAER00109", false);
  1589. //
  1590. // pid = model.getValue("/root/send/pid");
  1591. // orddd = model.getValue("/root/temp/progressnote/list/orddd");
  1592. // cretno = model.getValue("/root/temp/progressnote/list/cretno");
  1593. // ioflag = model.getValue("/root/temp/progressnote/list/ioflag");
  1594. // orddeptcd = model.getValue("/root/temp/progressnote/list/orddeptcd");
  1595. // orddrid = model.getValue("/root/temp/progressnote/list/orddrid");
  1596. // patnm = "";
  1597. // age = "";
  1598. // sex = "";
  1599. // suppdeptcd = model.getValue("/root/send/globalinstance/instance1");
  1600. //
  1601. // model.setValue("/root/send/pid","");
  1602. // model.refresh();
  1603. //
  1604. // }
  1605. setParameter("SPMMR05400_parm_pinfo", pid + "▦" + orddd + "▦" + cretno + "▦" + ioflag + "▦" + orddeptcd + "▦" + orddrid +"▦"+ patnm + "▦" + age + "▦" + sex + "▦" + suppdeptcd );
  1606. // open("SPMMR05400", "", "", "" ,"SPMMR05400", "", "");
  1607. modal("SPMMR05400", "", "", "" ,"SPMMR05400", "", "");
  1608. ]]>
  1609. </script>
  1610. </button>
  1611. <datagrid id="datagrid3" nodeset="/root/init/calenlist/calendinfo" visibility="hidden" caption="caption1^caption2" colsep="^" colwidth="100, 100" mergecellsfixedrows="bycolrec" rowsep="|" style="left:305px; top:565px; width:220px; height:150px; ">
  1612. <col ref="basedd"/>
  1613. <col ref="dutflag"/>
  1614. </datagrid>
  1615. <button id="button5" class="btn3_letter6" style="left:117px; top:758px; width:104px; height:22px; ">
  1616. <caption>통합기록조회</caption>
  1617. <script type="javascript" ev:event="DOMActivate">
  1618. <![CDATA[
  1619. setParameter("SMMRI00400_param_pid", model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"));
  1620. setParameter("SMMRI00400_param_chosflag", model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/prcpgenrflag"));
  1621. //내원구분은 I O S E D 모두 가능
  1622. modal("SMMRI00400", "", "", "" ,"SMMMR01600", "", "");
  1623. ]]>
  1624. </script>
  1625. </button>
  1626. <select1 id="cmb_excuroom" ref="/root/send/retroomcd" class="combo_default" navindex="3" appearance="minimal" style="left:805px; top:28px; width:200px; height:19px; ">
  1627. <choices>
  1628. <itemset nodeset="/root/init/cmb_info/initexecroom">
  1629. <label ref="excuroomcdnm"/>
  1630. <value ref="excuroomcdid"/>
  1631. </itemset>
  1632. </choices>
  1633. <script type="javascript" ev:event="xforms-value-changed">
  1634. <![CDATA[
  1635. if(ipt_fromdd.value > ipt_todd.value){
  1636. messageBox("조회시작일자가 조회종료일자보다 큽니다. 다시","C002");
  1637. }
  1638. if(model.getValue("/root/send/ioflag") =="") {
  1639. model.setValue("/root/send/ioflag","I");
  1640. btn_iprcp.selected= true;
  1641. }
  1642. grd_rehbprcp.rebuildStyle();
  1643. model.removeNodeset("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo");
  1644. model.removeNodeset("/root/main/rehbprcpsubinfolist/rsrvprescond");
  1645. submit("TRAEA01903");
  1646. fsetRsrvYN();
  1647. ]]>
  1648. </script>
  1649. </select1>
  1650. <caption id="caption11" class="search_name" style="left:730px; top:30px; width:86px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">치료실 :</caption>
  1651. <button id="button6" class="btn3_letter6" style="left:432px; top:758px; width:104px; height:22px; ">
  1652. <caption>AlarmNotify</caption>
  1653. <script type="javascript" ev:event="DOMActivate">
  1654. <![CDATA[
  1655. //modal("SPAEA02000", "", "", "" ,"SPAEA02000", "", "");
  1656. openInternal("modeless_topmost","SPAEA02000","scn",1,1000,0,0,"","", "min;max:hidden;", 0);
  1657. ]]>
  1658. </script>
  1659. </button>
  1660. <bool id="bool2" ref="/root/hidden/boolcontrol/bool" style="left:304px; top:88px; width:20px; height:20px; ">
  1661. <script type="javascript" ev:event="xforms-select">
  1662. <![CDATA[
  1663. for (var i = 1; i < grd_prcpsubinfo.rows; i ++){
  1664. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check", "Y");
  1665. }
  1666. grd_prcpsubinfo.refresh();
  1667. ]]>
  1668. </script>
  1669. <script type="javascript" ev:event="xforms-deselect">
  1670. <![CDATA[
  1671. for (var i = 1; i < grd_prcpsubinfo.rows; i ++){
  1672. model.setValue("/root/main/rehbprcpsubinfolist/rehbprcpsubinfo[" + i + "]/check", "N");
  1673. }
  1674. grd_prcpsubinfo.refresh();
  1675. ]]>
  1676. </script>
  1677. </bool>
  1678. <datagrid id="datagrid1" nodeset="/root/main/baseconfinfo/baseconflist" visibility="hidden" caption="caption1^caption2" colsep="^" colwidth="81, 62" mergecellsfixedrows="bycolrec" rowsep="|" style="left:115px; top:505px; width:160px; height:230px; ">
  1679. <col ref="basedd"/>
  1680. <col ref="basecnt"/>
  1681. </datagrid>
  1682. <caption id="caption15" ref="/root/hidden/isolinfo/isoldata" visibility="visible" style="left:150px; top:60px; width:60px; height:20px; font-size:12pt; font-weight:bold; color:#ff0000; ">
  1683. <script type="javascript" ev:event="ondblclick">
  1684. <![CDATA[
  1685. group7.visible = true;
  1686. cpt_isoldata.visible = true;
  1687. txt_isol.visible = true;
  1688. btn_close.visible = true;
  1689. line_isol.visible = true;
  1690. line_isol2.visible = true;
  1691. cpt_isoltitle.visible = true;
  1692. ]]>
  1693. </script>
  1694. </caption>
  1695. <group id="group7" visibility="hidden" style="left:100px; top:100px; width:279px; height:119px; vertical-align:top; background-color:#080808; ">
  1696. <caption id="cpt_isoldata" visibility="hidden" style="left:2px; top:2px; width:275px; height:115px; font-size:11pt; font-weight:bold; color:#ff0000; background-color:#d6dadc; "/>
  1697. <button id="btn_close" class="btn5_letter2" visibility="hidden" style="left:227px; top:95px; width:42px; height:19px; ">
  1698. <caption>확인</caption>
  1699. <script type="javascript" ev:event="DOMActivate">
  1700. <![CDATA[
  1701. group7.visible = false;
  1702. cpt_isoldata.visible = false;
  1703. txt_isol.visible = false;
  1704. btn_close.visible = false;
  1705. line_isol.visible = false;
  1706. line_isol2.visible = false;
  1707. cpt_isoltitle.visible = false;
  1708. ]]>
  1709. </script>
  1710. </button>
  1711. <line id="line_isol" class="line_1" visibility="hidden" style="x1:10px; y1:21px; x2:270px; y2:21px; "/>
  1712. <line id="line_isol2" class="line_3" visibility="hidden" style="x1:10px; y1:93px; x2:270px; y2:93px; "/>
  1713. <textarea id="txt_isol" ref="/root/main/rehbprcpsubinfolist/isolinfo/isoldispcd" visibility="hidden" style="left:10px; top:26px; width:260px; height:66px; "/>
  1714. <caption id="cpt_isoltitle" class="tit_2" visibility="hidden" style="left:12px; top:7px; width:115px; height:13px; ">감염정보</caption>
  1715. </group>
  1716. <bool id="bool3" checkvalue="true" ref="/root/send/satdayflag" style="left:795px; top:421px; width:35px; height:20px; ">
  1717. <script type="javascript" ev:event="xforms-value-changed">
  1718. <![CDATA[
  1719. model.removeNodeset("/root/main/baseconfinfo/baseconflist");
  1720. submit("TRAEA01907");
  1721. model.refresh();
  1722. ]]>
  1723. </script>
  1724. </bool>
  1725. <caption id="caption12" style="left:825px; top:421px; width:102px; height:20px; ">토요일제외여부</caption>
  1726. <button id="btn_rsrvpaper" class="btn3_letter3" style="left:537px; top:758px; width:68px; height:22px; background-image:../../../com/commonweb/images/btn3_letter4.gif; ">
  1727. <caption>예약증</caption>
  1728. <script type="javascript" ev:event="DOMActivate">
  1729. <![CDATA[
  1730. if(model.getValue("/root/send/subinfopid") == "")
  1731. {
  1732. messageBox("환자를 선택하셔야 합니다.", "E");
  1733. return;
  1734. }
  1735. var ioflag = model.getValue("/root/send/ioflag");
  1736. var fromdd = model.getValue("/root/send/fromdd");
  1737. var todd = model.getValue("/root/send/todd");
  1738. //2011.05.02 입원환자 예약+10일까지 출력 - 박재영
  1739. if(ioflag == "O"){
  1740. //todd = model.getValue("/root/send/todd");
  1741. }else{
  1742. todd = fromdd.toDate().getAddDate(10,"D").getDateFormat("YYYYMMDD");
  1743. }
  1744. model.setValue("/root/send/rsrvpaper/fromdd", fromdd);
  1745. model.setValue("/root/send/rsrvpaper/todd", todd);
  1746. model.setValue("/root/send/rsrvpaper/pid", model.getValue("/root/send/subinfopid"));
  1747. model.setValue("/root/send/rsrvpaper/basesuppdeptcd", model.getValue("/root/send/globalinstance/instance1"));
  1748. submit("TRAEA01210");
  1749. model.makeValue("/root/main/rsrvlist/basesuppdeptcd", model.getValue("/root/send/globalinstance/instance1"));
  1750. model.makeValue("/root/main/rsrvlist/logoimg", getImageURL("biglogo"+getUserInfo("dutplceinstcd"), "jpg"));
  1751. // 2010.12.29 c y w
  1752. // exeReportPreview("RPAEA05200","XMLSTR");
  1753. exeReportPreview("RPAEA05200", "XMLSTR" , "" , "" , "true" , "", "", "", "", "true");
  1754. ]]>
  1755. </script>
  1756. </button>
  1757. <line id="line11" class="line_1" style="x1:295px; y1:376px; x2:1047px; y2:376px; "/>
  1758. <textarea id="tar_prcpremfact" ref="/root/send/prcprem" editable="false" style="left:295px; top:380px; width:752px; height:35px; "/>
  1759. <caption id="caption13" class="tit_2" style="left:295px; top:360px; width:125px; height:13px; background-image:../../../com/commonweb/images/tit_bullet2.gif; ">처방 comment</caption>
  1760. <button id="button8" class="btn3_letter4" style="left:607px; top:758px; width:80px; height:22px; background-image:../../../com/commonweb/images/btn3_letter4.gif; ">
  1761. <caption>일괄반환</caption>
  1762. <script type="javascript" ev:event="DOMActivate">
  1763. <![CDATA[
  1764. if ( grd_rehbprcp.row > 0 ) {
  1765. var sexage = model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/sex") + "/" + model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/age");
  1766. var rrgstno = model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/rrgstno1") +" /" +model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/rrgstno2");
  1767. model.makeValue("/root/temp/totaldclist/patinfolist/pid", model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/pid"));
  1768. model.makeValue("/root/temp/totaldclist/patinfolist/sexage", sexage);
  1769. model.makeValue("/root/temp/totaldclist/patinfolist/hngnm", model.getValue("/root/main/rehbprcplist/rehbprcp["+grd_rehbprcp.row+"]/hngnm"));
  1770. model.makeValue("/root/temp/totaldclist/patinfolist/rrgstno", rrgstno);
  1771. modal("SPAEA01201","","","","","/root/temp/totaldclist/patinfolist","/root/temp/patinfolist");
  1772. }
  1773. ]]>
  1774. </script>
  1775. </button>
  1776. <button id="button7" class="btn3_letter4" style="left:770px; top:758px; width:80px; height:22px; background-image:../../../com/commonweb/images/btn3_letter4.gif; ">
  1777. <caption>접수관리</caption>
  1778. <script type="javascript" ev:event="DOMActivate">
  1779. <![CDATA[
  1780. //navigate("SMAEA01200_접수관리(재활)");
  1781. model.makeNode("/root/senda/pid");
  1782. if (grd_rehbprcp.row > 0){
  1783. model.setValue("/root/senda/pid", model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"));
  1784. }
  1785. open("SMAEA01200", "","","", "SMAEA01200", "/root/senda/pid","/root/send/data/srchpid");
  1786. // modal("SMAEA01200", "","","", "SMAEA01200", "/root/senda/pid","/root/send/data/srchpid");
  1787. ]]>
  1788. </script>
  1789. </button>
  1790. <button id="button9" class="btn3_letter4" style="left:689px; top:758px; width:80px; height:22px; background-image:../../../com/commonweb/images/btn3_letter4.gif; ">
  1791. <caption>예약현황</caption>
  1792. <script type="javascript" ev:event="DOMActivate">
  1793. <![CDATA[
  1794. model.makeNode("/root/senda/pid");
  1795. if (grd_rehbprcp.row > 0){
  1796. model.setValue("/root/senda/pid", model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid"));
  1797. }
  1798. open("SMAEA04100", "","","", "SMAEA04100", "/root/senda/pid","/root/send/srchpid");
  1799. ]]>
  1800. </script>
  1801. </button>
  1802. <button id="btn_patedu" class="btn3_letter4" visibility="hidden" style="left:852px; top:758px; width:80px; height:22px; ">
  1803. <caption>환자교육</caption>
  1804. <script type="javascript" ev:event="DOMActivate">
  1805. <![CDATA[
  1806. //다학제간 환자 교육 연동
  1807. fPateduSync();
  1808. ]]>
  1809. </script>
  1810. </button>
  1811. <button id="btn_careplan" class="btn3_letter5" visibility="hidden" style="left:934px; top:758px; width:92px; height:22px; ">
  1812. <caption>Care Plan</caption>
  1813. <script type="javascript" ev:event="DOMActivate">
  1814. <![CDATA[
  1815. //Care Plan 연동
  1816. fCarePlanSync();
  1817. ]]>
  1818. </script>
  1819. </button>
  1820. <button id="button10" class="btn3_letter6" style="left:222px; top:758px; width:80px; height:22px; ">
  1821. <caption>환자진료정보</caption>
  1822. <script type="javascript" ev:event="DOMActivate">
  1823. <![CDATA[
  1824. var pid = model.getValue("/root/main/rehbprcplist/rehbprcp[" + grd_rehbprcp.row + "]/pid");
  1825. setParameter ( "SMMMO02500_cond" , pid);
  1826. open("SMMMO02500", 2, "0", "0", "SMMMO02500", "", "/root/init/srchcond2");
  1827. ]]>
  1828. </script>
  1829. </button>
  1830. <bool id="bool4" checkvalue="true" ref="/root/send/searchflag" style="left:660px; top:421px; width:35px; height:20px; ">
  1831. <script type="javascript" ev:event="xforms-value-changed">
  1832. <![CDATA[
  1833. ]]>
  1834. </script>
  1835. </bool>
  1836. <caption id="caption14" style="left:690px; top:421px; width:100px; height:20px; ">예약가용현황조회</caption>
  1837. <shape id="rectangle3" appearance="rectangle" style="left:645px; top:60px; width:20px; height:15px; background-color:#ffff00; "/>
  1838. <caption id="caption27" style="left:670px; top:60px; width:34px; height:15px; ">VIP</caption>
  1839. </xhtml:body>
  1840. </xhtml:html>