123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375 |
- <?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>
- <!-- grid 컨트롤에 mapping되는 instance - 시작 -->
- <matrcstcodelist>
- <item>
- <!-- 검사 코드(영문+숫자 조합) -->
- <excucd/>
- <!-- 검사 코드명 -->
- <excucdnm/>
- <!-- 핵종 코드 -->
- <nuclcd/>
- <!-- 화합물 코드 -->
- <compdcd/>
- <!-- 약물 투여량 -->
- <drugqty/>
- <!-- 약물 투여방법 -->
- <drugmthdcd/>
- <!-- 소모량 -->
- <cstqty/>
- <!-- IV.SITE -->
- <injpartcd/>
- <!-- 공급처 -->
- <suplcustcd/>
- <!-- 검사자 -->
- <execrid/>
- <!-- 지원부서코드 -->
- <basesuppdeptcd/>
- </item>
- </matrcstcodelist>
- </main>
- <!-- grid 컨트롤에 mapping되는 instance - 종료 -->
- <send>
- <srchexcucd/>
- <srchexcucdnm/>
- <req>
- <data/>
- </req>
- <globalinstance>
- <instance1/>
- </globalinstance>
- <windowloadinstance>SMAEB02000</windowloadinstance>
- </send>
- <init>
- <cmb_info>
- <initnuclcd>
- <nuclcdid/>
- <nuclcdnm/>
- </initnuclcd>
- <initcompdcd>
- <compdcdid/>
- <compdcdnm/>
- </initcompdcd>
- <initdrugmthdcd>
- <drugmthdcdid/>
- <drugmthdcdnm/>
- </initdrugmthdcd>
- <initinjpartcd>
- <injpartcdid/>
- <injpartcdnm/>
- </initinjpartcd>
- <initsuplcustcd>
- <suplcustcdid/>
- <suplcustcdnm/>
- </initsuplcustcd>
- <initexecrid>
- <execridid/>
- <execridnm/>
- </initexecrid>
- </cmb_info>
- </init>
- <hidden>
- <count/>
- </hidden>
- </root>
- </instance>
- <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/numericHelper.js"/>
- <script type="javascript" src="../../../ast/examcureweb/js/AEZ0001.js"/>
- <submission id="TRAEA02301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/globalinstance" replace="instance" resultref="/root/init/cmb_info"/>
- <submission id="TRAEB02001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/main/matrcstcodelist"/>
- <submission id="TXAEB02001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/req" replace="instance" resultref="/root/hidden"/>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- aezfSetSuppDeptcd();
-
- submit("TRAEA02301");
- submit("TRAEB02001");
-
- //model.removeNodeset("/root/main/matrcstcodelist/item");
- model.refresh();
-
- model.setFocus("ipt_excucd");
- ]]>
- </script>
- <script type="javascript">
- <![CDATA[
- function isDecimalNumber(param) {
- if( typeof( param ) == "undefined" ) return false;
- if( param.length == 0 ) return false;
- var thisSting = param.toString();
- for ( var i=0; i < thisSting.length; i++ ) {
- var thisNumber = thisSting.substring( i, i+1 );
- // 숫자, 혹은 소수점이 아니면 FALSE 리턴
- if (thisNumber != "." && isNaN( thisNumber )) return false;
-
- // 공백이면 FALSE 리턴
- if( " " == thisNumber ) return false;
- }
- return true;
- }
-
- function chkMandatoryData() {
- var msg = "";
-
- for (var i = 1; i < parseInt(grd_matrcstcode.rows); i++) {
- var _code = model.getValue("/root/main/matrcstcodelist/item[" + i + "]/excucd");
- var _cdnm = model.getValue("/root/main/matrcstcodelist/item[" + i + "]/excucdnm");
- var _nucl = model.getValue("/root/main/matrcstcodelist/item[" + i + "]/nuclcd");
-
- // if ( _code == "" || _cdnm == "" || _nucl == "" ) {
- // msg += i + "/";
- // }
- if ( _code == "" || _nucl == "" ) {
- msg += i + "/";
- }
- }
-
- if ( msg != "" ) {
- messageBox("필수입력항목(검사코드, 코드명, 핵종)에 대한 내용이 누락되었습니다. " + msg + "번 째 row를 저장", "E001");
- return false;
- }
- }
-
- function chkUpdatedData() {
- if ( messageBox("", "Q002") == 6 ) {
- var update = getGridUpdateData(grd_matrcstcode);
-
- if ( update == "" ) {
- messageBox("업데이트 정보가 없습니다.", "I");
- model.setFocus("ipt_excucd");
- }
-
- else {
- var _msg = "";
-
- if ( chkMandatoryData() == false ) {
- return true;
- }
-
- for (var i = 1; i < parseInt(grd_matrcstcode.rows); i++) {
- var dqty = model.getValue("/root/main/matrcstcodelist/item[" + i + "]/drugqty");
- var cqty = model.getValue("/root/main/matrcstcodelist/item[" + i + "]/cstqty");
-
- if (isDecimalNumber(dqty) == false || isDecimalNumber(cqty) == false) {
- _msg += i + "/";
- }
- }
-
- if ( _msg != "" ) {
- messageBox("투여량/소모량 입력은 숫자만이 가능합니다." + _msg + "번 째 row를 확인해 주십시오.", "E");
- return true;
- }
-
- model.setValue("/root/send/req/data", update);
- submit("TXAEB02001");
- submit("TRAEB02001");
-
- model.refresh();
- }
- }
- }
- ]]>
- </script>
- </model>
- </xhtml:head>
- <xhtml:body guideline="1,1195;2,757;2,784;">
- <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
- <!-- 메인 타이틀 -->
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:142px; height:14px; ">재료소모코드관리</caption>
- </group>
- <group id="group3" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
- <group id="grp_sea" style="left:0px; top:10px; width:1195px; height:35px; vertical-align:top; ">
- <!-- 조회영역 배경 -->
- <shape id="roundrect2" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1195px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
- <!-- 검사코드 입력부분 -->
- <caption id="caption3" class="search_name" style="left:15px; top:9px; width:60px; height:17px; ">코드 :</caption>
- <input id="ipt_excucd" ref="/root/send/srchexcucd" class="input_search" style="left:78px; top:8px; width:150px; height:19px; "/>
- <script type="javascript" ev:event="onkeyup">
- <![CDATA[
- inputEnterKey("btn_sea", "DOMActivate");
- ]]>
- </script>
- <!-- 검사코드명 입력부분 -->
- <caption id="caption1" class="search_name" style="left:260px; top:9px; width:75px; height:17px; ">코드명 :</caption>
- <input id="ipt_excucdnm" ref="/root/send/srchexcucdnm" class="input_search" style="left:338px; top:8px; width:150px; height:19px; "/>
- <line id="line13" class="line_4" style="x1:1108px; y1:9px; x2:1108px; y2:31px; "/>
- <!-- 조회 버튼 -->
- <button id="btn_sea" class="btn1_letter2" style="left:1124px; top:7px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- submit("TRAEB02001");
-
- model.setValue("/root/send/srchexcucd", "");
- model.setValue("/root/send/srchexcucdnm", "");
- model.refresh();
- ]]>
- </script>
- </button>
- </group>
- <!-- Grid에 행 추가 -->
- <button id="btn_grdadd" class="btn2_letter3" style="left:1020px; top:49px; width:53px; height:19px; ">
- <caption>행추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- grd_matrcstcode.addItem();
-
- var i = parseInt(grd_matrcstcode.row);
-
- model.setValue("/root/main/matrcstcodelist/item[" + i + "]/basesuppdeptcd",
- model.getValue("/root/send/globalinstance/instance1") );
- model.setValue("/root/main/matrcstcodelist/item[" + i + "]/drugqty", 0);
- model.setValue("/root/main/matrcstcodelist/item[" + i + "]/cstqty", 0);
- ]]>
- </script>
- </button>
- <!-- Grid에 있는 행 삭제 -->
- <button id="btn_grddel" class="btn2_letter3" style="left:1076px; top:49px; width:53px; height:19px; ">
- <caption>행삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- deleteSelectedRows(grd_matrcstcode, true);
- //datagrid1.addStatus(datagrid1.row,"delete");
- ]]>
- </script>
- </button>
- <!-- Grid에 있는 목록을 Excel에 저장 -->
- <button id="btn_excsave" class="btn2_letter4" style="left:1131px; top:49px; width:42px; height:19px; ">
- <caption>엑셀저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var file = window.fileDialog("save","","false","","xls","Excel Files(*.xls)|*.xls");
- grd_matrcstcode.saveExcel(file);
- ]]>
- </script>
- </button>
- <!-- Grid 타이틀 -->
- <line id="line1" class="line_1" style="x1:0px; y1:69px; x2:1195px; y2:69px; "/>
- <caption id="caption14" class="tit_2" style="left:5px; top:54px; width:130px; height:14px; ">재료소모코드관리</caption>
- <datagrid id="grd_matrcstcode" nodeset="/root/main/matrcstcodelist/item" caption="검사(처방)코드^검사(처방)코드명^핵종^화합물^투여량^투여방법^소모량^IV.SITE^공급처^검사자^지원부서" colsep="^" colwidth="104, 292, 95, 95, 95, 95, 95, 95, 95, 95, 0" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:74px; width:1195px; height:670px; ">
- <!-- 검사 코드 -->
- <col ref="excucd" type="inputbutton" _key="true"/>
- <!-- 검사 코드명 -->
- <col ref="excucdnm"/>
- <!-- 핵종 코드 -->
- <col ref="nuclcd" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initnuclcd">
- <label ref="nuclcdnm"/>
- <value ref="nuclcdid"/>
- </itemset>
- </choices>
- </col>
- <!-- 화합물 코드 -->
- <col ref="compdcd" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initcompdcd">
- <label ref="compdcdnm"/>
- <value ref="compdcdid"/>
- </itemset>
- </choices>
- </col>
- <!-- 약물 투여량 -->
- <col ref="drugqty" type="input" format="#,###.000" style="text-align:right; "/>
- <!-- 약물 투여방법 -->
- <col ref="drugmthdcd" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initdrugmthdcd">
- <label ref="drugmthdcdnm"/>
- <value ref="drugmthdcdid"/>
- </itemset>
- </choices>
- </col>
- <!-- 소모량 -->
- <col ref="cstqty" type="input" format="#,###.000" style="text-align:right; "/>
- <!-- IV.SITE -->
- <col ref="injpartcd" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initinjpartcd">
- <label ref="injpartcdnm"/>
- <value ref="injpartcdid"/>
- </itemset>
- </choices>
- </col>
- <!-- 공급처 -->
- <col ref="suplcustcd" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initsuplcustcd">
- <label ref="suplcustcdnm"/>
- <value ref="suplcustcdid"/>
- </itemset>
- </choices>
- </col>
- <!-- 검사자 -->
- <col ref="execrid" type="combo">
- <choices>
- <itemset nodeset="/root/init/cmb_info/initexecrid">
- <label ref="execridnm"/>
- <value ref="execridid"/>
- </itemset>
- </choices>
- </col>
- <!-- 지원부서코드 -->
- <col ref="basesuppdeptcd"/>
- <!-- 검사(처방)코드 column의 박스를 클릭했을 때의 이벤트 (팝업창 띄우기) -->
- <script type="javascript" ev:event="onbuttonclick">
- <![CDATA[
- var colidx = grd_matrcstcode.col;
-
- if ( colidx == 1) {
- window.load( "SPAEA02302_코드조회(검사치료).xrw","modal","code", "left:100px; top:150px; width:530px; height:380px;min:hidden;max:hidden;resize:false;" );
- }
- ]]>
- </script>
- <!-- 검사(처방)코드 column의 내용을 수정했을 때의 이벤트 (업데이트 표시) -->
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- var iRow = grd_matrcstcode.row;
-
- if(grd_matrcstcode.mouseCol == 1){
- grd_matrcstcode.addStatus(iRow, "update");
- }
- ]]>
- </script>
- </datagrid>
- </group>
- <group id="grp_btn" style="left:0px; top:757px; width:1195px; height:27px; ">
- <!-- 초기화 버튼 -->
- <button id="btn_clear" class="btn4_letter3" style="left:1127px; top:5px; width:56px; height:22px; ">
- <caption>초기화</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if ( messageBox("초기화하시겠습니까?", "Q") == 6) {
- model.reset();
- }
- model.setFocus("ipt_excucd");
- ]]>
- </script>
- </button>
- <!-- 저장 버튼 -->
- <button id="btn_save" class="btn4_letter2" style="left:1069px; top:5px; width:56px; height:22px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- chkUpdatedData();
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|