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

901 lines
32 KiB
Plaintext

<!-- #include virtual = "lib/config.asp" -->
<!-- #include file = "../include/top_menu.asp" -->
<OBJECT RUNAT=Server PROGID=ADODB.Recordset id=Rs></OBJECT>
<%'####################################################
'인트라넷 메인
'정보분석부 전체, 자료조사부 팀장, 검증,
' => 현년도의 종료 프로젝트 리스트보이고, 진행중인 리스트도 보이게함
'자료조사부 팀원 : chk_admin = "field"
' => 팀원은 : 진행중인 프로젝트중 자기 자신이 배정된 프로젝트만 보이기
' => 자료조사부 계약직 팀원은 : 진행중인 프로젝트 리스트중 직접비가 입력된 리스트보이기
''연구부서 : chk_admin = "etc_buser1"
' => 진행중인 프로젝트중 자기 자신이 배정된 프로젝트만 보이기
' => 팀장은 팀 전체 리스트 보이기
'기타부서(경영지원실) : chk_admin = "etc_buser2"
' => 아무것도 안보임(즉, 사용권한 없음)
''진행중의 의미는 오늘날짜까지이고, 종료의 의미는 오늘 이전날짜까지임.
'####################################################
''2006년 11월 1일 추가분
'조사기간이 종료된 프로젝트 리스트 본후 직접비 관리로 갔다가 직접비 관리에서 다른 프로젝트 선택시
'현해 화면으로 오게 수정(변수 url_posi 추가로 함)
'####################################################
'홍근테스트전용들 및 개발 프로그램들을 제외하던 루틴 삭제
'왜냐하면 fgi모임이 and substring(p_sn,5,3) <> '000')에 걸리기에
%>
<%
'Response.Cookies("krc_username")
'Response.Write "'"
'Response.Write "<font color=red style='FONT-FAMILY: 고딕체;font-size:12px;FONT-WEIGHT: bold;'>위치 : 프로젝트 => 진행 상황</font>"
call Time_Check(Session("Login_Check"))
'Response.Expires = 0
'Response.Buffer = false
Dim Sql
dim i, j
dim u_name
dim ConDate
dim chk_admin
dim sc_year
dim sc_month
dim sc_team
dim sc_name
dim krc_team()
dim krc_team_cnt
dim prj_search_cnt
dim tmpstr
dim method
dim db_p_dp() 'dp 배열에 저장
dim prj_dp '담당dp
dim line_cnt
dim dp_rank(3) '전산 난이도
dim db_p_sv() 'sv 배열에 저장
dim prj_sv '담당sv
dim max_width
dim sample_cnt '샘플수
dim sv_rank(3) '실사 난이도
dim db_p_research() '연구 배열에 저장
dp_rank(0) = ""
dp_rank(1) = "상"
dp_rank(2) = "중"
dp_rank(3) = "하"
sv_rank(0) = ""
sv_rank(1) = "상"
sv_rank(2) = "중"
sv_rank(3) = "하"
sc_year = Request.QueryString("sc_year")
sc_month = Request.QueryString("sc_month")
sc_team = Request.QueryString("sc_team")
sc_name = Request.QueryString("sc_name")
if sc_year = "" then
sc_year = year(date)
end if
if sc_month = "" then
sc_month = month(date)
end if
if sc_team = "" then
sc_team="0"
end if
sql = "select * from depart where ((d_code >0 and d_code < 11) or (d_code >= 20 and d_code <=60)) and d_yes_no = 'y' order by d_code"
Rs.open sql, adoconn,adopenstatic, adlockreadonly
krc_team_cnt = Rs.recordcount
redim krc_team(krc_team_cnt,2)
krc_team_cnt = 0
do while not Rs.eof
krc_team_cnt = krc_team_cnt + 1
krc_team(krc_team_cnt,1) = rs("d_code")
krc_team(krc_team_cnt,2) = rs("d_name")
Rs.movenext
loop
Rs.close
''/=========================
''/===========================
''사용권한
''자료조사부 팀장(부서:12), 정보분석부(부서:11), 경영지원실(부서:13),임원(부서 0은 임원)
''2011년 1월 7일로 다시 변경
'자료조사부 팀장(부서:12), 정보시스템부(17). 경영전략실(부서:18),임원(부서 0은 임원)
if ( Session("Depart_Code") = "12" and Session("admin_Code") = "1") or Session("Depart_Code") = "17" or Session("Depart_Code") = "18" or Session("Depart_Code") = "0" then
chk_admin="admin"
max_width = 1000
elseif Session("Depart_Code") = "12" then '자료조사부
chk_admin="field"
max_width = 870
elseif cint(Session("Depart_Code")) <= 10 or (cint(Session("Depart_Code")) >= 20 and cint(Session("Depart_Code")) <=60) then '연구부서
chk_admin = "etc_buser1"
max_width = 870
else '경영지원실
chk_admin = "etc_buser2"
end if
max_width = 1050
''/=========================
''/===========================
ConDate=year(date) & "-" & zeroFormat(month(date),2) & "-" & zeroFormat(day(date),2)
Sql = "select p_name from person where p_no ='" & Session("user_number") & "'"
Rs.open sql, adoconn,adopenstatic, adlockreadonly
u_name = Rs.fields("p_name")
Rs.close
''/===========================
''/===========================
'p_job_part => 0:임원, 1:연구, 2:제작, 3:s/v, 4:검증, 5:코딩, 6:펀치, 7:dp, 8:it, 9:회계, 99:기타
''/===========================
'Person 테이블에서 DP 업어오기
sql = "SELECT * "
sql = sql & "FROM Person "
sql = sql & "WHERE (p_depart='17' AND p_resign='0' and p_job_part = '07')" '전산의 dp
sql = sql & "OR (p_depart='88' AND p_resign='0') " '기타
sql = sql & "order by p_order "
adoRs.open sql, adoconn,adopenstatic, adlockreadonly
redim db_p_dp(adoRs.recordcount,3)
i=0
db_p_dp(i,1) = "0"
db_p_dp(i,2) = "= 선택 ="
do until adoRs.eof
i=i+1
db_p_dp(i,1) = trim(adoRs("p_no"))
db_p_dp(i,2) = trim(adoRs("p_name"))
adoRs.movenext
loop
adoRs.close
''/===========================
'Person 테이블에서 sv 업어오기
sql = "select * from person "
sql = sql & "where ( p_depart='12' AND p_resign='0')" 'svand p_job_part = '03'
sql = sql & " OR (p_depart='88' AND p_resign='0') " '기타
sql = sql & " order by p_order "
adoRs.open sql, adoconn,adopenstatic, adlockreadonly
redim db_p_sv(adoRs.recordcount,3)
i=0
db_p_sv(i,1) = "0"
db_p_sv(i,2) = "= 선택 ="
do until adoRs.eof
i=i+1
db_p_sv(i,1) = trim(adoRs("p_no"))
db_p_sv(i,2) = trim(adoRs("p_name"))
adoRs.movenext
loop
adoRs.close
''/===========================
'Person 테이블에서 연구원 업어오기(퇴사자 포함)
sql = "select * from person "
sql = sql & "where ((p_depart <='10' or (p_depart >= 20 and p_depart <= 95)) and p_job_part = '01')" '연구원
sql = sql & " OR (p_depart='88' ) " '기타
sql = sql & " order by p_order "
adoRs.open sql, adoconn,adopenstatic, adlockreadonly
redim db_p_research(adoRs.recordcount,3)
i=0
db_p_research(i,1) = "0"
db_p_research(i,2) = "= 선택 ="
do until adoRs.eof
i=i+1
db_p_research(i,1) = trim(adoRs("p_no"))
db_p_research(i,2) = trim(adoRs("p_name"))
adoRs.movenext
loop
adoRs.close
%>
<script language=javascript>
function help_open()
{
var width_size = screen.width - 600;
var height_size= screen.height;
window.open ("/help/project_stat_help.htm", "", "left=" + width_size + " top=5 width=600 height=500 scrollbars=yes statbar=no" );
}
function go_search(goPageNum)
{
var sc_year = document.frm_new_main.sc_year.value;
var sc_month = document.frm_new_main.sc_month.value;
var sc_team = document.frm_new_main.sc_team.value;
var sc_name = document.frm_new_main.sc_name.value;
var url;
// var sc_method = document.frm_new_main.sc_method.value;
//유형포함 document.frm_new_main.action="new_main.asp?sc_year="+sc_year+"&sc_month="+sc_month+"&sc_team="+sc_team+"&sc_name="+sc_name+"&sc_method="+sc_method+"&curpage="+goPageNum;
url = "project_stat.asp?sc_year="+sc_year+"&sc_month="+sc_month+"&sc_team="+sc_team+"&sc_name="+sc_name+"&curpage="+goPageNum;
document.frm_new_main.action=url;
document.frm_new_main.submit();
// window.open('project_stat.asp?' + url,'_self')
}
function Change_DP(p_sn, line_cnt)
{
//담당 dp와 난이도를 동시에 바꾸기를 함
var x;
var dp = document.all.prj_dp[line_cnt-1].value;
var dp_rank = document.all.prj_dp_rank[line_cnt-1].value;
x = window.showModalDialog('project_dpSave.asp?C_dp='+dp+'&p_sn='+p_sn+'&c_dp_rank='+dp_rank,window,"dialogTop:middle;dialogLeft:middle;dialogWidth:550px;dialogHeight:600px;scroll:1;center:1;");
if (x!="")
{
//window.location.reload();
document.frm_new_main.prj_dp[line_cnt-1].value = x;
alert ("DP 및 난이도 저장 성공");
}
else
{
alert ("DP 및 난이도 저장 실패");
}
}
function Change_Sv(p_sn, line_cnt)
{
//담당 sv를 바꾸기를 함
var x;
// var sv = document.all.sel_prj_sv[line_cnt-1].value;
var sv_rank = document.all.prj_sv_rank[line_cnt-1].value;
// x = window.showModalDialog('project_svSave.asp?C_sv='+sv+'&p_sn='+p_sn,window,"dialogTop:middle;dialogLeft:middle;dialogWidth:550px;dialogHeight:600px;scroll:1;center:1;");
x = window.showModalDialog('project_svSave.asp?p_sn='+p_sn+'&c_sv_rank='+sv_rank,window,"dialogTop:middle;dialogLeft:middle;dialogWidth:550px;dialogHeight:600px;scroll:1;center:1;");
if (x!="")
{
//window.location.reload();
// document.frm_new_main.sel_prj_sv[line_cnt-1].value = x;
alert ("실사 난이도 저장 성공");
}
else
{
alert ("실사 난이도 저장 실패");
}
}
function openit(p_sn,sc_year,sc_month,sc_team,sc_name) {
var url = 'project_list2_dep.asp?p_sn=' + p_sn + '&teamname=' + sc_team;
var tmp_width = 850;
var tmp_height = 800;
window.open(url,'','left=0,top=0,width='+tmp_width+',height='+tmp_height+',scrollbars=yes,resizable=yes')
}
</script>
<SCRIPT LANGUAGE="JavaScript" SRC="/js/common.js"></SCRIPT>
<form method='post' name='frm_new_main'>
<td width="100%" valign="top">
<%''//================================
''//================================
'금번달 종료 프로젝트 목록
sql =""
line_cnt=0
' if chk_admin = "admin" then
%>
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<!-- 확인 -->
</tr>
<tr>
<td colspan="2" style="padding:20;">
<div id="popdiv_obj1" style="position:absolute; background-color:FFFFDD;color:black;border-color:black;border-width:20; display:none; left:25px; top:100px; z-index:10" onmouseover="overdiv=20;" onmouseout="overdiv=0;setTimeout('hideLayer()',1000)">asdf</div>
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td>
<font class="brown">※ 조사 기간이 종료된 프로젝트 조회 ※ 검색 조건을 선택하세요.</font>
</font>
</td>
</tr>
<tr>
<td style="padding:5 0 0 0">
<table width="100%" height="37" cellpadding="3" cellspacing="0" border="0" style="border-collapse:collapse;">
<tr>
<td bgcolor="#DFDFDF" style="padding:0 0 0 10">
년도별:
<SELECT name=sc_year>
<%for i=cint(year(date)) to 2009 step -1 %>
<OPTION value='<%=i%>'
<%if cint(i) = cint(sc_year) then%>
selected
<%end if%>
><%=i%></OPTION>
<%next%>
</SELECT>
&nbsp;&nbsp;
조사시작월:
<SELECT name=sc_month>
<OPTION value='0'>전체</OPTION>
<% for i=1 to 12%>
<OPTION value='<%=zeroFormat(i,2)%>'
<%if cint(i) = cint(sc_month) then%>
selected
<%end if%>
><%=i%>월</OPTION>
<%next%>
</SELECT>
&nbsp;&nbsp;
본부별:
<SELECT name=sc_team>
<OPTION value='0'>전체</OPTION>
<%for i=1 to krc_team_cnt%>
<OPTION value='<%=krc_team(i,1)%>'
<%if cint(sc_team) = cint(krc_team(i,1)) then%>
selected
<%end if%>
><%=krc_team(i,2)%></OPTION>
<%next%>
</SELECT>
&nbsp;&nbsp;
프로젝트명 :
<input type=text name=sc_name maxlength=20 size=20 style='ime-mode:inactive;' value = '<%=sc_name%>'>
&nbsp;&nbsp;
&nbsp;<img src='/images/common/btn_smallsrch.gif' style='cursor:pointer' onclick='go_search("1");' title ='찾기' align="absmiddle">
</td>
</tr>
</table>
<%'end if' if chk_admin = "admin" then
sql = "SELECT a.*, "
sql = sql & " b.p_order AS p_order "
sql = sql & "FROM dbo.project a LEFT OUTER JOIN "
if Session("Depart_Code") = "15" or Session("Depart_Code") = "17" then
sql = sql & " dbo.person b ON a.p_dper = b.p_no "
elseif Session("Depart_Code") = "12" or Session("Depart_Code") = "16" then
sql = sql & " dbo.person b ON a.p_sv = b.p_no "
else
sql = "select * from project as a "
end if
sql = sql & "where p_field_end < '" & ConDate & "'" ' and substring(p_field_end,1,7) = '" & mid(condate,1,7) & "'"
' sql = sql & " and substring(p_sn,5,3) <> '000' " '홍근테스트전용들 및 개발 프로그램들
if sc_month <> "0" and sc_month <> "" then
'원본
'2005-09-27 필드스타트 날짜의 월별 검색으로 변경(p_field_st)
sql = sql & " and substring(p_field_end,1,4) = '" & zeroformat(sc_year,4) & "'" '년별
sql = sql & " and substring(p_field_end,6,2) = '" & zeroformat(sc_month,2) & "'" '월별
else
sql = sql & " and substring(p_field_end,1,4) = '" & zeroformat(sc_year,4) & "'" '년별
end if
if sc_team <> "0" and sc_team <> "" then
sql = sql & " and a.p_depart_dep='" & sc_team & "'" '팀별
end if
if sc_name <> "" then
sql = sql & " and a.p_subject like '%" & sc_name & "%'" '프로젝트이름별
end if
''로그인 사용자별 권한주기..
'연구팀장은 해당 부서의 전체의 것
'연구팀원은 자기 자신의 것만
'자료조사부, 정보분석부 팀장/팀원은 모두
'자료조사부 팀원은 자기 자신의 것만
'
if chk_admin = "etc_buser1" then '연구부서
sql = sql & " and substring(p_sn,5,1) = '" & cint(Session("Depart_Code")) & "' " '자기 부서만
if Session("admin_Code") <> "True" then '팀장이 아니면 연구원 자신의 이름이 들어간 모든 프로젝트
sql = sql & "and ("
sql = sql & "p_rsch_1 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_2 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_3 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_4 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_5 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_6 = '" & Session("user_number") & "' "
sql = sql & ") "
end if
elseif chk_admin = "field" then '자료조사
end if
sql = sql & " and (substring(p_sn,1,2) <> '08') "
if Session("Depart_Code") = "15" or Session("Depart_Code") = "17" then
sql = sql & " order by p_order, p_field_end, p_subject"' p_dper,p_name, p_field_end"
elseif Session("Depart_Code") = "12" or Session("Depart_Code") = "16" then
sql = sql & " order by p_sv, p_field_end"
else
sql = sql & " order by p_subject "
end if
Rs.open sql, adoconn,adopenstatic, adlockreadonly
prj_search_cnt = Rs.recordcount
tmpstr= sc_year & "년 "
if cint(sc_month) > 0 then
tmpstr = tmpstr & sc_month & "월 "
end if
if cint(sc_team) > 0 then
for i = 1 to krc_team_cnt
if cint(krc_team(i,1)) = cint(sc_team) then
tmpstr = tmpstr & krc_team(i,2)
exit for
end if
next
end if
%>
<table width="100%" cellpadding="3" cellspacing="0" border="0" style="border-collapse:collapse;">
<tr>
<td>&nbsp;<font color=#000069>◆ <%=Response.Write (u_name)%>님 <%=condate%> 일 현재 <font size=3 color=red><b>(조건:<%=tmpstr%>)</b></font> 종료 프로젝트 목록입니다.(<%=prj_search_cnt%>개)
</font></td>
</tr>
<tr>
<td colspan="13" bgcolor="#d5d5d5" height="1"></td>
</tr>
</table>
<div style="overflow-x:hidden;overflow-y:scroll;height:37px;100%;border:none;">
<table width="100%" cellpadding="3" cellspacing="0" border="0" style="border-collapse:collapse;">
<tr >
<td align=center width='10%' >프로젝트명</td>
<td align=center width='20%' >조사내용</td>
<td align=center width='5%' >조사방법</td>
<td align=center width='5%' >샘플수</td>
<td align=center width='5%' >담당연구</td>
<td align=center width='5%' >담당전산</td>
<td align=center width='5%' >담당SV</td>
<td align=center width='10%' >실사시작일</td>
<td align=center width='10%' >실사종료일</td>
<td align=center width='10%' >펀치종료일</td>
<td align=center width='5%' >직접비<br>관리</td>
<td align=center width='10%' >직접비</td>
</tr>
</table>
</div>
<div style="overflow-x:hidden;overflow-y:scroll;height:400px;100%;border:none;">
<table width="100%" cellpadding="3" cellspacing="0" border="0" style="border-collapse:collapse;">
<% if Rs.recordcount<1 then %>
<tr align=center onmouseover="this.style.background='#FFE3EE'" onmouseout="this.style.background='white'" height=20>
<td colspan=6 align=center> 현재 완료된 프로젝트가 없습니다.</td>
</tr>
<tr height=1>
<td background='/images/dot.gif' colspan=6>
</tr>
<% else
prj_dp = ""
for i=0 to ubound(db_p_dp)
db_p_dp(i,3) = 0
next
for i=0 to ubound(db_p_sv)
db_p_sv(i,3) = 0
next
for i=0 to ubound(db_p_research)
db_p_research(i,3) = 0
next
tmp_bgcolor="#dbe9f2"
do until Rs.EOF
line_cnt = line_cnt + 1
method = Rs("p_method")
sql = "select * from p_method where code1 = '" & method & "'"
' Response.Write sql
' Response.Write RS("p_sn")
AdoRs.open sql, adoconn,adopenstatic, adlockreadonly
method = adors("name1")
AdoRs.close
tmpstr = "조사방법 : " & method & "<br>"
tmpstr = tmpstr & "조사내용 : " & Rs("p_intention")
sample_cnt = rs("p_sample")
if tmp_bgcolor="" then
tmp_bgcolor="#dbe9f2"
else
tmp_bgcolor=""
end if
%>
<tr align=center bgcolor="<%=tmp_bgcolor%>" id='row<%=line_cnt%>' onmouseover="MultiRowSelection('row<%=line_cnt%>',0,'on');popLayer('<%=tmpstr%>');" onmouseout="MultiRowSelection('row<%=line_cnt%>',0,'off','<%=tmp_bgcolor%>');hideLayer();">
<td align=left width='10%' style='cursor:pointer' onclick = 'openit("<%=Rs("p_sn")%>","<%=sc_year%>","<%=sc_month%>","<%=sc_team%>","<%=sc_name%>")' ><%=Rs("p_subject")%></td>
<td align=left width='20%' ><%=replace(csformat(Rs("p_intention"),30),"&nbsp;","")%></td>
<td align=left width='5%' >
<%i = cint(instr(1,method,"("))
if i > 0 then
tmpstr = mid(method,1,i - 1)
else
tmpstr = method
end if
Response.Write tmpstr
%>
</td>
<td align=right width='5%' ><%=formatnumber(sample_cnt,0)%></td>
<%''담당 연구원
tmpstr="&nbsp;"
for i=0 to ubound(db_p_research)
if db_p_research(i,1) = rs("p_rsch_1") then
tmpstr = db_p_research(i,2)
db_p_research(i,3) = cint(db_p_research(i,3)) + 1''연구 담당별 프로젝트 갯수 카운드
end if
next
if tmpstr="&nbsp;" then '퇴직자 찾기
sql = "SELECT * "
sql = sql & "FROM Person "
sql = sql & "WHERE ( p_resign='1' )"
sql = sql & " and p_no = '" & rs("p_rsch_1") & "'"
sql = sql & "order by p_order "
AdoRs.Open sql, adoConn, 1%>
<%
if AdoRs.recordcount > 0 then
%>
<%tmpstr = AdoRs("p_name")%>
<%
end if
%>
<%AdoRs.Close
end if%>
<td width='5%' ><%=tmpstr%></td>
<%''담당 전산
tmpstr="&nbsp;"
for i=0 to ubound(db_p_dp)
if db_p_dp(i,1) = rs("p_dper") then
tmpstr = db_p_dp(i,2)
db_p_dp(i,3) = cint(db_p_dp(i,3)) + 1''dp담당별 프로젝트 갯수 카운드
end if
next
if tmpstr="&nbsp;" and trim(rs("p_dper")) <> "" then '퇴직자 찾기
sql = "SELECT * "
sql = sql & "FROM Person "
' sql = sql & "WHERE ( p_resign='1' )"
sql = sql & "WHERE p_no = '" & rs("p_dper") & "'"
sql = sql & " order by p_order "
AdoRs.Open sql, adoConn, 1
%>
<%prj_dp = AdoRs("p_name")%>
<%AdoRs.Close
else
prj_dp = tmpstr '담당dp
end if
%>
<td width='5%' ><%=prj_dp%></td>
<%''담당 sv
tmpstr="&nbsp;"
for i=0 to ubound(db_p_sv)
if db_p_sv(i,1) = rs("p_sv") then
tmpstr = db_p_sv(i,2)
db_p_sv(i,3) = cint(db_p_sv(i,3)) + 1''sv 담당별 프로젝트 갯수 카운드
end if
next
if tmpstr="&nbsp;" and trim(rs("p_sv")) <> "" then '퇴직자 찾기
sql = "SELECT * "
sql = sql & "FROM Person "
sql = sql & "WHERE ( p_resign='1' )"
sql = sql & " and p_no = '" & rs("p_sv") & "'"
sql = sql & " order by p_order "
AdoRs.Open sql, adoConn, 1
if isnull(AdoRs("p_name")) then
tmpstr = ""
else
tmpstr = AdoRs("p_name")
end if
AdoRs.Close
end if
%>
<td width='5%' ><%=tmpstr%></td>
<td width='10%' ><%=Rs("p_field_st")%></td>
<td width='10%'><%=Rs("p_field_end")%></td>
<td width='10%'><%=Rs("P_punch_end")%></td>
<td width='5%' >
<%
tmpstr = default_path_root & "inspection/project_direct_cost.asp?url_posi=project_stat&p_sn=" & RS("p_sn") & "&p_method=" & Rs("p_method")
if tmpstr = "해당프로젝트에 조사방법이 등록되어 있지 않습니다" then%>
<a href='javascript:alert("해당프로젝트에 조사방법이 등록되어 있지 않습니다.\n\n연구부서에서 프로젝트 관리의 수정 및 조회에서 조사방법을 지정해야합니다.");'>관 리</a>
<%else
if cint(Session("Depart_Code") ) < 11 or (cint(Session("Depart_Code") ) >= 20 and cint(Session("Depart_Code") ) <=60) then '연구부서이면
tmpstr = tmpstr & "&printmode=1"%>
<a target=new href = '<%=tmpstr%>'>관리</a>
<%else
' tmpstr = tmpstr & "&url_posi=project_stat"
tmpstr = tmpstr & "&sc_year=" & sc_year
tmpstr = tmpstr & "&sc_month=" & sc_month
tmpstr = tmpstr & "&sc_team=" & sc_team
tmpstr = tmpstr & "&sc_name=" & sc_name%>
<a href = '<%=tmpstr%>'>관리</a>
<%end if
%>
<%end if%>
</td>
<td align=right ><!--직접비 금액-->
<%if not isnull(rs("p_esti_cost")) then%>
<%=formatnumber(rs("p_esti_cost"),0)%>
<%end if%>
&nbsp;&nbsp;&nbsp;
</td>
</tr>
<%
Rs.movenext
loop
end if ' if Rs.recordcount<1 then
Rs.Close
%>
</tr>
<tr>
<td colspan=100>
<%'dp담당별 프로젝트 갯수 카운드 보여주기
if ((Session("Depart_Code") = "15" or Session("Depart_Code") = "17") and Session("admin_Code") = "1") then '전산팀장 %>
<table border=2 cellspacing=0 cellpadding=0 bordercolor=#000069 width=<%=max_width%>>
<tr bgcolor=#B9E2FA align=center height=30>
<td > <font size=2 color=blue><b>담당 DP 별 종료 갯수(전산팀장만보임)</b></font></td>
<%for i = 1 to ubound(db_p_dp)%>
<td>
<%=db_p_dp(i, 2)%> => <%=db_p_dp(i, 3)%> 개
</td>
<%next%>
</tr>
</table>
<%end if%>
</td>
</tr>
<%''//================================
''//================================
''현재 진행중인 프로젝트 목록(계약 상태로 )
''//================================
''//================================
sql = ""
if chk_admin = "admin" then
sql = "SELECT a.*, "
sql = sql & " b.p_order AS p_order "
sql = sql & "FROM dbo.project a LEFT OUTER JOIN "
if Session("Depart_Code") = "15" or Session("Depart_Code") = "17" then
sql = sql & " dbo.person b ON a.p_dper = b.p_no "
elseif Session("Depart_Code") = "12" or Session("Depart_Code") = "16" then
sql = sql & " dbo.person b ON a.p_sv = b.p_no "
else
sql = "select * from project "
end if
sql = sql & "where (( p_field_end >= '" & ConDate & "')"
' sql = sql & " and substring(p_sn,5,3) <> '000') " '홍근테스트전용들 및 개발 프로그램들
sql = sql & " or ((p_field_end is null or p_field_end ='') and substring(p_sn,1,2) = '" & mid(year(date),3,2) & "' ) "' and substring(p_sn,5,3) <> '000') " '실사기간이 없는 것
sql = sql & " ) "
if Session("Depart_Code") = "15" or Session("Depart_Code") = "17" then
' sql = sql & " order by p_order, a.p_field_end, a.p_subject"' p_dper,p_name, p_field_end"
sql = sql & " order by p_order, a.p_subject, p_field_end"
elseif Session("Depart_Code") = "12" then
sql = sql & " order by p_order, p_subject"
else
sql = sql & " order by p_subject"
end if
elseif chk_admin = "field" then '자료조사부 팀원
sql = "select * from project where ((p_sv = '" & Session("user_number") & "' and p_field_end >= '" & ConDate & "') "
sql = sql & " or ((p_field_end is null or p_field_end ='') and substring(p_sn,1,2) = '" & mid(year(date),3,2) & "')"' and substring(p_sn,5,3) <> '000') " '실사기간이 없는 것
sql = sql & " ) "
sql = sql & " order by p_subject"
elseif chk_admin = "etc_buser1" then '연구부서
if Session("admin_Code") ="True" or Session("admin_Code") = "1" then '부서장이면
sql = "select * "
sql = sql & "from project "
sql = sql & " where (((p_field_end >= '" & ConDate & "')"'
sql = sql & " or ((p_field_end is null or p_field_end ='') and substring(p_sn,1,2) = '" & mid(year(date),3,2) & "'))"'
sql = sql & " and substring(p_sn,5,1) = '" & Session("Depart_Code") & "'"
sql = sql & " ) "
sql = sql & " order by p_subject"
else
sql = "select *"
sql = sql & " from project "
sql = sql & " where ( "
sql = sql & "p_rsch_1 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_2 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_3 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_4 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_5 = '" & Session("user_number") & "' or "
sql = sql & "p_rsch_6 = '" & Session("user_number") & "' "
sql = sql & ") "
sql = sql & " and ( "
sql = sql & " p_field_end >= '" & ConDate & "'"
' sql = sql & " or ((p_field_end is null or p_field_end ='') and substring(p_sn,1,2) = '" & mid(year(date),3,2) & "') "' and substring(p_sn,5,3) <> '000') " '실사기간이 없는 것
sql = sql & " ) "
sql = sql & " order by p_subject"
end if
elseif chk_admin = "etc_buser2" then '정보분석부, 자료조사부, 연구부서를 제외한 나머지팀, 즉 경영지원실
alert2("사용권한이 없습니다")
end if
Rs.open sql, adoconn,adopenstatic, adlockreadonly
prj_search_cnt = Rs.recordcount
if chk_admin <> "etc_buser" then%>
<tr height=50>
<% if chk_admin = "admin" then %>
<td colspan=100 >&nbsp;<font color=#000069>◆ <%=Response.Write (u_name)%>님 현재 계약 상태로 실사중인 프로젝트 목록입니다.
<% else%>
<td colspan=100>&nbsp;<font color=#000069>◆ <%=Response.Write (u_name)%>님의 현재 계약 상태로 진행 중 프로젝트 목록입니다.
<% end if %>
<font color=red size=3><b>실사기간이 오늘날짜 포함 : <%=prj_search_cnt%>개</b></font>(실사종료일이 지난것은 보이지 않음)<br>
<font color=red size=3><b>&nbsp;◆ 담당SV, 담당DP가 지정되지 않은 프로젝트는 모든 직원에게 보입니다.</b></font>
</font></td>
</tr>
</tr>
<tr height=45 bgcolor=Yellow>
<td colspan=100> 계약으로 등록된 프로젝트 중 실사가 현재 진행중이거나, 진행 예정인 프로젝트 목록입니다.</td>
</tr>
<% if Rs.recordcount<1 then %>
<tr align=center onmouseover="this.style.background='#FFE3EE'" onmouseout="this.style.background='white'" height=20>
<td colspan=6 align=center> 현재 진행중인 프로젝트가 없습니다.</td>
</tr>
<tr height=1>
<td background='/images/dot.gif' colspan=6>
</tr>
<% else %>
<% 'line_cnt = 0
prj_dp = ""
for i=0 to ubound(db_p_dp)
db_p_dp(i,3) = 0
next
for i=0 to ubound(db_p_sv)
db_p_sv(i,3) = 0
next
for i=0 to ubound(db_p_research)
db_p_research(i,3) = 0
next
tmp_bgcolor="#dbe9f2"
do until Rs.EOF
line_cnt = line_cnt + 1
method = Rs("p_method")
if trim(method ) <> "" then
sql = "select * from p_method where code1 = " & method
AdoRs.open sql, adoconn,adopenstatic, adlockreadonly
method = adors("name1")
AdoRs.close
else
method = "&nbsp;"
end if
tmpstr = "조사방법 : " & method & "<br>"
tmpstr = tmpstr & "조사내용 : " & Rs("p_intention")
sample_cnt = rs("p_sample")
if tmp_bgcolor="" then
tmp_bgcolor="#dbe9f2"
else
tmp_bgcolor=""
end if
%>
<tr align=center bgcolor="<%=tmp_bgcolor%>" id='row<%=line_cnt%>' onmouseover="MultiRowSelection('row<%=line_cnt%>',0,'on');popLayer('<%=tmpstr%>');" onmouseout="MultiRowSelection('row<%=line_cnt%>',0,'off','<%=tmp_bgcolor%>');hideLayer();">
<td width = '10%' align=left style='cursor:pointer' onclick = 'openit("<%=Rs("p_sn")%>","<%=sc_year%>","<%=sc_month%>","<%=sc_team%>","<%=sc_name%>")' ><%=Rs("p_subject")%></td>
<td width = '20%' align=left ><%=replace(csformat(Rs("p_intention"),30),"&nbsp;","")%></td>
<td width = '5%' align=left >
<%i = cint(instr(1,method,"("))
if i > 0 then
tmpstr = mid(method,1,i - 1)
else
tmpstr = method
end if
Response.Write tmpstr
%>
</td>
<td width = '5%' align=right ><%=formatnumber(sample_cnt,0)%></td>
<%''담당 연구원
tmpstr="&nbsp;"
for i=0 to ubound(db_p_research)
if db_p_research(i,1) = rs("p_rsch_1") then
tmpstr = db_p_research(i,2)
db_p_research(i,3) = cint(db_p_research(i,3)) + 1''연구 담당별 프로젝트 갯수 카운드
end if
next%>
<td width = '5%' ><%=tmpstr%></td>
<%''담당 전산
tmpstr="&nbsp;"
for i=0 to ubound(db_p_dp)
if db_p_dp(i,1) = rs("p_dper") then
tmpstr = db_p_dp(i,2)
db_p_dp(i,3) = cint(db_p_dp(i,3)) + 1''dp담당별 프로젝트 갯수 카운드
end if
next
prj_dp = tmpstr '담당dp
%>
<td width = '5%' ><%=prj_dp%></td>
<%''담당 sv
tmpstr="&nbsp;"
for i=0 to ubound(db_p_sv)
if db_p_sv(i,1) = rs("p_sv") then
tmpstr = db_p_sv(i,2)
db_p_sv(i,3) = cint(db_p_sv(i,3)) + 1''sv 담당별 프로젝트 갯수 카운드
end if
next
prj_sv = tmpstr
%>
<td width = '5%' ><%=prj_sv%></td>
<td width = '10%' ><%=Rs("p_field_st")%></td>
<td width = '10%' ><%=Rs("p_field_end")%></td>
<td width = '10%' ><%=Rs("P_punch_end")%></td>
<td width = '5%' >
<%
tmpstr = Rs("p_method")
if trim(tmpstr) <> "" then
tmpstr = default_path_root & "inspection/project_direct_cost.asp?url_posi=project_stat&p_sn=" & RS("p_sn") & "&p_method=" & Rs("p_method")
if tmpstr = "해당프로젝트에 조사방법이 등록되어 있지 않습니다" then%>
<a href='javascript:alert("해당프로젝트에 조사방법이 등록되어 있지 않습니다.\n\n연구부서에서 프로젝트 관리의 수정 및 조회에서 조사방법을 지정해야합니다.");'>관리</a>
<%else
if cint(Session("Depart_Code") ) < 11 or (cint(Session("Depart_Code") ) >= 20 and cint(Session("Depart_Code") ) <=60) then '연구부서이면
tmpstr = tmpstr & "&printmode=1"%>
<a target=new href = '<%=tmpstr%>'>관리</a>
<%else
' tmpstr = tmpstr & "&url_posi=project_stat"
tmpstr = tmpstr & "&sc_year=" & sc_year
tmpstr = tmpstr & "&sc_month=" & sc_month
tmpstr = tmpstr & "&sc_team=" & sc_team
tmpstr = tmpstr & "&sc_name=" & sc_name%>
<a href = '<%=tmpstr%>'>관리</a>
<%end if
%>
<%end if
else%>
<a href='javascript:alert("해당프로젝트에 조사방법이 등록되어 있지 않습니다.\n\n연구부서에서 프로젝트 관리의 수정 및 조회에서 조사방법을 지정해야합니다.");'>관리</a>
<%end if%>
</td>
<!--
<td width=6%> <a href='<%=Root_Url%>자료조사부/Recruit/Recruit_condition.asp?prj_code=<%=RS("p_sn")%>&u_name=<%=u_name%>'>관 리</a></td>
-->
<td width = '10%' align=right ><!--직접비 금액-->
<%if not isnull(rs("p_esti_cost")) then%>
<%=formatnumber(rs("p_esti_cost"),0)%>
<%end if%>
&nbsp;&nbsp;&nbsp;
</td>
<%
Rs.movenext
loop
end if 'if Rs.recordcount<1 then
Rs.Close
%>
</table>
<br>
<%'dp담당별 프로젝트 갯수 카운드 보여주기
if ((Session("Depart_Code") = "15" or Session("Depart_Code") = "17") and Session("admin_Code") = "1") then '전산팀장 %>
<table border=2 cellspacing=0 cellpadding=0 bordercolor=#000069 width='<%=max_width%>'>
<tr bgcolor=#B9E2FA align=center height=30>
<td > <font size=2 color=blue><b>담당 DP 별 진행중 갯수(전산팀장만보임)</b></font></td>
<%for i = 1 to ubound(db_p_dp)%>
<td>
<%=db_p_dp(i, 2)%> => <%=db_p_dp(i, 3)%> 개
</td>
<%next%>
</tr>
</table>
<%end if%>
<%end if 'if chk_admin <> "etc_buser" then%>
</table>
</td>
</tr>
</table>
</td>
</form>
<% %>