123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
- <xhtml:html xmlns:ex="http://www.comsquare.co.kr/xforms/excel" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:my="http://www.comsquare.co.kr/example" xmlns:ms="urn:schemas-microsoft-com:xslt" 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" xmlns:cs="http://www.comsquare.co.kr/xforms">
- <xhtml:head>
- <xhtml:title>약품선택</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <druglist>
- <item>
- <lrgcd/>
- <lrgnm/>
- <mdlcd/>
- <mdlnm/>
- <smlcd/>
- <smlnm/>
- <goodcd/>
- <goodnm/>
- </item>
- </druglist>
- </main>
- <target/>
- <init>
- </init>
- <send>
- <search>
- <lrgcd/>
- <mdlcd/>
- <smlcd/>
- <liketype>name</liketype>
- <searchcont/>
- <goodflag/>
- <mngtcls/>
- </search>
- </send>
- <temp>
- <category/>
- <dummyDruglist/>
- </temp>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- misfComboComCdList("030M0003",cmb_mngtcls,"Y");
- model.setValue("/root/send/search/goodflag", "PH");
-
- /*rszfLMSComboList(model.getValue("/root/send/search/goodflag"), "", "", "cmb_lrg", "", "L", "Y", "Y");
-
- model.removenode("/root/init/mdlCategory/item");
- model.removenode("/root/init/smlCategory/item");*/
- model.removeNodeset("/root/main/druglist/item");
- model.refresh();
- ]]>
- </script>
- <submission id="TRRSC09001" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" replace="instance" resultref="/root/temp/category"/>
- <submission id="TRRSC09002" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" replace="instance" resultref="/root/main/deptdata"/>
- <submission id="TRRSC09010" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" replace="instance" resultref="/root/main/druglist"/>
- </model>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
- <script type="javascript">
- <![CDATA[
- function fGetMdlCategory() {
- var selLrgCde = model.getValue("/root/send/search/lrgcd");
- var existCnt = model.getXPathValue("count(/root/init/mdlCategory/item[lrgcde='"+selLrgCde+"'])");
-
- if (existCnt == 0) {
- var nodeCnt = model.getXPathValue("count(/root/init/mdlCategory/item)");
- submit("TRRSC09001");
- if (nodeCnt == 0) {
- model.copyNode("/root/init/mdlCategory", "/root/temp/category");
- } else {
- var getCnt = model.getXPathValue("count(/root/temp/category/item)");
- for (var i = 1; i <= getCnt; i++) {
- model.duplicate("/root/init/mdlCategory", "/root/temp/category/item["+i+"]", "*[1]");
- }
- }
- model.removenode("/root/temp/category");
- model.makeNode("/root/temp/category");
- }
- cmb_mdl.choices.itemset.attribute("nodeset") = "/root/init/mdlCategory/item[lrgcde='"+selLrgCde+"']";
- cmb_sml.choices.itemset.attribute("nodeset") = "/root/init/smlCategory/item[lrgcde=-1]";
- model.setValue("/root/send/search/mdlcd", "");
- model.setValue("/root/send/search/smlcd", "");
- cmb_mdl.refresh();
- cmb_sml.refresh();
- }
-
- function fGetSmlCategory() {
- var selMdlCde = model.getValue("/root/send/search/mdlcd");
- var existCnt = model.getXPathValue("count(/root/init/smlCategory/item[mdlcde='"+selMdlCde+"'])");
-
- if (existCnt == 0) {
- var nodeCnt = model.getXPathValue("count(/root/init/smlCategory/item[mdlcde='"+selMdlCde+"'])");
- submit("TRRSC09001");
- if (nodeCnt == 0) {
- model.copyNode("/root/init/smlCategory", "/root/temp/category");
- } else {
- var getCnt = model.getXPathValue("count(/root/temp/category/item)");
- for (var i = 1; i <= getCnt; i++) {
- model.duplicate("/root/init/smlCategory", "/root/tempcategory/item["+i+"]", "*[1]");
- }
- }
- model.removenode("/root/temp/category");
- model.makeNode("/root/temp/category");
- }
- cmb_sml.choices.itemset.attribute("nodeset") = "/root/init/smlCategory/item[mdlcde='"+selMdlCde+"']";
- model.setValue("/root/send/search/smlcd", "");
- cmb_sml.refresh();
- }
- function fSetOpenerVal() {
- var refPath = model.getValue("/root/target/receiveref");
- var selPk = grd_druglist.valueMatrix(grd_druglist.row, 1);
- var sNode = instance1.selectNodes("/root/temp/dummyDruglist/item[usrpk='"+selPk+"']/*");
-
-
- var tmp1 = "";
- var tmp2 = "";
- for (var i = 0; i < sNode.length; i++) {
- tmp1 += sNode.item(i).nodeName+"▦"
- tmp2 += sNode.item(i).nodeValue+"▦";
- }
-
- if (tmp1 == "") {
- messageBox("약품을 ", "C002");
- } else {
- window.opener.model.setValue(refPath, tmp1+"▩"+tmp2);
- window.close();
- }
- }
- function fSearch() {
- submit("TRRSC09010");
- model.copyNode("/root/temp/dummyDruglist", "/root/main/druglist");
- }
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="800" pageheight="550" guideline="1,823;2,343;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <shape id="roundrect1" class="roundrect_search" appearance="roundrect" style="left:7px; top:9px; width:765px; height:55px; "/>
- <caption id="caption1" class="tit_2" style="left:10px; top:70px; width:95px; height:13px; ">약품 리스트</caption>
- <line id="line13" class="line_4" style="x1:705px; y1:18px; x2:705px; y2:57px; border-color:#ffe4bb; border-left-style:solid; "/>
- <caption id="caption2" class="search_name" visibility="hidden" style="left:35px; top:60px; width:75px; height:17px; ">대분류 :</caption>
- <caption id="caption3" class="search_name" visibility="hidden" style="left:265px; top:60px; width:75px; height:17px; ">중분류 :</caption>
- <select1 id="cmb_sml" ref="/root/send/search/smlcd" visibility="hidden" appearance="minimal" style="left:570px; top:60px; width:150px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/smlCategory/item">
- <label ref="iname"/>
- <value ref="icode"/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption4" class="search_name" visibility="hidden" style="left:495px; top:60px; width:75px; height:17px; ">소분류 :</caption>
- <select1 id="cmb_lrg" ref="/root/send/search/lrgcd" visibility="hidden" appearance="minimal" style="left:110px; top:60px; width:150px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/lrgCategory/item">
- <label ref="iname"/>
- <value ref="icode"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- rszfLMSComboList(model.getValue("/root/send/search/goodflag"), cmb_lrg.value, "", "cmb_mdl", "", "M", "Y", "Y");
- cmb_mdl.value="";
- cmb_sml.value="";
- ]]>
- </script>
- </select1>
- <datagrid id="grd_druglist" nodeset="/root/main/druglist/item" class="datagrid2" caption="usrpk^대분류^중분류^소분류^선택^약품코드^약품명(영문)^함량^단위^단가" colsep="^" colwidth="6, 27, 24, 22, 34, 100, 284, 100, 100, 100" dataheight="23" defaultrows="0" mergecellsfixedrows="never" rowheader="seq" rowheight="23" rowsep="|" style="left:10px; top:89px; width:760px; height:375px; ">
- <col ref="usrpk" visibility="hidden"/>
- <col ref="lrgnm" visibility="hidden"/>
- <col ref="mdlnm" visibility="hidden"/>
- <col ref="smlnm" visibility="hidden"/>
- <col ref="chk" checkvalue="Y,N" type="checkbox"/>
- <col ref="goodcd" style="text-align:left; "/>
- <col ref="goodnm" style="text-align:left; "/>
- <col ref="setunit" style="text-align:center; "/>
- <col ref="cntsqtyunit" style="text-align:center; "/>
- <col ref="goodunitcost" style="text-align:right; "/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- if( grd_druglist.isCell(event.target) && grd_druglist.row >= grd_druglist.fixedRows )
- {
- btn_confirm.dispatch("DOMActivate");
- }
- ]]>
- </script>
- <script type="javascript" ev:event="onaftersort">
- <![CDATA[
- grd_druglist.gridToInstance();
- ]]>
- </script>
- </datagrid>
- <line id="line1" class="line_1" style="x1:10px; y1:85px; x2:770px; y2:85px; "/>
- <select1 id="radio1" ref="/root/send/search/liketype" appearance="full" cols="2" overflow="visible" style="left:15px; top:26px; width:135px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>약품코드</label>
- <value>code</value>
- </item>
- <item>
- <label>약품이름</label>
- <value>name</value>
- </item>
- </choices>
- </select1>
- <select1 id="cmb_mdl" ref="/root/send/search/mdlcd" visibility="hidden" appearance="minimal" style="left:340px; top:59px; width:150px; height:19px; ">
- <choices>
- <itemset nodeset="/root/init/mdlCategory/item">
- <label ref="iname"/>
- <value ref="icode"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- rszfLMSComboList(model.getValue("/root/send/search/goodflag"), cmb_lrg.value, cmb_mdl.value, "cmb_sml", "", "S", "Y", "Y");
- cmb_sml.value="";
- ]]>
- </script>
- </select1>
- <button id="btn_search" class="btn1_letter2" style="left:709px; top:25px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- fSearch();
- ]]>
- </script>
- </button>
- <input id="ipt_refcond" ref="/root/send/search/searchcont" class="input_s_essential" style="left:155px; top:26px; width:205px; height:19px; ">
- <script type="javascript" ev:event="onkeyup">
- <![CDATA[
- inputEnterKey("btn_search", "DOMActivate");
- ]]>
- </script>
- </input>
- <button id="btn_cancel" class="btn4_letter2" style="left:714px; top:470px; width:56px; height:22px; ">
- <caption>취소</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- window.close();
- ]]>
- </script>
- </button>
- <button id="btn_confirm" class="btn4_letter2" style="left:655px; top:470px; width:56px; height:22px; ">
- <caption>확인</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(grd_druglist.rows - grd_druglist.fixedRows == 0)
- {
- messageBox("적용할 내역이","I004");
- //window.close();
- return;
- }
-
- var nodelist = instance1.selectNodes(grd_druglist.nodeset+ "[chk ='Y']");
-
- var rCVS = getNodeListCSV(nodelist);
-
- if ( checkOpener() ) {
- opener.javascript.fGetGrugGoodInfo(rCVS);
- } else {
- var rtn = messageBox("상위화면을 찾을 수", "E001");
- }
- window.close();
-
- ]]>
- </script>
- </button>
- <select1 id="cmb_mngtcls" ref="/root/send/search/mngtcls" class="combo_s_essential" appearance="minimal" style="left:473px; top:26px; width:150px; height:19px; ">
- <choices>
- <itemset>
- <label/>
- <value/>
- </itemset>
- </choices>
- </select1>
- <caption id="caption5" class="search_name" style="left:385px; top:27px; width:88px; height:17px; ">관리분류 :</caption>
- </xhtml:body>
- </xhtml:html>
|