123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194 |
- <?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:ms="urn:schemas-microsoft-com:xslt" xmlns:my="http://www.comsquare.co.kr/example" 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>
- <matr>
- <matrlist/>
- </matr>
- </main>
- <send>
- <matrcd/>
- <matrnm/>
- <deptcd/>
- </send>
- <init>
- <searchcond/>
- <searchtext/>
- </init>
- <hidden/>
- <temp/>
- <popdata>
- <returntype/>
- </popdata>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- misfGridInit(grd_matr);
-
- misfMsterDetailSet(grd_matr, null, "TRRSM00111" ,"N"); //TRRSO20301
- //화면 초기값 setting
- rdo_cond.value = "명칭";
- //Opener로부터 받은 parameter값을 조회조건으로 setting함
- //model.setValue("/root/send/instcd", model.getValue("/root/popdata/instcd"));
- //model.setValue("/root/send/wareflag", model.getValue("/root/popdata/wareflag"));
- //2012.09.17 박준범 - 물질마스터 조회 기준일자 추가
- //model.setValue("/root/send/basedd", model.getValue("/root/popdata/basedd"));
-
- model.setValue("/root/send/deptcd", model.getValue("/root/popdata/deptcd"));
-
- btn_search.dispatch("DOMActivate");
-
- //model.setFocus("ipt_search");
-
- ]]>
- </script>
- <submission id="TRRSM00111" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/matr"/>
- </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/humtrafactmngtweb/js/RPB001.js"/>
- </xhtml:head>
- <xhtml:body pagewidth="660" pageheight="400">
- <line id="line8" class="line_1" style="x1:10px; y1:72px; x2:645px; y2:72px; "/>
- <caption id="caption20" class="tit_2" style="left:11px; top:57px; width:184px; height:14px; ">물질코드</caption>
- <shape id="roundrect2" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:10px; top:10px; width:635px; height:35px; background-color:#fffbf2; border-color:#ffd799; "/>
- <button id="btn_cancel" class="btn4_letter2" style="left:585px; top:365px; width:56px; height:22px; ">
- <caption>취소</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- //선택버튼을 click했는지 아닌지를 나타내는 구분값을 opener에 전달한다.
- opener.model.setValue("/root/popmatr/selectyn", "N");
-
- window.close();
- ]]>
- </script>
- </button>
- <button id="btn_select" class="btn4_letter2" style="left:525px; top:365px; width:56px; height:22px; ">
- <caption>선택</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- //조회 결과가 no rows 일 때
- if(grd_matr.rows == 1) {
- return;
- }
-
- //선택버튼을 click했는지 아닌지를 나타내는 구분값을 opener에 전달한다.
- opener.model.setValue("/root/popmatr/selectyn", "Y");
-
- //선택한 물질코드를 opener에 setting한다.
- opener.model.setValue("/root/popmatr/matrcd", model.getValue(grd_matr.nodeset + "[" + grd_matr.row + "]/matrcd"));
- opener.model.setValue("/root/popmatr/matrnm", model.getValue(grd_matr.nodeset + "[" + grd_matr.row + "]/matrnm"));
-
- /*
- //opener에서 matrnm 도 함께 return 받고자 하는 경우에, opener에서 returntype을 2로 설정하여 본 화면을 call 하면 됨.(SMRSO21100 참조)
- if( model.getValue("/root/popdata/returntype") == "2" ) {
- opener.model.setValue("/root/popmatr/matrnm", model.getValue(grd_matr.nodeset + "[" + grd_matr.row + "]/matrnm"));
- }
- */
- //opener에서 prodcmpynm, maincustlastsuplplcenm 도 함께 return 받고자 하는 경우에, opener에서 returntype을 3로 설정하여 본 화면을 call 하면 됨.(SMRSM01000 참조)
- if( model.getValue("/root/popdata/returntype") == "3" ) {
- opener.model.setValue("/root/popmatr/prodcmpynm", model.getValue(grd_matr.nodeset + "[" + grd_matr.row + "]/prodcmpynm"));
- opener.model.setValue("/root/popmatr/maincustlastsuplplcenm", model.getValue(grd_matr.nodeset + "[" + grd_matr.row + "]/maincustlastsuplplcenm"));
- }
- window.close();
- ]]>
- </script>
- </button>
- <select1 id="rdo_cond" ref="/root/init/searchcond" appearance="full" cols="2" overflow="visible" style="left:30px; top:20px; width:95px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>코드</label>
- <value>코드</value>
- </item>
- <item>
- <label>명칭</label>
- <value>명칭</value>
- </item>
- </choices>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- //검색어 부분으로 focus 옮김
- model.setFocus("ipt_search");
- //ipt_search.selBegin = 0;
- ]]>
- </script>
- </select1>
- <input id="ipt_search" ref="/root/init/searchtext" class="input1" navindex="1" style="left:124px; top:18px; width:136px; height:19px; ">
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- if( event.keyCode == 13 ) {
- //btn_search.dispatch("DOMActivate");
- // --> 위의 코드를 사용하면 input에 입력된 값이 인식이 안됨. TrustForm bug 같습니다.
- // --> 대신, 아래 코드 사용하면 input의 값이 인식이 됨
-
- //input 에서 EnterKey 이벤트 인식시 아래 function을 사용하세요!!
- inputEnterKey("btn_search", "DOMActivate");
- }
- ]]>
- </script>
- </input>
- <line id="line13" class="line_4" style="x1:279px; y1:17px; x2:279px; y2:39px; "/>
- <button id="btn_search" class="btn1_letter2" style="left:295px; top:17px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- /*
- //검색어를 입력하지 않았을 경우
- if( ipt_search.value == "" ) {
- messageBox("검색어를 입력하십시요", "I999", "");
- model.setFocus("ipt_search");
- return;
- }
- */
- //조회조건 setting함
- if(rdo_cond.value == "코드") {
- model.setValue("/root/send/matrcd", model.getValue("/root/init/searchtext"));
- model.setValue("/root/send/matrnm", "");
- }else{
- model.setValue("/root/send/matrcd", "");
- model.setValue("/root/send/matrnm", model.getValue("/root/init/searchtext"));
- }
-
- misfMsterDetailRetrieve();
- //조회 결과가 없는 경우
- if(grd_matr.rows == 1) {
- model.setFocus("ipt_search");
- }
- ]]>
- </script>
- </button>
- <datagrid id="grd_matr" nodeset="/root/main/matr/matrlist" visibility="visible" caption="코드^물질명^제조회사^공급처^제작부서^" colwidth="32, 236, 124, 110, 100" mergecellsfixedrows="bycolrec" rowheader="select" tooltip="true" style="left:10px; top:77px; width:635px; height:278px; ">
- <col ref="matrcd" style="text-align:center; "/>
- <col ref="matrnm"/>
- <col ref="prodcmpynm"/>
- <col ref="maincustlastsuplplcenm"/>
- <col ref="mkdeptnm"/>
- <script type="javascript" ev:event="ondblclick">
- <![CDATA[
- btn_select.dispatch("DOMActivate");
- ]]>
- </script>
- <script type="javascript" ev:event="onkeypress">
- <![CDATA[
- if(event.keyCode == 13) {
- btn_select.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </datagrid>
- </xhtml:body>
- </xhtml:html>
|