153 lines
4.7 KiB
Plaintext
153 lines
4.7 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>
|
|
</head>
|
|
<script>
|
|
$(document).ready(function(){
|
|
|
|
//닫기
|
|
$("#btnClose").click(function(){
|
|
self.close(0);
|
|
});
|
|
|
|
//저장
|
|
$("#btnDisconnect").click(function(){
|
|
fn_disConnectWBSTask();
|
|
});
|
|
|
|
fn_getConnectedWBSTask();
|
|
|
|
});
|
|
</script>
|
|
<script>
|
|
//검색조건에 해당하는 프로젝트의 WBS Task 목록을 가져온다.
|
|
function fn_getConnectedWBSTask(){
|
|
$.ajax({
|
|
url:"/project/wbs/getFNTaskConnectedTaskList.do",
|
|
type:"POST",
|
|
data:{"subObjId":"${param.subObjId}"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
$("#dataList").empty();
|
|
|
|
var appendText = "";
|
|
|
|
if(0 < data.length){
|
|
$.each(data, function(i){
|
|
appendText +="<colgroup>";
|
|
appendText +=" <col width='5%'>";
|
|
appendText +=" <col width='5%'>";
|
|
appendText +=" <col width='15%'>";
|
|
appendText +=" <col width='15%'>";
|
|
appendText +=" <col width='*'>";
|
|
appendText +="</colgroup>";
|
|
appendText += "<tr>";
|
|
appendText += " <td><input type='checkbox' name='wbsTaskCheckBox' value='"+fnc_checkNull(data[i].TARGET_OBJID)+"'></td>";
|
|
appendText += " <td>"+data[i].RNUM+"</td>";
|
|
appendText += " <td title='"+data[i].OEM_NAME+"'>"+data[i].OEM_NAME+"</td>";
|
|
appendText += " <td title='"+data[i].CAR_CODE+"("+data[i].CAR_NAME+"'>"+data[i].CAR_CODE+"("+data[i].CAR_NAME+")</td>";
|
|
appendText += " <td title='"+data[i].TASK_NAME+"'><a href='#' onclick=\"fn_openWBSTaskDetailPopUp('"+data[i].TARGET_OBJID+"');\">"+data[i].TASK_NAME+"</td>";
|
|
appendText += "</tr>";
|
|
});
|
|
}else{
|
|
appendText += "<tr>";
|
|
appendText += " <td colspan='5'>조건에 해당하는 Task가 없습니다.</td>";
|
|
appendText += "</tr>";
|
|
}
|
|
$("#dataList").append(appendText);
|
|
},
|
|
error: function(jqxhr, status, error){
|
|
}
|
|
});
|
|
}
|
|
|
|
//선택된 WBS Task와 연결을 해제한다.
|
|
function fn_disConnectWBSTask(){
|
|
var taskCheckBoxCnt = $("input[name=wbsTaskCheckBox]:checkbox:checked").length;
|
|
if(0 < taskCheckBoxCnt){
|
|
if(confirm("선택된 WBS Task와 연결해제 하시겠습니까?")){
|
|
var form = $("#form1").serialize();
|
|
$.ajax({
|
|
url:"/project/wbs/disConnectProjectWBSTask.do",
|
|
type:"POST",
|
|
data:form,
|
|
dataType:"json",
|
|
async:false,
|
|
success:function(data){
|
|
if(data.result == "true" || data.result == true || data.result){
|
|
Swal.fire("처리되었습니다.");
|
|
opener.location.reload();
|
|
self.close();
|
|
}
|
|
},
|
|
error: function(jqxhr, status, error){
|
|
}
|
|
});
|
|
}
|
|
}else{
|
|
Swal.fire("선택된 대상이 없습니다.");
|
|
return false;
|
|
}
|
|
}
|
|
|
|
//WBS Task의 상세내용을 보여준다.
|
|
function fn_openWBSTaskDetailPopUp(objId) {
|
|
//wbs 등록 팝업
|
|
window.open("/project/wbs/wbsTaskDetailPopUp.do?taskObjId="+objId+"&actionType=view", "wbsTaskPopUp", "width=700, height=450");
|
|
}
|
|
|
|
</script>
|
|
|
|
<body>
|
|
<form name="form1" id="form1" action="" method="post">
|
|
<input type="hidden" name="subObjId" id="subObjId" value="${param.subObjId}"/>
|
|
<section style="min-width:500px;">
|
|
<div class="plm_menu_name">
|
|
<h2>
|
|
<span>WBS Task</span>
|
|
</h2>
|
|
</div>
|
|
<div id="businessPopupFormWrap" style="">
|
|
<div class="form_popup_title"> 연결 WBS Task </div>
|
|
<div class="plm_table_wrap" style="width:98%; margin: 0 auto;">
|
|
<div style="overflow-y:scroll; margin-top:15px;">
|
|
<table class="project_form_in_table" style="width:100%;">
|
|
<colgroup>
|
|
<col width="5%">
|
|
<col width="5%">
|
|
<col width="15%">
|
|
<col width="15%">
|
|
<col width="*">
|
|
</colgroup>
|
|
<thead>
|
|
<tr>
|
|
<td><input type="checkbox"></td>
|
|
<td>No</td>
|
|
<td>고객사</td>
|
|
<td>차종</td>
|
|
<td>Task 명</td>
|
|
</tr>
|
|
</thead>
|
|
</table>
|
|
</div>
|
|
<div class="in_table_scroll_wrap" style="height:210px; width:100%;">
|
|
<table id="dataList" class="fileListscrollTbody"></table>
|
|
</div>
|
|
</div>
|
|
<div class="btn_wrap">
|
|
<div class="plm_btn_wrap_center">
|
|
<input type="button" value="연결해제" id="btnDisconnect" class="plm_btns">
|
|
<input type="button" value="닫기" id="btnClose" class="plm_btns">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</section>
|
|
</form>
|
|
</body>
|
|
</html> |