SuppNotiDetailPopup.jsp 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  1. <%--
  2. - FileName : SuppNotiDetail.jsp
  3. - Author : gyeongmo an
  4. - Date : 2014.07.18
  5. - Copyright : Copyright (c) 2014 www.udapsoft.co.kr, Inc.
  6. - All rights reserved.
  7. - Description: 협력업체 공지사항 상세
  8. --%>
  9. <%@ page contentType="text/html; charset=utf-8" %>
  10. <%@ page import="com.udapsoft.waf.system.HandlerStorage" %>
  11. <%@ page import="com.udapsoft.waf.common.ui.*" %>
  12. <%@ page import="kr.co.hsnc.common.util.*"%>
  13. <%@ page import="kr.co.hsnc.common.sql.*" %>
  14. <%@ page import="kr.co.hsnc.common.sql.*" %>
  15. <%@ page import="kr.co.udapsoft.ebid.buyer.common.file.FileManager" %>
  16. <%@ include file="/jsp/work/taglib.jsp" %>
  17. <jsp:useBean id="ctx" class="com.udapsoft.waf.system.context.SessionContext" scope="session" />
  18. <%
  19. ctx.init(request, response);
  20. String fevent = ctx.get("fevent");
  21. HandlerStorage storage = ctx.getHandlerStorage();
  22. ValueObject params = storage.getParams();
  23. ValueObject user = storage.getUser();
  24. String acct_id = "";
  25. if(user != null) {
  26. acct_id = user.get("acct_id");
  27. }
  28. ValueObject vo = storage.getValueObject("suppNotiDetailRowSet");
  29. String notiDy = vo.get("noti_dy").substring(0, 4) + "-" + vo.get("noti_dy").substring(4, 6) + "-" +
  30. vo.get("noti_dy").substring(6, 8);
  31. // 레이어로 띄웠는지 체크
  32. String layerYn = params.get("layerYn");
  33. String tempWidth= "";
  34. if(layerYn.equals("Y")) {
  35. tempWidth="770px";
  36. } else {
  37. tempWidth="100%";
  38. }
  39. String pop_win_id = "";
  40. if(!"".equals(params.get("pop_win_id"))) {
  41. pop_win_id = params.get("pop_win_id");
  42. }
  43. %>
  44. <SCRIPT language="JavaScript">
  45. function _onReady(){
  46. var f = document.form1;
  47. jQuery("#btnList").click(function() {
  48. var f = document.form1;
  49. f.fevent.value ="";
  50. f.layerYn.value = '<%=layerYn%>';
  51. f.pop_win_id.value = '<%=pop_win_id%>';
  52. f.action = "/supplier/portal/center/SuppNotiListPopup.screen";
  53. f.target = "_self";
  54. f.submit();
  55. });
  56. jQuery("#btnClose").click(function() {
  57. setTimeout(function(){parent.searchNoticeClose(null);},100);
  58. });
  59. }
  60. //첨부파일
  61. function doAttachFile(obj) {
  62. if(obj.value==''){
  63. alert("저장을 한 후 파일을 첨부할 수 있습니다.");
  64. }
  65. else if(obj.value != ''){
  66. viewFileListNew('NOTI_DETAIL', obj.value, document.form1.p_AttachFile, "N", "");
  67. }
  68. }
  69. function doAttachFileDiv(obj) {
  70. if(obj==''){
  71. alert("저장을 한 후 파일을 첨부할 수 있습니다.");
  72. }
  73. else if(obj != ''){
  74. viewFileListNew('NOTI_DETAIL', obj.value, document.getElementById("attach_file_view"), "N", "");
  75. }
  76. }
  77. function doDownFile(fileId){
  78. var url="/common/file/FileDownloadServlet";
  79. url += "?file_id=" + fileId;
  80. window.open(url, "_fileDown", "toolbar=no, width=400, height=100, top=500, left=400, toolbar=no,directories=no,status=no,scrollbars=yes,resize=no,menubar=no,target=new")
  81. }
  82. /**
  83. * 첨부파일 예약 함수
  84. */
  85. function fileDown(file_id){
  86. var url="/common/file/FileDownloadServlet";
  87. url += "?file_id=" + file_id;
  88. //window.open(url, "_fileDown", "toolbar=no, width=400, height=100, top=500, left=400, toolbar=no,directories=no,status=no,scrollbars=yes,resize=no,menubar=no,target=new")
  89. window.open("", "_fileDown", "toolbar=no, width=400, height=100, top=500, left=400, toolbar=no,directories=no,status=no,scrollbars=yes,resize=no,menubar=no,target=new")
  90. var fd = document.getElementById("form_filedown");
  91. fd.target = "_fileDown";
  92. fd.file_id.value = file_id;
  93. fd.submit();
  94. }
  95. </script>
  96. <form id="form1" name="form1" method="post" modular:type="search">
  97. <STYLE>
  98. BODY {
  99. OVERFLOW-X : HIDDEN ;
  100. }
  101. </STYLE>
  102. <INPUT type="hidden" name="fevent" value="<%= params.get("fevent") %>">
  103. <INPUT type="hidden" name="write_id" value="<%=acct_id%>">
  104. <INPUT type="hidden" name="seq" value="<%=vo.get("seq")%>">
  105. <INPUT type="hidden" name="supp_open_yn_value">
  106. <INPUT type="hidden" name="layerYn">
  107. <INPUT type="hidden" name="pop_win_id">
  108. <!-- 제목 및 버튼 -->
  109. <table width="100%">
  110. <colgroup>
  111. <col width="500" />
  112. <col width="*" />
  113. </colgroup>
  114. <tr>
  115. <td align="right">
  116. <span class="btnSearch center"><a href="javascript:void(0);" id="btnList">목록</a></span>
  117. <%if(layerYn.equals("Y")) { %>
  118. <span class="btnSearch center"><a href="javascript:void(0);" id="btnClose">닫기</a></span>
  119. <%} %>
  120. </td>
  121. </tr>
  122. </table>
  123. <TABLE class="form-table">
  124. <col width="18%">
  125. <col width="44%">
  126. <col width="18%">
  127. <col width="20%">
  128. <tr>
  129. <th style="text-align: left;">
  130. 제목
  131. </th>
  132. <td>
  133. <%= InputText.get("supp_noti_title", vo.get("title"), 45, 30, "class=input_blank, readOnly=white, string, left, tabIndex=-1", "string") %>
  134. </td>
  135. <th style="text-align: left;">
  136. 공지일자
  137. </th>
  138. <td>
  139. <%= InputText.get("notiDy", notiDy, 45, 30, "class=input_blank, readOnly=white, string, left, tabIndex=-1", "string") %>
  140. </td>
  141. </tr>
  142. <tr>
  143. <th style="text-align: left;">
  144. 작성자
  145. </th>
  146. <td colspan="3">
  147. <%= InputText.get("write_nm", vo.get("write_nm"), 45, 30, "class=input_blank, readOnly=white, string, left, tabIndex=-1", "string") %>
  148. </td>
  149. </tr>
  150. <tr>
  151. <th style="text-align: left;">
  152. 내용
  153. </th>
  154. <td colspan="3" >
  155. <div id="content" style="overflow:auto;width:100%;height:220px;min-height:200px;">
  156. <%=HTMLCvt.cvtHTML(vo.get("content")) %>
  157. </div>
  158. </td>
  159. </tr>
  160. <tr>
  161. <th style="text-align: left;">
  162. 첨부파일
  163. </th>
  164. <td colspan="3">
  165. <div id="attach_file_view" class="attach_file_view" style="overflow:auto;width:100%;height:60px;min-height:60px;">
  166. <!-- 첨부 파일 화면에 바로보일때 사용 -->
  167. <%=FileManager.getFileListForDiv("NOTI_DETAIL", vo.get("seq")) %>
  168. </div>
  169. </td>
  170. </tr>
  171. </table>
  172. </form>
  173. <FORM id="form_filedown" name="form_filedown" method="get" action="/common/file/FileDownloadServlet" style="display:none">
  174. <input type="hidden" id="file_id" name="file_id"/>
  175. </FORM>