164 lines
4.6 KiB
Plaintext
164 lines
4.6 KiB
Plaintext
<%@ page language="java" contentType="text/html; charset=UTF-8"
|
|
pageEncoding="UTF-8"%>
|
|
<%@ page import="com.pms.common.utils.*"%>
|
|
<%@ page import="java.util.*"%>
|
|
<%@include file="/init.jsp"%>
|
|
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
<title><%=Constants.SYSTEM_NAME%></title>
|
|
|
|
<script type="text/javascript">
|
|
|
|
$(document).ready(function(){
|
|
fnc_setFileDropZone("dropzone", "${boardInfo.OBJID}", "${NOTICE_ATTACH_CODE}", "${NOTICE_ATTACH_NAME}", "fn_fileCallback",false);
|
|
|
|
fn_fileCallback();
|
|
|
|
});
|
|
|
|
function save(){
|
|
if(confirm("저장하시겠습니까?")){
|
|
$.ajax({
|
|
type : "POST",
|
|
url : "/notice/saveNotice.do",
|
|
data:$("#form1").serialize(),
|
|
dataType:"JSON",
|
|
async:false,
|
|
error: function(jqxhr, status, error){
|
|
},
|
|
success: function(result){
|
|
Swal.fire(result.message);
|
|
opener.fn_search();
|
|
self.close();
|
|
}
|
|
});
|
|
}
|
|
}
|
|
|
|
function fn_fileCallback(){
|
|
$.ajax({
|
|
url:"/common/getFileList.do",
|
|
type:"POST",
|
|
data:{"targetObjId":"${boardInfo.OBJID}", "docType":"${NOTICE_ATTACH_CODE}"},
|
|
dataType:"json",
|
|
async:true,
|
|
success:function(data){
|
|
if(0 < data.length){
|
|
//파일드롭다운 영역 hide
|
|
$("#uploadedFileAreaDefault").hide();
|
|
//첨부파일 목록 영역 show
|
|
$("#specAttachFileList").show();
|
|
$("#uploadedFileArea").empty();
|
|
|
|
$.each(data, function(i){
|
|
|
|
var appendText = "";
|
|
appendText+= "<tr>";
|
|
appendText+= " <td><a href='javascript:fnc_downloadFile(\""+data[i].OBJID+"\")'>"+data[i].REAL_FILE_NAME+"</a></td>";
|
|
appendText+= "</tr>";
|
|
|
|
$("#uploadedFileArea").append(appendText);
|
|
});
|
|
}else{
|
|
$("#uploadedFileAreaDefault").show();
|
|
$("#specAttachFileList").show();
|
|
$("#uploadedFileArea").empty();
|
|
}
|
|
},
|
|
error: function(jqxhr, status, error){
|
|
}
|
|
});
|
|
}
|
|
|
|
|
|
function openSpecDataPopUp(objid){
|
|
window.open("","specDataPopUp","width=900 height=780 menubar=no status=no");
|
|
|
|
var hiddenForm = document.form1;
|
|
var url = "/specData/specDataDetailViewPopup.do";
|
|
|
|
hiddenForm.objid.value = objid;
|
|
hiddenForm.target = "specDataPopUp";
|
|
hiddenForm.action = url;
|
|
hiddenForm.submit();
|
|
}
|
|
|
|
</script>
|
|
|
|
</head>
|
|
<body class="backcolor_light_blue">
|
|
<form name="form1" id="form1" method="post">
|
|
<input type="hidden" name="objid" id="objid">
|
|
<input type="hidden" name="objId" id="objId" value="${boardInfo.OBJID}">
|
|
<input type="hidden" name="systemType" id="systemType" value="${empty boardInfo.SYSTEM_TYPE? systemType:boardInfo.SYSTEM_TYPE}">
|
|
<input type="hidden" name="boardType" id="boardType" value="notice">
|
|
<input type="hidden" name="actionType" id="actionType" value="${param.actionType}">
|
|
<div class="plm_menu_name">
|
|
<h2>
|
|
<span>공지사항</span>
|
|
</h2>
|
|
</div>
|
|
<div id="businessPopupFormWrap">
|
|
<table class="pmsPopupForm">
|
|
<colgroup>
|
|
<col width="10%">
|
|
<col width="77%">
|
|
<col width="10%">
|
|
<col width="3%">
|
|
</colgroup>
|
|
<tr>
|
|
<td class="input_title"><label for="" class="">제목</label></td>
|
|
<td class="tr_data_border_bottom">
|
|
${boardInfo.TITLE}
|
|
</td>
|
|
<td class="input_title"><label for="">중요</label></td>
|
|
<td>
|
|
<input type="checkbox" name="important" id="important" ${!empty boardInfo.IMPORTANT? 'checked': ''} value="checked" disabled>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="input_title"><label for="">내용</label></td>
|
|
<td colspan="3">
|
|
<c:choose>
|
|
<c:when test="${'specRevision' eq boardInfo.REQ_CATEGORY}">
|
|
<a href="#" onclick="openSpecDataPopUp('${boardInfo.REQ_CONTENTS}');">바로가기</a>
|
|
</c:when>
|
|
<c:otherwise>
|
|
<textarea class="" style="width:100%;" rows="20" readonly name="reqContents" id="reqContents" placeholder="내용을 입력하세요." readonly>${boardInfo.REQ_CONTENTS}</textarea>
|
|
</c:otherwise>
|
|
</c:choose>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="input_title" rowspan="2">
|
|
<label for="">첨부파일</label>
|
|
</td>
|
|
<td colspan="3">
|
|
<div id="specAttachFileList" style="height:50px;">
|
|
<table id="uploadedFileAreaTable" class="spec_data_in_table">
|
|
<colgroup>
|
|
<col width="*">
|
|
</colgroup>
|
|
<tbody id="uploadedFileAreaDefault">
|
|
<tr>
|
|
<td colspan="2">첨부된 파일이 없습니다.</td>
|
|
</tr>
|
|
</tbody>
|
|
<tbody id="uploadedFileArea">
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<div class="btnCenterWrap">
|
|
<center class="center_btns_wrap">
|
|
<input type="button" id="closeBtn" value="닫기" class="plm_btns" onclick="javascript:self.close();">
|
|
</center>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</body>
|
|
</html> |