123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
- <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">
- <xhtml:head>
- <xhtml:title>Angio 일정조회</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <send>
- <opdd/>
- <globalinstance>
- <instance1/>
- </globalinstance>
- </send>
- <init>
- <curerprescondlist>
- <opcalendar>
- <opdd/>
- <count/>
- </opcalendar>
- </curerprescondlist>
- </init>
- <hidden>
- <calendar>
- <year/>
- <month/>
- <weeklist>
- <list>
- <sun/>
- <mon/>
- <tue/>
- <wed/>
- <thu/>
- <fri/>
- <sat/>
- <sun_memo/>
- <mon_memo/>
- <tue_memo/>
- <wed_memo/>
- <thu_memo/>
- <fri_memo/>
- <sat_memo/>
- </list>
- </weeklist>
- <dd/>
- </calendar>
- <grdcellcolor>
- <calrow/>
- <calcol/>
- </grdcellcolor>
- <count/>
- </hidden>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- initCalendar();
- setCurrentDate();
- //20101011 해당근무지에 따라 타이틀 변경 - 박재영
- var dutplcenm = getUserInfo("dutplcenm");
- document.title = dutplcenm + " 수술일정조회";
- caption1.text = dutplcenm + " 수술일정조회";
- ]]>
- </script>
- <!--예약가용인원 조회-->
- <submission id="TRAEA02404" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/init/curerprescondlist"/>
- </model>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
- <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
- <script type="javascript">
- <![CDATA[
- // 달력 초기화
- function initCalendar() {
- aezfSetSuppDeptcd();
-
- var curDate = getCurrentDate().toDate();
-
- model.setValue("/root/hidden/calendar/year", curDate.getDateFormat('YYYY'));
- model.setValue("/root/hidden/calendar/month", curDate.getDateFormat('MM'));
- model.refresh();
- setCalendar(curDate);
- }
-
- // 달력 setting
- function setCalendar(dateObj) {
-
- // 그리드 초기화
- model.removeNodeset("/root/hidden/calendar/weeklist/list");
- //model.removeNodeset("/root/init/curerprescondlist/rsrvcalendar");
- //grd_calendar.rebuild();
-
- dateObj.setDate(1);
- var startDay = dateObj.getDay();
- var days = dateObj.getMonthDay();
-
- var rows = Math.ceil( ( startDay + days ) / 7 );
- for( var i = 0; i < rows; i++ )
- grd_calendar.addRow(false);
-
- grd_calendar.rebuild();
- var rowIndex = grd_calendar.fixedRows;
- var colIndex = startDay;
- for( var i = 1; i <= days; i++ ) {
- grd_calendar.valueMatrix(rowIndex, colIndex) = i;
- //grd_calendar.valueMatrix(rowIndex, colIndex + 7) = "일정: 0";
- colIndex++;
- if( colIndex == 7 ) {
- colIndex = 0;
- rowIndex++;
- }
- }
-
- //model.setValue("/root/send/rsrvdd",model.getValue("/root/hidden/calendar/year")+model.getValue("/root/hidden/calendar/month")+"01");
-
- setRsrvPresCondByMonth();
-
- }
-
- /* @group : 접수관리(기능검사)
- * @ver : 2007.08.10
- * @by : 임헤정
- * @-----------------------------------
- * @type : function
- * @access : public
- * @desc : 오늘날짜 달력에 표시
- */
- function setCurrentDate() {
-
- var curDate = getCurrentDate().substr(6,2); //오늘날짜
- var curWeek = getCurrentDate().toDate().getDayOfWeek("E").toLowerCase(); //오늘요일
- if(curDate <10) {
- curDate= curDate.substr(1,1);
- }
-
- if(curWeek == "sun")
- model.setValue("/root/hidden/grdcellcolor/calcol",0);
- if(curWeek == "mon")
- model.setValue("/root/hidden/grdcellcolor/calcol",1);
- if(curWeek == "tue")
- model.setValue("/root/hidden/grdcellcolor/calcol",2);
- if(curWeek == "wed")
- model.setValue("/root/hidden/grdcellcolor/calcol",3);
- if(curWeek == "thu")
- model.setValue("/root/hidden/grdcellcolor/calcol",4);
- if(curWeek == "fri")
- model.setValue("/root/hidden/grdcellcolor/calcol",5);
- if(curWeek == "sat")
- model.setValue("/root/hidden/grdcellcolor/calcol",6);
-
- for(var i = 0 ; i <grd_calendar.rows; i++ ) {
- if(model.getValue("/root/hidden/calendar/weeklist/list["+i+"]/"+curWeek) == curDate ) {
- model.setValue("/root/hidden/grdcellcolor/calrow",i);
-
- }
- }
-
- setCellColor(grd_calendar)
- }
-
-
- function setCellColor(gridObj) {
-
- var calRow = 0;
- var calCol = 0;
-
- calRow = Number(model.getValue("/root/hidden/grdcellcolor/calrow"));
- calCol = Number(model.getValue("/root/hidden/grdcellcolor/calcol"));
-
-
- gridObj.rebuildStyle();
-
- gridObj.cellStyle("background-color", calRow, calCol) = "#daa7d9";
-
- if( calCol < 7 )
- calCol += 7;
- else
- calCol -= 7;
-
- gridObj.cellStyle("background-color", calRow, calCol) = "#daa7d9";
-
- }
-
- /* @group : 치료예약(재활)
- * @ver : 2007.05.18
- * @by : 이선경
- * @-----------------------------------
- * @type : function
- * @access : public
- * @desc : 달력에 일자별로 일정현황을 보여준다.
- */
- function setRsrvPresCondByMonth() {
- submit("TRAEA02404");
-
- var isMonth = model.getValue("/root/hidden/calendar/month");
- var isYear = model.getValue("/root/hidden/calendar/year");
- var isDate = (isYear+isMonth+1).toDate();
- var startDay = isDate.getDay();
-
- for (var i = 1; i < grd_temp.rows; i++) {
- var dd = model.getValue("/root/init/curerprescondlist/opcalendar[" + i + "]/opdd");
- var _year = dd.substr(0, 4);
- var _month = dd.substr(4, 2);
-
- if ( _year != isYear || _month != isMonth)
- continue;
-
- var colidx = dd.toDate().getDay();
- var rowidx = Math.ceil( ( startDay + Number(dd.substr(6,2)) ) / 7 );
- grd_calendar.valueMatrix(rowidx, colidx+7) = "일정: " + model.getValue("/root/init/curerprescondlist/opcalendar[" + i + "]/count");
- }
- }
-
- /* @group : Angio일정조회
- * @ver : 2007.09.27
- * @by : 조원영
- * @-----------------------------------
- * @type : function
- * @access : public
- * @desc : 달력에서 선택한 날짜에 대한 Angio 검사현황 조회
- */
-
- function getAngioSche(gridObj) {
-
- var calRow = model.getValue("/root/hidden/grdcellcolor/calrow");
- var calCol = model.getValue("/root/hidden/grdcellcolor/calcol");
-
- if( calCol >= 7 )
- calCol -= 7;
-
- var yyyy = model.getValue("/root/hidden/calendar/year");
- var mm = model.getValue("/root/hidden/calendar/month");
- var dd = model.getValue("/root/hidden/calendar/weeklist/list[" + calRow + "]/" + gridObj.colAttribute(calCol, "ref"));
- if (getStringLength(dd) == 1) {
- dd = "0" + dd;
- }
-
- model.setValue("/root/send/opdd", yyyy + mm + dd);
- open("SMAEA02400", "", "50", "50", "SMAEA02400", "/root/send/opdd", "/root/send/frdt");
- }
-
- /* @group : Angio일정조회
- * @ver : 2007.09.27
- * @by : 조원영
- * @-----------------------------------
- * @type : function
- * @access : public
- * @desc : 달력에서 선택한 날짜에 대한 Angio 일정 등록
- */
-
- function insAngioSche(gridObj) {
-
- var calRow = model.getValue("/root/hidden/grdcellcolor/calrow");
- var calCol = model.getValue("/root/hidden/grdcellcolor/calcol");
-
- if( calCol >= 7 )
- calCol -= 7;
-
- var yyyy = model.getValue("/root/hidden/calendar/year");
- var mm = model.getValue("/root/hidden/calendar/month");
- var dd = model.getValue("/root/hidden/calendar/weeklist/list[" + calRow + "]/" + gridObj.colAttribute(calCol, "ref"));
- if (getStringLength(dd) == 1) {
- dd = "0" + dd;
- }
-
- model.setValue("/root/send/opdd", yyyy + mm + dd);
- modal("SPAEA00400", "","300","250", "SPAEA00400", "/root/send/opdd","/root/send/data/opdd");
- }
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="405" pageheight="370" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <caption id="caption1" class="tit_2" style="left:5px; top:10px; width:375px; height:13px; ">Angio일정조회</caption>
- <line id="line1" class="line_1" style="x1:0px; y1:26px; x2:387px; y2:26px; "/>
- <group id="grp_calendar" scroll="auto" style="left:0px; top:31px; width:387px; height:291px; ">
- <shape id="rectangle2" class="calendar_header" appearance="rectangle" style="left:0px; top:0px; width:387px; height:25px; "/>
- <button id="btn_preyear" class="icon_pre_year" style="left:48px; top:5px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_pre_y.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var isMonth = model.getValue("/root/hidden/calendar/month");
- var isYear = model.getValue("/root/hidden/calendar/year");
- var isDate = (isYear+isMonth+1).toDate().getAddDate(-1,'Y');
- model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
- model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
- model.refresh();
- setCalendar(isDate);
- ]]>
- </script>
- </button>
- <button id="btn_premonth" class="icon_pre_month" style="left:66px; top:5px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_pre_m.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var isMonth = model.getValue("/root/hidden/calendar/month");
- var isYear = model.getValue("/root/hidden/calendar/year");
- var isDate = (isYear+isMonth+1).toDate().getAddDate(-1,'M');
- model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
- model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
- model.refresh();
- setCalendar(isDate);
- ]]>
- </script>
- </button>
- <button id="btn_nextmonth" class="icon_next_month" style="left:304px; top:5px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_next_m.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var isMonth = model.getValue("/root/hidden/calendar/month");
- var isYear = model.getValue("/root/hidden/calendar/year");
- var isDate = (isYear+isMonth+1).toDate().getAddDate(1,'M');
- model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
- model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
- model.refresh();
- setCalendar(isDate);
- ]]>
- </script>
- </button>
- <button id="btn_nextyear" class="icon_next_year" style="left:322px; top:5px; width:16px; height:16px; background-image:../../../com/commonweb/images/cal_next_y.gif; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var isMonth = model.getValue("/root/hidden/calendar/month");
- var isYear = model.getValue("/root/hidden/calendar/year");
- var isDate = (isYear+isMonth+1).toDate().getAddDate(1,'Y');
- model.setValue("/root/hidden/calendar/year", isDate.getDateFormat('YYYY'));
- model.setValue("/root/hidden/calendar/month", isDate.getDateFormat('MM'));
- model.refresh();
-
- setCalendar(isDate);
- ]]>
- </script>
- </button>
- <output id="opt_year" ref="/root/hidden/calendar/year" class="calendar_output" style="left:130px; top:3px; width:30px; height:19px; "/>
- <output id="opt_month" ref="/root/hidden/calendar/month" class="calendar_output" style="left:203px; top:3px; width:30px; height:19px; "/>
- <caption id="caption15" class="calendar_output" style="left:163px; top:3px; width:20px; height:19px; ">년</caption>
- <caption id="caption18" class="calendar_output" style="left:236px; top:3px; width:20px; height:19px; ">월</caption>
- <multilinegrid id="grd_calendar" nodeset="/root/hidden/calendar/weeklist/list" class="gridcalendar" autoresize="true" caption="일^월^화^수^목^금^토" colsep="^" colwidth="55, 55, 55, 55, 55, 55, 55" dataheight="20" focuscolor="transparent" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" mergecellsfixedrows="bycolrec" style="left:0px; top:26px; width:387px; height:265px; ">
- <row>
- <col class="color_sun" ref="sun" style="border-bottom-width:0px; "/>
- <col ref="mon" style="border-bottom-width:0px; "/>
- <col ref="tue" style="border-bottom-width:0px; "/>
- <col ref="wed" style="border-bottom-width:0px; "/>
- <col ref="thu" style="border-bottom-width:0px; "/>
- <col ref="fri" style="border-bottom-width:0px; "/>
- <col class="color_sat" ref="sat" style="border-bottom-width:0px; "/>
- </row>
- <row>
- <col ref="sun_memo" style="border-top-width:0px; "/>
- <col ref="mon_memo" style="border-top-width:0px; "/>
- <col ref="tue_memo" style="border-top-width:0px; "/>
- <col ref="wed_memo" style="border-top-width:0px; "/>
- <col ref="thu_memo" style="border-top-width:0px; "/>
- <col ref="fri_memo" style="border-top-width:0px; "/>
- <col ref="sat_memo" style="border-top-width:0px; "/>
- </row>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- model.setValue("/root/hidden/grdcellcolor/calrow",grd_calendar.row);
- model.setValue("/root/hidden/grdcellcolor/calcol",grd_calendar.col);
-
- setCellColor(grd_calendar);
- getAngioSche(grd_calendar);
-
- model.refresh();
- ]]>
- </script>
- <script type="javascript" ev:event="onrowchanged">
- <![CDATA[
- model.setValue("/root/hidden/grdcellcolor/calrow",grd_calendar.row);
- model.setValue("/root/hidden/grdcellcolor/calcol",grd_calendar.col);
-
- setCellColor(grd_calendar);
- ]]>
- </script>
- <script type="javascript" ev:event="oncolchanged">
- <![CDATA[
- model.setValue("/root/hidden/grdcellcolor/calrow",grd_calendar.row);
- model.setValue("/root/hidden/grdcellcolor/calcol",grd_calendar.col);
-
- setCellColor(grd_calendar);
- ]]>
- </script>
- </multilinegrid>
- <datagrid id="grd_temp" nodeset="/root/init/curerprescondlist/opcalendar" visibility="hidden" caption="일자(dd)^인원현황" colsep="^" colwidth="76, 62" mergecellsfixedrows="bycolrec" rowsep="|" fixed.background-image="../../../com/commonweb/images/grid_bg.gif" style="left:115px; top:100px; width:145px; height:170px; ">
- <col ref="opdd"/>
- <col ref="count"/>
- </datagrid>
- </group>
- <!--line id="line2" class="line_3" style="x1:0px; y1:323px; x2:352px; y2:323px; "/-->
- <group id="grp_btn" scroll="auto" style="left:0px; top:327px; width:387px; height:23px; ">
- <button id="button91" class="btn6_letter4" style="left:0px; top:0px; width:80px; height:22px; ">
- <caption>일정등록</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- insAngioSche(grd_calendar);
- model.refresh();
- ]]>
- </script>
- </button>
- <button id="button2" class="btn4_letter2" style="left:330px; top:0px; width:56px; height:22px; ">
- <caption>닫기</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- window.close();
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|