210 lines
6.7 KiB
Plaintext
210 lines
6.7 KiB
Plaintext
|
|
|
|
<!-- #include file = "../include/default_values.asp" -->
|
|
<%'####################################################
|
|
'비용 정산을 위해 업무일지에 기록된 프로젝트 리스트를 보여주는 것
|
|
'''일반업무는 업무일지의 업무구분 코드를 '99999'으로 구분
|
|
|
|
|
|
'식대 표시 기준(2010년 9월 16일 정리)
|
|
'평일에는 택시비-휴일, 식대-저녁(점심), 식대-저녁(휴일), 간식비(휴일) 않되고,
|
|
'휴일에는 식대-저녁, 택시비-야근, 간식비(평일) 않됨.
|
|
'####################################################
|
|
%>
|
|
<%
|
|
|
|
call Time_Check(Session("Login_Check"))
|
|
|
|
|
|
dim Query
|
|
dim Max_Width
|
|
dim actval
|
|
dim actval2
|
|
dim actval3
|
|
dim actval4
|
|
dim part '어디서 왔나
|
|
dim condate '해당일자
|
|
dim cost_type '비용의 형태(둘다, 프로젝트, 일반)
|
|
dim txt_pay_type
|
|
dim Max_Col
|
|
dim cost_list()
|
|
dim cnt, i, j
|
|
|
|
actval = request("actval")
|
|
actval2 = request("actval2")
|
|
actval3 = request("actval3")
|
|
actval4 = request("actval4")
|
|
condate = request("condate")
|
|
part = request("part")
|
|
cost_type = request("cost_type")
|
|
txt_pay_type = request("txt_pay_type")
|
|
|
|
' Response.Write "actval = '" & actval & "<br>"
|
|
' Response.Write "actval2 = '" & actval2 & "<br>"
|
|
' Response.Write "actval3 = '" & actval3 & "<br>"
|
|
' Response.Write "actval4 = '" & actval4 & "<br>"
|
|
' Response.Write "condate = '" & condate & "<br>"
|
|
' Response.Write "part = '" & part & "<br>"
|
|
' Response.Write "cost_type = '" & cost_type & "<br>"
|
|
' Response.Write "txt_pay_type = '" & txt_pay_type & "<br>"
|
|
|
|
|
|
|
|
if part = "job_cost_project" then '비용의 프로젝트명 선택시 온다
|
|
Query = "select * from job"
|
|
Query = Query & " where j_p_no = '" & Session("User_Number") & "'"
|
|
Query = Query & " and j_date = '" & condate & "'" '현재 보고자하는 날짜
|
|
elseif part = "job_cost_category" then '비용항목 선택시 온다
|
|
query = "select * from cost_category where (cost_type = 0 or cost_type = " & cost_type & ")"
|
|
if instr(1,txt_pay_type,"평일") > 0 then
|
|
query = query & " and not (cost_code = 9 " ''평일에는 식대-저녁(점심) 안되요..
|
|
query = query & " or cost_code = 21 " ''평일에는 식대-저녁(휴일) 안되요..
|
|
query = query & " or cost_code = 18 " ''평일에는 택시비-주말 안되요..
|
|
query = query & " or cost_code = 22 ) " ''평일에는 간식비(휴일) 안되요..
|
|
else
|
|
query = query & " and not (cost_code = 10 " ''휴일에는 식대-저녁 안되요..
|
|
query = query & " or cost_code = 17 " ''휴일에는 택시비-야근 안되요..
|
|
query = query & " or cost_code = 1) " ''휴일에는 간식비(평일) 안되요..
|
|
end if
|
|
query = query & " order by sort_key"
|
|
end if
|
|
'''Response.Write query & "<br>"
|
|
adors.Open query, adoconn ,adOpenStatic,adLockReadOnly
|
|
|
|
Max_Width=770
|
|
Max_Col = 3
|
|
%>
|
|
<script language="javascript">
|
|
if (document.all) {
|
|
docObj = "document.all."
|
|
styleObj = ".style"
|
|
} else {
|
|
docObj = "document."
|
|
styleObj = ""
|
|
}
|
|
|
|
function SendName(j_name, j_pcode, j_detail, j_detail_code, actval,actval2,actval3,actval4,part) {
|
|
eval("opener.document.forms[0]." + actval).value = j_name;
|
|
eval("opener.document.forms[0]." + actval2).value = j_pcode;
|
|
if (part == "job_cost_project")
|
|
{
|
|
eval("opener.document.forms[0]." + actval3).value = j_detail;
|
|
eval("opener.document.forms[0]." + actval4).value = j_detail_code;
|
|
}
|
|
else if (part == "job_cost_category")
|
|
{ //간식비, 식대-점심(휴일), 식대-저녁,식대-저녁(휴일), 간식비(휴일)
|
|
if ((eval(j_pcode) == 1) || (eval(j_pcode) == 9) || (eval(j_pcode) == 10) || (eval(j_pcode) == 21) || (eval(j_pcode) == 22))
|
|
{
|
|
eval("opener.document.forms[0]." + actval3).style.display="";
|
|
eval("opener.document.forms[0]." + actval4).style.display="";
|
|
eval("opener.document.forms[0]." + actval3).focus();
|
|
}
|
|
else
|
|
{
|
|
eval("opener.document.forms[0]." + actval3).value = ""
|
|
eval("opener.document.forms[0]." + actval3).style.display="none";
|
|
eval("opener.document.forms[0]." + actval4).style.display="none";
|
|
}
|
|
}
|
|
self.close();
|
|
}
|
|
|
|
|
|
function dir_input(actval)
|
|
{
|
|
eval("opener.document.forms[0]." + actval).value = "";
|
|
// eval("opener.document.forms[0]." + actval).readonly = true;
|
|
eval("opener.document.forms[0]." + actval).focus();
|
|
self.close();
|
|
}
|
|
function closeWin(){
|
|
self.close();
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<HTML>
|
|
<HEAD>
|
|
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
|
|
<TITLE>프로젝트 선택</TITLE>
|
|
<link rel="StyleSheet" href="/css/basic.css" type="text/css">
|
|
|
|
</HEAD>
|
|
<BODY >
|
|
<form name='frmProjectList' method='post' style="TEXT-ALIGN: left" >
|
|
|
|
<%if part = "job_cost_project" then%>
|
|
<table border='3' width='<%=Max_Width%>' bordercolordark="#FFFFFF" cellspacing="0" cellpadding="4" bgcolor=mintcream >
|
|
<tr>
|
|
<td align=left style='FONT-SIZE:12pt;FONT-WEIGHT: bold'>
|
|
아래에 보여지는 프로젝트 목록은 <%=session("loginuser") %>님의 <%=condate%> 업무일지 기록 내용입니다.
|
|
</td>
|
|
</tr>
|
|
<%do while not adors.EOF%>
|
|
<tr bgcolor=white align=center>
|
|
<td height='30' align=left title="<%=adors("j_p_name")%> => <%=adors("j_detail")%>">
|
|
<p> <font color=blue><a href="javascript:SendName('<%=adors("j_p_name")%>','<%=adors("j_p_sn")%>','<%=adors("j_detail")%>','<%=adors("j_detail_code")%>','<%=actval%>','<%=actval2%>','<%=actval3%>','<%=actval4%>','<%=part%>')"><%=adors("j_p_name")%> => <%=adors("j_detail")%> => <%=adors("j_detail2")%></a> </font> </p>
|
|
</td>
|
|
</tr>
|
|
<%adors.MoveNext
|
|
loop%>
|
|
</table>
|
|
<%elseif part = "job_cost_category" then%>
|
|
<table border='3' width='<%=Max_Width%>' bordercolordark="#FFFFFF" cellspacing="0" cellpadding="4" bgcolor=mintcream >
|
|
<tr>
|
|
<td align=left colspan=<%=max_col%> style='FONT-SIZE:12pt;FONT-WEIGHT: bold'>
|
|
아래에 보여지는 항목은 비용정산을 위한 비용항목들입니다. <br><font color=blue>추가로 필요한 항목이 있으면 정보분석부 김홍근에게 연락주세요.</font>
|
|
</td>
|
|
</tr>
|
|
<%cnt = 0
|
|
cnt = adors.recordcount
|
|
redim cost_list(cnt,2)
|
|
cnt = 0
|
|
do while not adors.EOF
|
|
cnt = cnt + 1
|
|
cost_list(cnt,1) = adors("cost_name")
|
|
cost_list(cnt,2) = adors("cost_code")
|
|
adors.movenext
|
|
loop
|
|
adors.close
|
|
for i=1 to cnt%>
|
|
<tr bgcolor=white >
|
|
<%for j=1 to max_col%>
|
|
<td width='<%=100 / max_col%>%' height='30' class=td_center title="<%=cost_list(i,1)%>" style="cursor:pointer" onclick="SendName('<%=cost_list(i,1)%>','<%=cost_list(i,2)%>','','','<%=actval%>','<%=actval2%>','<%=actval3%>','<%=actval4%>','<%=part%>')">
|
|
<%=cost_list(i,1)%>
|
|
</td>
|
|
<%if i = cnt then
|
|
exit for
|
|
end if
|
|
if j <> Max_col then i=i+1
|
|
%>
|
|
<%next%>
|
|
</tr>
|
|
<%next%>
|
|
</table>
|
|
<%end if%>
|
|
|
|
|
|
<br>
|
|
<table border='1' width='<%=Max_Width%>' bordercolordark="#FFFFFF" cellspacing="0" cellpadding="4" >
|
|
<tr><td align=center>
|
|
<img src='/images/common/btn_cancel.jpg' title='닫기' style="cursor:pointer" align=middle onclick='closeWin();' >
|
|
해당 항목을 클릭하시면 선택이 됩니다
|
|
</td></tr>
|
|
</table>
|
|
</form>
|
|
</body>
|
|
</html>
|
|
|
|
<%
|
|
|
|
nothing
|
|
adoConn.Close
|
|
%>
|
|
|
|
|
|
|