227 lines
9.1 KiB
Plaintext
227 lines
9.1 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>
|
|
|
|
<c:set var="oemObjId" value="${projectMap.oem_objid}" />
|
|
<c:set var="carObjId" value="${projectMap.car_objid}" />
|
|
<c:set var="factoryObjId" value="${projectMap.OEM_FACTORY}" />
|
|
|
|
</head>
|
|
<script>
|
|
$(document).ready(function(){
|
|
$("#btn_close").click(function(){
|
|
self.close(0);
|
|
});
|
|
|
|
if('${projectMap.CFT_TEAM_CD}'!=''){
|
|
optionJobGroup('${projectMap.CFT_TEAM_CD}');
|
|
$("#cft_userid").val('${projectMap.CFT_USERID}');
|
|
}
|
|
|
|
//취소
|
|
$("#btnCancel").click(function(){
|
|
var objId = $(this).attr("data-OBJID");
|
|
var params = "?objId="+objId;
|
|
document.form1.action ="/project/projectDetailPopUp.do"+params;
|
|
document.form1.submit();
|
|
});
|
|
|
|
|
|
//SR자료등록 팝업
|
|
$(".File1").click(function(){
|
|
var objId = $(this).attr("data-OBJID");
|
|
Swal.fire(objId);
|
|
/* var docType =$(this).attr("data-docType");
|
|
var docTypeName = $(this).attr("data-docTypeName");
|
|
var params = "?targetObjId="+objId+"&docType="+docType+"&docTypeName="+docTypeName;
|
|
window.open("/projectConcept/FileRegistPopup.do"+params, "", "width=800, height=335"); */
|
|
});
|
|
|
|
$("#cav").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
$("#assy_labor_ct").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
$("#labor_wage_rate").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
});
|
|
$("#setup_time").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
$("#setup_person").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
$("#lot").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
|
|
$("#et").keyup(function(event) {
|
|
Setassy_labor_price();
|
|
Setassy_expense_price();
|
|
});
|
|
$("#expense_wage_rate").keyup(function(event) {
|
|
Setassy_expense_price();
|
|
});
|
|
$("#ind_exp").keyup(function(event) {
|
|
Setassy_expense_price();
|
|
});
|
|
|
|
});
|
|
|
|
|
|
function Setassy_labor_price(){
|
|
var assy_labor_ct = parseFloat($("#assy_labor_ct").val());
|
|
var et = parseFloat($("#et").val());
|
|
var cav = parseFloat($("#cav").val());
|
|
var setup_time = parseFloat($("#setup_time").val());
|
|
var lot = parseFloat($("#lot").val());
|
|
var labor_wage_rate = parseFloat($("#labor_wage_rate").val());
|
|
var setup_person = parseFloat($("#setup_person").val());
|
|
|
|
if("" != assy_labor_ct && "" != et && "" != cav && "" != setup_time && "" != lot && "" != labor_wage_rate && "" != setup_person){
|
|
assy_labor_price = Math.round(((assy_labor_ct*(1+(et/100)))/cav + (setup_time*60/lot))*labor_wage_rate/3600*setup_person*100)/100
|
|
$("#assy_labor_price").val(assy_labor_price)
|
|
}
|
|
|
|
}
|
|
|
|
function Setassy_expense_price(){
|
|
var assy_labor_ct = parseFloat($("#assy_labor_ct").val());
|
|
var et = parseFloat($("#et").val());
|
|
var cav = parseFloat($("#cav").val());
|
|
var setup_time = parseFloat($("#setup_time").val());
|
|
var lot = parseFloat($("#lot").val());
|
|
var expense_wage_rate = parseFloat($("#expense_wage_rate").val());
|
|
var ind_exp = parseFloat($("#ind_exp").val());
|
|
var setup_person = parseFloat($("#setup_person").val());
|
|
|
|
if("" != assy_labor_ct && "" != et && "" != cav && "" != setup_time && "" != lot && "" != labor_wage_rate && "" != setup_person){
|
|
assy_expense_price = Math.round(((assy_labor_ct*(1+(et/100)))/cav + (setup_time*60/lot))*expense_wage_rate*(1+(ind_exp/100))/3600*setup_person*100)/100
|
|
$("#assy_expense_price").val(assy_expense_price)
|
|
}
|
|
}
|
|
|
|
|
|
//수주활동 등록정보 수정
|
|
function fn_save(){
|
|
if(fnc_valitate("form1")){
|
|
if(confirm("저장하시겠습니까?")){
|
|
saveProcess();
|
|
}
|
|
}
|
|
}
|
|
|
|
function saveProcess(){
|
|
$.ajax({
|
|
url:"/project/saveAssemblyCost.do",
|
|
type:"POST",
|
|
data:$("#form1").serialize(),
|
|
dataType:"json",
|
|
success:function(data){
|
|
Swal.fire(data.RESULT.msg);
|
|
opener.location.reload();
|
|
self.close();
|
|
},
|
|
error: function(jqxhr, status, error){
|
|
}
|
|
});
|
|
}
|
|
|
|
</script>
|
|
<body>
|
|
<form name="form1" id="form1" action="" method="post">
|
|
<input type="hidden" name="objId" id="objId" value="${info.objid}">
|
|
<input type="hidden" name="target_objid" id="target_objid" value="${param.objId}">
|
|
<section class="business_popup_min_width">
|
|
<div class="plm_menu_name">
|
|
<h2>
|
|
<span>조립비 등록</span>
|
|
</h2>
|
|
</div>
|
|
<div class="plm_table_wrap">
|
|
<div>
|
|
<!-- <div style="width:100%;">
|
|
<div style="overflow-y:scroll; height:500px;"> -->
|
|
<table class="plm_table">
|
|
<colgroup>
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
<col width="10%">
|
|
</colgroup>
|
|
<thead>
|
|
<tr class="plm_thead">
|
|
<td>PART NAME</td>
|
|
<td>photo</td>
|
|
<td>Process</td>
|
|
<td>CAV</td>
|
|
<td>조립노무C/T</td>
|
|
<td>조립경비C/T</td>
|
|
<td>노무임율</td>
|
|
<td>경비임율</td>
|
|
<td>조립 SET UP 준비시간<br>(Min)</td>
|
|
<td>조립 SET UP 준비인원</td>
|
|
<td>LOT 수량</td>
|
|
<td>ET 율(EXCEPTION TIME)</td>
|
|
<td>조립가동율(IND EXP)</td>
|
|
<td>조립 노무비 금액</td>
|
|
<td>조립 경비 금액</td>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td><input type="text" id="part_name" name="part_name" value="${info.PART_NAME}"></td>
|
|
<td><input type="text" id="photo" name="photo" value="${info.PHOTO}"></td>
|
|
<td><input type="text" id="process" name="process" value="${info.PROCESS}"></td>
|
|
<td><input type="text" id="cav" name="cav" value="${info.CAV}" required reqTitle="cav" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="assy_labor_ct" name="assy_labor_ct" value="${info.ASSY_LABOR_CT}" required reqTitle="assy_labor_ct" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="assy_expense_ct" name="assy_expense_ct" value="${info.ASSY_EXPENSE_CT}" required reqTitle="assy_expense_ct" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="labor_wage_rate" name="labor_wage_rate" value="${info.LABOR_WAGE_RATE}" required reqTitle="labor_wage_rate" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="expense_wage_rate" name="expense_wage_rate" value="${info.EXPENSE_WAGE_RATE}" required reqTitle="expense_wage_rate" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="setup_time" name="setup_time" value="${info.SETUP_TIME}" required reqTitle="setup_time" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="setup_person" name="setup_person" value="${info.SETUP_PERSON}" required reqTitle="setup_person" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="lot" name="lot" value="${info.LOT}" required reqTitle="lot" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="et" name="et" value="${info.ET}" required reqTitle="et" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="ind_exp" name="ind_exp" value="${info.IND_EXP}" required reqTitle="ind_exp" style="background-color: yellow;"></td>
|
|
<td><input type="text" id="assy_labor_price" name="assy_labor_price" value="${info.ASSY_LABOR_PRICE}" required reqTitle="assy_labor_price" style="background-color: #26f926;"></td>
|
|
<td><input type="text" id="assy_expense_price" name="assy_expense_price" value="${info.ASSY_EXPENSE_PRICE}" required reqTitle="assy_expense_price" style="background-color: #26f926;"></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="btn_wrap" style="clear:both;">
|
|
<div class="plm_btn_wrap_center">
|
|
<input type="button" value="저장" class="plm_btns" onclick="javascript:fn_save();">
|
|
<input type="button" value="닫기" class="plm_btns" onclick="javascript:self.close(0);">
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</section>
|
|
</form>
|
|
</body>
|
|
</html> |