Files
KIN/project/project_list2_dep_2014.asp
2025-09-29 17:55:08 +09:00

3858 lines
277 KiB
Plaintext
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!-- #include virtual = "include/header.asp" -->
<!-- #include virtual = "include/left.asp" -->
<OBJECT RUNAT=Server PROGID=ADODB.Recordset id=rsa></OBJECT>
<%
Dim research_count
research_count = 0
p_sn = Request("p_sn")
p_sub_type = Request("p_sub_type")
initstatus = Request("initstatus")
req_p_method_cd = Request("p_method_cd")
temp_p_child_sn = ""
query = ""
query = query & "select top 1 p_method_cd from T_PROJECT_METHOD where p_child_sn = '" & Request("p_child_sn") & "' "
Adors.Open query, adoConn, 1
if Adors.recordCount > 0 and req_p_method_cd = "" then
req_p_method_cd = Adors("p_method_cd")
end if
Adors.Close
If initstatus = "init" Then
set dbin = server.CreateObject("ADODB.CONNECTION")
q = "select p_sn, p_sub_type, p_method_cd from T_PROJECT_METHOD where p_sn = '" & p_sn & "' "
Adors.Open q, adoConn, 1
if Adors.RecordCount > 0 Then
for i = 1 to Adors.RecordCount
tmp_method_cd = Adors("p_method_cd")
tmp_method_count = i
If CInt(tmp_method_cd) < 10 Then
tmp_method_cd = "0" & tmp_method_cd
End If
If tmp_method_count < 10 Then
tmp_method_count = "0" & i
End If
query = " UPDATE T_PROJECT_METHOD "
query = query & " SET p_sub_type = '"& p_sub_type &"' "
'##### ¿¬±¸ ######
query = query & " ,p_rsch_1_a = '' "
query = query & " ,p_rsch_2_a = '' "
query = query & " ,p_rsch_3_a = '' "
query = query & " ,p_rsch_4_a = '' "
query = query & " ,p_rsch_1_b = '' "
query = query & " ,p_rsch_2_b = '' "
query = query & " ,p_rsch_3_b = '' "
query = query & " ,p_rsch_4_b = '' "
query = query & " ,p_rsch_1_c = '' "
query = query & " ,p_rsch_2_c = '' "
query = query & " ,p_rsch_3_c = '' "
query = query & " ,p_rsch_4_c = '' "
'##### ½Ç»ç ######
query = query & " ,p_sv_1 = '' "
query = query & " ,p_sv_2 = '' "
query = query & " ,p_sv_3 = '' "
query = query & " ,p_sv_4 = '' "
query = query & " ,p_punch_1 = '' "
query = query & " ,p_punch_2 = '' "
query = query & " ,p_punch_3 = '' "
query = query & " ,p_punch_4 = '' "
'##### QC ######
query = query & " ,p_verify_1 = '' "
query = query & " ,p_verify_2 = '' "
query = query & " ,p_verify_3 = '' "
query = query & " ,p_verify_4 = '' "
'##### DP ######
query = query & " ,p_code_1 = '' "
query = query & " ,p_code_2 = '' "
query = query & " ,p_code_3 = '' "
query = query & " ,p_code_4 = '' "
query = query & " ,p_dp_1 = '' "
query = query & " ,p_dp_2 = '' "
query = query & " ,p_dp_3 = '' "
query = query & " ,p_dp_4 = '' "
'##### °æ¿µÀü·«½Ç ######
query = query & " ,p_it_1 = '' "
query = query & " ,p_it_2 = '' "
query = query & " ,p_it_3 = '' "
query = query & " ,p_it_4 = '' "
query = query & " ,p_progress_status = '001' "
query = query & " ,p_progress_flag = 'xxx' " ' index 1 :¿¬±¸, 2 :½Ç»ç, 3 :DP
query = query & " ,p_child_sn = '"& p_sn &"_"& p_sub_type & tmp_method_count & "' "
If CInt(req_p_method_cd) = CInt(Adors("p_method_cd")) Then
temp_p_child_sn = p_sn &"_"& p_sub_type & tmp_method_count
End If
query = query & " WHERE p_sn = '"& p_sn &"' and p_sub_type = '' and p_method_cd = '" & Adors("p_method_cd") & "' "
dbin.Open adoConn
dbin.Execute query
dbin.Close
Adors.MoveNext
Next
end If
Adors.Close
End if
'ÇÁ·ÎÁ§Æ® ±âº» Á¤º¸ °¡Á®¿À±â
If p_sub_type = "M" then
query = " SELECT PB.p_sn, PB.p_cli_company_cd as p_cli_company_cd, PB.p_cli_per_cd as p_cli_per_cd, "
query = query & " p_state, PB.p_subject, p_cli_company_nm, CP.p_cli_depart as p_cli_depart, "
query = query & " p_cli_per_nm, p_cli_per_com_tel, p_cli_per_tel, p_cli_per_email, "
query = query & " PB.p_project_type_cd as p_project_type_cd, "
query = query & " PB.p_project_nation_cd as p_project_nation_cd, "
query = query & " PB.p_client_type_cd as p_client_type_cd, p_obtain_cost, PB.p_cont_cost, PB.p_decide_date, "
query = query & " PB.p_con_date_st, PB.p_con_date_end, PB.p_export_range, PB.p_category, "
query = query & " PB.p_memo, PB.p_depart_dep as p_depart_dep, PB.p_input_user, '007' as p_progress_status, "
query = query & " isnull(PM.p_research_complete,0) as p_research_complete, "
query = query & " isnull(PM.p_field_complete,0) as p_field_complete, "
query = query & " isnull(PM.p_dp_complete,0) as p_dp_complete, "
query = query & " isnull(PM.p_it_complete,0) as p_it_complete "
query = query & " FROM "
query = query & " T_PROJECT_BASE PB INNER JOIN T_PROJECT_METHOD PM ON PB.p_sn = PM.p_sn AND PM.p_child_sn = PB.p_sn + '_M01' "
query = query & " INNER JOIN V_CLIENT_COMP CC ON PB.p_cli_company_cd = CC.p_cli_company_cd "
query = query & " INNER JOIN V_CLIENT_PERSON CP ON PB.p_cli_company_cd = CP.p_cli_company_cd AND PB.P_CLI_PER_CD = CP.P_CLI_PER_CD "
query = query & " INNER JOIN T_CLIENT_TYPE_CD CTC ON PB.p_client_type_cd = CTC.p_client_type_cd "
query = query & " WHERE PB.p_sn = '"&p_sn& "' "
else
query = " SELECT PB.p_sn "
query = query & " , PB.p_cli_company_cd as p_cli_company_cd "
query = query & " , PB.p_cli_per_cd as p_cli_per_cd "
query = query & " , p_state "
query = query & " , PM.p_subject "
query = query & " , p_cli_company_nm "
query = query & " , CP.p_cli_depart as p_cli_depart "
query = query & " , p_cli_per_nm "
query = query & " , p_cli_per_com_tel "
query = query & " , p_cli_per_tel "
query = query & " , p_cli_per_email "
query = query & " , PB.p_project_type_cd as p_project_type_cd "
query = query & " , PB.p_project_nation_cd as p_project_nation_cd "
query = query & " , PB.p_client_type_cd as p_client_type_cd "
query = query & " , PB.p_obtain_cost "
query = query & " , PM.p_cont_cost "
query = query & " , PM.p_decide_date "
query = query & " , PM.p_con_date_st "
query = query & " , PM.p_con_date_end "
query = query & " , PM.p_export_range "
query = query & " , PM.p_category "
query = query & " , PM.p_progress_status "
query = query & " , isnull(PM.p_research_complete,0) as p_research_complete "
query = query & " , isnull(PM.p_field_complete,0) as p_field_complete "
query = query & " , isnull(PM.p_dp_complete,0) as p_dp_complete "
query = query & " , isnull(PM.p_it_complete,0) as p_it_complete "
query = query & " , PB.p_memo "
query = query & " , pb.p_depart_dep as p_depart_dep "
query = query & " , PM.p_rsch_dept as p_depart_dep2 "
query = query & " , PB.p_input_user "
query = query & " FROM T_PROJECT_BASE PB "
query = query & " left outer JOIN T_PROJECT_METHOD PM "
query = query & " ON PB.p_sn = PM.p_sn "
query = query & " AND PM.p_method_cd = '" & req_p_method_cd & "' "
query = query & " left outer JOIN V_CLIENT_COMP CC "
query = query & " ON PB.p_cli_company_cd = CC.p_cli_company_cd "
query = query & " left outer JOIN V_CLIENT_PERSON CP "
query = query & " ON PB.p_cli_company_cd = CP.p_cli_company_cd "
query = query & " AND PB.P_CLI_PER_CD = CP.P_CLI_PER_CD "
query = query & " left outer JOIN T_CLIENT_TYPE_CD CTC "
query = query & " ON PB.p_client_type_cd = CTC.p_client_type_cd "
query = query & " WHERE PB.p_sn = '" & p_sn & "' "
query = query & " AND PM.p_sub_type = 'C' "
If temp_p_child_sn = "" Then
query = query & " AND PM.p_child_sn = '"& Request("p_child_sn") &"' "
Else
query = query & " AND PM.p_child_sn = '"& temp_p_child_sn &"' "
End if
End if
'Response.write query
Adors.Open query, adoConn, 1
if Adors.RecordCount > 0 Then
p_sn = Adors("p_sn")
p_cli_company_cd = Adors("p_cli_company_cd")
p_cli_per_cd = Adors("p_cli_per_cd")
p_state = Adors("p_state")
p_subject = Adors("p_subject")
p_cli_company_nm = Adors("p_cli_company_nm")
p_cli_depart = Adors("p_cli_depart")
p_cli_per_nm = Adors("p_cli_per_nm")
p_cli_per_com_tel = Adors("p_cli_per_com_tel")
p_cli_per_tel = Adors("p_cli_per_tel")
p_cli_per_email = Adors("p_cli_per_email")
p_project_type_cd = Adors("p_project_type_cd")
p_project_nation_cd = Adors("p_project_nation_cd")
p_client_type_cd = Adors("p_client_type_cd")
p_depart_dep = Adors("p_depart_dep")
p_depart_dep2 = Adors("p_depart_dep2")
p_decide_date = Adors("p_decide_date")
p_con_date_st = Adors("p_con_date_st")
p_con_date_end = Adors("p_con_date_end")
p_export_range = Adors("p_export_range")
p_category = Adors("p_category")
p_memo = Adors("p_memo")
p_input_user = Adors("p_input_user")
p_research_complete = Adors("p_research_complete")
p_field_complete = Adors("p_field_complete")
p_dp_complete = Adors("p_dp_complete")
p_it_complete = Adors("p_it_complete")
If p_sub_type = "M" then
q = "select p_sn, p_sub_type, p_child_sn from T_PROJECT_METHOD where p_sn = '" & p_sn & "' and p_sub_type = '" & p_sub_type & "' "
else
q = "select p_sn, p_sub_type, p_child_sn from T_PROJECT_METHOD where p_sn = '" & p_sn & "' and p_sub_type = '" & p_sub_type & "' and p_child_sn = '"& Request("p_child_sn") &"' "
End If
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 Then
query_p_child_sn = " and p_child_sn in ( "
query_p_child_sn2 = " and convert(varchar(50), target20) in ( "
for i = 1 to Rs.RecordCount
If i > 1 Then
query_p_child_sn = query_p_child_sn & ","
query_p_child_sn2 = query_p_child_sn2 & ","
End if
query_p_child_sn = query_p_child_sn & " '" & Rs("p_child_sn") & "' "
query_p_child_sn2 = query_p_child_sn2 & " '" & Rs("p_child_sn") & "' "
Rs.MoveNext
Next
query_p_child_sn = query_p_child_sn & " ) "
query_p_child_sn2 = query_p_child_sn2 & " ) "
end if
Rs.Close
'¿¹»ó °è¾à¾× ,¼öÁ¤
if Adors("p_cont_cost") <> "" then
tmp_len = len(Adors("p_cont_cost"))
for i = 1 to int(tmp_len)
if i mod 3 = 1 and i <> 1 then
p_cont_cost = "," & p_cont_cost
end if
p_cont_cost = left(right(Adors("p_cont_cost"),i), 1) & p_cont_cost
next
Else
p_cont_cost = 0
end If
Dim p_category_arr(19)
If p_category <> "" Then
temp_category_arr = Split(p_category, ",")
If UBound(temp_category_arr)-1 > 0 Then
For i = 0 To UBound(temp_category_arr)-1 Step 1
p_category_arr(temp_category_arr(i)-1) = temp_category_arr(i)
Next
Else
If UBound(temp_category_arr) = 1 Then
If Trim(temp_category_arr(0)) <> "" Then
p_category_arr(temp_category_arr(0)-1) = temp_category_arr(0)
End if
End if
End if
End if
end If
if tmp_year = "" then
tmp_year = year(date)
end If
p_depart = Session("Depart_Code")
cost_type = ""
if (p_depart >= 20 and p_depart <=99) then
p_depart_name = "research" '##### ¿¬±¸
cost_type = "research"
elseif p_depart = 12 then
p_depart_name = "field" '##### ½Ç»ç(QCÆ÷ÇÔ)
cost_type = "field"
elseif p_depart = 17 then
p_depart_name = "dp" '##### DP(ÄÚµùÆ÷ÇÔ)
cost_type = "dp"
else
p_depart_name = "admin"
end If
dim p_rsch_a_per, p_rsch_b_per, p_rsch_c_per
dim p_rsch_a_yn, p_rsch_b_yn, p_rsch_c_yn
q = " DECLARE @prjcode nvarchar(20) "
If temp_p_child_sn = "" Then
q = q & " set @prjcode='" & Request("p_child_sn") & "' "
Else
q = q & " set @prjcode='" & temp_p_child_sn & "' "
End if
q = q & " "
q = q & " DECLARE @t1 int "
q = q & " DECLARE @t2 nchar(3) "
q = q & " "
q = q & " DECLARE @x1 int, @x2 int, @x3 int "
q = q & " set @x1=0 set @x2=0 set @x3=0 "
q = q & " "
q = q & " DECLARE @z1 int, @z2 int, @z3 int "
q = q & " set @z1=0 set @z2=0 set @z3=0 "
q = q & " "
q = q & " select @t1=p_export_range from dbo.T_PROJECT_METHOD "
q = q & " where p_child_sn=@prjcode "
q = q & " "
q = q & " select @t2=p_gubn from dbo.T_PROJECT_METHOD_CD "
q = q & " where p_method_cd in ( "
q = q & " select p_method_cd from dbo.T_PROJECT_METHOD "
q = q & " where p_child_sn=@prjcode "
q = q & " ) "
q = q & " "
q = q & " select @x1=tplan,@x2=tprogress,@x3=treport from dbo.sales_index "
q = q & " where div_use='1' "
q = q & " and prj_type=@t2 "
q = q & " and service_type=@t1 "
q = q & " and convert(nvarchar(4),tyear)+'-'+tmonth in ( "
q = q & " select top 1 convert(nvarchar(4),tyear)+'-'+tmonth from dbo.sales_index "
q = q & " where div_use='1' "
q = q & " ) "
q = q & " group by tplan,tprogress,treport "
q = q & " "
q = q & " select "
q = q & " @z1=case when isnull(p_rsch_1_a,'')+isnull(p_rsch_2_a,'')+isnull(p_rsch_3_a,'')+isnull(p_rsch_4_a,'')='' then '0' else '1' end, "
q = q & " @z2=case when isnull(p_rsch_1_b,'')+isnull(p_rsch_2_b,'')+isnull(p_rsch_3_b,'')+isnull(p_rsch_4_b,'')='' then '0' else '1' end, "
q = q & " @z3=case when isnull(p_rsch_1_c,'')+isnull(p_rsch_2_c,'')+isnull(p_rsch_3_c,'')+isnull(p_rsch_4_c,'')='' then '0' else '1' end "
q = q & " from dbo.T_PROJECT_METHOD "
q = q & " where p_child_sn=@prjcode "
q = q & " "
q = q & " select @x1 as x1,@x2 as x2,@x3 as x3, @z1 as z1,@z2 as z2,@z3 as z3 "
Rs.Open q, adoConn, 1
' response.Write Rs.recordCount
' if Rs.recordCount > 0 Then
if not Rs.eof Then
p_rsch_a_per = Rs("x1")
p_rsch_b_per = Rs("x2")
p_rsch_c_per = Rs("x3")
p_rsch_a_yn = Rs("z1")
p_rsch_b_yn = Rs("z2")
p_rsch_c_yn = Rs("z3")
end if
Rs.Close
%>
<!-- Content Wrapper. Contains page content -->
<div class="content-wrapper">
<!-- Content Header (Page header) -->
<div class="content-header">
<h1></h1>
</div>
<!-- /.content-header -->
<!-- Main content -->
<div class="content-body">
<div class="content">
<div class="container-fluid">
<div class="row">
<div class="col-12">
<form id="pms" name="pms" method="post">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors" width="1000px">
<tr height="26">
<td colspan="4" style="padding: 10px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<img src="/images/main/bubble_1num.png" style="">
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">ÇÁ·ÎÁ§Æ® °³¿ä</span>
</div>
</td>
<td align="right">
<%
q = " SELECT case when d_order_cnt = '2' then 'ÆÀÀå' "
q = q & " when d_order_cnt = '3' then 'ºÎ¼­Àå' "
q = q & " when d_order_cnt = '4' then 'ÀÓ¿ø' "
q = q & " when d_order_cnt = '5' then '´ëÇ¥ÀÌ»ç' end as order_name, d_order1, d_order2, d_order3, d_order4, d_order5, "
q = q & " case when dbo.split(cast(target100 as varchar(100)), '^^', 1) = '/' then '¹Ì°áÀç' else dbo.split(cast(target100 as varchar(100)), '^^', 1) end as d_order1_date, "
q = q & " case when dbo.split(cast(target100 as varchar(100)), '^^', 2) = '/' then '¹Ì°áÀç' else dbo.split(cast(target100 as varchar(100)), '^^', 2) end as d_order2_date, "
q = q & " case when dbo.split(cast(target100 as varchar(100)), '^^', 3) = '/' then '¹Ì°áÀç' else dbo.split(cast(target100 as varchar(100)), '^^', 3) end as d_order3_date, "
q = q & " case when dbo.split(cast(target100 as varchar(100)), '^^', 4) = '/' then '¹Ì°áÀç' else dbo.split(cast(target100 as varchar(100)), '^^', 4) end as d_order4_date, "
q = q & " case when dbo.split(cast(target100 as varchar(100)), '^^', 5) = '/' then '¹Ì°áÀç' else dbo.split(cast(target100 as varchar(100)), '^^', 5) end as d_order5_date "
q = q & " FROM ¹®¼­³»¿ë m left outer join Document d ON m.¹®¼­¹øÈ£ = d.D_no "
q = q & " WHERE m.p_child_sn = '" & Request("p_child_sn") & "' and d_order_cnt not in ('99', '77') and m.del_yes_no = 'no' "
Rs.Open q, adoConn, 1
order_name = ""
if Rs.recordCount > 0 then
order_name = Rs("order_name")
%>
<table class="table table-sm table-sm2 table-bordered table-head tr-colors" width="50%">
<tr>
<td width="11%" class="k_small" align="center" bgcolor="#F1F1F1">»ó½ÅÀÚ</td>
<td width="11%" class="k_small" align="center" bgcolor="#F1F1F1">±×·ìÀå</td>
<td width="11%" class="k_small" align="center" bgcolor="#F1F1F1">ÆÄÆ®³Ê</td>
<td width="11%" class="k_small" align="center" bgcolor="#F1F1F1">´ëÇ¥ÀÌ»ç</td>
</tr>
<tr height=20>
<td bgcolor="#FFFFFF" align="center" class="k_small"><%if Rs("d_order1") = "Àü°á" then %>Àü°á<%else %><%=Rs("d_order1_date")%><%end if %></td>
<td bgcolor="#FFFFFF" align="center" class="k_small"><%if Rs("d_order3") = "Àü°á" then %>Àü°á<%else %><%=Rs("d_order3_date")%><%end if %></td>
<td bgcolor="#FFFFFF" align="center" class="k_small"><%if Rs("d_order4") = "Àü°á" then %>Àü°á<%else %><%=Rs("d_order4_date")%><%end if %></td>
<td bgcolor="#FFFFFF" align="center" class="k_small"><%if Rs("d_order5") = "Àü°á" then %>Àü°á<%else %><%=Rs("d_order5_date")%><%end if %></td>
</tr>
<tr height="20">
<td bgcolor="#FFFFFF" align="center" class="k_small" colspan="4"><span style="color:Red; font-size:13px; font-weight:bold; background-color:Yellow; font-family:¸¼Àº °íµñ; width:100%;height:100%;vertical-align:middle;"><%=order_name %> °áÀç ´Ü°è</span></td>
</tr>
</table>
<%
end if
Rs.close
%>
</td>
</tr>
<tr height="26">
<td colspan="2" align="center" >ÇÁ·ÎÁ§Æ® ¹øÈ£</td>
<td >
<% If p_sub_type = "C" Then %>
<input type="text" style="width:150;" value="<%=Request("p_child_sn")%>">
<% Else %>
<input type="text" style="width:150;" value="<%=p_sn & "_M01"%>">
<% End If %>
<input type="hidden" name="p_sn" value="<%=p_sn %>">
<input type="hidden" name="p_sub_type" value="<%=p_sub_type %>">
<% If p_sub_type = "C" Then %>
<input type="hidden" name="p_child_sn" value="<%=Request("p_child_sn") %>">
<input type="hidden" name="p_method_cd" value="<%=req_p_method_cd%>">
<% End If %>
<input type="hidden" name="p_state" value="<%=p_state %>">
<input type="hidden" name="p_depart_dep" value="<%=p_depart_dep %>">
<input type="hidden" name="p_memo" value="<%=p_memo %>">
<input type='hidden' name="tmp_year" value = '<%=tmp_year%>'>
<input type='hidden' name="cost_type" value = '<%=cost_type%>'>
<input type='hidden' name="p_depart_name" value = '<%=p_depart_name%>'>
<input type="hidden" name="f_work_type" value="001"/>
<input type="hidden" name="user_no" value="<%=Session("User_Number")%>"/>
<input type='hidden' name="fileCount" value = ''>
<input type='hidden' name="p_input_user" value = '<%= p_input_user %>'>
<input type="hidden" name="depart_no" value="<%=Session("Depart_Code")%>"/>
</td>
<td align="center" >ÇÁ·ÎÁ§Æ® ¸í</td>
<td >
<input class="input tahoma_blue" type="text" name="p_subject" style="width:540px;" value="<%=replace(p_subject,chr(34),"&quot;")%>" <% If session("depart_code") <> p_depart_dep Then %>readonly<% End if %>>
</td>
</tr>
<tr>
<td align="center" rowspan="8" >Ŭ¶óÀ̾ðÆ®</td>
</tr>
<tr>
<td align="center" >ȸ»ç</td>
<td >
<input type="text" style="width:150;" name="p_cli_company_nm" value="<%=p_cli_company_nm%>" readonly style="cursor:pointer">
<input type="hidden" name="p_cli_company_cd" value="7" />
<input type="hidden" name="p_cli_per_cd" value="9" />
</td>
<td align="center" >¾÷Á¾</td>
<td >
<select name="p_client_type_cd" id="p_client_type_cd">
<option value="">¼±ÅÃ</option>
<%
q = "SELECT p_client_type_cd, p_client_type_nm FROM T_CLIENT_TYPE_CD "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for i = 1 to Rs.RecordCount
%>
<option value="<%=Rs("p_client_type_cd")%>" <% if p_client_type_cd = Rs("p_client_type_cd") then %> selected <% end if %>> <%=Rs("p_client_type_nm")%></option>
<%
Rs.MoveNext
next
end if
Rs.Close
%>
</select>
</td>
</tr>
<tr>
<td align="center" >ºÎ¼­</td>
<td >
<input type="text" style="width:150;" name="p_cli_depart" value="<%=p_cli_depart%>" readonly>
</td>
<td align="center" > °è¾à ±â°£</td>
<td >
<input type="text" name="p_con_date_st" id="p_con_date_st" style="width:100;" readonly value="<%=p_con_date_st%>" class='selectDate'>
~
<input type="text" name="p_con_date_end" id="p_con_date_end" style="width:100;" readonly value="<%=p_con_date_end%>" class='selectDate'>
</td>
</tr>
<tr>
<td align="center" >´ã´çÀÚ À̸§</td>
<td >
<input type="text" style="width:150;" name="p_cli_per_nm" value="<%=p_cli_per_nm%>" readonly>
</td>
<td align="center" >°è¾à ÀÏÀÚ</td>
<td >
<input type="text" name="p_decide_date" id="p_decide_date" style="width:100;" readonly value="<%=p_decide_date%>" class='selectDate'>
</td>
</tr>
<tr>
<td align="center" >ȸ»ç¹øÈ£</td>
<td >
<input type="text" style="width:150;" name="p_cli_per_nm" value="<%=p_cli_per_com_tel%>" readonly>
</td>
<td align="center" >´ÜÀ§ °è¾à¾×</td>
<td >
<%
'2016-07-20 Àüü°è¾à±Ý¾×Àº T_PROJECT_BASEÀÇ p_total_cost·Î »ç¿ëÇϱâ·Î ÇÔ ====================
q = " select SUM(p_cont_cost) as all_project_cont_cost "
q = q +" from ( "
q = q +" select p_sn, p_sub_type, SUM(p_cont_cost) as p_cont_cost from t_project_method where p_sn = '" & p_sn & "' "
If temp_p_child_sn = "" Then
q = q +" and p_child_sn <> '" & Request("p_child_sn") & "' "
Else
q = q +" and p_child_sn <> '" & temp_p_child_sn & "' "
End if
q = q +" and p_sub_type = 'C' group by p_sn, p_sub_type "
q = q +" ) as t "
Rs.Open q, adoConn, 1
Dim all_project_cont_cost
all_project_cont_cost = 0
If Rs.RecordCount > 0 then
all_project_cont_cost = Rs("all_project_cont_cost")
End If
Rs.close
'=================================================================================================
%>
<%
all_project_total_cost = ""
q = " select p_total_cost "
q = q +"from T_PROJECT_base where p_sn = '" & p_sn & "' "
Rs.Open q, adoConn, 1
If Rs.RecordCount > 0 then
if Rs("p_total_cost") <> "" then
tmp_len = len(Rs("p_total_cost"))
for i = 1 to int(tmp_len)
if i mod 3 = 1 and i <> 1 then
all_project_total_cost = "," & all_project_total_cost
end if
all_project_total_cost = left(right(Rs("p_total_cost"),i), 1) & all_project_total_cost
next
Else
all_project_total_cost = 0
end If
End If
Rs.close
%>
<input type="text" id="p_cont_cost" name="p_cont_cost" value="<%=p_cont_cost%>" style="width:100;text-align:right;" onKeyUp="setFormatPrice()" >¿ø (<font class="tahoma_red">VATº°µµ</font>)
<img src="/images/common/btn_smallmodif.gif" align="absmiddle" OnClick="winnewoepn()" style="cursor:pointer;" id="cost_mod_button">
&nbsp; <b class="tahoma" >[Àüü ¼öÁÖ±Ý¾× : <%=all_project_total_cost%>¿ø]</b>
<input type="hidden" id="all_project_total_cost" name="all_project_total_cost" value="<%=all_project_total_cost %>" />
<input type="hidden" id="all_project_cont_cost" name="all_project_cont_cost" value="<%=all_project_cont_cost %>" />
</td>
</tr>
<tr>
<td align="center" >´ã´çÀÚ ÈÞ´ëÆù</td>
<td >
<input type="text" style="width:150;" name="p_cli_per_tel" value="<%=p_cli_per_tel%>" readonly>
</td>
<td align="center" >ÀüüÁ÷Á¢ºñ ¿¹»ê(ºñÀ²)</td>
<td >
<%
q = " select sum(T.total_money) as total_money "
q = q + " from( "
q = q + " select sum(convert(money, est_money)) as total_money from direct_cost "
q = q + " where p_sn like '" & p_sn & "' and cost_type = 'research' and del_yes_no = 'no' " '##### ¿¬±¸
q = q + query_p_child_sn
q = q + " union all "
q = q + " select sum(convert(money, est_money)) as total_money from direct_cost "
q = q + " where p_sn like '" & p_sn & "' and cost_type = 'field' and del_yes_no = 'no' " '##### ½Ç»ç
q = q + query_p_child_sn
q = q + " ) as T "
Rs.Open q, adoConn, 1
tmp_total_money = ""
tmp_total_rate = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for i = 1 to int(tmp_len)
if i mod 3 = 1 and i <> 1 then
tmp_total_money = "," & tmp_total_money
end if
tmp_total_money = left(right(Rs("total_money"),i), 1) & tmp_total_money
Next
If p_cont_cost = 0 Then
tmp_total_rate = "0.00"
Else
tmp_total_rate = formatnumber((tmp_total_money / p_cont_cost) * 100, 2)
End if
Else
tmp_total_money = "0"
tmp_total_rate = "0"
end If
%>
<span style="text-align:right;"><b class="tahoma" ><%=tmp_total_money%>¿ø</b> (<font class="tahoma_red">VATº°µµ</font>), <b class="tahoma" >ºñÀ² : </b><b class="tahoma_blue"> <%=tmp_total_rate%>%</b></span>
<%
end if
Rs.Close
%>
</td>
</tr>
<tr>
<td align="center" >À̸ÞÀÏ</td>
<td >
<input type="text" style="width:150;" name="p_cli_per_email" value="<%=p_cli_per_email%>" readonly>
</td>
<td align="center" >¿ë¿ª¹üÀ§</td>
<td >
<%
q = " SELECT p_gubn "
q = q +" FROM T_PROJECT_METHOD_CD "
q = q +" WHERE p_method_cd in (SELECT p_method_cd FROM T_PROJECT_METHOD WHERE "
If temp_p_child_sn = "" Then
q = q +" p_child_sn = '" & Request("p_child_sn") & "') "
Else
q = q +" p_child_sn = '" & temp_p_child_sn & "') "
End if
Rs.Open q, adoConn, 1
Dim p_gubn
If Rs.RecordCount > 0 then
p_gubn = Rs("p_gubn")
End If
Rs.close
%>
<select name="p_export_range" id="p_export_range">
<option value="">¼±ÅÃ</option>
<% q = "SELECT c_kind_code, c_common_code, c_code_name FROM T_COMMON_CODE_DETAIL WHERE c_kind_code = '011' "
if p_gubn = "3" then
q = q + "and c_common_code = '002' "
end if
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for i = 1 to Rs.RecordCount %>
<option value="<%=Rs("c_common_code")%>" <% if p_export_range = Rs("c_common_code") then %> selected <% end if %>> <%=Rs("c_code_name")%></option>
<% Rs.MoveNext
next
end if
Rs.Close %>
</select>
</td>
</tr>
<tr>
<td align="center" >KRi or KRC or KRD</td>
<td >
<% if "kri" = p_project_type_cd then %> KRi <% end if %>
<% if "krc" = p_project_type_cd then %> KRC <% end if %>
<% if "krt" = p_project_type_cd then %> KRT <% end if %> <!--240627 krt -> krdº¯°æ ÁøÇàÁßÀÎ °Ç À¯Áö¸¦ À§ÇØ µÑ´Ù »ì¸² -->
<% if "krd" = p_project_type_cd then %> KRD <% end if %>
</td>
<td align="center" >Á¶»ç ±¹°¡</td>
<td >
<% if "ko" = p_project_nation_cd then %> ±¹³» Á¶»ç <% end if %>
<% if "fn" = p_project_nation_cd then %> ÇØ¿Ü Á¶»ç <% end if %>
</td>
</tr>
<tr>
<td align="center" >Á¶»ç³»¿ë</td>
<td class="tit4 tit_right" colspan="4">
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="1" <% If p_category_arr(0) = 1 Then %>checked<% End if %>>°í°´¸¸Á·µµ</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="2" <% If p_category_arr(1) = 2 Then %>checked<% End if %>>A&U/½ÇÅÂÁ¶»ç</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="3" <% If p_category_arr(2) = 3 Then %>checked<% End if %>>±¤°íÈ¿°ú</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="4" <% If p_category_arr(3) = 4 Then %>checked<% End if %>>ÄÁ¼ÁÅ×½ºÆ®</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="5" <% If p_category_arr(4) = 5 Then %>checked<% End if %>>Á¦Ç°·Â</input>
</td>
</tr>
<tr>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="6" <% If p_category_arr(5) = 6 Then %>checked<% End if %>>¼ö¿ä¿¹Ãø</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="7" <% If p_category_arr(6) = 7 Then %>checked<% End if %>>±â¾÷À̹ÌÁö</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="8" <% If p_category_arr(7) = 8 Then %>checked<% End if %>>ÆÇ¸Å/À¯Åë</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="9" <% If p_category_arr(8) = 9 Then %>checked<% End if %>>ÇàÁ¤¼­ºñ½º</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="10" <% If p_category_arr(9) = 10 Then %>checked<% End if %>>Á¤Ä¡/»çȸÇö¾È</input>
</td>
</tr>
<tr>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="11" <% If p_category_arr(10) = 11 Then %>checked<% End if %>>¼±°Å¿©·Ð</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="12" <% If p_category_arr(11) = 12 Then %>checked<% End if %>>Á¤Ã¥°ü·Ã</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="13" <% If p_category_arr(12) = 13 Then %>checked<% End if %>>û·Åµµ</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="14" <% If p_category_arr(13) = 14 Then %>checked<% End if %>>ºê·£µåÁø´Ü</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="15" <% If p_category_arr(14) = 15 Then %>checked<% End if %>>Segmentation</input>
</td>
</tr>
<tr>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="16" <% If p_category_arr(15) = 16 Then %>checked<% End if %>>Positioning</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="17" <% If p_category_arr(16) = 17 Then %>checked<% End if %>>½ÅÁ¦Ç°°³¹ß</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="18" <% If p_category_arr(17) = 18 Then %>checked<% End if %>>µðÀÚÀÎ/UIÅ×½ºÆ®</input>
</td>
<td>
<input type="checkbox" class="none mr-1" name="p_category" value="19" <% If p_category_arr(18) = 19 Then %>checked<% End if %>>±âŸ</input>
</td>
</tr>
</table>
</td>
</tr>
<tr height="26">
<td colspan="5" style="padding: 25px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<img src="/images/main/bubble_1num.png" style="">
<%
if p_sub_type = "M" then
cost_p_child_sn = p_sn
else
cost_p_child_sn = request("p_child_sn")
end if
%>
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">ºñ¿ë ÁýÇà ÇöȲ</span>
</div>
</td>
</tr>
<tr>
<td colspan="5" align="left">
<button type="button" class='btn btn-sm btn-primary' onclick=" direct_cost_detail('<%=cost_p_child_sn%>', '<%=tmp_year%>', 'all', '<%=p_sub_type%>')">Àüü Á÷Á¢ºñ ³»¿ª</button>
<button type="button" class='btn btn-sm btn-primary' onclick=" direct_cost_detail('<%=cost_p_child_sn%>', '<%=tmp_year%>', 'research', '<%=p_sub_type%>')">¿¬±¸ Á÷Á¢ºñ ³»¿ª</button>
<button type="button" class='btn btn-sm btn-primary' onclick=" direct_cost_detail('<%=cost_p_child_sn%>', '<%=tmp_year%>', 'field', '<%=p_sub_type%>')">½Ç»ç Á÷Á¢ºñ ³»¿ª</button>
</td>
</tr>
<tr>
<td style="padding:0px;" colspan="5">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="20px;">
<td align="center" rowspan=2 width=80>±¸ºÐ</td>
<td align="center" colspan=2>¿¹»ê ºñ¿ë</td>
<td align="center" colspan=2>´©Àû ÁýÇà ±Ý¾×</td>
<td align="center" colspan=2>Â÷¾×</td>
<td align="center" class="tit_left tit_right" colspan=3>ºñÀ²</td>
</tr>
<tr height="20px;">
<td align="center" width=100>¿¬±¸</td>
<td align="center" width=100>½Ç»ç</td>
<td align="center" width=100>¿¬±¸</td>
<td align="center" width=100>½Ç»ç</td>
<td align="center" width=100>°æ¿µÀü·«½Ç<br />(´©Àû ÁýÇà ºñ¿ë)</td>
<td align="center" width=100>¿¬±¸</td>
<td align="center" width=100>½Ç»ç</td>
<td align="center" width=80>¿¬±¸</td>
<td align="center" class="tit_left tit_right" width=80>½Ç»ç</td>
</tr>
<tr>
<td align="center" >Á÷Á¢ºñ</td>
<!-- ¿¹»ê ºñ¿ë -->
<!-- ¿¬±¸ÆÀ -->
<td align="center" >
<%
q = " select sum(convert(money, est_money)) as total_money from direct_cost "
q = q + " where p_sn like '" & p_sn & "' and cost_type = 'research' and del_yes_no = 'no' " '¿¬±¸
q = q + query_p_child_sn
Rs.Open q, adoConn, 1
tmp_research_esti_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_research_esti_money = "," & tmp_research_esti_money
end if
tmp_research_esti_money = left(right(Rs("total_money"),j), 1) & tmp_research_esti_money
Next
Else
tmp_research_esti_money = "0"
end If
%>
<b class="tahoma"><%=tmp_research_esti_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<!-- ½Ç»çÆÀ (ÄÚµù Á¦¿Ü)-->
<td align="center" >
<%
q = " select sum(convert(money, est_money)) as total_money from direct_cost "
q = q + " where p_sn like '" & p_sn & "' and cost_type = 'field' and del_yes_no = 'no' " ' ½Ç»ç
q = q + query_p_child_sn
Rs.Open q, adoConn, 1
tmp_field_esti_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_field_esti_money = "," & tmp_field_esti_money
end if
tmp_field_esti_money = left(right(Rs("total_money"),j), 1) & tmp_field_esti_money
Next
Else
tmp_field_esti_money = "0"
end If
%>
<b class="tahoma"><%=tmp_field_esti_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<!-- ´©Àû ÁýÇà ±Ý¾× -->
<!-- ¿¬±¸ÆÀ -->
<td align="center" >
<%
q = " select SUM(convert(float, act_money)) as total_money from direct_cost "
q = q & " where cost_type = 'research' and del_yes_no = 'no' "
if p_sub_type = "M" then
q = q & " and p_sn LIKE '"& p_sn &"%' "
else
q = q & " and p_sn LIKE '"& p_sn &"%' and p_child_sn = '" & request("p_child_sn") & "' "
end If
Rs.Open q, adoConn, 1
tmp_research_actual_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_research_actual_money = "," & tmp_research_actual_money
end if
tmp_research_actual_money = left(right(Rs("total_money"),j), 1) & tmp_research_actual_money
Next
Else
tmp_research_actual_money = "0"
end If
%>
<b class="tahoma"><%=tmp_research_actual_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<!-- ½Ç»ç(ÄÚµù Á¦¿Ü) -->
<td align="center" >
<%
q = " select SUM(convert(money, act_money)) as total_money from direct_cost "
q = q & " where cost_type = 'field' and del_yes_no = 'no' "
if p_sub_type = "M" then
q = q & " and p_sn LIKE '"& p_sn &"%' "
else
q = q & " and p_sn LIKE '"& p_sn &"%' and p_child_sn = '" & request("p_child_sn") & "' "
end If
Rs.Open q, adoConn, 3, 1
tmp_field_actual_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_field_actual_money = "," & tmp_field_actual_money
end if
tmp_field_actual_money = left(right(Rs("total_money"),j), 1) & tmp_field_actual_money
Next
Else
tmp_field_actual_money = "0"
end If
%>
<b class="tahoma"><%=tmp_field_actual_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<!-- °æ¿µÀü·«½Ç(´©ÀûÁýÇàºñ¿ë) -->
<td align="center" >
<%
q = " select SUM(convert(float, act_money)) as total_money from direct_cost "
q = q & " where cost_type = 'support' and del_yes_no = 'no' "
if p_sub_type = "M" then
q = q & " and p_sn LIKE '"& p_sn &"%' "
else
q = q & " and p_sn LIKE '"& p_sn &"%' and p_child_sn = '" & request("p_child_sn") & "' "
end If
Rs.Open q, adoConn, 1
tmp_support_actual_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_support_actual_money = "," & tmp_support_actual_money
end if
tmp_support_actual_money = left(right(Rs("total_money"),j), 1) & tmp_support_actual_money
Next
Else
tmp_support_actual_money = "0"
end If
%>
<b class="tahoma"><%=tmp_support_actual_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<!-- Â÷¾× -->
<!-- ¿¬±¸ÆÀ -->
<td align="center" >
<%
tmp_research_difference_money = ""
tmp_len = len(tmp_research_esti_money - tmp_research_actual_money)
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_research_difference_money = "," & tmp_research_difference_money
end if
tmp_research_difference_money = left(right(tmp_research_esti_money - tmp_research_actual_money,j), 1) & tmp_research_difference_money
Next
%>
<b class="tahoma"><%=tmp_research_difference_money%>¿ø</b>
</td>
<!-- ½Ç»ç(ÄÚµù Á¦¿Ü) -->
<td align="center" >
<%
tmp_field_difference_money = ""
tmp_len = len(tmp_field_esti_money - tmp_field_actual_money)
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_field_difference_money = "," & tmp_field_difference_money
end if
tmp_field_difference_money = left(right(tmp_field_esti_money - tmp_field_actual_money,j), 1) & tmp_field_difference_money
Next
%>
<b class="tahoma"><%=tmp_field_difference_money%>¿ø</b>
</td>
<!-- ºñÀ² -->
<!-- ¿¬±¸ÆÀ -->
<td align="center" >
<%
If tmp_research_esti_money = 0 Then
tmp_research_esti_money = 1
tmp_total_rate = "0.00"
Else
tmp_total_rate = formatnumber((tmp_research_actual_money / tmp_research_esti_money) * 100, 2)
End if
%>
<b class="tahoma_blue"><%=tmp_total_rate%>%</b>
</td>
<!-- ½Ç»ç(ÄÚµù Á¦¿Ü) -->
<td align="center" >
<%
If tmp_field_esti_money = 0 Then
tmp_field_esti_money = 1
tmp_total_rate = "0.00"
Else
tmp_total_rate = formatnumber((tmp_field_actual_money / tmp_field_esti_money) * 100, 2)
End if
%>
<b class="tahoma_blue"><%=tmp_total_rate%>%</b>
</td>
</tr>
</table>
</td>
</tr>
<%
q = " "
q = q & " select intranet_project, "&VbCrlf
q = q & " p_child_sn, "&VbCrlf
q = q & " p_subject, "&VbCrlf
q = q & " allocation_cnt, "&VbCrlf
q = q & " escalation_cnt, "&VbCrlf
q = q & " error_cnt, "&VbCrlf
q = q & " complete_cnt, "&VbCrlf
q = q & " round(tok_rating, 2) as tok_rating, "&VbCrlf
q = q & " round(error_rating, 2) as error_rating "&VbCrlf
q = q & " from "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " select intranet_project, "&VbCrlf
q = q & " p_child_sn, "&VbCrlf
q = q & " p_subject, "&VbCrlf
q = q & " allocation_cnt, "&VbCrlf
q = q & " escalation_cnt, "&VbCrlf
q = q & " error_cnt, "&VbCrlf
q = q & " complete_cnt, "&VbCrlf
q = q & " case when complete_cnt = 0 then 0.00 else case when escalation_cnt = 0 then 0.00 else round(convert(float, complete_cnt)/escalation_cnt * 100, 2) end end as tok_rating, "&VbCrlf
q = q & " case when error_cnt = 0 then 0.00 else case when escalation_cnt = 0 then 0.00 else round(convert(float, error_cnt)/escalation_cnt * 100, 2) end end as error_rating "&VbCrlf
q = q & " from "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " SELECT case when TPM.intranet_project = '' then T.p_child_sn else TPM.intranet_project end as intranet_project, "&VbCrlf
q = q & " T.p_child_sn, "&VbCrlf
q = q & " TPM.p_subject, "&VbCrlf
q = q & " 0 as allocation_cnt, "&VbCrlf
q = q & " isnull(escalation_cnt,0) as escalation_cnt, "&VbCrlf
q = q & " isnull(T.error_cnt,0) as error_cnt, "&VbCrlf
q = q & " isnull(T.tok_cnt,0) as complete_cnt "&VbCrlf
q = q & " FROM "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " SELECT p_child_sn, "&VbCrlf
q = q & " sum(escalation_cnt) as escalation_cnt, "&VbCrlf
q = q & " sum(tok_cnt) as tok_cnt, "&VbCrlf
q = q & " sum(error_cnt) as error_cnt, "&VbCrlf
q = q & " sum(no_tel) as no_tel "&VbCrlf
q = q & " FROM "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " SELECT C.p_sn as p_child_sn, "&VbCrlf
q = q & " C.m_no as i_id, "&VbCrlf
q = q & " C.m_name, "&VbCrlf
q = q & " CASE WHEN isnull(C.r_sn, 0) <> 0 THEN 1 ELSE 0 END as escalation_cnt, "&VbCrlf
q = q & " D.r_result, "&VbCrlf
q = q & " CASE WHEN (D.r_result = '1' and D.qc_stat='OK') OR D.pass_stat = 'pass' THEN 1 ELSE 0 END as tok_cnt, "&VbCrlf
q = q & " CASE WHEN pass_stat = 'ERROR' THEN 1 ELSE 0 END as error_cnt, "&VbCrlf
q = q & " CASE WHEN D.r_result in ('5', '6', '7') AND isnull(D.pass_stat,'') not in ('error','pass') THEN 1 ELSE 0 END as no_tel "&VbCrlf
q = q & " FROM "&VbCrlf
q = q & " res C "&VbCrlf
q = q & " LEFT OUTER JOIN project2.dbo.T_INSPECTION_RES as D ON D.p_sn = C.p_sn AND D.r_sn = C.r_sn AND D.m_name = C.m_name "&VbCrlf
q = q & " where r_error is null "&VbCrlf
q = q & " AND s_error is null "&VbCrlf
q = q & " AND m_error is null "&VbCrlf
q = q & " AND q_error is null "&VbCrlf
q = q & " AND DelGubun = 'N' "&VbCrlf
q = q & " group by C.p_sn, C.m_no, C.m_name, C.r_sn, D.r_result, D.pass_stat, D.qc_stat "&VbCrlf
q = q & " ) as sumT "&VbCrlf
q = q & " GROUP BY p_child_sn "&VbCrlf
q = q & " ) AS T "&VbCrlf
q = q & " left outer join V_PROJECT_FCS TPM on T.p_child_sn = TPM.p_child_sn "&VbCrlf
q = q & " ) s "&VbCrlf
q = q & " union all "&VbCrlf
q = q & " select p.intranet_project as intranet_project, "&VbCrlf
q = q & " p.prj_code as p_child_sn, "&VbCrlf
q = q & " p.prj_name as p_subject, "&VbCrlf
q = q & " isnull(tqt.allocation_cnt, '0') as allocation_cnt, "&VbCrlf
q = q & " isnull(s.q_complete,'0') as escalation_cnt, "&VbCrlf
q = q & " isnull(error, '0') as error_cnt, "&VbCrlf
q = q & " isnull(tok, '0') as complete_cnt, "&VbCrlf
q = q & " case when isnull(tok, '0') = '0' then 0.00 else case when isnull(s.q_complete,'0') = '0' then 0.00 else round(convert(float, tok)/q_complete * 100, 2) end end as tok_rating, "&VbCrlf
q = q & " case when isnull(error, '0') = '0' then 0.00 else case when isnull(s.q_complete,'0') = '0' then 0.00 else round(convert(float, error)/q_complete * 100, 2) end end as error_rating "&VbCrlf
q = q & " from "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " SELECT CP.* "&VbCrlf
q = q & " FROM NEW_CATI.DBO.PROJECT CP "&VbCrlf
q = q & " left outer join PROJECT2.DBO.V_PROJECT_METHOD TPM ON CP.intranet_project = TPM.p_child_sn "&VbCrlf
q = q & " WHERE ISNULL(CP.prj_end_chk, 'Ãë¼Ò') != 'Ãë¼Ò' "&VbCrlf
q = q & " AND ISNULL(TPM.p_field_complete,'') = '' "&VbCrlf
q = q & " ) p left outer join "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " select sum(q_allocation) as allocation_cnt, "&VbCrlf
q = q & " prj_code "&VbCrlf
q = q & " from new_cati.dbo.T_QUOTA_TABLE "&VbCrlf
q = q & " where type='1' "&VbCrlf
q = q & " group by prj_code "&VbCrlf
q = q & " ) tqt on p.prj_code = tqt.prj_code left outer join "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " select T.prj_code, count(s_tcnt) as q_complete from "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " select s_tcnt, prj_code "&VbCrlf
q = q & " from new_cati.dbo.sheet1_send "&VbCrlf
q = q & " where chk='4' "&VbCrlf
q = q & " union all "&VbCrlf
q = q & " select s_tcnt, prj_code "&VbCrlf
q = q & " from new_cati.dbo.sheet1 "&VbCrlf
q = q & " ) T left outer join new_cati.dbo.T_INSPECTION_CATI A "&VbCrlf
q = q & " ON T.prj_code = A.prj_code and T.s_tcnt = A.tel_cnt and A.tel_del_yn = 'N' "&VbCrlf
q = q & " group by T.prj_code "&VbCrlf
q = q & " ) s on p.prj_code = s.prj_code left outer join "&VbCrlf
q = q & " ( "&VbCrlf
q = q & " select sum(case when tel_result = '1' then 1 else 0 end) as tok, sum(case when tel_result = '2' then 1 else 0 end) as error, a.prj_code "&VbCrlf
q = q & " from "&VbCrlf
q = q & " (select s_tcnt, s_client, prj_code from new_cati.dbo.sheet1 union all select s_tcnt, s_client, prj_code from new_cati.dbo.sheet1_send where chk = '4') a "&VbCrlf
q = q & " left outer join new_cati.dbo.T_INSPECTION_CATI b on a.prj_code = b.prj_code and a.s_client = b.tel_client_no and a.s_tcnt = b.tel_cnt "&VbCrlf
q = q & " where tel_del_yn='N' "&VbCrlf
q = q & " group by a.prj_code "&VbCrlf
q = q & " ) tci on s.prj_code = tci.prj_code "&VbCrlf
q = q & " ) a "&VbCrlf
If temp_p_child_sn = "" Then
q = q & " where isnull(intranet_project, '') <> '' and intranet_project = '" & Request("p_child_sn") & "' "&VbCrlf
Else
q = q & " where isnull(intranet_project, '') <> '' and intranet_project = '" & temp_p_child_sn & "' "&VbCrlf
End If
' Response.Write q
Rs.Open q, adoConn, 1
if Rs.recordCount > 0 then
%>
<tr height="26">
<td colspan="5" style="padding: 25px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<img src="/images/main/bubble_1num.png" style="">
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">ÁøÇà ÇöȲ</span>
</div>
</td>
</tr>
<tr>
<td style="padding:0px;" colspan="5">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="30px;">
<td align="center" >ÇÏÀ§ ÇÁ·ÎÁ§Æ®ÄÚµå</td>
<td align="center" >ÇÏÀ§ ÇÁ·ÎÁ§Æ®Á¦¸ñ</td>
<td align="center" >ÇÒ´ç·®</td>
<td align="center" >À̰ü(Á¶»ç¿Ï·á)</td>
<td align="center" >¿¡·¯</td>
<td align="center" >¿Ï·á</td>
<td align="center" >°ËÁõ·ü</td>
<td align="center" >¿¡·¯À²</td>
</tr>
<%
do while not Rs.Eof
%>
<tr>
<td align="center" ><a href="javascript:winopn_detail('<%=req_p_method_cd %>', '<%= Rs("p_child_sn")%>', '<%=session("User_Number") %>')"><%= Rs("p_child_sn")%></a></td>
<td align="center" ><a href="javascript:winopn_detail('<%=req_p_method_cd %>', '<%= Rs("p_child_sn")%>', '<%=session("User_Number") %>')"><%= Rs("p_subject")%></a></td>
<td align="center" ><%= Rs("allocation_cnt")%></td>
<td align="center" ><%= Rs("escalation_cnt")%></td>
<td align="center" ><%= Rs("error_cnt")%></td>
<td align="center" ><%= Rs("complete_cnt")%></td>
<td align="center" ><%= Rs("tok_rating")%></td>
<td align="center" ><%= Rs("error_rating")%></td>
</tr>
<%
Rs.moveNext
loop
%>
</table>
</td>
</tr>
<%
end if
Rs.close
%>
<tr height="26">
<td colspan="5" style="padding: 25px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<img src="/images/main/bubble_1num.png" style="">
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">Á¶»ç µðÀÚÀÎ</span>
</div>
</td>
</tr>
<tr>
<td style="padding:0px;" colspan="5">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="30px;">
<td align="center" width="180px">Á¶»ç¹æ¹ý</td>
<td align="center" width="180px">Á¶»ç³»¿ë</td>
<td align="center" style="display:none;">Á÷Á¢ºñ ¿¹»ê</td>
<td align="center" >Á¶»çÁö¿ª</td>
<td align="center" >Á¶»ç´ë»ó</td>
<td align="center" >Ç¥º»¼ö</td>
<td align="center" >Á¶»ç±â°£</td>
<td align="center" >Á¶»çºÐ·ù</td>
<td align="center" class="tit_left tit_right">½Ç»ç¼öÇà</td>
<td align="center" class="tit_left tit_right">°ËÁõ·ü</td>
</tr>
<!-- loop start -->
<%
'Á¶»ç¹æ¹ý °¡Á®¿À±â
query = " SELECT p_index, PMC.p_method_cd, p_method_nm, p_intention, p_child_sn, p_sur_area, p_sur_target, p_sample, p_inspection_rate, p_research_date_st, p_research_date_end, p_sur_part, p_field_process "&VbCrlf
query = query & " ,p_rsch_dept, p_field_dept, p_is_dept, p_it_dept, p_supp_dept "&VbCrlf
query = query & " ,isnull(p_rsch_1_a, '') as p_rsch_1_a, isnull(p_rsch_2_a, '') as p_rsch_2_a, isnull(p_rsch_3_a, '') as p_rsch_3_a, isnull(p_rsch_4_a, '') as p_rsch_4_a "&VbCrlf '##### ¿¬±¸
query = query & " ,isnull(p_rsch_1_b, '') as p_rsch_1_b, isnull(p_rsch_2_b, '') as p_rsch_2_b, isnull(p_rsch_3_b, '') as p_rsch_3_b, isnull(p_rsch_4_b, '') as p_rsch_4_b "&VbCrlf '##### ¿¬±¸
query = query & " ,isnull(p_rsch_1_c, '') as p_rsch_1_c, isnull(p_rsch_2_c, '') as p_rsch_2_c, isnull(p_rsch_3_c, '') as p_rsch_3_c, isnull(p_rsch_4_c, '') as p_rsch_4_c "&VbCrlf '##### ¿¬±¸
query = query & " ,isnull(p_sv_1, '') as p_sv_1 , isnull(p_sv_2, '') as p_sv_2 , isnull(p_sv_3, '') as p_sv_3 , isnull(p_sv_4, '') as p_sv_4 "&VbCrlf '##### ½Ç»ç
query = query & " ,isnull(p_punch_1, '') as p_punch_1 , isnull(p_punch_2, '') as p_punch_2 , isnull(p_punch_3, '') as p_punch_3 , isnull(p_punch_4, '') as p_punch_4 "&VbCrlf '##### ½Ç»ç
query = query & " ,isnull(p_verify_1, '') as p_verify_1, isnull(p_verify_2, '') as p_verify_2, isnull(p_verify_3, '') as p_verify_3, isnull(p_verify_4, '') as p_verify_4 "&VbCrlf '##### ½Ç»ç
query = query & " ,isnull(p_code_1, '') as p_code_1 , isnull(p_code_2, '') as p_code_2 , isnull(p_code_3, '') as p_code_3 , isnull(p_code_4, '') as p_code_4 "&VbCrlf '##### DP
query = query & " ,isnull(p_dp_1, '') as p_dp_1 , isnull(p_dp_2, '') as p_dp_2 , isnull(p_dp_3, '') as p_dp_3 , isnull(p_dp_4, '') as p_dp_4 "&VbCrlf '##### DP
query = query & " ,isnull(p_it_1, '') as p_it_1 , isnull(p_it_2, '') as p_it_2 , isnull(p_it_3, '') as p_it_3 , isnull(p_it_4, '') as p_it_4 "&VbCrlf '##### °æ¿µÀü·«½Ç
query = query & " ,isnull(p_supp_1, '') as p_supp_1 , isnull(p_supp_2, '') as p_supp_2 , isnull(p_supp_3, '') as p_supp_3 , isnull(p_supp_4, '') as p_supp_4 "&VbCrlf
query = query & " ,isnull(p_rsch_date_st, '') as p_rsch_date_st, isnull(p_rsch_date_end, '') as p_rsch_date_end, isnull(p_field_date_st, '') as p_field_date_st, isnull(p_field_date_end, '') as p_field_date_end "&VbCrlf
query = query & " ,isnull(p_punch_date_st, '') as p_punch_date_st, isnull(p_punch_date_end, '') as p_punch_date_end "&VbCrlf
query = query & " ,isnull(p_code_date_st, '') as p_code_date_st, isnull(p_code_date_end, '') as p_code_date_end, isnull(p_verify_date_st, '') as p_verify_date_st, isnull(p_verify_date_end, '') as p_verify_date_end "&VbCrlf
query = query & " ,isnull(p_dp_date_st, '') as p_dp_date_st, isnull(p_dp_date_end, '') as p_dp_date_end, isnull(p_it_date_st, '') as p_it_date_st, isnull(p_it_date_end, '') as p_it_date_end "&VbCrlf
query = query & " ,isnull(p_premeet_date, '') as p_premeet_date, isnull(p_premeet_time, '') as p_premeet_time, isnull(p_premeet_place, '') as p_premeet_place "&VbCrlf
query = query & " ,isnull(p_ot_date, '') as p_ot_date, isnull(p_ot_time, '') as p_ot_time, isnull(p_ot_place, '') as p_ot_place, isnull(p_sur_memo, '') as p_sur_memo, isnull(p_memo, '') as p_memo "&VbCrlf
query = query & " ,p_progress_flag, p_progress_status, p_input_complete "&VbCrlf
query = query & " FROM T_PROJECT_METHOD PM INNER JOIN T_PROJECT_METHOD_CD PMC ON PM.p_method_cd = PMC.p_method_cd "&VbCrlf
query = query & " WHERE p_method_yn = 'y' "&VbCrlf
query = query & " AND p_sn = '" & p_sn & "'"&VbCrlf
query = query & " AND p_sub_type = '" & p_sub_type & "'"&VbCrlf
If p_sub_type = "C" Then
query = query & " AND PM.p_method_cd = '" & req_p_method_cd & "'"&VbCrlf
If initstatus <> "init" Then
query = query & " AND PM.p_child_sn = '" & Request("p_child_sn") & "'"&VbCrlf
End if
End If
'Response.Write Query
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
for i = 1 to Rs.RecordCount
If Rs("p_progress_flag") = "" Then
'ÇÁ·ÎÁ§Æ® º» Å×ÀÌºí ¼öÁ¤
'---------------------------------------
query2 = " UPDATE T_PROJECT_METHOD "
query2 = query2 & " SET p_progress_flag = 'xxx' "
'##### ¿¬±¸
query2 = query2 & " ,p_rsch_1_a = '' "
query2 = query2 & " ,p_rsch_2_a = '' "
query2 = query2 & " ,p_rsch_3_a = '' "
query2 = query2 & " ,p_rsch_4_a = '' "
query2 = query2 & " ,p_rsch_1_b = '' "
query2 = query2 & " ,p_rsch_2_b = '' "
query2 = query2 & " ,p_rsch_3_b = '' "
query2 = query2 & " ,p_rsch_4_b = '' "
query2 = query2 & " ,p_rsch_1_c = '' "
query2 = query2 & " ,p_rsch_2_c = '' "
query2 = query2 & " ,p_rsch_3_c = '' "
query2 = query2 & " ,p_rsch_4_c = '' "
'##### ½Ç»ç
query2 = query2 & " ,p_sv_1 = '' "
query2 = query2 & " ,p_sv_2 = '' "
query2 = query2 & " ,p_sv_3 = '' "
query2 = query2 & " ,p_sv_4 = '' "
query2 = query2 & " ,p_punch_1 = '' "
query2 = query2 & " ,p_punch_2 = '' "
query2 = query2 & " ,p_punch_3 = '' "
query2 = query2 & " ,p_punch_4 = '' "
query2 = query2 & " ,p_verify_1 = '' "
query2 = query2 & " ,p_verify_2 = '' "
query2 = query2 & " ,p_verify_3 = '' "
query2 = query2 & " ,p_verify_4 = '' "
query2 = query2 & " ,p_code_1 = '' "
query2 = query2 & " ,p_code_2 = '' "
query2 = query2 & " ,p_code_3 = '' "
query2 = query2 & " ,p_code_4 = '' "
'##### DP
query2 = query2 & " ,p_dp_1 = '' "
query2 = query2 & " ,p_dp_2 = '' "
query2 = query2 & " ,p_dp_3 = '' "
query2 = query2 & " ,p_dp_4 = '' "
'##### °æ¿µÀü·«½Ç
query2 = query2 & " ,p_it_1 = '' "
query2 = query2 & " ,p_it_2 = '' "
query2 = query2 & " ,p_it_3 = '' "
query2 = query2 & " ,p_it_4 = '' "
query2 = query2 & " WHERE p_sn = '"& p_sn &"' and p_child_sn = '"& Request("p_child_sn") &"' and p_method_cd = " & Rs("p_method_cd") & " "
set dbin = server.CreateObject("ADODB.CONNECTION")
dbin.Open adoConn
dbin.Execute query2
dbin.Close
End If
Rs.moveNext
Next
Rs.Close
End if
rsa.Open query, adoConn, 1
research_count = rsa.RecordCount
%>
<input type="hidden" name="research_count"id="research_count" value="<%=research_count %>">
<%
Dim p_index()
Dim p_method_cd()
Dim p_child_sn()
Dim p_intention()
Dim p_sur_area()
Dim p_sur_target()
Dim p_sample()
Dim p_inspection_rate()
Dim p_research_date_st()
Dim p_research_date_end()
Dim p_sur_part()
Dim p_field_process()
Dim p_rsch_dept()
Dim p_rsch_team()
Dim p_field_dept()
Dim p_is_dept()
Dim p_it_dept() '##### °³¹ßÆÀ
Dim p_supp_dept()
Dim p_rsch_a() '##### ¿¬±¸(±âȹ)
Dim p_rsch_b() '##### ¿¬±¸(ºÐ¼®)
Dim p_rsch_c() '##### ¿¬±¸(º¸°í¼­)
Dim p_sv_() '##### ½Ç»ç
Dim p_verify_() '##### ½Ç»ç(°ËÁõ)
Dim p_punch_() '##### ½Ç»ç(ÆÝÄ¡)
Dim p_code_() '##### DP(ÄÚµù)
Dim p_dp_() '##### DP
Dim p_it_() '##### °æ¿µÀü·«½Ç(IT)
Dim p_supp_()
Dim p_rsch_date_st() '##### ¿¬±¸
Dim p_rsch_date_end()
Dim p_rsch_date_time_st()
Dim p_rsch_date_time_end()
Dim p_field_date_st() '##### ½Ç»ç
Dim p_field_date_end()
Dim p_field_date_time_st()
Dim p_field_date_time_end()
Dim p_verify_date_st() '##### ½Ç»ç(°ËÁõ)
Dim p_verify_date_end()
Dim p_verify_date_time_st()
Dim p_verify_date_time_end()
Dim p_punch_date_st() '##### ½Ç»ç(ÆÝÄ¡)
Dim p_punch_date_end()
Dim p_punch_date_time_st()
Dim p_punch_date_time_end()
Dim p_code_date_st() '##### DP(ÄÚµù)
Dim p_code_date_end()
Dim p_code_date_time_st()
Dim p_code_date_time_end()
Dim p_dp_date_st() '##### DP
Dim p_dp_date_end()
Dim p_dp_date_time_st()
Dim p_dp_date_time_end()
Dim p_it_date_st() '##### °æ¿µÀü·«½Ç(IT)
Dim p_it_date_end()
Dim p_it_date_time_st()
Dim p_it_date_time_end()
Dim p_premeet_date() '##### ³»ºÎ¹ÌÆÃ
Dim p_premeet_time()
Dim p_premeet_place()
Dim p_ot_date() '##### ½Ç»çOT
Dim p_ot_time()
Dim p_ot_place()
Dim p_progress_flag()
Dim p_progress_status()
Dim p_sur_memo()
Dim p_input_complete()
Dim tmp_input_complete()
Dim tmp_progress_flag()
ReDim p_index(research_count)
ReDim p_method_cd(research_count, 2)
ReDim p_child_sn(research_count)
ReDim p_intention(research_count)
ReDim p_sur_area(research_count)
ReDim p_sur_target(research_count)
ReDim p_sample(research_count)
ReDim p_inspection_rate(research_count)
ReDim p_research_date_st(research_count)
ReDim p_research_date_end(research_count)
ReDim p_sur_part(research_count)
ReDim p_field_process(research_count)
ReDim p_rsch_dept(research_count)
ReDim p_rsch_team(research_count)
ReDim p_field_dept(research_count)
ReDim p_is_dept(research_count)
ReDim p_it_dept(research_count)
ReDim p_supp_dept(research_count)
ReDim p_rsch_a(4, research_count) '##### ¿¬±¸(±âȹ)
ReDim p_rsch_b(4, research_count) '##### ¿¬±¸(½Ç»ç)
ReDim p_rsch_c(4, research_count) '##### ¿¬±¸(º¸°í)
ReDim p_sv_(4, research_count) '##### ½Ç»ç
ReDim p_verify_(4, research_count) '##### ½Ç»ç(°ËÁõ)
ReDim p_punch_(4, research_count) '##### ½Ç»ç(ÆÝÄ¡)
ReDim p_code_(4, research_count) '##### ½Ç»ç(ÄÚµù)
ReDim p_dp_(4, research_count) '##### DP
ReDim p_it_(4, research_count) '##### °æ¿µÀü·«½Ç(IT)
ReDim p_supp_(4, research_count)
ReDim p_rsch_date_st(research_count) '##### ¿¬±¸
ReDim p_rsch_date_end(research_count)
ReDim p_field_date_st(research_count) '##### ½Ç»ç
ReDim p_field_date_end(research_count)
ReDim p_verify_date_st(research_count) '##### ½Ç»ç(°ËÁõ)
ReDim p_verify_date_end(research_count)
ReDim p_punch_date_st(research_count) '##### ½Ç»ç(ÆÝÄ¡)
ReDim p_punch_date_end(research_count)
ReDim p_code_date_st(research_count) '##### ½Ç»ç(ÄÚµù)
ReDim p_code_date_end(research_count)
ReDim p_dp_date_st(research_count) '##### DP
ReDim p_dp_date_end(research_count)
ReDim p_it_date_st(research_count) '##### °æ¿µÀü·«½Ç(IT)
ReDim p_it_date_end(research_count)
ReDim p_rsch_date_time_st(research_count) '##### ¿¬±¸
ReDim p_rsch_date_time_end(research_count)
ReDim p_field_date_time_st(research_count) '##### ½Ç»ç
ReDim p_field_date_time_end(research_count)
ReDim p_verify_date_time_st(research_count) '##### ½Ç»ç(°ËÁõ)
ReDim p_verify_date_time_end(research_count)
ReDim p_punch_date_time_st(research_count) '##### ½Ç»ç(ÆÝÄ¡)
ReDim p_punch_date_time_end(research_count)
ReDim p_code_date_time_st(research_count) '##### ½Ç»ç(ÄÚµù)
ReDim p_code_date_time_end(research_count)
ReDim p_dp_date_time_st(research_count) '##### DP
ReDim p_dp_date_time_end(research_count)
ReDim p_it_date_time_st(research_count) '##### °æ¿µÀü·«½Ç(IT)
ReDim p_it_date_time_end(research_count)
ReDim p_premeet_date(research_count)
ReDim p_premeet_time(research_count)
ReDim p_premeet_place(research_count)
ReDim p_ot_date(research_count)
ReDim p_ot_time(research_count)
ReDim p_ot_place(research_count)
ReDim p_progress_flag(research_count)
ReDim p_progress_status(research_count)
ReDim p_input_complete(research_count)
ReDim p_sur_memo(research_count)
p_index(1) = rsa("p_index")
p_method_cd(1, 1) = rsa("p_method_cd")
p_method_cd(1, 2) = rsa("p_method_nm")
tmp_method_cd = rsa("p_method_cd")
tmp_method_count = i
If CInt(tmp_method_cd) < 10 Then
tmp_method_cd = "0" & tmp_method_cd
End If
If tmp_method_count < 10 Then
tmp_method_count = "0" & 1
End if
If rsa("p_child_sn") = "" Or Len(rsa("p_child_sn")) < 10 Then
p_child_sn(1) = p_sn & "_" & p_sub_type & tmp_method_count
Else
p_child_sn(1) = rsa("p_child_sn")
End if
p_intention(1) = rsa("p_intention")
p_sur_area(1) = rsa("p_sur_area")
p_sur_target(1) = rsa("p_sur_target")
p_sample(1) = rsa("p_sample")
p_inspection_rate(1)= rsa("p_inspection_rate")
p_research_date_st(1) = rsa("p_research_date_st")
p_research_date_end(1) = rsa("p_research_date_end")
p_sur_part(1) = rsa("p_sur_part")
p_field_process(1) = rsa("p_field_process")
p_rsch_dept(1) = rsa("p_rsch_dept")
p_field_dept(1) = rsa("p_field_dept")
p_is_dept(1) = rsa("p_is_dept")
p_it_dept(1) = rsa("p_it_dept")
p_supp_dept(1) = rsa("p_supp_dept")
'##### ¿¬±¸
p_rsch_a(1, 1) = rsa("p_rsch_1_a")
p_rsch_a(2, 1) = rsa("p_rsch_2_a")
p_rsch_a(3, 1) = rsa("p_rsch_3_a")
p_rsch_a(4, 1) = rsa("p_rsch_4_a")
p_rsch_b(1, 1) = rsa("p_rsch_1_b")
p_rsch_b(2, 1) = rsa("p_rsch_2_b")
p_rsch_b(3, 1) = rsa("p_rsch_3_b")
p_rsch_b(4, 1) = rsa("p_rsch_4_b")
p_rsch_c(1, 1) = rsa("p_rsch_1_c")
p_rsch_c(2, 1) = rsa("p_rsch_2_c")
p_rsch_c(3, 1) = rsa("p_rsch_3_c")
p_rsch_c(4, 1) = rsa("p_rsch_4_c")
'##### ½Ç»ç
p_sv_(1, 1) = rsa("p_sv_1")
p_sv_(2, 1) = rsa("p_sv_2")
p_sv_(3, 1) = rsa("p_sv_3")
p_sv_(4, 1) = rsa("p_sv_4")
p_verify_(1, 1) = rsa("p_verify_1")
p_verify_(2, 1) = rsa("p_verify_2")
p_verify_(3, 1) = rsa("p_verify_3")
p_verify_(4, 1) = rsa("p_verify_4")
p_punch_(1, 1) = rsa("p_punch_1")
p_punch_(2, 1) = rsa("p_punch_2")
p_punch_(3, 1) = rsa("p_punch_3")
p_punch_(4, 1) = rsa("p_punch_4")
p_code_(1, 1) = rsa("p_code_1")
p_code_(2, 1) = rsa("p_code_2")
p_code_(3, 1) = rsa("p_code_3")
p_code_(4, 1) = rsa("p_code_4")
'##### DP
p_dp_(1, 1) = rsa("p_dp_1")
p_dp_(2, 1) = rsa("p_dp_2")
p_dp_(3, 1) = rsa("p_dp_3")
p_dp_(4, 1) = rsa("p_dp_4")
'###### °æ¿µÀü·«½Ç
p_it_(1, 1) = rsa("p_it_1")
p_it_(2, 1) = rsa("p_it_2")
p_it_(3, 1) = rsa("p_it_3")
p_it_(4, 1) = rsa("p_it_4")
p_supp_(1, 1) = rsa("p_supp_1")
p_supp_(2, 1) = rsa("p_supp_2")
p_supp_(3, 1) = rsa("p_supp_3")
p_supp_(4, 1) = rsa("p_supp_4")
'##### ¿¬±¸
if rsa("p_rsch_date_st") <> "" then
p_rsch_date_st(1) = split(rsa("p_rsch_date_st"), " ")(0)
p_rsch_date_time_st(1) = left(split(rsa("p_rsch_date_st"), " ")(1),2)
else
p_rsch_date_st(1) = ""
p_rsch_date_time_st(1) = ""
end if
if rsa("p_rsch_date_end") <> "" then
p_rsch_date_end(1) = split(rsa("p_rsch_date_end"), " ")(0)
p_rsch_date_time_end(1) = left(split(rsa("p_rsch_date_end"), " ")(1),2)
else
p_rsch_date_end(1) = ""
p_rsch_date_time_end(1) = ""
end if
'##### ½Ç»ç
if rsa("p_field_date_st") <> "" then
p_field_date_st(1) = split(rsa("p_field_date_st"), " ")(0)
p_field_date_time_st(1) = left(split(rsa("p_field_date_st"), " ")(1),2)
else
p_field_date_st(1) = ""
p_field_date_time_st(1) = ""
end if
if rsa("p_field_date_end") <> "" then
p_field_date_end(1) = split(rsa("p_field_date_end"), " ")(0)
p_field_date_time_end(1)= left(split(rsa("p_field_date_end"), " ")(1),2)
else
p_field_date_end(1) = ""
p_field_date_time_end(1)= ""
end if
if rsa("p_verify_date_st") <> "" then
p_verify_date_st(1) = split(rsa("p_verify_date_st"), " ")(0)
p_verify_date_time_st(1)= left(split(rsa("p_verify_date_st"), " ")(1),2)
else
p_verify_date_st(1) = ""
p_verify_date_time_st(1)= ""
end if
if rsa("p_verify_date_end") <> "" then
p_verify_date_end(1) = split(rsa("p_verify_date_end"), " ")(0)
p_verify_date_time_end(1)= left(split(rsa("p_verify_date_end"), " ")(1),2)
else
p_verify_date_end(1) = ""
p_verify_date_time_end(1)= ""
end if
if rsa("p_punch_date_st") <> "" then
p_punch_date_st(1) = split(rsa("p_punch_date_st"), " ")(0)
p_punch_date_time_st(1) = left(split(rsa("p_punch_date_st"), " ")(1),2)
else
p_punch_date_st(1) = ""
p_punch_date_time_st(1) = ""
end if
if rsa("p_punch_date_end") <> "" then
p_punch_date_end(1) = split(rsa("p_punch_date_end"), " ")(0)
p_punch_date_time_end(1) = left(split(rsa("p_punch_date_end"), " ")(1),2)
else
p_punch_date_end(1) = ""
p_punch_date_time_end(1) = ""
end if
'###### DP
if rsa("p_code_date_st") <> "" then
p_code_date_st(1) = split(rsa("p_code_date_st"), " ")(0)
p_code_date_time_st(1) = left(split(rsa("p_code_date_st"), " ")(1),2)
else
p_code_date_st(1) = ""
p_code_date_time_st(1) = ""
end if
if rsa("p_code_date_end") <> "" then
p_code_date_end(1) = split(rsa("p_code_date_end"), " ")(0)
p_code_date_time_end(1) = left(split(rsa("p_code_date_end"), " ")(1),2)
else
p_code_date_end(1) = ""
p_code_date_time_end(1) = ""
end if
if rsa("p_dp_date_st") <> "" then
p_dp_date_st(1) = split(rsa("p_dp_date_st"), " ")(0)
p_dp_date_time_st(1) = left(split(rsa("p_dp_date_st"), " ")(1),2)
else
p_dp_date_st(1) = ""
p_dp_date_time_st(1) = ""
end if
if rsa("p_dp_date_end") <> "" then
p_dp_date_end(1) = split(rsa("p_dp_date_end"), " ")(0)
p_dp_date_time_end(1) = left(split(rsa("p_dp_date_end"), " ")(1),2)
else
p_dp_date_end(1) = ""
p_dp_date_time_end(1) = ""
end if
'###### °æ¿µÀü·«½Ç(1T)
if rsa("p_it_date_st") <> "" then
p_it_date_st(1) = split(rsa("p_it_date_st"), " ")(0)
p_it_date_time_st(1) = left(split(rsa("p_it_date_st"), " ")(1),2)
else
p_it_date_st(1) = ""
p_it_date_time_st(1) = ""
end if
if rsa("p_it_date_end") <> "" then
p_it_date_end(1) = split(rsa("p_it_date_end"), " ")(0)
p_it_date_time_end(1) = left(split(rsa("p_it_date_end"), " ")(1),2)
else
p_it_date_end(1) = ""
p_it_date_time_end(1) = ""
end if
p_premeet_date(1) = rsa("p_premeet_date")
p_premeet_time(1) = rsa("p_premeet_time")
p_premeet_place(1) = rsa("p_premeet_place")
p_ot_date(1) = rsa("p_ot_date")
p_ot_time(1) = rsa("p_ot_time")
p_ot_place(1) = rsa("p_ot_place")
p_sur_memo(1) = rsa("p_sur_memo")
p_progress_flag(1) = rsa("p_progress_flag")
p_progress_status(1) = rsa("p_progress_status")
p_input_complete(1) = rsa("p_input_complete")
%>
<tr bgcolor="<%=tmp_bgcolor%>">
<td align="center" id="p_method_nm1"> <!-- Á¶»ç¹æ¹ý -->
<select id="p_method_c" <%= iif(p_progress_status(1) = "008", "Disabled", "") %>>
<%
q = " SELECT p_method_cd, p_method_nm FROM T_PROJECT_METHOD_CD WHERE p_use_yn ='Y' OR p_method_cd = '" & p_method_cd(1, 1) & "' ORDER BY p_gubn, p_method_cd "
Rs.Open q, adoConn, 1
Do while not Rs.Eof
%>
<option value="<%=Rs("p_method_cd")%>" <%= iif(Rs("p_method_cd") = p_method_cd(1, 1), "Selected", "") %>><%=Rs("p_method_nm")%></option>
<%
Rs.MoveNext
Loop
Rs.Close
%>
</select>
<input type="hidden" name="p_index1" style="width:80;" value="<%=p_index(1)%>" readonly>
<input type="hidden" name="p_method_cd1" style="width:80;" value="<%=p_method_cd(1, 1)%>" readonly>
<input type="hidden" name="p_child_sn1" style="width:80;" value="<%=p_child_sn(1)%>" readonly>
<input type="hidden" name="p_progress_flag1" style="width:160;" value="<%=p_progress_flag(1)%>">
<input type="hidden" name="p_progress_status1" style="width:160;" value="<%=p_progress_status(1)%>">
</td>
<td align="left" > <!-- Á¶»ç³»¿ë -->
<input type="text" name="p_intention1" id="p_intention1" style="width:170;" value="<%=p_intention(1)%>">
</td>
<td align="center" style="display:none;"> <!-- Á÷Á¢ºñ ¿¹»ê -->
<%
q = " select sum(convert(money, est_money)) as total_money from direct_cost "
q = q + " where p_sn like '" & p_sn & "' and cost_type = 'field' and del_yes_no = 'no' and p_child_sn = '" & p_child_sn(1) & "' "
Rs.Open q, adoConn, 1
tmp_total_money = ""
if Rs.RecordCount = 1 Then
if Rs("total_money") <> "" then
tmp_len = len(Rs("total_money"))
for j = 1 to int(tmp_len)
if j mod 3 = 1 and j <> 1 then
tmp_total_money = "," & tmp_total_money
end if
tmp_total_money = left(right(Rs("total_money"),j), 1) & tmp_total_money
Next
Else
tmp_total_money = "0"
end If
%>
<b class="tahoma"><%=tmp_total_money%>¿ø</b>
<%
end if
Rs.Close
%>
</td>
<td align="center" > <!-- Á¶»çÁö¿ª -->
<select name = "p_sur_area1" id="p_sur_area1">
<option value="">¼±ÅÃ</option>
<% q = "SELECT c_kind_code, c_common_code, c_code_name FROM T_COMMON_CODE_DETAIL WHERE c_kind_code = '012' "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("c_common_code")%>" <% if p_sur_area(1) = Rs("c_common_code") then %> selected <% end if %>> <%=Rs("c_code_name")%></option>
<% Rs.MoveNext
next
end if
Rs.Close %>
</select>
</td>
<td align="center" > <!-- Á¶»ç´ë»ó -->
<select name = "p_sur_target1" id ="p_sur_target1">
<option value="">¼±ÅÃ</option>
<% q = "SELECT c_kind_code, c_common_code, c_code_name FROM T_COMMON_CODE_DETAIL WHERE c_kind_code = '013' "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("c_common_code")%>" <% if p_sur_target(1) = Rs("c_common_code") then %> selected <% end if %>> <%=Rs("c_code_name")%></option>
<% Rs.MoveNext
next
end if
Rs.Close %>
</select>
</td>
<td align="center" > <!-- Ç¥º»¼ö -->
<input type="text" name="p_sample1" id="p_sample1" style="width:60px;" value="<%=p_sample(1)%>">
</td>
<td align="center" > <!-- Á¶»ç±â°£ -->
<input type="text" name="p_research_date_st1" id="p_research_date_st1" size="10" readonly value="<%=p_research_date_st(1)%>" class='selectDate' style="cursor:pointer">
~
<input type="text" name="p_research_date_end1" id="p_research_date_end1" size="10" readonly value="<%=p_research_date_end(1)%>" class='selectDate' style="cursor:pointer">
</td>
<td align="center" > <!-- Á¶»çºÐ·ù -->
<select name = "p_sur_part1" id="p_sur_part1">
<option value="">¼±ÅÃ</option>
<% q = "SELECT c_kind_code, c_common_code, c_code_name FROM T_COMMON_CODE_DETAIL WHERE c_kind_code = '014' "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("c_common_code")%>" <% if p_sur_part(1) = Rs("c_common_code") then %> selected <% end if %>> <%=Rs("c_code_name")%></option>
<% Rs.MoveNext
next
end if
Rs.Close %>
</select>
</td>
<td align="center" > <!-- ½Ç»ç¼öÇà -->
<select name = "p_field_process1" id="p_field_process1">
<option value="">¼±ÅÃ</option>
<% q = "SELECT c_kind_code, c_common_code, c_code_name FROM T_COMMON_CODE_DETAIL WHERE c_kind_code = '015' "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("c_common_code")%>" <% if p_field_process(1) = Rs("c_common_code") then %> selected <% end if %>> <%=Rs("c_code_name")%></option>
<% Rs.MoveNext
next
end if
Rs.Close %>
</select>
</td>
<td align="center" > <!-- °ËÁõ·ü -->
<input type="text" name="p_inspection_rate1" id="p_inspection_rate1" style="width:60px;text-align:right;" value="<%=p_inspection_rate(1)%>">%
</td>
</tr>
<%
rsa.Close
%>
<!-- loop end -->
</table>
</td>
</tr>
<tr height="26">
<td colspan="5" style="padding: 25px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<img src="/images/main/bubble_1num.png" style="">
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">¾÷¹« ¼öÇà ÀηÂ/ÀÏÁ¤ &nbsp;
<%
Dim detailViewShow
Dim document_work_flow
detailViewShow = False
document_work_flow = false
If CInt(p_progress_status(1)) >= 1 Then
If CInt(p_progress_status(1)) = 1 Then
If session("depart_code") = p_depart_dep or session("depart_code") = "0" or (session("depart_code") = "64" and p_depart_dep = "61") or (session("depart_code") = "63" and p_depart_dep = "62") Then
detailViewShow = true
End If
%>
<font style="color: orange;">(Âü¿©ºÎ¼­ Á¤º¸ ÀÔ·Â Áß ÀÔ´Ï´Ù.)</font>
<%
ElseIf CInt(p_progress_status(1)) = 6 Then
detailViewShow = True
query = "select p_progress_flag, p_input_complete, p_field_dept, isnull(sv_prog, '') as sv_prog, isnull(qc_prog, '') as qc_prog "
query = query & " from T_PROJECT_METHOD TPM LEFT JOIN direct_cost_field DCF ON TPM.p_child_sn = DCF.p_child_sn AND DCF.del_yn = 'n' "
query = query & " where p_sn = '"&p_sn&"' and p_sub_type = '"&p_sub_type&"' "
If p_sub_type = "C" Then
query = query + " and TPM.p_child_sn = '"&p_child_sn(1)&"' "
End if
Dim direct_cost_depart
Dim information_depart
ReDim tmp_input_complete(3)
ReDim tmp_progress_flag(3)
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 Then
If p_sub_type = "C" Then
if Rs("p_progress_flag") = "ooo" then
If Rs("p_input_complete") = "ooo" Or Rs("p_input_complete") = "oooo" Then '' index 1 ¿¬±¸, index 2 ½Ç»ç, index 3 QCÆÀ
document_work_flow = True
Else
if mid(Rs("p_input_complete"),1,1) = "x" then
direct_cost_depart = "¿¬±¸ "
end if
if mid(Rs("p_input_complete"),2,1) = "x" then
if direct_cost_depart <> "" then
direct_cost_depart = direct_cost_depart & ", "
End if
direct_cost_depart = direct_cost_depart & "½Ç»ç"
if Rs("p_field_dept") = "8" Then
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(QC) "
End If
ElseIf Rs("p_field_dept") = "9" Then
if Rs("sv_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(SV) "
End If
Else
if Rs("sv_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(SV"
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & ", QC) "
Else
direct_cost_depart = direct_cost_depart & ") "
End If
Else
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(QC) "
End If
End If
End If
end if
if mid(Rs("p_input_complete"),3,1) = "x" then
if direct_cost_depart <> "" then
direct_cost_depart = direct_cost_depart & ", "
End if
direct_cost_depart = direct_cost_depart & "QC "
end if
End if
else
if mid(Rs("p_progress_flag"),1,1) = "x" then
information_depart = "¿¬±¸ "
end if
if mid(Rs("p_progress_flag"),2,1) = "x" then
if information_depart <> "" then
information_depart = information_depart & ", "
End if
information_depart = information_depart & "½Ç»ç "
end if
if mid(Rs("p_progress_flag"),3,1) = "x" then
if information_depart <> "" then
information_depart = information_depart & ", "
End if
information_depart = information_depart & "DP "
end if
if mid(Rs("p_input_complete"),1,1) = "x" then
direct_cost_depart = "¿¬±¸ "
end if
if mid(Rs("p_input_complete"),2,1) = "x" then
if direct_cost_depart <> "" then
direct_cost_depart = direct_cost_depart & ", "
End if
direct_cost_depart = direct_cost_depart & "½Ç»ç"
if Rs("p_field_dept") = "8" Then
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(QC) "
Else
direct_cost_depart = direct_cost_depart & " "
End If
ElseIf Rs("p_field_dept") = "9" Then
if Rs("sv_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(SV) "
Else
direct_cost_depart = direct_cost_depart & " "
End If
Else
if Rs("sv_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(SV"
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & ", QC) "
Else
direct_cost_depart = direct_cost_depart & ") "
End If
Else
if Rs("qc_prog") = "" Then
direct_cost_depart = direct_cost_depart & "(QC) "
Else
direct_cost_depart = direct_cost_depart & " "
End If
End If
End If
end if
if mid(Rs("p_input_complete"),3,1) = "x" then
if direct_cost_depart <> "" then
direct_cost_depart = direct_cost_depart & ", "
End if
direct_cost_depart = direct_cost_depart & "QC "
end if
end if
Else
End if
end if
Rs.Close
If document_work_flow Then
%>
<font style="color: orange;">(Á÷Á¢ºñ ¿¹»ê ÀÔ·Â ¿Ï·á. ¼öÇà°èȹ¼­ °áÀç »ó½Å Çϼ¼¿ä)</font>
<%
Else
if information_depart <> "" then
%>
<font style="color: orange;">(<%=information_depart%>Á¤º¸ ÀÔ·Â Áß)</font>
<%
end if
if direct_cost_depart <> "" then
%>
<font style="color: orange;">(<%=direct_cost_depart%>Á÷Á¢ºñ ¿¹»ê Á¤º¸ ÀÔ·Â Áß)</font>
<%
end if
End if
ElseIf CInt(p_progress_status(1)) = 7 Then
detailViewShow = true
%>
<font style="color: orange;">(¼öÇà°èȹ¼­ °áÀç Áß) - (<%= order_name %> °áÀç ´Ü°è)</font>
<%
ElseIf CInt(p_progress_status(1)) = 8 Then
detailViewShow = true
%>
<font style="color: orange;">(¼öÇà°èȹ¼­ °áÀç ¿Ï·á)</font>
<%
detailViewShow = true
End if
Else
detailViewShow = true
End If
%>
</span>
</div>
</td>
</tr>
<tr>
<td style="padding:10px 0 5px 0;" colspan="8">
<font class="k_darkorange">Âü¿© ºÎ¼­</font><br>
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="30px;">
<td align="center" >¸®¼­Ä¡¾ØÄÁ¼³ÆÃ</td>
<td align="center" >µ¥ÀÌÅÍÀ̳뺣À̼Ç</td>
<td align="center" class="tit_left tit_right">µðÁöÅÐÄÁ¹öÀü½º</td>
</tr>
<tr id="joindept">
<td align="center" width="25%">
<select name="p_rsch_dept1" id="p_rsch_dept1">
<option value="">¼±ÅÃ</option>
<%
'##### Á¶Á÷ °³Æí(2019)
q = ""
q = q&" select d_code, d_name, b.t_name, b.t_code from Depart as a "
q = q&" left join "
q = q&" ( "
q = q&" select T_name, T_code, before_t_cd1 from V_department "
q = q&" ) as b on a.d_code=b.before_t_cd1 "
q = q&" where d_yes_no = 'Y' and ((d_code >= 20 and d_code < 40) OR d_code > 45) "
q = q&" order by t_code "
Rs.Open q, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount
if p_rsch_dept(1) = Rs("d_code") or cint(Rs("d_code")) > 54 then
%>
<option value="<%=Rs("d_code")%>" <% if p_rsch_dept(1) = Rs("d_code") then %> selected <% end if %>> <%=Rs("t_name")%> ( <%=Rs("d_name")%> )</option>
<%
end if
Rs.MoveNext
next
end if
Rs.Close
'TF °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
<option value="900" <% if p_rsch_dept(1) = 900 then %> selected <% end if %>>Âü¿©¾ÈÇÔ</option>
</select>
</td>
<td align="center" width="25%">
<select name="p_field_dept1" id="p_field_dept1">
<option value="">¼±ÅÃ</option>
<option value="12" <% if p_field_dept(1) = 12 then %> selected <% end if %>>FW/QC</option>
<option value="9" <% if p_field_dept(1) = 9 then %> selected <% end if %>>FW</option>
<option value="8" <% if p_field_dept(1) = 8 or p_is_dept(1) = 16 then %> selected <% end if %>>QC</option>
<option value="900" <% if p_field_dept(1) = 900 then %> selected <% end if %>>Âü¿©¾ÈÇÔ</option>
</select>
<input type="hidden" name="sel_p_field_dept1" value="<%=p_field_dept(1)%>" />
</td>
<td align="center" width="25%">
<select name="p_is_dept1" id="p_is_dept1">
<option value="">¼±ÅÃ</option>
<option value="17" <% if p_is_dept(1) = 17 or p_is_dept(1) = 15 then %> selected <% end if %>>DI</option>
<option value="900" <% if p_is_dept(1) = 900 or p_is_dept(1) = 16 then %> selected <% end if %>>Âü¿©¾ÈÇÔ</option>
</select>
<select name="p_it_dept1" id="p_it_dept1">
<option value="">¼±ÅÃ</option>
<option value="18" <% if p_it_dept(1) = 18 then %> selected <% end if %>>DS/DB</option>
<option value="900" <% if p_it_dept(1) = 900 or p_it_dept(1) = 16 then %> selected <% end if %>>Âü¿©¾ÈÇÔ</option>
</select>
</td>
</td>
</tr>
<%if p_progress_status(1) = "008" then %>
<tr>
<td align="center" class="tit_left tit_right" colspan="3">¿Ï·á ó¸® ¿©ºÎ
<%if p_research_complete = "1" and p_field_complete = "1" and p_dp_complete = "1" then %>
<font color="red">(Àüü ¿Ï·á µÊ)</font>
<%end if %>
</td>
</tr>
<tr>
<td align="center" >
<%if p_rsch_dept(1) <> "900" then %><%if p_research_complete = "1" then %><font color="red">¿Ï·á</font>
<%if session("Depart_Code") = 18 Or session("Depart_Code") = 19 Or Session("User_Number")="20220303" Or Session("User_Number")="20220410" then '20240726 Depart_Code À̵¿À¸·Î ¹øÈ£·Î Ãß°¡ %>
<a href="javascript:prj_release('research');">(ÇØÁ¦)</a>
<%end if %>
<%end if %>
<%else %>¹ÌÂü¿©<%end if %>
</td>
<td align="center" >
<%if p_field_dept(1) <> "900" then %><%if p_field_complete = "1" then %><font color="red">¿Ï·á</font>
<%if session("Depart_Code") = 18 Or session("Depart_Code") = 19 Or Session("User_Number")="20220303" Or Session("User_Number")="20220410" then %>
<a href="javascript:prj_release('field');">(ÇØÁ¦)</a>
<%end if %>
<%end if %>
<%else %>¹ÌÂü¿©<%end if %>
</td>
<td align="center" >
<%if p_is_dept(1) <> "900" then %><%if p_dp_complete = "1" then %><font color="red">¿Ï·á</font>
<%if session("Depart_Code") = 18 Or session("Depart_Code") = 19 Or Session("User_Number")="20220303" Or Session("User_Number")="20220410" then %>
<a href="javascript:prj_release('dp');">(ÇØÁ¦)</a>
<%end if %>
<%end if %>
<%else %>¹ÌÂü¿©<%end if %>
<%if p_it_dept(1) <> "900" then %><%if p_it_complete = "1" then %><font color="red">¿Ï·á</font>
<%if session("Depart_Code") = 18 Or session("Depart_Code") = 19 Or Session("User_Number")="20220303" Or Session("User_Number")="20220410" then %>
<a href="javascript:prj_release('it');">(ÇØÁ¦)</a>
<%end if %>
<%end if %>
<%else %>¹ÌÂü¿©<%end if %>
</td>
</tr>
<%end if %>
</table>
</td>
</tr>
<%
If CInt(p_progress_status(1)) > 1 Then
%>
<tr>
<td style="padding:10px 0 5px 0;" colspan="8">
<div style="height: 24px">
<font class="k_darkorange">Âü¿©ÀηÂ</font>&nbsp;&nbsp;&nbsp;&nbsp;
<!--<a href="javascript:js_user_rate_view('<%=Request("p_child_sn")%>');" >[¢Ñ ¿¬±¸ºÎ¼­ »ç¿ø ÇÒ´çºñÀ² È®ÀÎ]</a>-->
</div>
<table class="table table-sm table-sm2 table-bordered table-head tr-colors" id="joindept">
<tr height="30px;">
<td align="center" rowspan="2" width="10%">¼ø¹ø</td>
<td align="center" colspan="3" width="30%">¸®¼­Ä¡¾ØÄÁ¼³ÆÃ<%if p_rsch_dept(1) <> "900" then %> <span><input type="button" onclick="other_depart();" value="Àüü ¿¬±¸ºÎ¼­ ¸ñ·Ïº¸±â"/></span><%end if %></td>
<td align="center" colspan="4" width="40%">µ¥ÀÌÅÍÀ̳뺣À̼Ç</td>
<td align="center" colspan="2" width="20%">µðÁöÅÐÄÁ¹öÀü½º</td>
<!--<td align="center" class="tit_left tit_right" rowspan="2" width="10%">°æ¿µÀü·«½Ç</td>-->
</tr>
<tr>
<td align="center" >±âȹ(¼³¹®Áö)</td>
<td align="center" >½Ç»ç(ºÐ¼®)</td>
<td align="center" >º¸°í(Á¦Ãâ)</td>
<td align="center" >½Ç»ç</td>
<td align="center" >°ËÁõ</td>
<td align="center" >ÆÝÄ¡</td>
<td align="center" >ÄÚµù</td>
<td align="center" >ºÐ¼®</td>
<td align="center" >DS/DB</td>
</tr>
<%for k = 1 to 4 %>
<tr>
<td align="center" ><%=k %></td>
<!--±âȹ1-->
<td align="center" >
<select name="p_rsch_<%=k %>_a1" id="p_rsch_<%=k %>_a1">
<option value="">¼±ÅÃ</option>
<%
resignCnt = 0
%>
<!-- --------------------------------------------->
<option value="20190601" <% if cstr(p_rsch_a(k, 1)) = "20190601" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)ÀÌÇýÁø</option>
<option value="20190301" <% if cstr(p_rsch_a(k, 1)) = "20190301" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)Á¶¿ìö</option> <!--2024-06-17 M3°ø¼®À¸·Î ´ë¸® -->
<option value="20160205" <% if cstr(p_rsch_a(k, 1)) = "20160205" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)¹ÚÁöÈÆ</option>
<option value="20210107" <% if cstr(p_rsch_a(k, 1)) = "20210107" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)½Å»ó¿í </option>
<!-- 2024-05-09 ¼­¼º¿Ï @¸¶ÄÉÆÃ 1±×·ìÀå ºÎÀç·Î ¾ÈÁ¤¸ð ±×·ìÀå º¸ÀÌ°Ô ÇϵåÄÚµù -->
<%if Session("N_team") = 701 then %>
<option value="20200302" <% if cstr(p_rsch_a(k, 1)) = "20200302" then %> selected <% end if %>>(¸¶ÄÉ)¾ÈÁ¤¸ð </option>
<%end if%>
<!-- --------------------------------------------->
<% query = "select p_no, p_name, p_team_name as p_depart from v_person "
query = query & " where p_resign = 0 "
if p_rsch_dept(1) = 90 then
query = query & " and (p_depart between '20' and '90' or p_depart = 90)"
else
query = query & " and p_depart = " & p_rsch_dept(1) & " "
end if
query = query & " and p_job_name in ('¿¬±¸', 'Á¦ÀÛ') "
query = query & " order by p_depart, p_no "
Rs.Open query, adoConn, 1
' response.write Rs.RecordCount
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_rsch_a(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>>(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<% if cstr(p_rsch_a(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_rsch_a(k, 1)) <> "" Then
query = "select p_name, p_team_name as p_depart from v_person where p_no = '"&cstr(p_rsch_a(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
' response.write query
%>
<option value="<%=p_rsch_a(k, 1)%>" selected >(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TF °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--½Ç»ç°ü¸®1-->
<td align="center" >
<select name="p_rsch_<%=k %>_b1" id="p_rsch_<%=k %>_b1">
<option value="">¼±ÅÃ</option>
<%
resignCnt = 0
%>
<!-- --------------------------------------------->
<option value="20190601" <% if cstr(p_rsch_b(k, 1)) = "20190601" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)ÀÌÇýÁø</option>
<option value="20190301" <% if cstr(p_rsch_a(k, 1)) = "20190301" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)Á¶¿ìö</option> <!--2024-06-17 M3°ø¼®À¸·Î ´ë¸® -->
<option value="20160205" <% if cstr(p_rsch_b(k, 1)) = "20160205" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)¹ÚÁöÈÆ</option>
<option value="20210107" <% if cstr(p_rsch_b(k, 1)) = "20210107" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)½Å»ó¿í</option>
<!-- 2024-05-09 ¼­¼º¿Ï @¸¶ÄÉÆÃ 1±×·ìÀå ºÎÀç·Î ¾ÈÁ¤¸ð ±×·ìÀå º¸ÀÌ°Ô ÇϵåÄÚµù -->
<%if Session("N_team") = 701 then %>
<option value="20200302" <% if cstr(p_rsch_a(k, 1)) = "20200302" then %> selected <% end if %>>(¸¶ÄÉ)¾ÈÁ¤¸ð </option>
<%end if%>
<!-- --------------------------------------------->
<% query = "select p_no, p_name, p_team_name as p_depart from v_person "
query = query & " where p_resign = 0 "
if p_rsch_dept(1) = 90 then
query = query & " and (p_depart between '20' and '90' or p_depart = 90)"
else
query = query & " and p_depart = " & p_rsch_dept(1) & " "
end if
if p_rsch_team(1) = 701 then
query = query & " and p_no = '20200302'"
end if
query = query & " and p_job_name in ('¿¬±¸', 'Á¦ÀÛ') "
query = query & " order by p_depart, p_no "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_rsch_b(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>>(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<% if cstr(p_rsch_b(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_rsch_b(k, 1)) <> "" Then
query = "select p_name, p_team_name as p_depart from v_person where p_no = '"&cstr(p_rsch_b(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_rsch_b(k, 1)%>" selected >(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TF °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--º¸°í¼­1-->
<td align="center" >
<select name="p_rsch_<%=k %>_c1" id="p_rsch_<%=k %>_c1">
<option value="">¼±ÅÃ</option>
<%
resignCnt = 0
%>
<!-- --------------------------------------------->
<option value="20190601" <% if cstr(p_rsch_c(k, 1)) = "20190601" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)ÀÌÇýÁø</option>
<!--<option value="20210105" <% if cstr(p_rsch_a(k, 1)) = "20210105" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)±è´Ù½½</option>-->
<option value="20190301" <% if cstr(p_rsch_a(k, 1)) = "20190301" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)Á¶¿ìö</option> <!--2024-06-17 M3°ø¼®À¸·Î ´ë¸® -->
<option value="20160205" <% if cstr(p_rsch_c(k, 1)) = "20160205" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)¹ÚÁöÈÆ</option>
<option value="20210107" <% if cstr(p_rsch_c(k, 1)) = "20210107" then %> selected <% resignCnt = 1 %> <% end if %>>(º»)½Å»ó¿í</option>
<!-- 2024-05-09 ¼­¼º¿Ï @¸¶ÄÉÆÃ 1±×·ìÀå ºÎÀç·Î ¾ÈÁ¤¸ð ±×·ìÀå º¸ÀÌ°Ô ÇϵåÄÚµù -->
<%if Session("N_team") = 701 then %>
<option value="20200302" <% if cstr(p_rsch_a(k, 1)) = "20200302" then %> selected <% end if %>>(¸¶ÄÉ)¾ÈÁ¤¸ð </option>
<%end if%>
<!-- --------------------------------------------->
<% query = "select p_no, p_name, p_team_name as p_depart from v_person "
query = query & " where p_resign = 0 "
if p_rsch_dept(1) = 90 then
query = query & " and (p_depart between '20' and '90' or p_depart = 90)"
else
query = query & " and p_depart = " & p_rsch_dept(1) & " "
end if
query = query & " and p_job_name in ('¿¬±¸', 'Á¦ÀÛ') "
query = query & " order by p_depart, p_no "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_rsch_c(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>>(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<% if cstr(p_rsch_c(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_rsch_c(k, 1)) <> "" Then
query = "select p_name, p_team_name as p_depart from v_person where p_no = '"&cstr(p_rsch_c(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_rsch_c(k, 1)%>" selected >(<%= left(Rs("p_depart"),2)%>)<%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TF °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--½Ç»ç1-->
<td align="center" >
<select name="p_sv_<%=k %>1" id="p_sv_<%=k %>1" <% If p_field_dept(1) = "900" Then %> disabled <% End if %>>
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and p_depart = '12' "
query = query & " and (c.code = '03') "
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_sv_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_sv_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_sv_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_sv_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_sv_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--°ËÁõ1-->
<td align="center" >
<select name="p_verify_<%=k %>1" id="p_verify_<%=k %>1" <% If p_field_dept(1) = "900" Then %> disabled <% End if %>>
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and p_depart = '12' "
query = query & " and (c.code = '04' or c.code = '12') "
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_verify_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_verify_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_verify_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_verify_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_verify_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--ÆÝÄ¡1-->
<td align="center" >
<select name="p_punch_<%=k %>1" id="p_punch_<%=k %>1" <% If p_field_dept(1) = "900" Then %> disabled <% End if %>>
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and p_depart = '12' "
query = query & " and (c.code = '06' or c.code='12' ) "
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_punch_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_punch_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_punch_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_punch_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_punch_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--ÄÚµù1-->
<td align="center" >
<!--<select name="p_code_<%=k %>1" id="p_code_<%=k %>1" <% If p_is_dept(1) = "900" Then %> disabled <% End if %>>-->
<select name="p_code_<%=k %>1" id="p_code_<%=k %>1" <% If p_field_dept(1) = "900" Then %> disabled <% End if %>>
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and p_depart = '12' "
query = query & " and c.d_yes_no='no' and (c.code = '05' or c.code='12') "
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_code_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_code_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_code_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_code_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_code_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--DP1(ºÐ¼®)-->
<td align="center" >
<!--<select name="p_dp_<%=k %>1" id="p_dp_<%=k %>1" <% If p_is_dept(1) = "900" Then %> disabled <% End if %>>-->
<select name="p_dp_<%=k %>1" id="p_dp_<%=k %>1">
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and p_depart = '17' "
'query = query & " where p_resign = 0 and p_depart = " & p_is_dept(1) & " "
query = query & " and c.code = '07' and c.d_yes_no='no' "
'ÀüÀÌ»ç´Ô ÇϵåÄÚµù
query = query & " union all"
query = query & " select p_no, p_name, p_depart, p_job_part from person where p_name in ('ÀüÁö¿ø','¹é¼ºÈñ')"
'Response.Write query
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_dp_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_dp_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_dp_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_dp_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_dp_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<td align="center" >
<select name="p_it_<%=k %>1" id="p_it_<%=k %>1">
<option value="">¼±ÅÃ</option>
<% query = "select p_no, p_name, p_depart, p_job_part from person as p "
query = query & " left outer join category_Àλç°ü¸®¿ë as c "
query = query & " on p.p_job_part = c.code "
query = query & " and c.±¸ºÐ = '´ã´ç¾÷¹«' "
query = query & " where p_resign = 0 and ((p_depart = '18' and c.code = '08') OR (p_depart = '17' and c.code <> '07') OR p_depart in ('19','20')) "
query = query & " and c.d_yes_no='no' "
'Response.Write query
Rs.Open query, adoConn, 1
resignCnt = 0
if Rs.RecordCount > 0 then
for j = 1 to Rs.RecordCount %>
<option value="<%=Rs("p_no")%>" <% if cstr(p_it_(k, 1)) = cstr(Rs("p_no")) then %> selected <% end if %>> <%=Rs("p_name")%></option>
<%
if cstr(p_it_(k, 1)) = cstr(Rs("p_no")) then
resignCnt = 1
End if
Rs.MoveNext
next
end if
Rs.Close
If resignCnt = 0 and cstr(p_it_(k, 1)) <> "" Then
query = "select p_name from person where p_no = '"&cstr(p_it_(k, 1))&"' "
Rs.Open query, adoConn, 1
if Rs.RecordCount > 0 then
%>
<option value="<%=p_it_(k, 1)%>" selected > <%=Rs("p_name")%></option>
<%
End If
Rs.Close
End If
'TFT °°Àº ŸÆÀÀÌ ÀÖÀ» °æ¿ì ·ÎÁ÷ Ãß°¡
%>
</select>
</td>
<!--IT1-->
</tr>
<% Next %>
</table>
</td>
</tr>
<tr>
<td style="padding:10px 0 5px 0;" colspan="8">
<font class="k_darkorange">ÀÏÁ¤</font><br>
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="30px;">
<td align="center" rowspan="2" >±¸ºÐ</td>
<td align="center" rowspan="2" width="13%">¸®¼­Ä¡¾ØÄÁ¼³ÆÃ</td>
<td align="center" colspan="4" >µ¥ÀÌÅÍÀ̳뺣À̼Ç</td>
<td align="center" colspan="2" >µðÁöÅÐÄÁ¹öÀü½º</td>
</tr>
<tr>
<td align="center" width="13%">½Ç»ç</td>
<td align="center" width="13%">°ËÁõ</td>
<td align="center" width="13%">ÆÝÄ¡</td>
<td align="center" width="13%">ÄÚµù</td>
<td align="center" width="13%">ºÐ¼®</td>
<td align="center" width="13%">DS/DB</td>
</tr>
<tr>
<td align="center" >¼¼ºÎÀÏÁ¤</td>
<td align="center" >
<input type="text" name="p_rsch_date_st1" id="p_rsch_date_st1" readonly value="<%=p_rsch_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;" >
~
<input type="text" name="p_rsch_date_end1" id="p_rsch_date_end1" readonly value="<%=p_rsch_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;" >
</td>
<td align="center" >
<input type="text" name="p_field_date_st1" id="p_field_date_st1" readonly value="<%=p_field_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_field_date_end1" id="p_field_date_end1" readonly value="<%=p_field_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
<td align="center" >
<input type="text" name="p_verify_date_st1" id="p_verify_date_st1" readonly value="<%=p_verify_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_verify_date_end1" id="p_verify_date_end1" readonly value="<%=p_verify_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
<!--ÆÝĪ -->
<td align="center" >
<input type="text" name="p_punch_date_st1" id="p_punch_date_st1" readonly value="<%=p_punch_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_punch_date_end1" id="p_punch_date_end1" readonly value="<%=p_punch_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
<!-- ÄÚµù -->
<td align="center" >
<input type="text" name="p_code_date_st1" id="p_code_date_st1" readonly value="<%=p_code_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_code_date_end1" id="p_code_date_end1" readonly value="<%=p_code_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
<!-- DP -->
<td align="center" >
<input type="text" name="p_dp_date_st1" id="p_dp_date_st1" readonly value="<%=p_dp_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_dp_date_end1" id="p_dp_date_end1" readonly value="<%=p_dp_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
<td align="center" >
<input type="text" name="p_it_date_st1" id="p_it_date_st1" readonly value="<%=p_it_date_st(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
~
<input type="text" name="p_it_date_end1" id="p_it_date_end1" readonly value="<%=p_it_date_end(1)%>" class='selectDate' style="cursor:pointer;font-size:11px;width:74px;">
</td>
</tr>
<tr>
<td align="center" >³»ºÎ¹ÌÆÃ</td>
<td colspan="7">
<input type="text" name="p_premeet_date1" id="p_premeet_date1" style="width:120px;cursor:pointer;" readonly value="<%=p_premeet_date(1)%>" class='selectDate' <% If session("depart_code") <> p_depart_dep Then %><% End if %>>
<select name="p_premeet_place1" id="p_premeet_place1" style='display:none;'>
<option value="">¼±ÅÃ</option>
</select>
</td>
</tr>
<tr>
<td align="center" >½Ç»çOT</td>
<td colspan="7">
<input type="text" name="p_ot_date1" id="p_ot_date1" style="width:120px;cursor:pointer;" readonly value="<%=p_ot_date(1)%>" class='selectDate' <% If session("depart_code") <> p_depart_dep Then %><% End if %>>
<select name="p_ot_place1" id="p_ot_place1" style='display:none;'>
<option value="">¼±ÅÃ</option>
</select>
</td>
</tr>
</table>
</td>
</tr>
<%
End if
%>
<tr>
<td style="padding:10px 0 5px 0;" colspan="8">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr>
<td align="center" class="tit_left tit_right" width="15%">ºñ°í(¸Þ¸ð)</td>
<td align="center" >
<TEXTAREA rows="5" cols="80" name="p_sur_memo1" style="width:100%;height:80;"><%=p_sur_memo(1)%></TEXTAREA>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td colspan="6" height="1px" bgcolor="#cecece"></td>
</tr>
<tr height="26">
<td colspan="5" style="padding: 25px 0 0 0;">
<div style="position:relative; padding: 0px; margin: 0px;">
<div style="float: left;width: 150px;"><img src="/images/main/bubble_1num.png" style="">
<span style="position:absolute; top: 1px; left: 27px; font-size: 12pt; font-weight:bold;">÷ºÎ¹®¼­</span></div>
<div style="float: left;" ><span style="color:red;" >
* ÇÁ·ÎÁ§Æ® °ü·Ã ÀÏüÀÇ ÀÚ·á(Á¦¾È¼­, º¸°í¼­, °ßÀû¼­ µî)´Â ¿µ¾÷ºñ¹ÐÀÌ Æ÷ÇÔµÈ È¸»çÀÇ ÀÚ»êÀÔ´Ï´Ù.
<br>&nbsp;&nbsp;ÇÁ·ÎÁ§Æ® ¼öÇà¿¡ Âü°íÇÏ´Â ¸ñÀû ¿Ü »çÀûÀ¸·Î »ç¿ëÇϰųª ¿ÜºÎ·Î À¯ÃâÇÏ´Â ÇàÀ§¸¦ ±ÝÁöÇÕ´Ï´Ù.
</span>
</div>
<div><img src="/images/project/btn_cost3.jpg" onClick="fileadd()" style='cursor:hand; position:absolute; top: 1px; right: 0px;' align="absmiddle"></div>
</div>
</td>
</tr>
<tr>
<td style="padding:0px;" colspan="5">
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr>
<td style="padding:0px 0 5px 0;">
<table id="attach_table" class="table table-sm table-sm2 table-bordered table-head tr-colors">
<tr height="30px;">
<td align="center" width="6%">¼ø¹ø</td>
<td align="center" width="8%">ÀÚ·áÄ«Å×°í¸®</td>
<td align="center" width="58%">÷ºÎ¹®¼­ÆÄÀϸí</td>
<td align="center" width="10%">´ã´çÀÚ</td>
<td align="center" class="tit_left tit_right" width="16%">÷ºÎÀÏÀÚ</td>
</tr>
<%
query = " SELECT f_id, f_kind, f_p_sn, f_file_name, f_save_name, f_input_dt, f_input_user, p_name "
query = query & " FROM T_SYSTEM_ATTACH as TSA "
query = query & " LEFT OUTER JOIN person as P "
query = query & " ON TSA.f_input_user = P.p_no "
query = query & " WHERE f_p_sn = '"&p_sn& "' "
query = query & " AND f_use_yn = 'Y' "
query = query & " AND f_work_type = '001' and f_kind <> '099' "
query = query & " order by f_kind, f_id "
Rs.Open query, adoConn, 1
attach_file_count = Rs.recordCount
dim f_attach_info()
redim f_attach_info(attach_file_count, 6)
Dim f_attach_index
f_attach_index = 1
select_kind_code_flag = True
other_kind_code_falg = True
default_kind_code_flag = false
kind_code = ""
i = 1
row_cnt = 1
Do While i < 10
kind_code = "00" & CStr(i)
If attach_file_count > 0 then
If default_kind_code_flag Then
select_kind_code_flag = true
Else
If kind_code = Rs("f_kind") Then
select_kind_code_flag = False
other_kind_code_falg = False
f_attach_info(f_attach_index, 0) = Rs("f_id")
f_attach_info(f_attach_index, 1) = Rs("f_kind")
f_attach_info(f_attach_index, 2) = Rs("f_file_name")
f_attach_info(f_attach_index, 3) = Rs("p_name")
f_attach_info(f_attach_index, 4) = Rs("f_input_dt")
f_attach_info(f_attach_index, 5) = Rs("f_input_user")
Else
select_kind_code_flag = True
End If
End If
If select_kind_code_flag Then
If other_kind_code_falg then
%>
<tr>
<td align="center" ><%=row_cnt%></td>
<td align="center" >
<input type="hidden" name="f_id[<%=row_cnt-1%>]" value="" class="file_id"/>
<select name="f_kind[<%=row_cnt-1%>]">
<option value="">¼±ÅÃ</option>
<% query = "select c_common_code, c_code_name from T_COMMON_CODE_DETAIL where c_kind_code = '001' and c_common_code <> '099' "
rsa.Open query, adoConn, 1
if rsa.RecordCount > 0 then
for j = 1 to rsa.RecordCount %>
<option value="<%=rsa("c_common_code")%>" <% if rsa("c_common_code") = kind_code then %> selected <% end if %>> <%=rsa("c_code_name")%></option>
<% rsa.MoveNext
next
end if
rsa.Close
%>
</select>
</td>
<td align="left" >
<input type="file" class="uploadFile_btn " name="ATTACH_FILENAME[<%=row_cnt-1%>]" maxlength="1" style="width:100%;" />
</td>
<td align="center" ></td>
<td align="center" ></td>
</tr>
<%
row_cnt = row_cnt + 1
other_kind_code_falg = false
End if
i = i + 1
other_kind_code_falg = true
Else
%>
<tr>
<td align="center" ><%=row_cnt%></td>
<td align="left" >
<input type="hidden" name="f_id[<%=row_cnt-1%>]" value="<%=f_attach_info(f_attach_index, 0)%>" class="file_id"/>
<% query = "select c_common_code, c_code_name from T_COMMON_CODE_DETAIL where c_kind_code = '001' and c_common_code <> '099' "
rsa.Open query, adoConn, 1
if rsa.RecordCount > 0 then
for j = 1 to rsa.RecordCount
if rsa("c_common_code") = kind_code Then
%>
<input type="hidden" name="f_kind[<%=row_cnt-1%>]" value="<%=rsa("c_common_code")%>"/>
<input type="text" value="<%=rsa("c_code_name")%>" readonly style="border: 0px none0; text-align: center;"/>
<%
end if
rsa.MoveNext
next
end if
rsa.Close
%>
</td>
<td align="left" >
<input type="file" class="uploadFile_btn" name="ATTACH_FILENAME[<%=row_cnt-1%>]" maxlength="1" style="width:200px;" />
<input type="text" class='align-middle' <% If Session("teamplace") <> 10 Then %> onclick="download(<%=f_attach_info(f_attach_index, 0)%>)" <% end if %>
<% If CInt(p_research_complete)+CInt(p_field_complete)+CInt(p_dp_complete) < 3 Then %>style="width:480px; color:blue; cursor:pointer;"<%Else %>style="width:540px; color:blue; cursor:pointer;"<%End If %> value = "<%=f_attach_info(f_attach_index, 2)%>" readonly/>
<% If CInt(p_research_complete)+CInt(p_field_complete)+CInt(p_dp_complete) < 3 Then %>
<button type="button" style="width:50px;" class="btn btn-sm btn-danger" onclick="delete_file('<%=f_attach_info(f_attach_index, 0)%>', '<%=f_attach_info(f_attach_index, 5)%>')">»èÁ¦</button>
<% End If %>
</td>
<td align="center" ><%=f_attach_info(f_attach_index, 3)%></td>
<td align="center" ><%=f_attach_info(f_attach_index, 4)%></td>
</tr>
<%
f_attach_index = f_attach_index + 1
row_cnt = row_cnt + 1
If f_attach_index <= attach_file_count Then
Rs.MoveNext
Else
If kind_code <> "009" Then
default_kind_code_flag = true
else
Exit do
End if
End if
End If
Else
%>
<tr>
<td align="center" ><%=row_cnt%></td>
<td align="center" >
<input type="hidden" name="f_id[<%=row_cnt-1%>]" value="" class="file_id"/>
<select name="f_kind[<%=row_cnt-1%>]" >
<option value="">¼±ÅÃ</option>
<% query = "select c_common_code, c_code_name from T_COMMON_CODE_DETAIL where c_kind_code = '001' and c_common_code <> '099' "
rsa.Open query, adoConn, 1
if rsa.RecordCount > 0 then
for j = 1 to rsa.RecordCount %>
<option value="<%=rsa("c_common_code")%>" <% if rsa("c_common_code") = ("00"&CStr(row_cnt)) then %> selected <% end if %>> <%=rsa("c_code_name")%></option>
<% rsa.MoveNext
next
end if
rsa.Close
%>
</select>
</td>
<td align="left" >
<input type="file" class="uploadFile_btn" name="ATTACH_FILENAME[<%=row_cnt-1%>]" maxlength="1" style="width:565;" />
</td>
<td align="center" ></td>
<td align="center" ></td>
</tr>
<%
row_cnt = row_cnt + 1
i = i + 1
End if
Loop
Rs.Close
%>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td colspan="6" height="1" bgcolor="#cecece"></td>
</tr>
<%
If detailViewShow Then
%>
<tr>
<% If Session("teamplace") <> 10 Then 'ÀÎÅÏ,°è¾àÁ÷,ÇÁ¸®·£¼­ÀÏ °æ¿ì ¾Èº¸À̵µ·Ï %>
<td align="center" colspan="6" style="padding:10 0 0 0; position:relative;">
<%
if CInt(p_progress_status(1)) <> 7 then
'if not (p_depart_name = "field" and session("teamplace") < 3) then
%>
<img src="/images/project/btn_save.jpg" align="absmiddle" style="cursor:pointer" onclick="save(<%=research_count%>, <%=p_sn%>)"> <!-- ÀúÀåÇϱâ onClick="subit(1,<%=p_sn %>)"-->
<%
'end if
end if
%>
<%
'######
If CInt(p_progress_status(1)) >= 6 Then
%>
<img src="/images/common/btn_directcost_input.JPG" align="absmiddle" style="cursor:pointer" onclick="direct_cost_input('<%= Request("p_child_sn") %>', '<%=tmp_year%>', '<%=cost_type%>', '<%=p_depart_name%>')"> <!-- Á÷Á¢ºñ ÀÔ·Â -->
<%
End If
%>
<img src="/images/common/btn_cancel2.jpg" align="absmiddle" style="cursor:pointer" onclick="window.close();"> <!-- Ãë¼ÒÇϱâ -->
<%
If CInt(p_progress_status(1)) = 006 And (session("depart_code") = p_depart_dep or session("depart_code") = p_depart_dep2 or Cstr(p_rsch_a(1, 1)) = Cstr(session("User_Number"))) Then
If document_work_flow then
%>
<!-- ¼öÇà°èȹ¼­ °áÀç »ó½Å -->
<img src="/images/common/btn_approve.jpg" align="absmiddle" style="cursor:pointer" onclick="project_plan_workflow('<%=p_sn%>','<%=p_sub_type%>','<%=p_method_cd(1, 1)%>')"> <!-- °áÀç»ó½Å -->
<%
End if
End if
%>
<%
If session("depart_code") = p_depart_dep or session("depart_code") = p_depart_dep2 or session("depart_code") = 0 or ((session("depart_code") = 17 or session("depart_code") = 19) and session("teamplace") = "3") Then
%>
<img src="/images/project/btn_add_project.jpg" align="absmiddle" style="cursor:pointer; position:absolute; top: 10px; right: 1px;" onclick="project_Add('<%=p_sn%>', '<%=p_sub_type%>', '<%=p_method_cd(1, 1)%>')"> <!-- ÇÁ·ÎÁ§Æ® Ãß°¡ -->
<%
End if
%>
</td>
<% end if %>
</tr>
<%
Else
%>
<tr>
<td align="center" colspan="6" style="padding:10 0 0 0; position:relative;">
<img src="/images/common/btn_cancel2.jpg" align="absmiddle" style="cursor:pointer" onclick="window.close();"> <!-- Ãë¼ÒÇϱâ -->
</td>
</tr>
<%
End If
%>
</table>
</form>
</div>
</div>
</div>
</div>
</div>
<!-- /.content -->
<!-- REQUIRED SCRIPTS -->
<script>
var jPath = "http://<%= split(Request.ServerVariables("HTTP_HOST"), ":")(0) %>:8088/krc_module/";
function viewit(a){
$("table .tab").each(function (index){
var tableObj = $(this);
var tableId = $(this).attr("id");
if(tableId == ("table"+a)){
$(this).css("display", "");
$('#Image'+(index+1)+'on').css("display", "");
$('#Image'+(index+1)+'off').css("display", "none");
}else{
$(this).css("display", "none");
$('#Image'+(index+1)+'on').css("display", "none");
$('#Image'+(index+1)+'off').css("display", "");
}
});
}
function setFormatPrice() {
strNum = document.pms.p_cont_cost.value;
strNum = strNum.replace(/,/g, "");
var result = '';
for (var i = 0; i < strNum.length; i++) {
if (i % 3 == 0 && i != 0) result = ',' + result;
result = strNum.charAt(strNum.length - (i + 1)) + result;
}
document.pms.p_cont_cost.value = result;
}
function winnewoepn() {
var url = "/approval/update_project_money.asp";
url = url + "?p_child_sn=" + document.pms.p_child_sn.value;
url = url + "&print_type=1";
window.open(url, "wins", "left=50, top=50, menubar=no, location=no, status=no, toolbar=no, width=850, height=800, scrollbars=yes ,resizable=no");
}
var interv
var wincati
function winopn_detail(method_cd, p_child_sn, p_no) {
if (method_cd == "2") {
alert("FF Á¶»çÀÇ ¼¼ºÎÇöȲÀº È®ÀÎ ºÒ°¡´ÉÇÕ´Ï´Ù.");
return;
}
var url = jPath + "main/cati?prj_code=" + p_child_sn + "&p_no=" + p_no;
wincati = window.open(url, "KCATI", "left=50, top=50, menubar=no, location=no, status=no, toolbar=no, width=1600, height=700, scrollbars=yes ,resizable=no");
interv = setInterval(loadfunc, 1000);
}
function loadfunc() {
if (wincati.document.readyState == "complete") {
wincati.search();
clearInterval(interv);
}
}
function js_user_rate_view(m_cd) {
var url = "../statistics/team_user_rate_ck.asp?t_prj="+m_cd;
window.open(url, "prj_rate", "left=50, top=50, menubar=no, location=no, status=no, toolbar=no, width=500, height=400, scrollbars=yes ,resizable=no");
}
function other_depart() {
ajaxCallJson("project_list2_dep_ajax_depart.asp", null, null, "post", "rsch_depart_return()");
}
function rsch_depart_return() {
var r_cnt = $("#research_count").val();
var tmp_p_no = "";
var tmp_p_name = "";
var chk_resign = true;
for(var i=0; i<4; i++){
for(var r=0; r<r_cnt; r++){
tmp_p_no = $("#p_rsch_"+(i+1)+"_a"+(r+1)).val();
tmp_p_name = $("#p_rsch_"+(i+1)+"_a"+(r+1) + " option:selected").text();
$("#p_rsch_"+(i+1)+"_a"+(r+1)).html(ajaxResponse);
$("#p_rsch_"+(i+1)+"_a"+(r+1)).find("option").each(function() {
if(tmp_p_no == $(this).val()){
chk_resign = false;
}
});
if(chk_resign == true){
$("#p_rsch_"+(i+1)+"_a"+(r+1)).append("<option value=\"" + tmp_p_no + "\" >" + tmp_p_name + "</option>");
}
$("#p_rsch_"+(i+1)+"_a"+(r+1)).val(tmp_p_no);
chk_resign = true;
tmp_p_no = $("#p_rsch_"+(i+1)+"_b"+(r+1)).val();
tmp_p_name = $("#p_rsch_"+(i+1)+"_b"+(r+1) + " option:selected").text();
$("#p_rsch_"+(i+1)+"_b"+(r+1)).html(ajaxResponse);
$("#p_rsch_"+(i+1)+"_b"+(r+1)).find("option").each(function() {
if(tmp_p_no == $(this).val()){
chk_resign = false;
}
});
if(chk_resign == true){
$("#p_rsch_"+(i+1)+"_b"+(r+1)).append("<option value=\"" + tmp_p_no + "\" >" + tmp_p_name + "</option>");
}
$("#p_rsch_"+(i+1)+"_b"+(r+1)).val(tmp_p_no);
chk_resign = true;
tmp_p_no = $("#p_rsch_"+(i+1)+"_c"+(r+1)).val();
tmp_p_name = $("#p_rsch_"+(i+1)+"_c"+(r+1) + " option:selected").text();
$("#p_rsch_"+(i+1)+"_c"+(r+1)).html(ajaxResponse);
$("#p_rsch_"+(i+1)+"_c"+(r+1)).find("option").each(function() {
if(tmp_p_no == $(this).val()){
chk_resign = false;
}
});
if(chk_resign == true){
$("#p_rsch_"+(i+1)+"_c"+(r+1)).append("<option value=\"" + tmp_p_no + "\" >" + tmp_p_name + "</option>");
}
$("#p_rsch_"+(i+1)+"_c"+(r+1)).val(tmp_p_no);
chk_resign = true;
}
}
alert("¸ðµç ¿¬±¸ºÎ¼­ ¼±Åà °¡´ÉÇϵµ·Ï ¼³Á¤µÇ¾ú½À´Ï´Ù.");
}
$(function () {
cutmenu();
$(".selectDate").datepicker();
var p_progress_status = "<%=p_progress_status(1)%>";
var f = document.pms;
var all_user = false;
if (parseFloat(p_progress_status) > 6) {
$("#p_cont_cost").attr("readonly", "true");
}
if (parseFloat(p_progress_status) < 8){
//$("#cost_mod_button").css("display", "none");
//¼öÇà°èȹ¼­ °áÀç Àü¿¡´Â ¼öÁ¤ ¹öưÀ» ¾Èº¸ÀÌ°Ô ÇÏ·Á°í ÇßÁö¸¸, Àüü ¼öÁÖ ±Ý¾×À» º¯°æÇØ¾ßµÉ ¼ö Àֱ⠶§¹®¿¡
}
if (parseFloat(p_progress_status) < 2){
//$("#cost_mod_button").css("display", "none");
}
if (parseFloat(p_progress_status) == 8) {
}
var p_method_c_prev = "";
$("#p_method_c").on("focus", function(){
p_method_c_prev = this.value;
}).on("change", function(){ // Á¶»ç¹æ¹ý º¯°æ
if(confirm("Á¶»ç¹æ¹ýÀ» º¯°æÇϽðڽÀ´Ï±î?")){
prj_method_change(this.value);
}else{
this.value = p_method_c_prev;
}
});
/*********************************************Disabled***************************************************/
var r_cnt = $("#research_count").val();
$("#p_client_type_cd").prop("disabled", true);
$("#p_con_date_st").prop("disabled", true);
$("#p_con_date_end").prop("disabled", true);
$("#p_decide_date").prop("disabled", true);
$("#p_decide_date_img").prop("disabled", true);
$("#p_cont_cost").prop("disabled", true);
$("#p_export_range").prop("disabled", true);
$("input[name='p_category']").prop("disabled", true);
for (var r = 1; r <= r_cnt * 1; r++) {
$("#p_intention" + r + "").prop("disabled", true);
$("#p_sur_area" + r + "").prop("disabled", true);
$("#p_sur_target" + r + "").prop("disabled", true);
$("#p_sample" + r + "").prop("disabled", true);
$("#p_research_date_st" + r + "").prop("disabled", true);
$("#p_research_date_end" + r + "").prop("disabled", true);
$("#p_sur_part" + r + "").prop("disabled", true);
$("#p_field_process" + r + "").prop("disabled", true);
$("#p_inspection_rate" + r + "").prop("disabled", true);
$("#p_rsch_1_a" + r + "").prop("disabled", true);
$("#p_rsch_2_a" + r + "").prop("disabled", true);
$("#p_rsch_3_a" + r + "").prop("disabled", true);
$("#p_rsch_4_a" + r + "").prop("disabled", true);
$("#p_rsch_1_b" + r + "").prop("disabled", true);
$("#p_rsch_2_b" + r + "").prop("disabled", true);
$("#p_rsch_3_b" + r + "").prop("disabled", true);
$("#p_rsch_4_b" + r + "").prop("disabled", true);
$("#p_rsch_1_c" + r + "").prop("disabled", true);
$("#p_rsch_2_c" + r + "").prop("disabled", true);
$("#p_rsch_3_c" + r + "").prop("disabled", true);
$("#p_rsch_4_c" + r + "").prop("disabled", true);
$("#p_sv_1" + r + "").prop("disabled", true);
$("#p_sv_2" + r + "").prop("disabled", true);
$("#p_sv_3" + r + "").prop("disabled", true);
$("#p_sv_4" + r + "").prop("disabled", true);
$("#p_verify_1" + r + "").prop("disabled", true);
$("#p_verify_2" + r + "").prop("disabled", true);
$("#p_verify_3" + r + "").prop("disabled", true);
$("#p_verify_4" + r + "").prop("disabled", true);
$("#p_punch_1" + r + "").prop("disabled", true);
$("#p_punch_2" + r + "").prop("disabled", true);
$("#p_punch_3" + r + "").prop("disabled", true);
$("#p_punch_4" + r + "").prop("disabled", true);
$("#p_code_1" + r + "").prop("disabled", true);
$("#p_code_2" + r + "").prop("disabled", true);
$("#p_code_3" + r + "").prop("disabled", true);
$("#p_code_4" + r + "").prop("disabled", true);
$("#p_dp_1" + r + "").prop("disabled", true);
$("#p_dp_2" + r + "").prop("disabled", true);
$("#p_dp_3" + r + "").prop("disabled", true);
$("#p_dp_4" + r + "").prop("disabled", true);
$("#p_it_1" + r + "").prop("disabled", true);
$("#p_it_2" + r + "").prop("disabled", true);
$("#p_it_3" + r + "").prop("disabled", true);
$("#p_it_4" + r + "").prop("disabled", true);
$("#p_rsch_date_st" + r + "").prop("disabled", true);
$("#p_rsch_date_end" + r + "").prop("disabled", true);
$("#p_rsch_date_time_st" + r + "").prop("disabled", true);
$("#p_rsch_date_time_end" + r + "").prop("disabled", true);
$("#p_field_date_st" + r + "").prop("disabled", true);
$("#p_field_date_end" + r + "").prop("disabled", true);
$("#p_field_date_time_st" + r + "").prop("disabled", true);
$("#p_field_date_time_end" + r + "").prop("disabled", true);
$("#p_verify_date_st" + r + "").prop("disabled", true);
$("#p_verify_date_end" + r + "").prop("disabled", true);
$("#p_verify_date_time_st" + r + "").prop("disabled", true);
$("#p_verify_date_time_end" + r + "").prop("disabled", true);
$("#p_punch_date_st" + r + "").prop("disabled", true);
$("#p_punch_date_end" + r + "").prop("disabled", true);
$("#p_punch_date_time_st" + r + "").prop("disabled", true);
$("#p_punch_date_time_end" + r + "").prop("disabled", true);
$("#p_code_date_st" + r + "").prop("disabled", true);
$("#p_code_date_end" + r + "").prop("disabled", true);
$("#p_code_date_time_st" + r + "").prop("disabled", true);
$("#p_code_date_time_end" + r + "").prop("disabled", true);
$("#p_dp_date_st" + r + "").prop("disabled", true);
$("#p_dp_date_end" + r + "").prop("disabled", true);
$("#p_dp_date_time_st" + r + "").prop("disabled", true);
$("#p_dp_date_time_end" + r + "").prop("disabled", true);
$("#p_it_date_st" + r + "").prop("disabled", true);
$("#p_it_date_end" + r + "").prop("disabled", true);
$("#p_it_date_time_st" + r + "").prop("disabled", true);
$("#p_it_date_time_end" + r + "").prop("disabled", true);
$("#p_premeet_date" + r + "").prop("disabled", true);
$("#p_premeet_time" + r + "").prop("disabled", true);
$("#p_premeet_place" + r + "").prop("disabled", true);
$("#p_premeet_date" + r + "_img").prop("disabled", true);
$("#p_ot_date" + r + "").prop("disabled", true);
$("#p_ot_time" + r + "").prop("disabled", true);
$("#p_ot_place" + r + "").prop("disabled", true);
$("#p_ot_date" + r + "_img").prop("disabled", true);
}
/*********************************************Disabled***************************************************/
if('<%= session("depart_code") %>' == '17' || '<%= session("depart_code") %>' == '18' || '<%= session("depart_code") %>' == '19' || '<%= session("depart_code") %>' == '12' || '<%= session("depart_code") %>' == '0'){ // ¸ðµÎ disabled ÇØÁ¦..
all_user = true;
}
/*********************************************Enabled****************************************************/
var depart_n = document.pms.depart_no.value;
if ((20 <= depart_n * 1 && 99 > depart_n * 1) || depart_n == 0 || all_user == true) { // ¿¬±¸
$("#p_client_type_cd").prop("disabled", false);
$("#p_con_date_st").prop("disabled", false);
$("#p_con_date_end").prop("disabled", false);
$("#p_decide_date").prop("disabled", false);
$("#p_decide_date_img").prop("disabled", false);
$("#p_cont_cost").prop("disabled", false);
$("#p_export_range").prop("disabled", false);
$("input[name='p_category']").prop("disabled", false);
for (var r = 1; r <= r_cnt * 1; r++) {
$("#p_intention" + r + "").prop("disabled", false);
$("#p_sur_area" + r + "").prop("disabled", false);
$("#p_sur_target" + r + "").prop("disabled", false);
$("#p_sample" + r + "").prop("disabled", false);
$("#p_research_date_st" + r + "").prop("disabled", false);
$("#p_research_date_end" + r + "").prop("disabled", false);
$("#p_sur_part" + r + "").prop("disabled", false);
$("#p_field_process" + r + "").prop("disabled", false);
$("#p_inspection_rate" + r + "").prop("disabled", false);
<%
If p_rsch_a_per <> "0" OR p_rsch_a_yn <> "0" Then
%>
$("#p_rsch_1_a" + r + "").prop("disabled", false);
$("#p_rsch_2_a" + r + "").prop("disabled", false);
$("#p_rsch_3_a" + r + "").prop("disabled", false);
$("#p_rsch_4_a" + r + "").prop("disabled", false);
<%
End If
If p_rsch_b_per <> "0" OR p_rsch_b_yn <> "0" Then
%>
$("#p_rsch_1_b" + r + "").prop("disabled", false);
$("#p_rsch_2_b" + r + "").prop("disabled", false);
$("#p_rsch_3_b" + r + "").prop("disabled", false);
$("#p_rsch_4_b" + r + "").prop("disabled", false);
<%
End If
If p_rsch_c_per <> "0" OR p_rsch_c_yn <> "0" Then
%>
$("#p_rsch_1_c" + r + "").prop("disabled", false);
$("#p_rsch_2_c" + r + "").prop("disabled", false);
$("#p_rsch_3_c" + r + "").prop("disabled", false);
$("#p_rsch_4_c" + r + "").prop("disabled", false);
<%
End If
%>
$("#p_rsch_date_st" + r + "").prop("disabled", false);
$("#p_rsch_date_end" + r + "").prop("disabled", false);
$("#p_rsch_date_time_st" + r + "").prop("disabled", false);
$("#p_rsch_date_time_end" + r + "").prop("disabled", false);
$("#p_field_date_st" + r + "").prop("disabled", false);
$("#p_field_date_end" + r + "").prop("disabled", false);
$("#p_field_date_time_st" + r + "").prop("disabled", false);
$("#p_field_date_time_end" + r + "").prop("disabled", false);
$("#p_premeet_date" + r + "").prop("disabled", false);
$("#p_premeet_time" + r + "").prop("disabled", false);
$("#p_premeet_place" + r + "").prop("disabled", false);
$("#p_premeet_date" + r + "_img").prop("disabled", false);
$("#p_it_1" + r + "").prop("disabled", false);
$("#p_it_2" + r + "").prop("disabled", false);
$("#p_it_3" + r + "").prop("disabled", false);
$("#p_it_4" + r + "").prop("disabled", false);
$("#p_it_date_st" + r + "").prop("disabled", false);
$("#p_it_date_end" + r + "").prop("disabled", false);
$("#p_it_date_time_st" + r + "").prop("disabled", false);
$("#p_it_date_time_end" + r + "").prop("disabled", false);
}
}
if ((depart_n * 1 == 12) || all_user == true) { // ½Ç»ç
//if (all_user == true) { // ½Ç»ç - °ü¸®ÀÚ¸¸ °¡´ÉÇϵµ·Ï
for (var r = 1; r <= r_cnt * 1; r++) {
if ($("#p_rsch_dept" + r + "").val() == "900") {
$("#p_intention" + r + "").prop("disabled", false);
$("#p_sur_area" + r + "").prop("disabled", false);
$("#p_sur_target" + r + "").prop("disabled", false);
$("#p_sample" + r + "").prop("disabled", false);
$("#p_research_date_st" + r + "").prop("disabled", false);
$("#p_research_date_end" + r + "").prop("disabled", false);
$("#p_sur_part" + r + "").prop("disabled", false);
$("#p_field_process" + r + "").prop("disabled", false);
}
$("#p_inspection_rate" + r + "").prop("disabled", false);
$("#p_sv_1" + r + "").prop("disabled", false);
$("#p_sv_2" + r + "").prop("disabled", false);
$("#p_sv_3" + r + "").prop("disabled", false);
$("#p_sv_4" + r + "").prop("disabled", false);
$("#p_verify_1" + r + "").prop("disabled", false);
$("#p_verify_2" + r + "").prop("disabled", false);
$("#p_verify_3" + r + "").prop("disabled", false);
$("#p_verify_4" + r + "").prop("disabled", false);
$("#p_punch_1" + r + "").prop("disabled", false);
$("#p_punch_2" + r + "").prop("disabled", false);
$("#p_punch_3" + r + "").prop("disabled", false);
$("#p_punch_4" + r + "").prop("disabled", false);
$("#p_code_1" + r + "").prop("disabled", false);
$("#p_code_2" + r + "").prop("disabled", false);
$("#p_code_3" + r + "").prop("disabled", false);
$("#p_code_4" + r + "").prop("disabled", false);
$("#p_field_date_st" + r + "").prop("disabled", false);
$("#p_field_date_end" + r + "").prop("disabled", false);
$("#p_field_date_time_st" + r + "").prop("disabled", false);
$("#p_field_date_time_end" + r + "").prop("disabled", false);
$("#p_verify_date_st" + r + "").prop("disabled", false);
$("#p_verify_date_end" + r + "").prop("disabled", false);
$("#p_verify_date_time_st" + r + "").prop("disabled", false);
$("#p_verify_date_time_end" + r + "").prop("disabled", false);
$("#p_punch_date_st" + r + "").prop("disabled", false);
$("#p_punch_date_end" + r + "").prop("disabled", false);
$("#p_punch_date_time_st" + r + "").prop("disabled", false);
$("#p_punch_date_time_end" + r + "").prop("disabled", false);
$("#p_code_date_st" + r + "").prop("disabled", false);
$("#p_code_date_end" + r + "").prop("disabled", false);
$("#p_code_date_time_st" + r + "").prop("disabled", false);
$("#p_code_date_time_end" + r + "").prop("disabled", false);
$("#p_ot_date" + r + "").prop("disabled", false);
$("#p_ot_time" + r + "").prop("disabled", false);
$("#p_ot_place" + r + "").prop("disabled", false);
$("#p_ot_date" + r + "_img").prop("disabled", false);
}
}
if ((depart_n * 1 == 17) || all_user == true) { // DP
for (var r = 1; r <= r_cnt * 1; r++) {
$("#p_dp_1" + r + "").prop("disabled", false);
$("#p_dp_2" + r + "").prop("disabled", false);
$("#p_dp_3" + r + "").prop("disabled", false);
$("#p_dp_4" + r + "").prop("disabled", false);
$("#p_dp_date_st" + r + "").prop("disabled", false);
$("#p_dp_date_end" + r + "").prop("disabled", false);
$("#p_dp_date_time_st" + r + "").prop("disabled", false);
$("#p_dp_date_time_end" + r + "").prop("disabled", false);
}
}
if ((depart_n * 1 == 18) || all_user == true) { // IT, °æ¿µ
for (var r = 1; r <= r_cnt * 1; r++) {
$("#p_it_1" + r + "").prop("disabled", false);
$("#p_it_2" + r + "").prop("disabled", false);
$("#p_it_3" + r + "").prop("disabled", false);
$("#p_it_4" + r + "").prop("disabled", false);
$("#p_it_date_st" + r + "").prop("disabled", false);
$("#p_it_date_end" + r + "").prop("disabled", false);
$("#p_it_date_time_st" + r + "").prop("disabled", false);
$("#p_it_date_time_end" + r + "").prop("disabled", false);
}
}
/*********************************************Enabled****************************************************/
});
function download(f_id) {//ÆÄÀÏ ´Ù¿î·Îµå
url = jPath + "download";
var p_sn = document.pms.p_sn.value;
var param = "?p_sn=" + p_sn + "&f_id=" + f_id;
//ÆÄÀÏ ´Ù¿î·Îµå ·Î±×
ajaxCallJson("/include/download_log.asp", { "f_id" : f_id }, null, "POST");
$(location).attr("href", url + param);
}
function save(r_cnt, p_sn){
var validFlag = true;
var tmpFlag1 = true;
var tmpFlag2 = true;
var tmpFlag3 = true;
var f = document.pms;
var involve_dept_cnt = 0;
var all_project_total_cost = document.pms.all_project_total_cost.value.replace(/,/gi, "");
var all_project_cont_cost = document.pms.all_project_cont_cost.value.replace(/,/gi, "");
var cont_cost = document.pms.p_cont_cost.value.replace(/,/gi, "");
var p_depart_name = document.pms.p_depart_name.value;
if (all_project_total_cost * 1 < all_project_cont_cost * 1 + cont_cost * 1) {
alert("´ÜÀ§ °è¾à¾×ÀÇ ÇÕÀÌ Àüü¼öÁֱݾ×À» ÃʰúÇÏ¿´½À´Ï´Ù.\nÀüü¼öÁֱݾ×À» º¯°æÇÏ·Á¸é ITÆÀ¿¡ ¹®ÀÇÇϼ¼¿ä.");
return;
}
if(f.p_subject.value == ""){
alert("ÇÁ·ÎÁ§Æ®¸íÀ» ÀÔ·ÂÇϽʽÿÀ.");
f.p_subject.focus();
return;
}
if(f.p_con_date_st.value == "" || f.p_con_date_end.value == "" ){
alert("°è¾à±â°£(½ÃÀÛ, Á¾·á)À» ÀÔ·ÂÇϽʽÿÀ.");
f.p_con_date_st.focus();
return;
}
var fileIndex = $(this).attr("name").replace("ATTACH_FILENAME[", "");
fileIndex = fileIndex.replace("]", "");
var temp_p_con_date_st = f.p_con_date_st.value.replace(/-/gi, "");
var temp_p_con_date_end = f.p_con_date_end.value.replace(/-/gi, "");
if(temp_p_con_date_st > temp_p_con_date_end ){
alert("°è¾à±â°£ÀÇ Á¾·áÀÏÀÚ°¡ ½ÃÀÛÀÏÀÚº¸´Ù ÀÛ½À´Ï´Ù.");
f.p_con_date_end.focus();
return;
}
if(f.p_cont_cost.value == "0"){
alert("°è¾à±Ý¾×À» ÀÔ·ÂÇϽʽÿÀ.");
f.p_cont_cost.focus();
return;
}
if(f.p_export_range.value == ""){
alert("ÇÁ·ÎÁ§Æ® ¿ë¿ª¹üÀ§¸¦ ¼±ÅÃÇϼ¼¿ä.");
f.p_export_range.focus();
return;
}
if($("input[name=p_category]:checked").length == 0){
alert("ÇÁ·ÎÁ§Æ® Á¶»ç³»¿ëÀ» ¼±ÅÃÇϼ¼¿ä.");
return;
}
for (var i = 1; i<r_cnt+1; i++)
{
involve_dept_cnt = 0;
if(f["p_rsch_dept"+i].value == ""){
validFlag = false;
alert(i+"¹øÂ° Tab Âü¿©ºÎ¼­- ¿¬±¸ºÎ¼­¸¦ ¼±ÅÃÇϽʽÿÀ.");
f["p_rsch_dept"+i].focus();
break;
}else if (f["p_rsch_dept"+i].value == "900"){
involve_dept_cnt = involve_dept_cnt + 1;
}
if(f["p_field_dept"+i].value == ""){
validFlag = false;
alert(i+"¹øÂ° Tab Âü¿©ºÎ¼­- ½Ç»çºÎ¼­¸¦ ¼±ÅÃÇϽʽÿÀ.");
f["p_field_dept"+i].focus();
break;
}else if (f["p_field_dept"+i].value == "900"){
involve_dept_cnt = involve_dept_cnt + 1;
}
if(f["p_is_dept"+i].value == ""){
validFlag = false;
alert(i+"¹øÂ° Tab Âü¿©ºÎ¼­- Àü»êºÎ¼­¸¦ ¼±ÅÃÇϽʽÿÀ.");
f["p_is_dept"+i].focus();
break;
}else if (f["p_is_dept"+i].value == "900"){
involve_dept_cnt = involve_dept_cnt + 1;
}
if(f["p_it_dept"+i].value == ""){
validFlag = false;
alert(i+"¹øÂ° Tab Âü¿©ºÎ¼­- °³¹ßºÎ¼­¸¦ ¼±ÅÃÇϽʽÿÀ.");
f["p_it_dept"+i].focus();
break;
}else if (f["p_it_dept"+i].value == "900"){
involve_dept_cnt = involve_dept_cnt + 1;
}
if(involve_dept_cnt == 4){
validFlag = false;
alert(i+"¹øÂ° Tab Âü¿©ºÎ¼­°¡ ¾ø½À´Ï´Ù. ¼öÁ¤ÇϽʽÿÀ.");
break;
}
if (p_depart_name == "research") {
if(f["p_intention"+i].value == ""){
validFlag = false;
alert($("#p_method_nm"+i).text()+"ÀÇ »ó¼¼³»¿ëÀ» ÀÔ·ÂÇϼ¼¿ä.");
f["p_intention"+i].focus();
return false;
break;
}
if(f["p_sample"+i].value == "0" || f["p_sample"+i].value == ""){
validFlag = false;
alert($("#p_method_nm"+i).text()+"ÀÇ »ùÇüö¸¦ ÀÔ·ÂÇϼ¼¿ä.");
f["p_sample"+i].focus();
return false;
break;
}
}
}
if(validFlag){
if(f["p_progress_status"+"1"].value == "001"){
f["p_progress_status" + "1"].value = "006";
} else if (p_depart_name == "research") {
tmpFlag1 = false;
tmpFlag2 = false;
tmpFlag3 = false;
for (var i = 1; i < 5; i++) {
if (f["p_rsch_" + i + "_a1"].value != "" || f["p_rsch_" + i + "_a1"].disabled) {
tmpFlag1 = true;
}
if (f["p_rsch_" + i + "_b1"].value != "" || f["p_rsch_" + i + "_b1"].disabled) {
tmpFlag2 = true;
}
if (f["p_rsch_" + i + "_c1"].value != "" || f["p_rsch_" + i + "_c1"].disabled) {
tmpFlag3 = true;
}
}
if (!tmpFlag1) {
alert("±âȹ(¼³¹®Áö) ºÎºÐÀÇ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (!tmpFlag2) {
alert("½Ç»ç(ºÐ¼®) ºÎºÐÀÇ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (!tmpFlag3) {
alert("º¸°í(Á¦Ãâ) ºÎºÐÀÇ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (f["p_rsch_date_st1"].value == "" || f["p_rsch_date_end1"].value == "") {
alert("¿¬±¸ºÎ¼­ ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (f["p_progress_flag1"].value.substring(0, 1) != "o") {
if (confirm("¿¬±¸ºÎ¼­ Á¤º¸ ÀÔ·ÂÀÌ ³¡³ª¼Ì½À´Ï±î?\nÃë¼Ò¸¦ ´©¸£¸é º¯°æ Á¤º¸¸¸ ÀúÀå µË´Ï´Ù.")) {
f["p_progress_flag1"].value = "o" + f["p_progress_flag1"].value.substring(1, 3);
} else {
f["p_progress_flag1"].value = "x" + f["p_progress_flag1"].value.substring(1, 3);
}
}
} else if (p_depart_name == "field") {
tmpFlag1 = false;
tmpFlag2 = false;
tmpFlag3 = false;
tmpFlag4 = false;
if (f["p_field_dept1"].value != "900") {
if (f["p_field_dept1"].value != "8") {
for (var i = 1; i < 5; i++) {
if (f["p_sv_" + i + "1"].value != "") {
tmpFlag1 = true;
}
}
if (!tmpFlag1) {
alert("½Ç»ç Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
} else {
if (f["p_field_date_st1"].value == "" || f["p_field_date_end1"].value == "") {
alert("½Ç»ç ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
}
}
if (f["p_field_dept1"].value != "9") {
for (var i = 1; i < 5; i++) {
if (f["p_verify_" + i + "1"].value != "") {
tmpFlag2 = true;
}
if (f["p_punch_" + i + "1"].value != "") {
tmpFlag3 = true;
}
if (f["p_code_" + i + "1"].value != "") {
tmpFlag4 = true;
}
}
if (!tmpFlag2 && !tmpFlag3 && !tmpFlag4) {
//alert("°ËÁõ ¶Ç´Â ÄÚµù/ÆÝÄ¡ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
//alert("ÆÝÄ¡ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
alert("°ËÁõ/ÄÚµù/ÆÝÄ¡ Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
} else {
if (!tmpFlag2) {
} else {
if (f["p_verify_date_st1"].value == "" || f["p_verify_date_end1"].value == "") {
alert("°ËÁõ ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
}
if (!tmpFlag3) {
} else {
/*
if (f["p_code_date_st1"].value == "" || f["p_code_date_end1"].value == "") {
alert("ÄÚµù/ÆÝÄ¡ ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
*/
if (f["p_punch_date_st1"].value == "" || f["p_punch_date_end1"].value == "") {
alert("ÆÝÄ¡ ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
}
if (!tmpFlag4) {
} else {
if (f["p_code_date_st1"].value == "" || f["p_code_date_end1"].value == "") {
alert("ÄÚµù ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
}
}
}
}
for (var i = 1; i < r_cnt + 1; i++) {
if (f["p_inspection_rate" + i].value == "" && f["p_field_dept1"].value != "9") {
alert("Á¶»ç µðÀÚÀÎ - °ËÁõ·ü ÀÇ °ªÀ» ÀÔ·ÂÇØÁÖ¼¼¿ä.");
return false;
}
}
if (f["p_progress_flag1"].value.substring(1, 2) != "o") {
if (confirm("½Ç»çºÎ¼­ Á¤º¸ ÀÔ·ÂÀÌ ³¡³ª¼Ì½À´Ï±î?\nÃë¼Ò¸¦ ´©¸£¸é º¯°æ Á¤º¸¸¸ ÀúÀå µË´Ï´Ù.")) {
f["p_progress_flag1"].value = f["p_progress_flag1"].value.substring(0, 1) + "o" + f["p_progress_flag1"].value.substring(2, 3);
} else {
f["p_progress_flag1"].value = f["p_progress_flag1"].value.substring(0, 1) + "x" + f["p_progress_flag1"].value.substring(2, 3);
}
}
} else if (p_depart_name == "dp" && $("select[name=p_is_dept1]").val()!="900") {
tmpFlag1 = false;
for (var i = 1; i < 5; i++) {
if (f["p_dp_" + i + "1"].value != "") {
tmpFlag1 = true;
}
}
if (!tmpFlag1) {
alert("ºÐ¼® Âü¿©ÀοøÀ» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (f["p_dp_date_st1"].value == "" || f["p_dp_date_end1"].value == "") {
alert("ºÐ¼® ¼¼ºÎÀÏÁ¤À» ¼³Á¤ÇØÁÖ¼¼¿ä.");
return false;
}
if (f["p_progress_flag1"].value.substring(2, 3) != "o") {
if (confirm("°³¹ßºÎ¼­ Á¤º¸ ÀÔ·ÂÀÌ ³¡³ª¼Ì½À´Ï±î?\nÃë¼Ò¸¦ ´©¸£¸é º¯°æ Á¤º¸¸¸ ÀúÀå µË´Ï´Ù.")) {
f["p_progress_flag1"].value = f["p_progress_flag1"].value.substring(0, 2) + "o";
} else {
f["p_progress_flag1"].value = f["p_progress_flag1"].value.substring(0, 2) + "x";
}
}
}
var fileCount = 0;
var fileAttachCcount = 0;
var upload_Flag = true;
var depart_no = document.pms.depart_no.value;
$("input:file").each(function (index) {
var uploadpath = $(this).val();
fileCount++;
if (uploadpath.length > 0) {
fileAttachCcount++;
var fileExtension = uploadpath.substring(uploadpath.lastIndexOf(".") + 1, uploadpath.length);
if (depart_no != "17" && depart_no != "18" && depart_no != "19" && depart_no != "12" ) {
if (fileExtension.toLowerCase() == "zip" || fileExtension.toLowerCase() == "rar" || fileExtension.toLowerCase() == "arj" || fileExtension.toLowerCase() == "egg") {
alert("¾ÐÃà ÆÄÀÏÀº ¾÷·Îµå ÇÒ ¼ö ¾ø½À´Ï´Ù.");
upload_Flag = false;
return false;
}
}
if ($("select[name*='f_kind[" + index + "]']").val() == "") {
alert((index + 1) + "¹ø ÷ºÎ ÆÄÀÏÀÇ Ä«Å×°í¸®¸¦ ¼±ÅÃÇϽʽÿÀ.");
upload_Flag = false;
return false;
}
}
});
document.pms.fileCount.value = fileCount;
if(upload_Flag){
fileInfo_save(p_sn, fileAttachCcount);
}
}
}
function fileInfo_save(p_sn, f_count) {//ÆÄÀÏ ¾÷·Îµå
var rowCount = 0;
var saveValidFlag = false;
if (f_count > 0) {
saveValidFlag = true;
}
if (saveValidFlag) {
var tempSampleCount = 0;
document.pms.action = jPath + "system/uploadFiles";
document.pms.enctype = "multipart/form-data";
document.pms.encoding = "multipart/form-data";
document.pms.method = "POST";
document.charset = "UTF-8";
$("#pms").ajaxForm({
success: function(response, textStatus, jqXHR) {
if (response == "{'success':true}") {
formDataSave();
} else {
saveFail();
}
},
error: function() {
saveFail();
},
dataType: "text"
}).submit();
}else{
formDataSave();
}
}
function showRequest(formData, jqForm, options) {
var queryString = $.param(formData);
return true;
}
function saveFail() {
alert("÷ºÎÆÄÀÏ ÀúÀå Áß ¿À·ù°¡ ¹ß»ý ÇÏ¿´½À´Ï´Ù.\n°ü¸®ÀÚ¿¡°Ô ¹®ÀÇ ¹Ù¶ø´Ï´Ù.");
}
function formDataSave() {
document.pms.enctype = "application/x-www-form-urlencoded";
document.pms.encoding = "application/x-www-form-urlencoded";
document.charset = "EUC-KR";
document.pms.action = 'project_list2_dep_ok_2014.asp';
document.pms.submit();
}
function delete_file(f_id, login_user) {
if (f_id == null) {
alert("»èÁ¦ÇÒ ÆÄÀÏÀÌ ¾ø½À´Ï´Ù");
return false;
}
<%If Session("Depart_Code") <> "18" Then%>
if (login_user != document.pms.user_no.value) {
alert("÷ºÎÆÄÀÏÀº ´ã´çÀÚ¸¸ Áö¿ï ¼ö ÀÖ½À´Ï´Ù.");
return false;
}
<%End If%>
if (confirm("Á¤¸» »èÁ¦ÇϽðڽÀ´Ï±î?") == true) {//ÆÄÀÏ »èÁ¦
var url = jPath + "system/deleteFiles";
var p_sn = document.pms.p_sn.value;
document.pms.action = url;
document.pms.enctype = "multipart/form-data";
document.pms.encoding = "multipart/form-data";
document.pms.method = "POST";
document.charset = "UTF-8";
$("#pms").ajaxForm({
data: { "del_f_id": f_id },
success: function(data) {
deleteComplete(data);
},
error: function() {
alert("»èÁ¦ Áß ¿À·ù ¹ß»ý!\n °ü¸®ÀÚ¿¡°Ô ¹®Àǹٶø´Ï´Ù. ");
},
complete: function() {
},
dataType: "text"
}).submit();
} else { //Ãë¼Ò
return;
}
}
function deleteComplete(data) {
if (data == "{'success':true}") {
alert("ÇØ´ç ÆÄÀÏÀÌ »èÁ¦ µÇ¾ú½À´Ï´Ù.");
p_sn = document.pms.p_sn.value;
p_sub_type = document.pms.p_sub_type.value;
if (p_sub_type == "C") {
p_method_cd = document.pms.p_method_cd.value;
p_child_sn = document.pms.p_child_sn.value;
url = "project_list2_dep_2014.asp?p_sn=" + p_sn + "&p_sub_type=" + p_sub_type + "&p_method_cd=" + p_method_cd + "&p_child_sn=" + p_child_sn;
} else if (p_sub_type == "M") {
url = "project_list2_dep_2014.asp?p_sn=" + p_sn + "&p_sub_type=" + p_sub_type;
}
location.href = url;
} else {
alert("»èÁ¦°¡ µÇÁö ¾Ê¾Ò½À´Ï´Ù. \n °ü¸®ÀÚ¿¡°Ô ¹®Àǹٶø´Ï´Ù. ");
}
}
function fileadd(){
var attach_count = 1;
$(".file_id").each(function (index){
attach_count++;
});
var temp_html = '<tr>'+
'<td align="center" >'+attach_count+'</td>'+
'<td align="center" >'+
'<select name="f_kind['+(attach_count-1)+']">'+
'<option value="">¼±ÅÃ</option>'+
'<option value="001">RFP</option>'+
'<option value="002">Á¦¾È¼­</option>'+
'<option value="003">°ßÀû¼­</option>'+
'<option value="004">º¸°í¼­</option>'+
'<option value="005">¼³¹®Áö</option>'+
'<option value="006">°¡À̵å</option>'+
'<option value="007">±âŸÀÚ·á</option>'+
'<option value="008">½Ç»ç(Field)</option>'+
'<option value="009">˟Ȑ(DP)</option>'+
'</select>'+
'</td>'+
'<td align="left" >'+
'<input type="hidden" name="f_id['+(attach_count-1)+']" value="" class="file_id"/>'+
'<input type="file" class="uploadFile_btn appendFile" name="ATTACH_FILENAME['+(attach_count-1)+']" maxlength="1" style="width:565;" />'+
'</td>'+
'<td align="center" ></td>'+
'<td align="center" ></td>'+
'</tr>';
$("#attach_table").append(temp_html);
}
function project_plan_workflow(p_sn, p_sub_type, p_method_cd){
var validFlag = true;
var f = document.pms;
var involve_dept_cnt = 0;
if(f.p_con_date_st.value == ""){
alert("°è¾à±â°£À» ÀÔ·ÂÇϽʽÿÀ.");
f.p_con_date_st.focus();
return;
}
if(f.p_con_date_end.value == ""){
alert("°è¾à±â°£À» ÀÔ·ÂÇϽʽÿÀ.");
f.p_con_date_end.focus();
return;
}
if(f.p_decide_date.value == ""){
alert("°è¾àÀÏÀÚ¸¦ ÀÔ·ÂÇϽʽÿÀ.");
f.p_decide_date.focus();
return;
}
if(confirm("¿¬±¸, ½Ç»ç Á÷Á¢ºñ ¿¹»ê ÀÔ·ÂÀÌ ³¡³ª¼Ì½À´Ï±î?\n\nÇÁ·ÎÁ§Æ® ¼öÇà°èȹ¼­¸¦ °áÀç »ó½Å ÇϽðڽÀ´Ï±î?")){
var f = document.pms;
if(p_sub_type == "M"){
f.action = 'project_report_2014.asp?p_sn='+p_sn+'&p_sub_type='+p_sub_type;
}else{
f.action = 'project_report_2014.asp?p_sn='+p_sn+'&p_sub_type='+p_sub_type+'&p_method_cd='+p_method_cd;
}
f.submit();
}
}
function direct_cost_input(p_sn, tmp_year, cost_type, p_depart_name){
var f = document.pms;
var url = "";
p_sub_type = document.pms.p_sub_type.value;
if (p_sub_type == "M") {
p_sn = document.pms.p_sn.value;
}
//if (p_depart_name == "admin" || p_depart_name == "dp") {
if (p_depart_name == "admin") {
if(confirm("¿¬±¸ Á÷Á¢ºñ [È®ÀÎ] / ½Ç»ç Á÷Á¢ºñ [Ãë¼Ò]")){
url = '/' + 'inspection/project_direct_cost_2014.asp?p_sn=' + p_sn + '&tmp_year=' + tmp_year + '&cost_type=research&p_sub_type=' + p_sub_type + '&tmp_month=0&p_depart=0&sc_name=&sc_method=100';
}else{
url = '/' + 'inspection/project_direct_cost_2014.asp?p_sn=' + p_sn + '&tmp_year=' + tmp_year + '&cost_type=field&p_sub_type=' + p_sub_type + '&tmp_month=0&p_depart=0&sc_name=&sc_method=100';
}
}else{
url = '/' + 'inspection/project_direct_cost_2014.asp?p_sn=' + p_sn + '&tmp_year=' + tmp_year + '&cost_type=' + cost_type + '&p_sub_type=' + p_sub_type + '&tmp_month=0&p_depart=0&sc_name=&sc_method=100';
}
if(window.opener && !window.opener.closed){
window.opener.document.location.href = url;
}else{
alert("ÀÎÆ®¶ó³Ý ÆäÀÌÁö âÀÌ ´ÝÇô ÀÖ´Â °Í °°½À´Ï´Ù. È®ÀÎ ÇÏ¿© ÁֽʽÿÀ.");
}
}
function direct_cost_detail(p_child_sn, tmp_year, cost_type, p_sub_type){
//##### 2018-02-28 ±èÁ¾ÈÖ
if (cost_type != "all") {
if (cost_type=="research"){
cost_type = "research";
}else if(cost_type=="field"){
cost_type = "field";
}else if(cost_type=="dp"){
cost_type = "dp";
}
}
var url = "/" + "ess/direct_cost_print_2014.asp?p_sn=" + p_child_sn + "@" + p_sub_type;
if (p_sub_type == "M")
{
url = url +"&tmp_year="+tmp_year+"&tmp_month=0&p_depart=0&sc_name=&sc_method=100&view_chk=2&cost_type="+cost_type;
}else{
var p_child_sn = document.pms.p_child_sn.value;
url = url +"&tmp_year="+tmp_year+"&tmp_month=0&p_depart=0&sc_name=&sc_method=100&view_chk=2&cost_type="+cost_type+"&p_child_sn="+p_child_sn;
}
window.open(url, "", 'left=0,top=0,width=1220,height=600,scrollbars=yes,resizable=yes');
}
function project_Add(p_sn, p_sub_type, p_method_cd) {
var url = 'project_list2_add_2014.asp?p_sn=' + p_sn;
var tmp_width = 1210;
var tmp_height = 450;
if (p_sub_type == "M")
{
url = url + "&p_sub_type=" + p_sub_type;
}else{
url = url + "&p_sub_type=" + p_sub_type+"&p_method_cd="+p_method_cd;
}
window.open(url,'','left=0,top=0,width='+tmp_width+',height='+tmp_height+',scrollbars=yes,resizable=yes')
}
function prj_release(dep){
ajaxCallJson("project_list2_dep_ajax_depart.asp", {dep : dep, p_child_sn : "<%=request("p_child_sn") %>"}, null, "post", "release_complete()");
}
function release_complete(){
alert("ÇØÁ¦¿Ï·á");
location.href="./project_list2_dep_2014.asp?p_sn=<%=request("p_sn") %>&p_sub_type=<%=request("p_sub_type") %>&p_method_cd=<%=req_p_method_cd %>&p_child_sn=<%=request("p_child_sn") %>";
}
function prj_method_change(method_cd){
ajaxCallJson("project_list2_dep_ajax_method.asp", {method_cd : method_cd, p_child_sn : "<%=request("p_child_sn") %>"}, null, "post", "method_change_complete('"+method_cd+"')");
}
function method_change_complete(method_cd){
alert("º¯°æµÇ¾ú½À´Ï´Ù.");
location.href="./project_list2_dep_2014.asp?p_sn=<%=request("p_sn") %>&p_sub_type=<%=request("p_sub_type") %>&p_method_cd="+method_cd+"&p_child_sn=<%=request("p_child_sn") %>";
}
</script>
</div>
<!-- /.content-wrapper -->
<!-- #include virtual = "include/footer.asp" -->