123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304 |
- <?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>
- <imagelst>
- <item>
- <filenm/>
- <filepath/>
- <healexamflag/>
- <rsrvdd/>
- <rsrvno/>
- </item>
- </imagelst>
- <image>
- <attachfile>
- <image/>
- </attachfile>
- </image>
- </main>
- <send>
- <healexamflag/>
- <healexamdetlflag/>
- <rsrvdd/>
- <rsrvno/>
- <pid/>
- <orddd/>
- <cretno/>
- <pkgcd/>
- <image>
- <file/>
- </image>
- <savedata/>
- <filepath/>
- </send>
- <delsend>
- <rtno/>
- <filepath/>
- <seq/>
- <ckno/>
- <cknoseq/>
- <trseq/>
- <imgseq/>
- <rttmd/>
- <appgb/>
- <m/>
- </delsend>
- <init>
- <send/>
- </init>
- <hidden>
- <dflag>N</dflag>
- </hidden>
- <imgsend>
- <filepath/>
- </imgsend>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-model-construct">
- <![CDATA[
-
- ]]>
- </script>
- <submission id="TRAHA04415" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/imagelst"/>
- <submission id="TRAHA04416" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/image"/>
- <submission id="TXAHA04413" mediatype="multipart/form-data" method="form-data-post" ref="/root/send" resultref="/root/hidden/temp"/>
- <submission id="TXAHA04414" mediatype="multipart/form-data" method="form-data-post" ref="/root/send" resultref="/root/hidden/temp"/>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- fInitialize();
- ]]>
- </script>
- </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="../../../ast/examcureweb/js/AEZ0001.js"/>
- <script type="javascript">
- <![CDATA[
- // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
- function fInitialize() {
- btn_addfile.disabled = true;
- btn_upload.disabled = true;
- btn_del.disabled = true;
- btn_down.disabled = true;
-
- if(checkOpener()) {
- var rsrvdd = model.getValue("/root/init/send/rsrvdd");
- var rsrvno = model.getValue("/root/init/send/rsrvno");
-
- if(rsrvdd != "" && rsrvno != "") {
- model.setValue("/root/send/healexamflag" , model.getValue("/root/init/send/healexamflag"));
- model.setValue("/root/send/healexamdetlflag" , model.getValue("/root/init/send/healexamdetlflag"));
- model.setValue("/root/send/rsrvdd" , rsrvdd);
- model.setValue("/root/send/rsrvno" , rsrvno);
- model.setValue("/root/send/pid" , model.getValue("/root/init/send/pid"));
- model.setValue("/root/send/orddd" , model.getValue("/root/init/send/orddd"));
- model.setValue("/root/send/cretno" , model.getValue("/root/init/send/cretno"));
- model.setValue("/root/send/pkgcd" , model.getValue("/root/init/send/pkgcd"));
-
- btn_addfile.disabled = false;
- btn_upload.disabled = false;
- btn_del.disabled = false;
- btn_down.disabled = false;
-
- submit("TRAHA04415");
- }else {
- btn_addfile.disabled = true;
- btn_upload.disabled = true;
- btn_del.disabled = true;
- btn_down.disabled = true;
- }
- model.removeNodeset(grd_addiamge.nodeset);
- grd_addiamge.refresh();
-
- }
-
- }
-
- var cnj_img_view = null;
-
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="1200" pageheight="750" guideline="1,1175;1,1175;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
- <group id="group3" scroll="auto" style="left:0px; top:0px; width:1180px; height:735px; ">
- <line id="line8" class="line_1" style="x1:0px; y1:42px; x2:1165px; y2:43px; "/>
- <caption id="caption20" class="tit_2" style="left:6px; top:27px; width:118px; height:14px; ">사진 목록</caption>
- <caption id="caption2" class="tit_1" style="left:0px; top:0px; width:217px; height:14px; vertical-align:middle; ">판정이미지 관리</caption>
- <button id="btn_upload" class="btn5_letter4" style="left:290px; top:390px; width:64px; height:19px; ">
- <caption>업로드</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if (grd_addiamge.rows == 1)
- {
- messageBox("업로드될 파일이", "I004");
- return false;
- }
- if (submit("TXAHA04413")) {
- submit("TRAHA04415");
- model.removeNodeset(grd_addiamge.nodeset);
- grd_addiamge.refresh();
- }
- ]]>
- </script>
- </button>
- <button id="btn_addfile" class="btn2_letter4" style="left:215px; top:390px; width:64px; height:19px; ">
- <caption>파일추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var maxsize = upload1.attribute("filesize");
-
- files = window.fileDialog("open", "|", true);
- filelist = files.split("|");
- for(var i = 0 ; i < filelist.length ; i++ ) {
- var file = filelist[i];
- if(file != "") {
- grd_addiamge.addRow(false);
- grd_addiamge.valueMatrix(grd_addiamge.rows - 1, 0) = file;
- if (!checkFileSize(upload1)){
- grd_addiamge.removeItem();
- messageBox("파일 크기가 최대치("+maxsize+"Byte)를", "E003");
-
- }
- }
- }
- ]]>
- </script>
- </button>
- <datagrid id="grd_attachfile" nodeset="/root/main/imagelst/item" visibility="visible" caption="첨부파일명^서버저장경로^건진구분^예약일자^예약번호" colwidth="307, 100, 100, 100, 100" extendlastcol="scroll" mergecellsfixedrows="bycolrec" rowheader="update" style="left:0px; top:47px; width:350px; height:333px; ">
- <col ref="filenm"/>
- <col ref="filepath" visibility="hidden"/>
- <col ref="healexamflag" visibility="hidden"/>
- <col ref="rsrvdd" visibility="hidden"/>
- <col ref="rsrvno" visibility="hidden"/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- if (isDataCell()) {
- var idx = grd_attachfile.row;
- if(idx == 0) return false;
- var filepath = grd_attachfile.valueMatrix( idx , grd_attachfile.colRef("filepath"));
-
- model.setValue("/root/send/filepath", filepath);
-
- submit("TRAHA04416");
-
- setImageRefInstance("/root/main/image/attachfile/image");
-
- model.refresh();
-
- img1.initStyle("height");
- img1.initStyle("width");
-
- if(img1.currentStyle.width > 800)
- {
- var imgWidth = img1.currentStyle.width;
- var imgHeight = img1.currentStyle.height;
-
- var imgRate = 800 / imgWidth;
-
- img1.attribute("width") = 800;
- img1.attribute("height") = imgHeight * imgRate;
- }
-
- if(img1.currentStyle.height > 700)
- {
- var imgWidth = img1.currentStyle.width;
- var imgHeight = img1.currentStyle.height;
-
- var imgRate = 700 / imgHeight;
-
- img1.attribute("width") = imgWidth / imgRate;
- img1.attribute("height") = 700;
- }
-
- img1.refresh();
- }
- ]]>
- </script>
- </datagrid>
- <upload id="upload1" nodeset="/root/send/image/file" ext="zip" filecount="5" filesize="5242880" validate="true" style="left:115px; top:380px; width:100px; height:20px; "/>
- <datagrid id="grd_addiamge" nodeset="/root/send/image" caption="파일경로^" colwidth="644" extendlastcol="scroll" mergecellsfixedrows="bycolrec" style="left:0px; top:410px; width:355px; height:150px; ">
- <col ref="file"/>
- </datagrid>
- <button id="btn_del" class="btn5_letter3" style="left:295px; top:20px; width:53px; height:19px; ">
- <caption>삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
-
- if ( (grd_attachfile.row < grd_attachfile.fixedRows) ) {
- return false;
- }
- if ( messageBox("선택된 파일을 ","Q001") != 6 )
- {
- return false;
- }
- grd_attachfile.clearStatus()
- for(var i = 0 ; i < grd_attachfile.selectedRows; i++)
- {
- var cur_row = grd_attachfile.selectedRow(i);
-
- grd_attachfile.rowStatus(cur_row) = 4;
- }
-
- model.setValue("/root/send/savedata", grd_attachfile.getUpdateData());
- if( messageBox("이미지를 ", "Q001") !=6) return ;
- if(submit("TXAHA04414")) {
- submit("TRAHA04415");
- }
- ]]>
- </script>
- </button>
- <img id="img1" ref="/root/main/image/attachfile/image" style="left:360px; top:50px; background-stretch:stretch; border-color:#B0B0B0; border-style:solid; ">
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- // 파라미터를 이용한 방법 첫번째
- // setParameter("opener_parameter_id", model.getValue("/root/image/attachfile/image"));
- // modal("SPAEA02603", "0", "900", "900", "SPAEA02603","","");
- // 파라미터 두번째 방법
- var image = model.getValue("/root/image/attachfile/image");
- var printyn = "N";
-
- var sendimage = (image + "▦" + printyn);
-
- setParameter("opener_parameter_id", sendimage);
- modal("SPAEA02603", "0", "0", "0", "SPAEA02603","","");
- ]]>
- </script>
- </img>
- <button id="btn_down" class="btn2_letter4" style="left:1100px; top:20px; width:64px; height:19px; ">
- <caption>파일저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(model.getValue("/root/main/image/attachfile/image") != "")
- {
- var idx = grd_attachfile.row;
- var filepath = grd_attachfile.valueMatrix(idx , grd_attachfile.colRef("filepath"));
- var filenm = grd_attachfile.valueMatrix(idx , grd_attachfile.colRef("filenm"));
- var localfile = window.fileDialog("save","|",false,filenm,"","All Files(*.*)|*.*");
- if (localfile != "") {
- model.download(getActionURL("TRAHA04417")+"&filepath="+filepath,localfile);
- var rtn = messageBox("파일을", "Q004");
- if( rtn == 6 ) {
- window.exec(localfile);
- }
- }
- }
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|