123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510 |
- <?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>동의서 중분류별 통계</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <indxlist>
- <indxlist>
- <orddd/>
- <fstprntdt/>
- <inorddeptnm/>
- <pid/>
- <hngnm/>
- <formnm/>
- <statcd/>
- </indxlist>
- </indxlist>
- </main>
- <send>
- <fromdd/>
- <todd/>
- <itemindxseq/>
- <formcd/>
- <supitemindxseq/>
- <reqdata/>
- </send>
- <temp>
- <indxinfo>
- <indxnm/>
- <itemindxseq/>
- </indxinfo>
- </temp>
- <temp2>
- <forminfo>
- <itemlist>
- <formnm/>
- <formcd/>
- </itemlist>
- </forminfo>
- </temp2>
- <templer>
- </templer>
- <inputSelectValue/>
- <inputSelectValue2/>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- model.setValue("/root/send/fromdd", getCurrentDate());
- model.setValue("/root/send/todd", getCurrentDate());
-
- mmbfGetHardCodeInfo("/root/send/reqdata", "/root/templer", 5506);
- model.setValue("/root/send/supitemindxseq", model.getValue("/root/templer/hardcd/hardcd"));
- submit("TRMRS02101");
-
- fGetFormlist("root/send/reqdata", "/root/temp2/forminfo", "OCR,OCR(CODE),OCR(PROG)", getUserInfo("dutplceinstcd"));
-
- // 기본 콤보 데이터 셋을 그리드 데이터셋으로 노드 복사
- var comboNodeset = instance1.selectNodes("/root/temp2/forminfo/itemlist");
-
- for(var i=0;i<comboNodeset.length;i++){
- model.makeNode("/root/gridData/row["+(i+1)+"]/formnm");
- model.setValue("/root/gridData/row["+(i+1)+"]/formnm",model.getValue("/root/temp2/forminfo/itemlist["+(i+1)+"]/formnm"));
-
- model.makeNode("/root/gridData/row["+(i+1)+"]/formcd");
- model.setValue("/root/gridData/row["+(i+1)+"]/formcd",model.getValue("/root/temp2/forminfo/itemlist["+(i+1)+"]/formcd"));
- }
-
- // 검색 박스 위치 초기화
- ufn_doResizeGrid(gridObj, inputObj);
- grid.refresh();
- ]]>
- </script>
- <script type="javascript">
- <![CDATA[
- var inputObj = "iptSearch";
- var inputValueObj = "iptSearchValue";
- var inputValueObj2 = "iptSearchValue2";
- var gridObj = "gridSearchList";
- var clickchk="false";
-
- var grid = document.controls(gridObj);
- var input = document.controls(inputObj);
- var valueInput = document.controls(inputValueObj);
- var valueInput2 = document.controls(inputValueObj2);
-
- // 검색 xpath (환경에 맞게 세팅해주세요)
- var xpData = "/root/send/formcd";
- var xpValueData = "/root/inputSelectValue";
- var xpValueData2 = "/root/inputSelectDate";
- var xpOrgGridNodeSet = "/root/gridData/row";
-
- // input - xpath
- var ref = document.controls(inputObj).attribute("ref");
- var valueRef = document.controls(inputValueObj).attribute("ref");
- var valueRef2 = document.controls(inputValueObj2).attribute("ref");
- // 검색 박스 인덱스
-
- var gStartIdx = 0;
-
- // 검색 박스 위치 초기화 함수
- function ufn_doResizeGrid(gridId, inputId, idx) {
- if(idx == null || idx == "" || idx == "unddefined") {
- idx = 0;
- }
-
- if(gStartIdx <= 0) { // datagrid 위치, 크기 설정
- document.controls(gridId).rowheight(0) = document.controls(inputId).currentStyle.height;
- document.controls(gridId).rowhidden(0) = true;
-
- document.controls(gridId).attribute("left") = document.controls(inputId).currentStyle.left; // left
- document.controls(gridId).attribute("top") = document.controls(inputId).currentStyle.top; // top
- document.controls(gridId).colWidth(0) = document.controls(inputId).currentStyle.width // width
-
- gStartIdx++;
- }
- }
- function ChkDate(){
- var fromdd = model.getValue("/root/send/fromdd");
- var todd = model.getValue("/root/send/todd");
-
- if( fromdd > todd ){
- messageBox("시작일자가 종료일자보다 클 수","I004"); //없습니다.
- return false;
- }else if( todd > getCurrentDate() ){
- messageBox("종료일자가 현재일자("+getCurrentDate()+")보다 클 수","I004"); //없습니다.
- return false;
- }
- }
-
- function fGetFormlist(ref, rsltRef, queryflag, dutplceinstcd){
- if(queryflag != null)
- model.makeValue(ref + "/queryflag", queryflag);
-
- if(dutplceinstcd != null)
- model.makeValue(ref + "/dutplceinstcd", dutplceinstcd);
-
- submit("TRMRF02603", true, ref, rsltRef);
- }
- ]]>
- </script>
- <submission id="TRMRS02100" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/indxlist"/>
- <submission id="TRMRS02101" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp/indxinfo"/>
- <submission id="TRMRS02102" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp2/forminfo/itemlist"/>
- <submission id="TRMRF02603" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/temp2/forminfo/itemlist"/>
- <submission id="TRMMB04103" mediatype="application/x-www-form-urlencoded" method="post"/>
- </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/stringHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../emr/carecomweb/js/CareCom.js"/>
- <script type="javascript" src="../../../emr/prcpmngtweb/js/MMO001.js"/>
- <script type="javascript" src="../../../emr/commonweb/js/EMRCommon.js"/>
- <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
- </xhtml:head>
- <xhtml:body pagewidth="870" pageheight="750" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:399px; height:15px; background-image:../../../com/commonweb/images/tit_bullet1.gif; ">동의서 중분류별 통계</caption>
- <group id="group2" scroll="none" style="left:0px; top:21px; width:845px; height:65px; vertical-align:top; ">
- <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:845px; height:65px; background-color:#fffbf2; border-color:#ffd799; "/>
- <button id="btn_search" class="btn1_letter2" style="left:770px; top:8px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn1_letter2.gif; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var rtn = ChkDate();
-
- if( rtn != "false" ){
- if( model.getValue("/root/send/itemindxseq") == "" ){
- messageBox("동의서 중분류선택은", "I003");
- return;
- }
- model.setValue("/root/send/fromdd", model.getValue("/root/send/fromdd"));
- model.setValue("/root/send/todd", model.getValue("/root/send/todd"));
- if (submit("TRMRS02100")){
- model.setValue("/root/send/fromdd", model.getValue("/root/send/fromdd"));
- model.setValue("/root/send/todd", model.getValue("/root/send/todd"));
- } else {
- messageBox("조회를","E009");
- }
- }else{
- return;
- }
-
- ]]>
- </script>
- </button>
- <line id="line13" style="x1:750px; y1:10px; x2:750px; y2:57px; border-color:#ffe4bb; border-left-style:solid; "/>
- <caption id="caption2" class="search_name" style="left:18px; top:9px; width:91px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">진료일자 :</caption>
- <input id="ipt_fromdd" ref="/root/send/fromdd" class="input_s_essential" inputtype="date" style="left:107px; top:8px; width:90px; height:19px; background-image:../../../com/commonweb/images/input_s_essential.gif; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- ChkDate();
- ]]>
- </script>
- </input>
- <caption id="caption5" style="left:199px; top:12px; width:15px; height:13px; ">~</caption>
- <input id="ipt_todd" ref="/root/send/todd" class="input_s_essential" inputtype="date" style="left:213px; top:8px; width:90px; height:19px; background-image:../../../com/commonweb/images/input_s_essential.gif; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- ChkDate();
- ]]>
- </script>
- </input>
- <button id="btn_excel" class="btn1_letter2" style="left:770px; top:35px; width:56px; height:22px; background-image:../../../com/commonweb/images/btn2_letter2.gif; ">
- <caption>엑셀</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var fromdd = model.getValue("/root/send/fromdd");
- var todd = model.getValue("/root/send/todd");
- var dt = "";
-
- if(fromdd == todd) {
- dt = fromdd;
- } else {
- dt = fromdd + "~" + todd;
- }
-
- var fileName = window.fileDialog("save", ",", false, "기간별 환자 시술목록(" + dt + ")", "xls", "All Files (*.*)|*.*|Excel Files(*.xls)|*.xls");
- grd_patlist.saveExcel(fileName, "SheetName", true, true, "", "", false);
-
- ]]>
- </script>
- </button>
- <caption id="caption1" class="search_name" style="left:323px; top:9px; width:111px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">동의서 중분류 :</caption>
- <select1 id="combo1" ref="/root/send/itemindxseq" class="combo_s_essential" appearance="minimal" style="left:440px; top:8px; width:195px; height:19px; ">
- <choices>
- <itemset nodeset="/root/temp/indxinfo">
- <label ref="indxnm"/>
- <value ref="itemindxseq"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- model.setValue("root/send/supitemindxseq",model.getValue("/root/send/itemindxseq"));
- submit("TRMRS02102");
-
- model.removenode("/root/gridData");
- model.makeNode("/root/gridData/row");
-
- // 기본 콤보 데이터 셋을 그리드 데이터셋으로 노드 복사
- var comboNodeset = instance1.selectNodes("/root/temp2/forminfo/itemlist");
-
- for(var i=0;i<comboNodeset.length;i++){
- model.makeNode("/root/gridData/row["+(i+1)+"]/formnm");
- model.setValue("/root/gridData/row["+(i+1)+"]/formnm",model.getValue("/root/temp2/forminfo/itemlist["+(i+1)+"]/formnm"));
-
- model.makeNode("/root/gridData/row["+(i+1)+"]/formcd");
- model.setValue("/root/gridData/row["+(i+1)+"]/formcd",model.getValue("/root/temp2/forminfo/itemlist["+(i+1)+"]/formcd"));
- }
- // 검색 박스 위치 초기화
- ufn_doResizeGrid(gridObj, inputObj);
- grid.refresh();
- ]]>
- </script>
- </select1>
- <caption id="caption3" class="search_name" style="left:18px; top:35px; width:76px; height:17px; background-image:../../../com/commonweb/images/search_bullet1.gif; ">서식명 :</caption>
- </group>
- <datagrid id="grd_patlist" nodeset="/root/main/indxlist/indxlist" class="datagrid4" caption="진료일자^출력일자^부서명^환자번호^환자명^서식명^출력상태" colsep="^" colwidth="84, 140, 75, 85, 70, 289, 70" mergecellsfixedrows="bycolrec" rowsep="|" style="left:0px; top:95px; width:845px; height:625px; ">
- <col ref="orddd" format="yyyy-mm-dd" style="text-align:center; "/>
- <col ref="fstprntdt" format="yyyy-mm-dd hh:nn:ss" style="text-align:center; "/>
- <col ref="inorddeptnm" style="text-align:center; "/>
- <col ref="pid" style="text-align:center; "/>
- <col ref="hngnm" format="yyyy-mm-dd hh:nn:ss" style="text-align:center; "/>
- <col ref="formnm"/>
- <col ref="statcd" style="text-align:center; "/>
- <script type="javascript" ev:event="onaftersort">
- <![CDATA[
- grd_patlist.gridToInstance();
- ]]>
- </script>
- </datagrid>
- <line id="line8" class="line_1" style="x1:0px; y1:91px; x2:844px; y2:91px; "/>
- <group id="group3" scroll="none" style="left:107px; top:58px; width:548px; height:20px; ">
- <datagrid id="gridSearchList" nodeset="/root/gridData/row" visibility="hidden" overflow="scroll" scroll="auto" caption="동의서명^caption2^caption3" colsep="^" colwidth="516, -11, 0" mergecellsfixedrows="bycolrec" rowsep="|" selectionmode="byrow" style="left:0px; top:20px; width:542px; height:140px; ">
- <col ref="formnm"/>
- <col ref="formcd" visibility="hidden"/>
- <col ref="formfromdt" visibility="hidden"/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- if(grid.isCell(event.target) == true && grid.row > grid.fixedRows-1)
- {
- var label = grid.valueMatrix(grid.row, 0);
- var value = grid.valueMatrix(grid.row, 1);
- var value2 = grid.valueMatrix(grid.row, 2);
-
- model.setValue(ref, label);
- model.setValue(valueRef, value);
- model.setValue(valueRef2, value2);
-
-
- input.refresh();
- valueInput.refresh();
- valueInput2.refresh();
-
- model.setFocus(inputObj);
-
- input.selBegin = 0;
- input.selEnd = label.length;
- input.caretPosition = label.length;
-
- grid.visible = false;
-
- }
-
- if(gridSearchList.col==0){
- group3.attribute("height")="20px";
- clickchk="false";
- }else{
- group3.attribute("height")="160px";
- clickchk="true";
- }
- ]]>
- </script>
- </datagrid>
- <input id="iptSearchValue" ref="/root/inputSelectValue" visibility="hidden" editable="false" style="left:431px; top:60px; width:35px; height:19px; color:#0000ff; background-color:#ffff99; border-style:none; "/>
- <input id="iptSearchValue2" ref="/root/inputSelectValue2" visibility="hidden" editable="false" style="left:430px; top:85px; width:35px; height:19px; color:#0000ff; background-color:#ffff99; border-style:none; "/>
- <input id="iptSearch" ref="/root/send/formcd" style="left:0px; top:0px; width:526px; height:19px; ">
- <script type="javascript" ev:event="onkeyup">
- <![CDATA[
- // datagrid 크기 리사이즈
- ufn_doResizeGrid(gridObj, inputObj);
-
- var tmp = input.currentText;
- var node = instance1.selectSingleNode(xpData);
- var currentRow = 0;
- var rowIdx = 0;
-
- var value = "";
- var label = "";
-
- // 입력한 값이 존재하고, 검색할 노드 데이터가 있는 경우 검색 수행
- if(tmp == "" || node == null)
- {
- grid.visible = false;
- group3.attribute("height")="20px";
- clickchk="false";
- return;
- }
- // <-, -> 버튼일 경우는 검색 기능 수행 안함
- if(event.keyCode == 37 || event.keyCode == 39) return;
-
- grid.visible = true;
-
- // up 버튼, down 버튼은 검색 결과 선택 기능 수행
- if(event.keyCode == 38 || event.keyCode == 40)
- {
- // up 버튼 - 검색 결과 위로 선택
- if(event.keyCode == 38)
- {
- // 선택되어 있는 행이 없을 경우
- if( grid.selectedRow(0) == -1 || grid.selectedRow(0) == 0 ){
- grid.visible = false;
- group3.attribute("height")="20px";
- clickchk="false";
- } else {
- currentRow = grid.selectedRow(0);
- rowIdx = currentRow-1;
-
- if(rowIdx >= grid.fixedRows) {
- grid.select(rowIdx, 0) = true;
-
- ref = input.attribute("ref");
- label = grid.valueMatrix(rowIdx, grid.colRef("formnm"));
-
- model.setValue(ref, label);
-
- input.refresh();
-
- input.selBegin = 0;
- input.selEnd = label.length;
- input.caretPosition = label.length;
- } else {
- grid.row = grid.fixedRows;
- }
- }
- // down 버튼 - 검색 결과 아래로 선택
- }
- if(event.keyCode == 40)
- {
- // 선택되어 있는 행이 없을 경우
- if(grid.selectedRow(0) == -1)
- {
- rowIdx = grid.fixedRows;
-
- grid.select(rowIdx, 0) = true;
-
- ref = input.attribute("ref");
- label = grid.valueMatrix( rowIdx, grid.colRef("formnm") )
-
- model.setValue(ref, label);
- input.refresh();
-
- input.selBegin = 0;
- input.selEnd = label.length;
- input.caretPosition = label.length;
- }
- else
- {
- currentRow = grid.selectedRow(0);
- rowIdx = currentRow+1;
-
- if(rowIdx <grid.rows)
- {
- grid.select(rowIdx, 0) = true;
-
- ref = input.attribute("ref");
- label = grid.valueMatrix(rowIdx, grid.colRef("formnm") )
-
- model.setValue(ref, label);
- input.refresh();
-
- input.selBegin = 0;
- input.selEnd = label.length;
- input.caretPosition = label.length;
- }
- }
- }
- } else if(event.keyCode == 27) {
- grid.visible = false;
- group3.attribute("height")="20px";
- clickchk="false";
- } else if(event.keyCode == 13) {
- if(model.getValue(ref) == "") {
- model.setValue(ref, tmp);
- }
- if(grid.rows == 2 && tmp.indexOf(grid.valueMatrix(1,0)) > -1){
- model.setValue(valueRef,grid.valueMatrix(1,1));
- } else {
- model.setValue(valueRef,grid.valueMatrix(grid.selectedRow(0),1));
- }
-
- valueInput.refresh();
- grid.visible = false;
- group3.attribute("height")="20px";
- clickchk="false";
- } else {
- grid.nodeset = "/root/gridData/row[contains(formnm, \""+ tmp +"\")]";
- }
-
- grid.attribute("overflow") = "";
- grid.attribute("scroll") = "vertical";
-
- if(tmp == ""){
- group3.attribute("height")="20px";
- clickchk="false";
- }
-
- if(event.keyCode != 13){
- if(clickchk=="false" && tmp != ""){
- group3.attribute("height")="160px";
- clickchk="true";
- }else if(clickchk=="true" && tmp == ""){
- group3.attribute("height")="20px";
- clickchk="false";
- }
- }
- ]]>
- </script>
- <script type="javascript" ev:event="DOMFocusIn">
- <![CDATA[
- var ref = input.attribute("ref");
- input.selBegin = 0;
- input.selEnd = model.getValue(ref).length;
- ]]>
- </script>
- </input>
- <button id="button3" style="left:512px; top:2px; width:13px; height:18px; focus-rect:hidden; ">
- <caption>▼</caption>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- if(clickchk=="false"){
- group3.attribute("height")="160px";
- clickchk="true";
- }else if(clickchk=="true"){
- group3.attribute("height")="20px";
- clickchk="false";
- }
-
- grid.attribute("overflow") = "";
- grid.attribute("scroll") = "vertical";
-
- var datagridVisible = grid.visible;
-
- if(datagridVisible==true)
- {
- grid.visible = false;
- }
- else
- {
- grid.visible = true;
- }
- model.setValue(ref,"");
- model.setValue(valueRef,"");
- model.setValue(valueRef2,"");
-
- input.refresh();
- valueInput.refresh();
- valueInput2.refresh();
-
- grid.nodeset = xpOrgGridNodeSet;
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|