최초커밋
This commit is contained in:
20
knowledge/a_delete.asp
Normal file
20
knowledge/a_delete.asp
Normal file
@@ -0,0 +1,20 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
a_sn = request("a_sn")
|
||||
|
||||
query = "UPDATE [T_AGREEMENT] "
|
||||
query = query & "SET "
|
||||
query = query & " use_div = '0' "
|
||||
query = query & "WHERE id = '" & a_sn & "' "
|
||||
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
<script>
|
||||
alert("<22><><EFBFBD><EFBFBD> <20>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
location.href = 'agreement_list.asp';
|
||||
</script>
|
||||
10
knowledge/a_downloads.asp
Normal file
10
knowledge/a_downloads.asp
Normal file
@@ -0,0 +1,10 @@
|
||||
<%@ Language=VBScript EnableSessionState="False"%>
|
||||
<%
|
||||
filepath = Server.MapPath("/") & "\upload\agreement\"
|
||||
filename = request("filename")
|
||||
'<27>ٿ<EFBFBD><D9BF>ε<EFBFBD> <20><>ü<EFBFBD><C3BC><EFBFBD><EFBFBD>
|
||||
Set objDownload = Server.CreateObject("DEXT.FileDownload")
|
||||
'objDownload.Download(filepath, <20><><EFBFBD><EFBFBD><EFBFBD≯<EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(True:<3A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>), <20>̾<EFBFBD><CCBE>ޱ<EFBFBD> <20><><EFBFBD><EFBFBD>(True:<3A>̾<EFBFBD><CCBE>ޱ<EFBFBD>))
|
||||
objDownload.Download filepath & filename, filename, true, false
|
||||
Set objDownload = Nothing
|
||||
%>
|
||||
119
knowledge/agreement_list.asp
Normal file
119
knowledge/agreement_list.asp
Normal file
@@ -0,0 +1,119 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<%
|
||||
if request("gotopage") <> "" then
|
||||
tmp_currentpage = request("gotopage")
|
||||
else
|
||||
tmp_currentpage = 1
|
||||
end if
|
||||
%>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>༭</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 name="agreement_list" method="post">
|
||||
<%
|
||||
query = " SELECT TA.id, client_nm, client_date, client_per_nm, client_per_tel, P.p_name, TA.input_user, Convert(VARCHAR(10), TA.input_dt, 120) as input_dt, file_list "
|
||||
query = query & " FROM [T_AGREEMENT] TA LEFT OUTER JOIN Person P ON TA.input_user = P.p_no "
|
||||
query = query & " WHERE use_div = '1' "
|
||||
query = query & " ORDER BY id DESC "
|
||||
adors.open query, adoConn, 1
|
||||
tmp_adorsount = adors.recordCount
|
||||
%>
|
||||
<table width="100%" cellpadding="0" cellspacing="0" border="0">
|
||||
<tr>
|
||||
<td style="padding:5"><3E><><EFBFBD>ϰ<EFBFBD><CFB0><EFBFBD> : <20><> <b class="tahoma_orange"><%=tmp_adorsount%></b><3E><><EFBFBD><EFBFBD> <20><EFBFBD><D7B8><EFBFBD> <20>ֽ<EFBFBD><D6BD>ϴ<EFBFBD>.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center">
|
||||
<table class="table table-sm table-sm2 table-bordered table-head tr-colors mt-1">
|
||||
<tr>
|
||||
<td align="center" height="26" width="5%" >No.</td>
|
||||
<td align="center" height="26" ><3E><>ü<EFBFBD><C3BC></td>
|
||||
<td align="center" height="26" width="8%" ><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td align="center" height="26" width="15%" ><3E><>ü<EFBFBD><C3BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td align="center" height="26" width="10%" ><3E>ۼ<EFBFBD><DBBC><EFBFBD></td>
|
||||
<td align="center" height="26" width="15%" ><3E>ۼ<EFBFBD><DBBC><EFBFBD></td>
|
||||
<td align="center" height="26" width="5%" >÷<><C3B7></td>
|
||||
<td align="center" height="26" width="10%" ></td>
|
||||
</tr>
|
||||
<%
|
||||
if adors.RecordCount > 0 then
|
||||
adors.PageSize = 20
|
||||
|
||||
PageCount = adors.PageCount
|
||||
adors.absolutepage = tmp_Currentpage
|
||||
tmp_total_record = adors.RecordCount
|
||||
tmp_for = Cint(tmp_total_record) - ((Cint(tmp_Currentpage) - 1) * adors.PageSize)
|
||||
|
||||
if adors.PageSize <= tmp_for then
|
||||
if adors.RecordCount <= adors.PageSize then
|
||||
tmp_for = adors.recordcount
|
||||
else
|
||||
tmp_for = adors.PageSize
|
||||
end if
|
||||
else
|
||||
tmp_for = tmp_for
|
||||
end if
|
||||
|
||||
for i = 1 to tmp_for
|
||||
%>
|
||||
<!--- Loop Set Start --->
|
||||
<tr>
|
||||
<td align="center" ><%=adors("id")%></td>
|
||||
<td align="center" ><%=adors("client_nm")%></td>
|
||||
<td align="center" ><%=adors("client_date")%></td>
|
||||
<td align="center" ><%=adors("client_per_nm")%><%if adors("client_per_tel") <> "" Then %> (<%=adors("client_per_tel") %>)<%end if %></td>
|
||||
<td align="center" ><%=adors("p_name")%></td>
|
||||
<td align="center" ><%=adors("input_dt")%></td>
|
||||
<td align="center" ><a href="./a_downloads.asp?filename=<%= adors("file_list")%>" ><i class="fa fa-file"></i></a></td>
|
||||
<td align="center" ><%if cstr(adors("input_user")) = cstr(session("User_Number")) OR tmp_admin_chk = 1 then %><a href="javascript:delete_go('<%= adors("id")%>');" ><i class="fa fa-trash-alt"></i></a><% end if %></td>
|
||||
</tr>
|
||||
<!--- Loop Set End --->
|
||||
<%
|
||||
adors.MoveNext
|
||||
next
|
||||
end if
|
||||
%>
|
||||
<tr>
|
||||
<td colspan="8" align="right"><img src="/images/common/btn_write.jpg" align="absmiddle" onClick="write_go();" style="CURSOR:pointer;"></td>
|
||||
</tr>
|
||||
</table>
|
||||
<!--- Paging Start --->
|
||||
<%=Pagelist("agreement_list.asp",tmp_currentpage ,tmp_bcolor , "", pagecount, "")%>
|
||||
<!--- Paging End --->
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
function write_go(a) {
|
||||
document.agreement_list.action = "agreement_write.asp";
|
||||
document.agreement_list.submit();
|
||||
}
|
||||
|
||||
function delete_go(id) {
|
||||
if (confirm("<22><><EFBFBD><EFBFBD><EFBFBD>Ͻðڽ<C3B0><DABD>ϱ<EFBFBD>?")) {
|
||||
location.href = "./a_delete.asp?a_sn=" + id;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
96
knowledge/agreement_write.asp
Normal file
96
knowledge/agreement_write.asp
Normal file
@@ -0,0 +1,96 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>༭</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 name="agree_write" method="post" enctype="multipart/form-data">
|
||||
<table class="table table-sm table-sm2 table-bordered table-head tr-colors">
|
||||
<tr>
|
||||
<td class='text-right align-middle' width="260px"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü <20><></td>
|
||||
<td >
|
||||
<input type="text" name="client_nm" class='form-control' >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='text-right align-middle'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td >
|
||||
<input type="text" name="client_date" class='selectDate form-control' readonly>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='text-right align-middle'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD></td>
|
||||
<td >
|
||||
<input type="text" name="client_per_nm" class='form-control' >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='text-right align-middle'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>ó</td>
|
||||
<td >
|
||||
<input type="text" name="client_per_tel" class='form-control' >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='text-right align-middle'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>༭ ÷<><C3B7></td>
|
||||
<td >
|
||||
<input type="file" name="txtFileName" class='form-control' >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" class='text-center align-middle py-3'>
|
||||
<img src="/images/common/btn_write.jpg" align="absmiddle" onClick="goit()" style="CURSOR:pointer;">
|
||||
<img src="/images/common/btn_list.jpg" align="absmiddle" onClick="history.back()" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
$(function(){
|
||||
$(".selectDate").datepicker();
|
||||
});
|
||||
|
||||
function goit() {
|
||||
if (document.agree_write.client_nm.value.trim() == "") {
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü <20><><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.agree_write.client_nm.value = "";
|
||||
document.agree_write.client_nm.focus();
|
||||
return;
|
||||
}
|
||||
document.agree_write.client_nm.value = document.agree_write.client_nm.value.trim();
|
||||
|
||||
if (document.agree_write.client_per_nm.value.trim() == "") {
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.agree_write.client_per_nm.value = "";
|
||||
document.agree_write.client_per_nm.focus();
|
||||
return;
|
||||
}
|
||||
document.agree_write.client_per_nm.value = document.agree_write.client_per_nm.value.trim();
|
||||
if (document.agree_write.txtFileName.value.trim() == "") {
|
||||
alert("÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.agree_write.txtFileName.focus();
|
||||
return;
|
||||
}
|
||||
|
||||
document.agree_write.action = "agreement_writeok.asp";
|
||||
document.agree_write.submit();
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
124
knowledge/agreement_writeok.asp
Normal file
124
knowledge/agreement_writeok.asp
Normal file
@@ -0,0 +1,124 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
dim attach_file
|
||||
dim FileSizeCheck
|
||||
dim xup
|
||||
dim countfilename
|
||||
dim fileattach, filename, fileNameTemp, file , ext, filesize, bExist, upd ,Upload_Filename
|
||||
|
||||
'<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD> <20><>ü<EFBFBD><C3BC> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
Set xup = Server.CreateObject("SiteGalaxyUpload.Form")
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>⺻ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
set fso = server.createobject("scripting.filesystemobject")
|
||||
|
||||
'<27><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> request<73><74> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF><EFBFBD> <20>Ʒ<EFBFBD><C6B7><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ƾ<DEBE> <20>մϴ<D5B4>.
|
||||
|
||||
client_nm = TransSTR(xup("client_nm"))
|
||||
client_per_nm = TransSTR(xup("client_per_nm"))
|
||||
client_per_tel = TransSTR(xup("client_per_tel"))
|
||||
client_date = TransSTR(xup("client_date"))
|
||||
a_input_user = session("User_Number")
|
||||
|
||||
FileSizeCheck = 1 '<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ <20>ϴ<EFBFBD><CFB4><EFBFBD> 5Mbyte<74><65><EFBFBD>϶<EFBFBD><CFB6><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
fileattach = xup("txtFileName")
|
||||
If fileattach <> "" then
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>丮<EFBFBD>Դϴ<D4B4>. nt<6E><74><EFBFBD><EFBFBD><EFBFBD>̶<EFBFBD><CCB6><EFBFBD> <20><><EFBFBD><EFBFBD> everyone <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> write <20>۹̼<DBB9><CCBC><EFBFBD> <20>־<EFBFBD><D6BE><EFBFBD> <20><><EFBFBD><EFBFBD>...^^
|
||||
upd = Server.MapPath("/") & "\upload\agreement\"
|
||||
Response.Write upd
|
||||
'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
If (fso.FolderExists(upd)) Then
|
||||
else
|
||||
fso.CreateFolder(upd)' <20>ش<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
End If
|
||||
|
||||
attach_file = fileattach.FilePath
|
||||
|
||||
' <20>ø<EFBFBD><C3B8><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD≯<EFBFBD><CCB8><EFBFBD> <20>̾Ƴ<CCBE><C6B3><EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ߺ<EFBFBD><DFBA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ó<><C3B3><EFBFBD><EFBFBD> <20><><EFBFBD>ؼ<EFBFBD><D8BC><EFBFBD>...^^
|
||||
filename = Mid(attach_file, instrRev(attach_file, "\") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
file = Mid(filename, 1, instr(filename, ".") - 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> Ȯ<><C8AE><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
ext = Mid(filename, instr(filename, ".") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20>ӽ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
fileNameTemp = upd & filename
|
||||
|
||||
bExist = True
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>, <20≯<EFBFBD> <20>ڿ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>Դϴ<D4B4>. <20>ܼ<EFBFBD><DCBC><EFBFBD> 0<><30><EFBFBD><EFBFBD> 1<><31> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
countfilename = 0
|
||||
|
||||
While bExist
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ͼ<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ο<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
If (fso.FileExists(fileNameTemp)) Then
|
||||
countfilename = countfilename + 1
|
||||
fileNameTemp = upd & file & "_v" & countfilename & "." & ext
|
||||
filename = file & "_v" & countfilename & "." & ext
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
Else
|
||||
bExist = False
|
||||
End if
|
||||
Wend
|
||||
' FileSystemObject<63><74> <20>ݾ<EFBFBD><DDBE>ݴϴ<DDB4>.
|
||||
'Set fso = nothing
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>⸦ <20><><EFBFBD>մϴ<D5B4>.
|
||||
filesize = fileattach.Size
|
||||
'204800 = 200kb
|
||||
'5 * 200kb = 1mb
|
||||
'204800 * 5 = 1024000(1Mbyte)
|
||||
if filesize > 20480000 then '20Mbyte
|
||||
FileSizeCheck = 0
|
||||
else
|
||||
FileSizeCheck = 1
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD> <20><EFBFBD><DEBD>ϴ<EFBFBD>.
|
||||
fileattach.SaveAs fileNameTemp
|
||||
end if
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ε带 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
Else '' If fileattach <> "" then
|
||||
filesize = 0
|
||||
filename = ""
|
||||
End if
|
||||
Upload_Filename = filename
|
||||
|
||||
if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 10Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
'''log db<64><62> <20><><EFBFBD><EFBFBD>
|
||||
query = "INSERT INTO T_AGREEMENT "
|
||||
query = query & "(client_nm, client_date, client_per_nm, client_per_tel, file_list, file_size, input_user) "
|
||||
query = query & "VALUES "
|
||||
query = query & "('" & client_nm & "', "
|
||||
query = query & "'" & client_date & "', "
|
||||
query = query & "'" & client_per_nm & "', "
|
||||
query = query & "'" & client_per_tel & "', "
|
||||
query = query & "'" & filename & "', "
|
||||
query = query & "'" & filesize & "', "
|
||||
query = query & "'" & a_input_user & "') "
|
||||
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
end if 'if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
set xup = nothing
|
||||
set fso = nothing
|
||||
|
||||
if FileSizeCheck = 0 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 5Mbyte <20>̻<EFBFBD><CCBB≯<EFBFBD>
|
||||
Alert_Back("÷<><C3B7> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte<74><65><EFBFBD><EFBFBD> Ŀ<><C4BF> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ʽ<EFBFBD><CABD>ϴ<EFBFBD>")
|
||||
else
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
<script>
|
||||
alert("<22>Է<EFBFBD> <20>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
|
||||
location.href="agreement_list.asp";
|
||||
</script>
|
||||
<% end if%>
|
||||
21
knowledge/b_delok.asp
Normal file
21
knowledge/b_delok.asp
Normal file
@@ -0,0 +1,21 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
b_sn = request("b_sn")
|
||||
|
||||
query = "UPDATE [intranet_board] "
|
||||
query = query & "SET "
|
||||
query = query & " b_delok='Y' "
|
||||
query = query & "WHERE b_sn='" & b_sn & "' "
|
||||
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
<script>
|
||||
alert("<22><><EFBFBD><EFBFBD> <20>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
location.href = './b_list.asp?b_type=<%=b_type%>';
|
||||
</script>
|
||||
11
knowledge/b_downloads.asp
Normal file
11
knowledge/b_downloads.asp
Normal file
@@ -0,0 +1,11 @@
|
||||
<%@ Language=VBScript EnableSessionState="False"%>
|
||||
<%
|
||||
filepath = Server.MapPath("/") & "\upload\board\"
|
||||
|
||||
filename = request("filename")
|
||||
'<27>ٿ<EFBFBD><D9BF>ε<EFBFBD> <20><>ü<EFBFBD><C3BC><EFBFBD><EFBFBD>
|
||||
Set objDownload = Server.CreateObject("DEXT.FileDownload")
|
||||
'objDownload.Download(filepath, <20><><EFBFBD><EFBFBD><EFBFBD≯<EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(True:<3A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>), <20>̾<EFBFBD><CCBE>ޱ<EFBFBD> <20><><EFBFBD><EFBFBD>(True:<3A>̾<EFBFBD><CCBE>ޱ<EFBFBD>))
|
||||
objDownload.Download filepath & filename, filename, true, false
|
||||
Set objDownload = Nothing
|
||||
%>
|
||||
35
knowledge/b_file_delete_ajax.asp
Normal file
35
knowledge/b_file_delete_ajax.asp
Normal file
@@ -0,0 +1,35 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
b_sn = request("b_sn")
|
||||
file_name = unescape(request("file_name"))
|
||||
i = 0
|
||||
Response.CharSet = "EUC-KR"
|
||||
Response.AddHeader "Pragma","no-cache"
|
||||
Response.AddHeader "cache-control", "no-staff"
|
||||
Response.Expires = -1
|
||||
|
||||
query = ""
|
||||
query = query & " SELECT b_filename, b_filesize FROM intranet_board WHERE b_sn = '" & b_sn & "' "
|
||||
Adors.Open query, adoConn, 1
|
||||
If Adors.RecordCount > 0 Then
|
||||
arr_file_name = split(Adors("b_filename"), ",")
|
||||
arr_file_size = split(Adors("b_filesize"), ",")
|
||||
file_name_str = ""
|
||||
file_size_str = ""
|
||||
For i = LBound(arr_file_name) To UBound(arr_file_name)
|
||||
If arr_file_name(i) <> file_name AND arr_file_name(i) <> "" Then
|
||||
file_name_str = file_name_str & arr_file_name(i) & ","
|
||||
file_size_str = file_size_str & arr_file_size(i) & ","
|
||||
End if
|
||||
Next
|
||||
Else
|
||||
Response.Write "0"
|
||||
Response.End
|
||||
End If
|
||||
query = ""
|
||||
query = query & " UPDATE intranet_board SET b_filename = '" & file_name_str & "', b_filesize = '" & file_size_str & "' WHERE b_sn = '" & b_sn & "' "
|
||||
|
||||
adoConn.execute query
|
||||
|
||||
Response.Write "1"
|
||||
%>
|
||||
222
knowledge/b_list.asp
Normal file
222
knowledge/b_list.asp
Normal file
@@ -0,0 +1,222 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
searchtype = request("searchtype")
|
||||
if searchtype = "" then
|
||||
searchtype = "0"
|
||||
end if
|
||||
searchword = request("searchword")
|
||||
|
||||
if request("gotopage") <> "" then
|
||||
tmp_currentpage = request("gotopage")
|
||||
else
|
||||
tmp_currentpage = 1
|
||||
end if
|
||||
|
||||
tmp_menuname = ""
|
||||
Select case b_type
|
||||
case "not"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "con"
|
||||
tmp_menuname = "<22><><EFBFBD>ȿ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "rule"
|
||||
tmp_menuname = "<22>系<EFBFBD><E7B3BB><EFBFBD><EFBFBD>"
|
||||
case "sug"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD> <20>Ŵ<EFBFBD><C5B4><EFBFBD>"
|
||||
case "klg"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD>â<EFBFBD><C3A2>"
|
||||
case "fre"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
End Select
|
||||
%>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><%=tmp_menuname%></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 name="b_board" method="post">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<table width="100%" cellpadding="0" cellspacing="0" border="0">
|
||||
<%
|
||||
query = "SELECT * "
|
||||
query = query & "FROM [intranet_board] "
|
||||
query = query & "WHERE b_type='" & b_type & "' "
|
||||
if searchtype = "0" then
|
||||
query = query & "and b_subject like '%" & searchword & "%' "
|
||||
elseif searchtype = "1" then
|
||||
query = query & "and b_content like '%" & searchword & "%' "
|
||||
elseif searchtype = "2" then
|
||||
query = query & "and (b_subject like '%" & searchword & "%' or b_content like '%" & searchword & "%') "
|
||||
elseif searchtype = "3" then
|
||||
query = query & "and b_name like '%" & searchword & "%' "
|
||||
end if
|
||||
query = query & "AND b_delok='N' "
|
||||
query = query & "ORDER BY b_sn DESC "
|
||||
'Response.Write query & "<BR>"
|
||||
Rs.Open query, adoConn, 1
|
||||
%>
|
||||
<tr>
|
||||
<td style="padding:5"><3E><><EFBFBD>ϰ<EFBFBD><CFB0><EFBFBD> : <20><> <b class="tahoma_orange"><%=Rs.RecordCount%></b><3E><><EFBFBD><EFBFBD> <20><EFBFBD><D7B8><EFBFBD> <20>ֽ<EFBFBD><D6BD>ϴ<EFBFBD>.</td>
|
||||
<td align="right">
|
||||
<select id="searchType">
|
||||
<option value="0"><3E><><EFBFBD><EFBFBD></option>
|
||||
<option value="1"><3E><><EFBFBD><EFBFBD></option>
|
||||
<option value="2"><3E><><EFBFBD><EFBFBD>+<2B><><EFBFBD><EFBFBD></option>
|
||||
<option value="3"><3E>ۼ<EFBFBD><DBBC><EFBFBD></option>
|
||||
</select>
|
||||
<input type="text" id="searchWord" value="" />
|
||||
<input type="button" id="searchBtn" value="<22>˻<EFBFBD>" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" colspan="2">
|
||||
<table class="table table-sm table-sm2 table-bordered table-head tr-colors mt-1">
|
||||
<tr>
|
||||
<td align="center" height="26" width="2%" >No.</td>
|
||||
<td align="center" height="26" width="50%" ><3E><><EFBFBD><EFBFBD></td>
|
||||
<td align="center" height="26" ><3E>з<EFBFBD></td>
|
||||
<td align="center" height="26" ><3E>ۼ<EFBFBD><DBBC><EFBFBD></td>
|
||||
<td align="center" height="26" ><3E>ۼ<EFBFBD><DBBC><EFBFBD></td>
|
||||
<td align="center" height="26" ><3E><><EFBFBD><EFBFBD></td>
|
||||
<td align="center" height="26" >÷<><C3B7></td>
|
||||
</tr>
|
||||
|
||||
<%
|
||||
if Rs.RecordCount > 0 then
|
||||
Rs.PageSize = 20
|
||||
tmp_ok = 1
|
||||
PageCount = Rs.PageCount
|
||||
Rs.absolutepage = tmp_Currentpage
|
||||
tmp_total_record = Rs.RecordCount
|
||||
tmp_for = Cint(tmp_total_record) - ((Cint(tmp_Currentpage) - 1) * Rs.PageSize)
|
||||
|
||||
if Rs.PageSize <= tmp_for then
|
||||
if Rs.RecordCount <= Rs.PageSize then
|
||||
tmp_for = Rs.recordcount
|
||||
else
|
||||
tmp_for = Rs.PageSize
|
||||
end if
|
||||
else
|
||||
tmp_for = tmp_for
|
||||
end if
|
||||
|
||||
for i = 1 to tmp_for
|
||||
if Cint(tmp_Currentpage)=1 then
|
||||
Num=Cint(tmp_total_record)- i+1
|
||||
else
|
||||
Num=Cint(tmp_total_record) - ((Cint(tmp_Currentpage) - 1) * Rs.PageSize) - i +1
|
||||
end if
|
||||
|
||||
tmp_subject = Rs("b_subject")
|
||||
|
||||
query = " SELECT p_team_name as d_name FROM project2.dbo.V_Person WHERE p_no = '" & Rs("b_namecode") & "' "
|
||||
Adors.Open query, adoConn, 1
|
||||
if Adors.RecordCount > 0 then
|
||||
tmp_depart = Adors("d_name")
|
||||
else
|
||||
tmp_depart = "-"
|
||||
end if
|
||||
Adors.Close
|
||||
|
||||
if Rs("b_filename") <> "" then
|
||||
fileArray = Split(replace(Rs("b_filename"),",,",","),",")
|
||||
|
||||
tmp_file = Ubound(fileArray)
|
||||
If tmp_file=0 then
|
||||
tmp_file = 1
|
||||
End If
|
||||
tmp_file = tmp_file & "<22><>"
|
||||
else
|
||||
tmp_file = "-"
|
||||
end if
|
||||
|
||||
if isnull(Rs("b_reply_cnt")) OR Rs("b_reply_cnt") = "0" then
|
||||
tmp_reply_cnt = ""
|
||||
else
|
||||
tmp_reply_cnt = "[ " & Rs("b_reply_cnt") & " ]"
|
||||
end if
|
||||
%>
|
||||
<!--- Loop Set Start --->
|
||||
<tr>
|
||||
<td align="center" height="26" ><%=Num%></td>
|
||||
<td align="left" height="26"><a href="javascript:goit('2','<%=Rs("b_sn")%>')" class="blue"><%=tmp_subject%></a> <%=tmp_reply_cnt%></td>
|
||||
<td align="center" height="26"><%=tmp_depart%></td>
|
||||
<td align="center" height="26"><%=Rs("b_name")%></td>
|
||||
<td align="center" height="26" ><%=left(Rs("b_regdate"), 10)%></td>
|
||||
<td align="center" height="26" ><%=Rs("b_readcnt")%></td>
|
||||
<td align="center" height="26">
|
||||
<%=tmp_file%>
|
||||
</td>
|
||||
</tr>
|
||||
<!--- Loop Set End --->
|
||||
<%
|
||||
Rs.MoveNext
|
||||
next
|
||||
end if
|
||||
Rs.Close
|
||||
%>
|
||||
</table>
|
||||
<!--- Paging Start --->
|
||||
<%=Pagelist("b_list.asp",tmp_currentpage ,tmp_bcolor , "", pagecount, "&b_type=" & b_type & "&searchtype=" & searchtype & "&searchword=" & searchword)%>
|
||||
<!--- Paging End --->
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right" colspan="2">
|
||||
<img src="/images/common/btn_write.jpg" align="absmiddle" onClick="goit('1')" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
function goit(a, b){
|
||||
if (a == 1){
|
||||
document.b_board.action = "b_write.asp";
|
||||
document.b_board.submit();
|
||||
}else if (a == 2){
|
||||
document.b_board.action = "b_view.asp?b_sn=" + b;
|
||||
document.b_board.submit();
|
||||
}else if (a == 3){
|
||||
document.b_board.action = "b_list.asp";
|
||||
document.b_board.submit();
|
||||
}
|
||||
}
|
||||
|
||||
$(function(){
|
||||
$("#searchBtn").on("click", function(){
|
||||
var searchType = $("#searchType option:selected").val();
|
||||
var searchWord = $("#searchWord").val();
|
||||
searchWord = searchWord.replace(/'/g, "");
|
||||
|
||||
location.href="./b_list.asp?b_type=<%=b_type%>&searchtype=" + searchType + "&searchword=" + searchWord;
|
||||
});
|
||||
$("#searchWord").on("keyup", function(e){
|
||||
e.preventDefault();
|
||||
var keycode = event.which ? event.which : event.keyCode;
|
||||
if(keycode == 13){
|
||||
$("#searchBtn").click();
|
||||
}
|
||||
});
|
||||
$("#searchType").val("<%=searchtype%>");
|
||||
$("#searchWord").val("<%=searchword%>");
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
216
knowledge/b_modi.asp
Normal file
216
knowledge/b_modi.asp
Normal file
@@ -0,0 +1,216 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
b_sn = request("b_sn")
|
||||
tmp_menuname = ""
|
||||
Select case b_type
|
||||
case "not"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "con"
|
||||
tmp_menuname = "<22><><EFBFBD>ȿ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "rule"
|
||||
tmp_menuname = "<22>系<EFBFBD><E7B3BB><EFBFBD><EFBFBD>"
|
||||
case "sug"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD> <20>Ŵ<EFBFBD><C5B4><EFBFBD>"
|
||||
case "klg"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD>â<EFBFBD><C3A2>"
|
||||
case "fre"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
End Select
|
||||
%>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><%=tmp_menuname%></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 name="b_board" method="post" enctype="multipart/form-data">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<input type="hidden" name="b_sn" value="<%=b_sn%>">
|
||||
|
||||
<%
|
||||
query = "SELECT * "
|
||||
query = query & "FROM [intranet_board] "
|
||||
query = query & "WHERE b_type='" & b_type & "' "
|
||||
query = query & " AND b_sn='" & b_sn & "' "
|
||||
|
||||
Adors.Open query, adoConn, 1
|
||||
if Adors.RecordCount > 0 then
|
||||
Dim tmp_icon_array()
|
||||
if Adors("b_filename") <> "" then
|
||||
fileArray = Split(Adors("b_filename"),",")
|
||||
blcnt = 0
|
||||
For i=LBound(fileArray) To UBound(fileArray)
|
||||
if fileArray(i) = "" Then
|
||||
blcnt = blcnt + 1
|
||||
End If
|
||||
Next
|
||||
|
||||
arraycnt = cint(Ubound(fileArray))
|
||||
if arraycnt = 0 then
|
||||
arraycnt = 1
|
||||
end if
|
||||
reDim tmp_icon_array(arraycnt)
|
||||
|
||||
for i=0 To arraycnt-1
|
||||
|
||||
tmp_pro = right(fileArray(i), 3)
|
||||
|
||||
if lcase(tmp_pro)="zip" or lcase(tmp_pro)="hwp" or lcase(tmp_pro)="ppt" or lcase(tmp_pro)="xls" or lcase(tmp_pro)="pdf" or lcase(tmp_pro)="doc" or lcase(tmp_pro)="bmp" or lcase(tmp_pro)="jpg" then
|
||||
tmp_file_icon = "<IMG alt=" & fileArray(i) & " width='16' height='16' border=0 src=./images/common/icon_" & tmp_pro & ".gif align=absmiddle>"
|
||||
tmp_icon_array(i) = tmp_file_icon
|
||||
else
|
||||
tmp_file_icon = "<IMG alt=" & fileArray(i) & " width='16' height='16' border=0 src=/images/common/icon_etc.gif align=absmiddle>"
|
||||
tmp_icon_array(i) = tmp_file_icon
|
||||
end if
|
||||
|
||||
next
|
||||
end if
|
||||
%>
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<td width="10%" align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:0 10 0 10">
|
||||
<input type="text" name="b_subject" class='form-control' value="<%=Adors("b_subject")%>">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td height="26">
|
||||
<input type="hidden" name="fileCnt" value="<%=arraycnt - blcnt + 1%>" />
|
||||
<%
|
||||
for i=0 To arraycnt-1
|
||||
if fileArray(i)<>"" then
|
||||
%>
|
||||
<%=tmp_icon_array(i)%> <a href="b_downloads.asp?b_type=<%=b_type%>&filename=<%=Server.UrlEncode(fileArray(i))%>" class="blue"><%=fileArray(i)%></a>
|
||||
<%
|
||||
if int(Adors("b_namecode")) = int(session("User_Number")) or int(session("Depart_Code")) = 18 then
|
||||
%>
|
||||
<img src="/images/business/icon_del.gif" style="width:15px;cursor:pointer;" onclick="del_files('<%=b_sn %>', '<%=fileArray(i) %>')" alt="<22><><EFBFBD><EFBFBD>" />
|
||||
<%
|
||||
End if
|
||||
%>
|
||||
<%
|
||||
end if
|
||||
next
|
||||
%>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'>÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td height="26">
|
||||
<input type="file" name="txtFileName1" id="txtFileName1" style="width:calc(100% - 110px);display:inline-block;" class='form-control'>
|
||||
<input type="checkbox" id="2FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)"/>
|
||||
<input type="file" name="txtFileName2" id="txtFileName2" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="3FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName3" id="txtFileName3" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="4FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName4" id="txtFileName4" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="5FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName5" id="txtFileName5" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="6FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName6" id="txtFileName6" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="7FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName7" id="txtFileName7" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="8FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName8" id="txtFileName8" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'><font color="red">÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>߰<EFBFBD></font><br />
|
||||
<font class="brown"><3E>ִ<EFBFBD> 20Mb <20><><EFBFBD><EFBFBD> ÷<><C3B7> <20><><EFBFBD><EFBFBD></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:5">
|
||||
<textarea name="b_content" rows="20" class='form-control'><%=ViewWord(Adors("b_content"))%></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center" style="padding:10 0 10 0;">
|
||||
<img src="/images/common/btn_modify.jpg" align="absmiddle" onClick="goit('1')" style="CURSOR:pointer;">
|
||||
<img src="/images/common/btn_list.jpg" align="absmiddle" onClick="go_list();" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<% end if %>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
$(function(){
|
||||
currentMenu("/knowledge/b_list.asp", "?b_type=<%=b_type%>");
|
||||
});
|
||||
function goit(a){
|
||||
if (a == 1){
|
||||
if (document.b_board.b_subject.value.trim() == ""){
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.b_board.b_subject.value = "";
|
||||
document.b_board.b_subject.focus();
|
||||
return;
|
||||
}
|
||||
if (document.b_board.b_content.value.trim() == ""){
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.b_board.b_content.value = "";
|
||||
document.b_board.b_content.focus();
|
||||
return;
|
||||
}
|
||||
document.b_board.b_subject.value = document.b_board.b_subject.value.trim().replace(/'/g, "");
|
||||
document.b_board.b_content.value = document.b_board.b_content.value.trim().replace(/'/g, "");
|
||||
|
||||
document.b_board.action = "b_modiok.asp";
|
||||
document.b_board.submit();
|
||||
}
|
||||
}
|
||||
|
||||
function attachPM(checkid){
|
||||
var numb = checkid.substring(0,1);
|
||||
var checkYN = $("#"+checkid).is(":checked");
|
||||
var filecnt = document.b_board.fileCnt.value;
|
||||
|
||||
if (filecnt * 1 + numb * 1 > 8) {
|
||||
alert("<22>ִ<EFBFBD> 8<><38><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ϰ<EFBFBD><CFB0><EFBFBD><EFBFBD>մϴ<D5B4>.");
|
||||
$("#" + checkid).prop("checked", false);
|
||||
} else {
|
||||
if(checkYN){
|
||||
$("#txtFileName"+numb).removeClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").removeClass("d-none");
|
||||
$("#"+(numb*1-1)+"FileCall").addClass("d-none");
|
||||
}else{
|
||||
$("#txtFileName"+numb).addClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").addClass("d-none");
|
||||
$("#"+(numb*1-1)+"FileCall").removeClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").removeAttr("checked");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function del_files(b_sn, file_name) {
|
||||
var param = { b_sn: b_sn, file_name: escape(file_name) };
|
||||
if (confirm("<22><><EFBFBD><EFBFBD>ó<EFBFBD><C3B3><EFBFBD>Ͻðڽ<C3B0><DABD>ϱ<EFBFBD>?")) {
|
||||
ajaxCallJson("b_file_delete_ajax.asp", param, null, "post", "del_files_complete()", "", "");
|
||||
}
|
||||
}
|
||||
|
||||
function del_files_complete() {
|
||||
alert("<22><><EFBFBD><EFBFBD>ó<EFBFBD><C3B3><EFBFBD>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
location.href = "./b_modi.asp?b_sn=" + document.b_board.b_sn.value + "&b_type=" + document.b_board.b_type.value;
|
||||
}
|
||||
|
||||
function go_list(){
|
||||
location.href = "./b_list.asp?b_type=" + document.b_board.b_type.value;
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
143
knowledge/b_modiok.asp
Normal file
143
knowledge/b_modiok.asp
Normal file
@@ -0,0 +1,143 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
dim attach_file(8)
|
||||
dim attachCount
|
||||
dim flagSuss
|
||||
dim strRet
|
||||
dim tmpstr
|
||||
dim getmenu
|
||||
dim FileSizeCheck
|
||||
dim xup
|
||||
dim anonymousChk
|
||||
dim countfilename(8)
|
||||
dim fileattach(8), filename(8), fileNameTemp(8), file(8) , ext(8), filesize(8), bExist, upd ,Upload_Filename(8)
|
||||
|
||||
'<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD> <20><>ü<EFBFBD><C3BC> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
Set xup = Server.CreateObject("SiteGalaxyUpload.Form")
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>⺻ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
set fso = server.createobject("scripting.filesystemobject")
|
||||
|
||||
'<27><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> request<73><74> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF><EFBFBD> <20>Ʒ<EFBFBD><C6B7><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ƾ<DEBE> <20>մϴ<D5B4>.
|
||||
|
||||
b_sn = TransSTR(xup("b_sn"))
|
||||
b_type = TransSTR(xup("b_type"))
|
||||
b_name = session("loginuser")
|
||||
b_namecode = session("User_Number")
|
||||
b_departcode= session("Depart_Code")
|
||||
b_flag = TransSTR(xup("b_flag"))
|
||||
b_subject = TransSTR(xup("b_subject"))
|
||||
b_content = TransSTR(xup("b_content"))
|
||||
b_regdate = now()
|
||||
|
||||
FileSizeCheck = 1 '<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ <20>ϴ<EFBFBD><CFB4><EFBFBD> 5Mbyte<74><65><EFBFBD>϶<EFBFBD><CFB6><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
for i=1 to 8
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
fileattach(i) = xup("txtFileName"&i)
|
||||
If fileattach(i) <> "" then
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>丮<EFBFBD>Դϴ<D4B4>. nt<6E><74><EFBFBD><EFBFBD><EFBFBD>̶<EFBFBD><CCB6><EFBFBD> <20><><EFBFBD><EFBFBD> everyone <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> write <20>۹̼<DBB9><CCBC><EFBFBD> <20>־<EFBFBD><D6BE><EFBFBD> <20><><EFBFBD><EFBFBD>...^^
|
||||
upd = Server.MapPath("/") & "\upload\board\"
|
||||
'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
If not (fso.FolderExists(upd)) Then
|
||||
FSO.CreateFolder(upd)
|
||||
End If
|
||||
|
||||
attach_file(i) = fileattach(i).FilePath
|
||||
|
||||
' <20>ø<EFBFBD><C3B8><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD≯<EFBFBD><CCB8><EFBFBD> <20>̾Ƴ<CCBE><C6B3><EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ߺ<EFBFBD><DFBA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ó<><C3B3><EFBFBD><EFBFBD> <20><><EFBFBD>ؼ<EFBFBD><D8BC><EFBFBD>...^^
|
||||
filename(i) = Mid(attach_file(i), instrRev(attach_file(i), "\") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
file(i) = Mid(filename(i), 1, instr(filename(i), ".") - 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> Ȯ<><C8AE><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
ext(i) = Mid(filename(i), instr(filename(i), ".") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20>ӽ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
fileNameTemp(i) = upd & filename(i)
|
||||
|
||||
bExist = True
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>, <20≯<EFBFBD> <20>ڿ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>Դϴ<D4B4>. <20>ܼ<EFBFBD><DCBC><EFBFBD> 0<><30><EFBFBD><EFBFBD> 1<><31> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
countfilename(i) = 0
|
||||
|
||||
While bExist
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ͼ<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ο<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
If (fso.FileExists(fileNameTemp(i))) Then
|
||||
countfilename(i) = countfilename(i) + 1
|
||||
fileNameTemp(i) = upd & file(i) & "_v" & countfilename(i) & "." & ext(i)
|
||||
filename(i) = file(i) & "_v" & countfilename(i) & "." & ext(i)
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
Else
|
||||
bExist = False
|
||||
End if
|
||||
Wend
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>⸦ <20><><EFBFBD>մϴ<D5B4>.
|
||||
filesize(i) = fileattach(i).Size
|
||||
'204800 * 5 = 1024000(10Mbyte)
|
||||
if filesize(i) > 20480000 then '20Mbyte
|
||||
FileSizeCheck = 0
|
||||
else
|
||||
FileSizeCheck = 1
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD> <20><EFBFBD><DEBD>ϴ<EFBFBD>.
|
||||
fileattach(i).SaveAs fileNameTemp(i)
|
||||
end if
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ε带 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
Else '' If fileattach <> "" then
|
||||
filesize(i) = 0
|
||||
filename(i) = ""
|
||||
End if
|
||||
Upload_Filename(i) = filename(i)
|
||||
Next
|
||||
|
||||
if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 10Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
'''log db<64><62> <20><><EFBFBD><EFBFBD>
|
||||
query = "UPDATE [intranet_board] "
|
||||
query = query & "SET "
|
||||
query = query & " b_type='" & b_type & "', "
|
||||
query = query & " b_flag='" & b_flag & "', "
|
||||
query = query & " b_subject='" & b_subject & "', "
|
||||
query = query & " b_content='" & CheckWord(b_content) & "', "
|
||||
query = query & " b_filename=convert(varchar(1000),b_filename) "
|
||||
for i=1 to 8
|
||||
if fileattach(i) <> "" then
|
||||
query = query & " +'," & filename(i) & ",'"
|
||||
end if
|
||||
Next
|
||||
query = query & ", b_filesize=convert(varchar(1000),b_filesize) "
|
||||
for i=1 to 8
|
||||
if fileattach(i) <> "" then
|
||||
query = query & " +'," & filesize(i) & ",'"
|
||||
end if
|
||||
Next
|
||||
query = query & ", b_raddr='" & Request.ServerVariables("REMOTE_ADDR") & "' "
|
||||
query = query & "WHERE b_sn='" & b_sn & "' "
|
||||
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
|
||||
end if 'if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
set xup = nothing
|
||||
set fso = nothing
|
||||
|
||||
if FileSizeCheck = 0 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte <20>̻<EFBFBD><CCBB≯<EFBFBD>
|
||||
Alert_Back("÷<><C3B7> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte<74><65><EFBFBD><EFBFBD> Ŀ<><C4BF> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ʽ<EFBFBD><CABD>ϴ<EFBFBD>")
|
||||
else
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
<form name="b_board" method="post">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<input type="hidden" name="b_sn" value="<%=b_sn%>">
|
||||
</form>
|
||||
<script>
|
||||
alert("<22><><EFBFBD><EFBFBD> <20>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
document.b_board.action = 'b_view.asp';
|
||||
document.b_board.submit();
|
||||
</script>
|
||||
<%
|
||||
end if
|
||||
%>
|
||||
73
knowledge/b_reply_work.asp
Normal file
73
knowledge/b_reply_work.asp
Normal file
@@ -0,0 +1,73 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
b_sn = request("b_sn")
|
||||
r_sn = request("r_sn")
|
||||
r_content = CheckWord(request("r_content"))
|
||||
x = request("x") '1=<3D><><EFBFBD><EFBFBD>, 2=<3D><><EFBFBD><EFBFBD>
|
||||
|
||||
if x = "1" then
|
||||
query = "INSERT INTO intranet_board_reply "
|
||||
query = query & "(r_bsn, r_name, r_name_no, r_content, r_date, r_delok) "
|
||||
query = query & "VALUES "
|
||||
query = query & "('" & b_sn & "', "
|
||||
query = query & "'" & Session("loginuser") & "', "
|
||||
query = query & "'" & Session("User_Number") & "', "
|
||||
query = query & "'" & r_content & "', "
|
||||
query = query & "'" & date() & "', "
|
||||
query = query & "'N') "
|
||||
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
|
||||
query = "UPDATE intranet_board "
|
||||
query = query & "SET "
|
||||
query = query & " b_reply_cnt = ISNULL(b_reply_cnt, 0) + 1 "
|
||||
query = query & "WHERE b_delok = 'N' "
|
||||
query = query & " AND b_sn = '" & b_sn & "' "
|
||||
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
|
||||
elseif x = "2" then
|
||||
query = "DELETE FROM intranet_board_reply "
|
||||
query = query & "WHERE r_delok='N' "
|
||||
query = query & " AND r_sn = '" & r_sn & "' "
|
||||
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
|
||||
query = "UPDATE intranet_board "
|
||||
query = query & "SET "
|
||||
query = query & " b_reply_cnt = ISNULL(b_reply_cnt, 1) - 1 "
|
||||
query = query & "WHERE b_delok = 'N' "
|
||||
query = query & " AND b_sn = '" & b_sn & "' "
|
||||
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
end if
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=EUC-KR">
|
||||
<form name="b_board" method="post">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<input type="hidden" name="b_sn" value="<%=b_sn%>">
|
||||
</form>
|
||||
<script>
|
||||
<% If x = "1" Then %>
|
||||
alert("<22><><EFBFBD>ϵǾ<CFB5><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
document.b_board.action = 'b_view.asp';
|
||||
document.b_board.submit();
|
||||
<% ElseIf x = "2" Then %>
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
document.b_board.action = 'b_view.asp';
|
||||
document.b_board.submit();
|
||||
<% End If %>
|
||||
</script>
|
||||
221
knowledge/b_view.asp
Normal file
221
knowledge/b_view.asp
Normal file
@@ -0,0 +1,221 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
b_sn = request("b_sn")
|
||||
|
||||
'<27><><EFBFBD><EFBFBD> Ƚ<><C8BD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʈ
|
||||
query = "UPDATE [intranet_board] "
|
||||
query = query & "SET "
|
||||
query = query & " b_readcnt=b_readcnt+1 "
|
||||
query = query & "WHERE b_sn='" & b_sn & "' "
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
|
||||
query = "SELECT * "
|
||||
query = query & "FROM [intranet_board] "
|
||||
query = query & "WHERE b_type='" & b_type & "' "
|
||||
query = query & " AND b_sn='" & b_sn & "' "
|
||||
query = query & " AND b_delok='N' "
|
||||
'Response.Write query & "<BR>"
|
||||
Adors.Open query, adoConn, 1
|
||||
|
||||
Dim tmp_icon_array()
|
||||
if Adors("b_filename") <> "" then
|
||||
fileArray = Split(Adors("b_filename"),",")
|
||||
|
||||
arraycnt = cint(Ubound(fileArray))
|
||||
if arraycnt = 0 then
|
||||
arraycnt = 1
|
||||
end if
|
||||
reDim tmp_icon_array(arraycnt)
|
||||
|
||||
for i=0 To arraycnt-1
|
||||
|
||||
tmp_pro = right(fileArray(i), 3)
|
||||
|
||||
if lcase(tmp_pro)="zip" or lcase(tmp_pro)="hwp" or lcase(tmp_pro)="ppt" or lcase(tmp_pro)="xls" or lcase(tmp_pro)="pdf" or lcase(tmp_pro)="doc" or lcase(tmp_pro)="bmp" or lcase(tmp_pro)="jpg" then
|
||||
tmp_file_icon = "<img alt=" & fileArray(i) & " width='16' height='16' border=0 src='/images/common/icon_" & tmp_pro & ".gif' align=absmiddle>"
|
||||
tmp_icon_array(i) = tmp_file_icon
|
||||
else
|
||||
tmp_file_icon = "<img alt=" & fileArray(i) & " width='16' height='16' border=0 src='/images/common/icon_etc.gif' align=absmiddle>"
|
||||
tmp_icon_array(i) = tmp_file_icon
|
||||
end if
|
||||
|
||||
next
|
||||
end if
|
||||
tmp_menuname = ""
|
||||
Select case b_type
|
||||
case "not"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "con"
|
||||
tmp_menuname = "<22><><EFBFBD>ȿ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "rule"
|
||||
tmp_menuname = "<22>系<EFBFBD><E7B3BB><EFBFBD><EFBFBD>"
|
||||
case "sug"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD> <20>Ŵ<EFBFBD><C5B4><EFBFBD>"
|
||||
case "klg"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD>â<EFBFBD><C3A2>"
|
||||
case "fre"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
End Select
|
||||
%>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><%=tmp_menuname%></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 name="b_board" method="post">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<input type="hidden" name="b_sn" value="<%=b_sn%>">
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<td width="10%" align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:0 0 0 10"><font class="brown"><%=Adors("b_subject")%></font></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'><3E>ۼ<EFBFBD><DBBC><EFBFBD></td>
|
||||
<td height="26" style="padding:0 0 0 10"><%=Adors("b_name")%></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'>÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:0 0 0 10">
|
||||
<%
|
||||
for i=0 To arraycnt-1
|
||||
if fileArray(i) <>"" then
|
||||
%>
|
||||
<%=tmp_icon_array(i)%> <a href="b_downloads.asp?b_type=<%=b_type%>&filename=<%=Server.UrlEncode(fileArray(i))%>" class="blue"><%=fileArray(i)%></a><br />
|
||||
<%
|
||||
end if
|
||||
next
|
||||
%>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:5">
|
||||
<textarea name="b_content" rows="20" class='form-control' readonly><%=ViewWord(Adors("b_content"))%></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="right" style="padding:10 0 10 0;">
|
||||
<%
|
||||
if int(Adors("b_namecode")) = int(session("User_Number")) or int(session("Depart_Code")) = 18 then
|
||||
%>
|
||||
<img src="/images/common/btn_modify.jpg" align="absmiddle" onClick="goit('2','<%=Adors("b_sn")%>')" style="CURSOR:pointer;">
|
||||
<img src="/images/common/btn_delete.jpg" align="absmiddle" onClick="goit('3','<%=Adors("b_sn")%>')" style="CURSOR:pointer;">
|
||||
<%
|
||||
end if
|
||||
%>
|
||||
<img src="/images/common/btn_list.jpg" align="absmiddle" onClick="goit('1')" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Reply List Start -->
|
||||
<%
|
||||
query = "SELECT * "
|
||||
query = query & "FROM intranet_board_reply "
|
||||
query = query & "WHERE r_delok = 'N' "
|
||||
query = query & " AND r_bsn = '" & b_sn & "' "
|
||||
query = query & "ORDER BY r_date, r_sn "
|
||||
|
||||
Rs.Open query, adoConn, 1
|
||||
if Rs.RecordCount > 0 then
|
||||
for i = 1 to Rs.RecordCount
|
||||
%>
|
||||
<tr>
|
||||
<td align="center" class='bg-cell py-2' ><%=Rs("r_name")%></td>
|
||||
<td class="py-2">
|
||||
<%=ViewWord(Rs("r_content"))%>
|
||||
<span style='font-size:11px;'> - (<%=Rs("r_date")%>)</span>
|
||||
<img src="/images/common/btn_reply_del.jpg" onClick="delit('<%=Rs("r_sn")%>')" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
<%
|
||||
Rs.MoveNext
|
||||
next
|
||||
end if
|
||||
Rs.Close
|
||||
%>
|
||||
<!-- Reply List End -->
|
||||
<!--- Reply Write Form Start --->
|
||||
<tr>
|
||||
<td colspan="2" class='p-0 pt-3'>
|
||||
<table class="table table-sm table-sm2 table-bordered table-head tr-colors border-top mb-0">
|
||||
<tr>
|
||||
<td width="10%" align="center" class='align-middle' ><3E><><EFBFBD>۾<EFBFBD><DBBE><EFBFBD></td>
|
||||
<td style="padding:5" rowspan="2">
|
||||
<textarea name="r_content" rows="3" class="form-control"></textarea>
|
||||
</td>
|
||||
<td rowspan="2" width="75px">
|
||||
<img src="/images/common/btn_reply.jpg" align="absmiddle" onClick="repit();" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center"class='align-middle' ><%=Session("loginuser")%></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!--- Reply Write Form End --->
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
$(function(){
|
||||
currentMenu("/knowledge/b_list.asp", "?b_type=<%=b_type%>");
|
||||
});
|
||||
|
||||
function goit(a,b){
|
||||
if (a == 1){
|
||||
document.b_board.action = "b_list.asp?b_type=<%=b_type%>";
|
||||
document.b_board.submit();
|
||||
}else if (a == 2){
|
||||
document.b_board.action = "b_modi.asp?b_sn=" + b;
|
||||
document.b_board.submit();
|
||||
}else if (a == 3){
|
||||
if (confirm("<22><><EFBFBD><EFBFBD><EFBFBD>Ͻðڽ<C3B0><DABD>ϱ<EFBFBD>?")){
|
||||
document.b_board.action = "b_delok.asp?b_sn=" + b;
|
||||
document.b_board.submit();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function repit(){
|
||||
if (document.b_board.r_content.value.trim() == ""){
|
||||
alert("<22><><EFBFBD><EFBFBD> <20>ۼ<EFBFBD><DBBC><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.b_board.r_content.value = "";
|
||||
document.b_board.r_content.focus();
|
||||
return false;
|
||||
}
|
||||
|
||||
document.b_board.action = "b_reply_work.asp?x=1";
|
||||
document.b_board.submit();
|
||||
}
|
||||
|
||||
function delit(a){
|
||||
if (confirm("<22><><EFBFBD><EFBFBD><EFBFBD>Ͻðڽ<C3B0><DABD>ϱ<EFBFBD>?")){
|
||||
document.b_board.action = "b_reply_work.asp?x=2&r_sn=" + a;
|
||||
document.b_board.submit();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
130
knowledge/b_write.asp
Normal file
130
knowledge/b_write.asp
Normal file
@@ -0,0 +1,130 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<%
|
||||
b_type = request("b_type")
|
||||
tmp_menuname = ""
|
||||
Select case b_type
|
||||
case "not"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "con"
|
||||
tmp_menuname = "<22><><EFBFBD>ȿ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
case "rule"
|
||||
tmp_menuname = "<22>系<EFBFBD><E7B3BB><EFBFBD><EFBFBD>"
|
||||
case "sug"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD> <20>Ŵ<EFBFBD><C5B4><EFBFBD>"
|
||||
case "klg"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD>â<EFBFBD><C3A2>"
|
||||
case "fre"
|
||||
tmp_menuname = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||||
End Select
|
||||
%>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><%=tmp_menuname%></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 name="b_board" method="post" enctype="multipart/form-data">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<td width="10%" align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:0 10 0 10">
|
||||
<input type="text" name="b_subject" class='form-control'>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'>÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD></td>
|
||||
<td height="26">
|
||||
<input type="file" name="txtFileName1" id="txtFileName1" style="width:calc(100% - 110px);display:inline-block;" class='form-control'>
|
||||
<input type="checkbox" id="2FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)"/>
|
||||
<input type="file" name="txtFileName2" id="txtFileName2" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="3FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName3" id="txtFileName3" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="4FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName4" id="txtFileName4" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="5FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName5" id="txtFileName5" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="6FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName6" id="txtFileName6" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="7FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName7" id="txtFileName7" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'>
|
||||
<input type="checkbox" id="8FileCall" value="1" style="display:inline-block;" onclick="attachPM(this.id)" class='d-none'/>
|
||||
<input type="file" name="txtFileName8" id="txtFileName8" style="width:calc(100% - 110px);display:inline-block;" class='form-control d-none'><font color="red">÷<><C3B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>߰<EFBFBD></font><br />
|
||||
<font class="brown"><3E>ִ<EFBFBD> 20Mb <20><><EFBFBD><EFBFBD> ÷<><C3B7> <20><><EFBFBD><EFBFBD></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" height="26" class='bg-dark'><3E><><EFBFBD><EFBFBD></td>
|
||||
<td height="26" style="padding:5">
|
||||
<textarea name="b_content" rows="20" class='form-control'></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center" style="padding:10 0 10 0;">
|
||||
<img src="/images/common/btn_write.jpg" align="absmiddle" onClick="goit('1')" style="CURSOR:pointer;">
|
||||
<img src="/images/common/btn_list.jpg" align="absmiddle" onClick="history.back()" style="CURSOR:pointer;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
$(function(){
|
||||
currentMenu("/knowledge/b_list.asp", "?b_type=<%=b_type%>");
|
||||
});
|
||||
|
||||
function goit(a){
|
||||
if (a == 1){
|
||||
if (document.b_board.b_subject.value.trim() == ""){
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.b_board.b_subject.value = "";
|
||||
document.b_board.b_subject.focus();
|
||||
return;
|
||||
}
|
||||
if (document.b_board.b_content.value.trim() == ""){
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD> <20>ּ<EFBFBD><D6BC><EFBFBD>");
|
||||
document.b_board.b_content.value = "";
|
||||
document.b_board.b_content.focus();
|
||||
return;
|
||||
}
|
||||
document.b_board.b_subject.value = document.b_board.b_subject.value.trim().replace(/'/g, "");
|
||||
document.b_board.b_content.value = document.b_board.b_content.value.trim().replace(/'/g, "");
|
||||
|
||||
document.b_board.action = "b_writeok.asp";
|
||||
document.b_board.submit();
|
||||
}
|
||||
}
|
||||
|
||||
function attachPM(checkid){
|
||||
var numb = checkid.substring(0,1);
|
||||
var checkYN = $("#"+checkid).is(":checked");
|
||||
|
||||
if(checkYN){
|
||||
$("#txtFileName"+numb).removeClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").removeClass("d-none");
|
||||
$("#"+(numb*1-1)+"FileCall").addClass("d-none");
|
||||
}else{
|
||||
$("#txtFileName"+numb).addClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").addClass("d-none");
|
||||
$("#"+(numb*1-1)+"FileCall").removeClass("d-none");
|
||||
$("#"+(numb*1+1)+"FileCall").removeAttr("checked");
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
153
knowledge/b_writeok.asp
Normal file
153
knowledge/b_writeok.asp
Normal file
@@ -0,0 +1,153 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<%
|
||||
dim attach_file(8)
|
||||
dim attachCount
|
||||
dim flagSuss
|
||||
dim strRet
|
||||
dim tmpstr
|
||||
dim getmenu
|
||||
dim FileSizeCheck
|
||||
dim xup
|
||||
dim anonymousChk
|
||||
dim countfilename(8)
|
||||
dim fileattach(8), filename(8), fileNameTemp(8), file(8) , ext(8), filesize(8), bExist, upd ,Upload_Filename(8)
|
||||
|
||||
'<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD> <20><>ü<EFBFBD><C3BC> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
Set xup = Server.CreateObject("SiteGalaxyUpload.Form")
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>⺻ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>.
|
||||
set fso = server.createobject("scripting.filesystemobject")
|
||||
|
||||
'<27><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> request<73><74> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ<EFBFBD><C6AE><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF><EFBFBD> <20>Ʒ<EFBFBD><C6B7><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ƾ<DEBE> <20>մϴ<D5B4>.
|
||||
|
||||
b_type = TransSTR(xup("b_type"))
|
||||
b_name = session("loginuser")
|
||||
b_namecode = session("User_Number")
|
||||
b_departcode= session("Depart_Code")
|
||||
b_flag = TransSTR(xup("b_flag"))
|
||||
b_subject = TransSTR(xup("b_subject"))
|
||||
b_content = TransSTR(xup("b_content"))
|
||||
b_regdate = now()
|
||||
|
||||
FileSizeCheck = 1 '<27><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ <20>ϴ<EFBFBD><CFB4><EFBFBD> 5Mbyte<74><65><EFBFBD>϶<EFBFBD><CFB6><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
for i=1 to 8
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD><CEB5><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
fileattach(i) = xup("txtFileName"&i)
|
||||
If fileattach(i) <> "" then
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>丮<EFBFBD>Դϴ<D4B4>. nt<6E><74><EFBFBD><EFBFBD><EFBFBD>̶<EFBFBD><CCB6><EFBFBD> <20><><EFBFBD><EFBFBD> everyone <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> write <20>۹̼<DBB9><CCBC><EFBFBD> <20>־<EFBFBD><D6BE><EFBFBD> <20><><EFBFBD><EFBFBD>...^^
|
||||
upd = Server.MapPath("/") & "\upload\board\"
|
||||
'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
If Not (fso.FolderExists(upd)) Then
|
||||
fso.CreateFolder(upd)
|
||||
End If
|
||||
|
||||
attach_file(i) = fileattach(i).FilePath
|
||||
|
||||
' <20>ø<EFBFBD><C3B8><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD≯<EFBFBD><CCB8><EFBFBD> <20>̾Ƴ<CCBE><C6B3><EFBFBD> <20>κ<EFBFBD><CEBA>Դϴ<D4B4>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ߺ<EFBFBD><DFBA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ó<><C3B3><EFBFBD><EFBFBD> <20><><EFBFBD>ؼ<EFBFBD><D8BC><EFBFBD>...^^
|
||||
filename(i) = Mid(attach_file(i), instrRev(attach_file(i), "\") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
file(i) = Mid(filename(i), 1, instr(filename(i), ".") - 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD> Ȯ<><C8AE><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD>մϴ<D5B4>.
|
||||
ext(i) = Mid(filename(i), instr(filename(i), ".") + 1)
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20>ӽ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
fileNameTemp(i) = upd & filename(i)
|
||||
|
||||
bExist = True
|
||||
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>, <20≯<EFBFBD> <20>ڿ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>Դϴ<D4B4>. <20>ܼ<EFBFBD><DCBC><EFBFBD> 0<><30><EFBFBD><EFBFBD> 1<><31> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
countfilename(i) = 0
|
||||
|
||||
While bExist
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ͼ<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD><CCB8><EFBFBD> <20><><EFBFBD>ڸ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ο<EFBFBD> <20><><EFBFBD><EFBFBD> <20≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
If (fso.FileExists(fileNameTemp(i))) Then
|
||||
countfilename(i) = countfilename(i) + 1
|
||||
fileNameTemp(i) = upd & file(i) & "_v" & countfilename(i) & "." & ext(i)
|
||||
filename(i) = file(i) & "_v" & countfilename(i) & "." & ext(i)
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
Else
|
||||
bExist = False
|
||||
End if
|
||||
Wend
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>⸦ <20><><EFBFBD>մϴ<D5B4>.
|
||||
filesize(i) = fileattach(i).Size
|
||||
'204800 * 5 = 1024000(1Mbyte)
|
||||
if filesize(i) > 20480000 then '20Mbyte
|
||||
FileSizeCheck = 0
|
||||
else
|
||||
FileSizeCheck = 1
|
||||
' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ε<EFBFBD> <20><EFBFBD><DEBD>ϴ<EFBFBD>.
|
||||
fileattach(i).SaveAs fileNameTemp(i)
|
||||
end if
|
||||
' <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ε带 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.
|
||||
Else '' If fileattach <> "" then
|
||||
filesize(i) = 0
|
||||
filename(i) = ""
|
||||
End if
|
||||
Upload_Filename(i) = filename(i)
|
||||
Next
|
||||
|
||||
if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 10Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
'''log db<64><62> <20><><EFBFBD><EFBFBD>
|
||||
query = "INSERT INTO intranet_board "
|
||||
query = query & "(b_type, b_namecode, b_name, b_departcode, b_flag, b_notify, b_subject, b_content, b_readcnt, b_regdate, b_raddr, b_filename, b_filesize, b_delok) "
|
||||
query = query & "VALUES "
|
||||
query = query & "('" & b_type & "', "
|
||||
query = query & "'" & b_namecode & "', "
|
||||
query = query & "'" & b_name & "', "
|
||||
query = query & "'" & b_departcode & "', "
|
||||
query = query & "'" & b_flag & "', "
|
||||
query = query & "'', "
|
||||
query = query & "'" & b_subject & "', "
|
||||
query = query & "'" & CheckWord(b_content) & "', "
|
||||
query = query & "'0', "
|
||||
query = query & "'" & now() & "', "
|
||||
query = query & "'" & Request.ServerVariables("REMOTE_ADDR") & "', '"
|
||||
|
||||
for i=1 to 8
|
||||
If filename(i) <> "" then
|
||||
query = query & filename(i) &","
|
||||
Else
|
||||
query = query & ""
|
||||
end If
|
||||
Next
|
||||
query = query & "' , '"
|
||||
for i=1 to 8
|
||||
If filename(i) <> "" then
|
||||
query = query & filesize(i) &","
|
||||
Else
|
||||
query = query & ""
|
||||
end If
|
||||
Next
|
||||
query = query & "' , 'N') "
|
||||
|
||||
'Response.Write query
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
dbin.Execute query
|
||||
dbin.Close
|
||||
'----------------------------------------------------------
|
||||
end if 'if FileSizeCheck = 1 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte <20><><EFBFBD><EFBFBD><EFBFBD>̰ų<CCB0> <20><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
set xup = nothing
|
||||
set fso = nothing
|
||||
|
||||
if FileSizeCheck = 0 then '<27><><EFBFBD>ε<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte <20>̻<EFBFBD><CCBB≯<EFBFBD>
|
||||
Alert_Back("÷<><C3B7> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ũ<>Ⱑ 20Mbyte<74><65><EFBFBD><EFBFBD> Ŀ<><C4BF> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ʽ<EFBFBD><CABD>ϴ<EFBFBD>")
|
||||
else
|
||||
%>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
|
||||
<form name="b_board" method="post">
|
||||
<input type="hidden" name="b_type" value="<%=b_type%>">
|
||||
</form>
|
||||
<script>
|
||||
alert("<22>Է<EFBFBD> <20>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
document.b_board.action = 'b_list.asp';
|
||||
document.b_board.submit();
|
||||
</script>
|
||||
<%
|
||||
end if
|
||||
%>
|
||||
493
knowledge/design_library.asp
Normal file
493
knowledge/design_library.asp
Normal file
@@ -0,0 +1,493 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<div id="loadingDiv"><div id="loadingMent">Design Library <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ֽ<EFBFBD>ȭ<EFBFBD>ϴ<EFBFBD> <20><><EFBFBD>Դϴ<D4B4>...</div></div>
|
||||
<style>
|
||||
#container{
|
||||
background-color:#eaeaea;
|
||||
min-width:1200px;
|
||||
}
|
||||
#description{
|
||||
height: 90px;
|
||||
padding: 3px 18px;
|
||||
font-size: 15px;
|
||||
font-weight: bold;
|
||||
letter-spacing: 0px;
|
||||
line-height: 27px;
|
||||
box-sizing: border-box;
|
||||
background-color: #eaeaea;
|
||||
border: 15px solid #d8d8d8;
|
||||
position:relative;
|
||||
}
|
||||
.btn{
|
||||
display: inline-block;
|
||||
padding: 2px 15px;
|
||||
border-radius: 5px;
|
||||
background-color: #d8d8d8 !important;
|
||||
color: #000;
|
||||
box-shadow: 1px 1px 1px 1px #6b6b6b;
|
||||
cursor: pointer;
|
||||
}
|
||||
#refreshLib{
|
||||
background: url(/images/knowledge/refresh.png) 93px center no-repeat;
|
||||
position: absolute;
|
||||
right: 10px;
|
||||
bottom: 13px;
|
||||
width: 134px;
|
||||
font-size: 1.25em;
|
||||
padding-right: 36px;
|
||||
}
|
||||
#pathTree{
|
||||
width: 346px;
|
||||
height: 620px;
|
||||
overflow-y: scroll;
|
||||
padding: 10px;
|
||||
display:inline-block;
|
||||
}
|
||||
#pathTree *:not(i){
|
||||
font-size: 14px;
|
||||
letter-spacing: 0px;
|
||||
}
|
||||
.tj_container ul{
|
||||
padding-left: 1em;
|
||||
}
|
||||
#fileInfo{
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
width: calc(100% - 384px);
|
||||
margin: 15px;
|
||||
}
|
||||
#topInfo{
|
||||
width: 100%;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
#pathInfo{
|
||||
width: 69%;
|
||||
height: 30px;
|
||||
border-radius: 15px;
|
||||
display: inline-block;
|
||||
padding: 5px 20px;
|
||||
background-color: #d8d8d8;
|
||||
box-sizing: border-box;
|
||||
font-size: 17px;
|
||||
}
|
||||
#saerchForm{
|
||||
display: inline-block;
|
||||
width: 30%;
|
||||
height: 30px;
|
||||
vertical-align: top;
|
||||
text-align: right;
|
||||
}
|
||||
#searchKeyword{
|
||||
height: 30px;
|
||||
width: 240px;
|
||||
border: none;
|
||||
background: url(/images/knowledge/search_icon.png) 210px center no-repeat;
|
||||
background-color: #d8d8d8;
|
||||
border-radius: 15px;
|
||||
padding: 3px 35px 3px 15px;
|
||||
font-size: 15px;
|
||||
}
|
||||
#fileContents{
|
||||
display: inline-block;
|
||||
background-color: #fff;
|
||||
width: 100%;
|
||||
padding-top: 10px;
|
||||
height: 555px;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
#baseMessage{
|
||||
text-align: center;
|
||||
font-size: 23px;
|
||||
font-weight: bold;
|
||||
top: 50%;
|
||||
position: relative;
|
||||
}
|
||||
#progress{
|
||||
position: absolute;
|
||||
left: 10px;
|
||||
width: calc(100% - 20px);
|
||||
top: 90px;
|
||||
height: calc(100% - 52px - 38px);
|
||||
background-color: rgba(255,255,255,0.4);
|
||||
display:none;
|
||||
}
|
||||
#progressDiv{
|
||||
position: absolute;
|
||||
width: 500px;
|
||||
height: 28px;
|
||||
top: calc(50% - 80px);
|
||||
left: calc(50% - 250px);
|
||||
background-color: #eaeaea;
|
||||
border-radius: 5px;
|
||||
border: 3px solid #172f59;
|
||||
}
|
||||
#progressBar{
|
||||
background-color: #ffd700;
|
||||
width: 0%;
|
||||
height: 100%;
|
||||
}
|
||||
#progressCnt{
|
||||
position: absolute;
|
||||
top: -1px;
|
||||
width: 300px;
|
||||
height: 16px;
|
||||
font-size: 16px;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
left: calc(50% - 150px);
|
||||
}
|
||||
#loadingDiv{
|
||||
background: url(/images/loadingBar.gif) no-repeat center;
|
||||
background-size: 240px;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
left:0;
|
||||
top:0;
|
||||
background-color: rgba(255,255,255,0.4);
|
||||
text-align:center;
|
||||
position: absolute;
|
||||
z-index: 5001;
|
||||
display:none;
|
||||
}
|
||||
#loadingMent{
|
||||
font-size: 20px;
|
||||
font-weight:bold;
|
||||
position: relative;
|
||||
top: calc(50% + 134px);
|
||||
}
|
||||
.filePreview{
|
||||
display: inline-block;
|
||||
width: 220px;
|
||||
height: 170px;
|
||||
margin: 5px;
|
||||
vertical-align: top;
|
||||
}
|
||||
.filePreview a{
|
||||
text-decoration: none;
|
||||
}
|
||||
.filePreview div{
|
||||
text-align: center;
|
||||
height: 80%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
/* justify-content: center; */
|
||||
}
|
||||
.filePreview div img{
|
||||
display: block;
|
||||
max-width: 95%;
|
||||
max-height: 90%;
|
||||
padding: 5px;
|
||||
margin: 2px auto;
|
||||
}
|
||||
.filePreview img.transBack{
|
||||
background: url(/images/knowledge/trans_back.png);
|
||||
}
|
||||
.filePreview span{
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 22px;
|
||||
font-size: 14px;
|
||||
color: #000;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
overflow-x: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1>Design Library</h1>
|
||||
</div>
|
||||
<!-- /.content-header -->
|
||||
<!-- Main content -->
|
||||
<div class="content-body">
|
||||
<div class="content">
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div id="container">
|
||||
<div id="description">
|
||||
Design Library<72><79> <20><><EFBFBD>ȼ<EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><>Ÿ <20>ڷῡ <20>ʿ<EFBFBD><CABF><EFBFBD> <20>ҽ<EFBFBD><D2BD><EFBFBD> <20>ٿ<EFBFBD><D9BF><EFBFBD> Ȱ<><C8B0><EFBFBD>Ͻ<EFBFBD> <20><> <20>ִ<EFBFBD> <20>Խ<EFBFBD><D4BD><EFBFBD><EFBFBD>Դϴ<D4B4>.<br>
|
||||
<20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>۱<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Ӱ<EFBFBD> <20>̿<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>մϴ<D5B4>.
|
||||
<% If Session("Depart_Code") = "18" Then %>
|
||||
<span class='btn' id="refreshLib">Update</span>
|
||||
<% End If %>
|
||||
</div>
|
||||
<div id="pathTree"></div>
|
||||
<div id="fileInfo">
|
||||
<div id="topInfo">
|
||||
<div id="pathInfo"></div>
|
||||
<div id="saerchForm">
|
||||
<input type="text" id="searchKeyword" value="" maxlength="50" />
|
||||
</div>
|
||||
</div>
|
||||
<div id="fileContents">
|
||||
<div id="baseMessage"><3E><><EFBFBD><EFBFBD> <20><><EFBFBD>Ͽ<EFBFBD><CFBF><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ּ<EFBFBD><D6BC><EFBFBD>.</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="progress"><div id="progressDiv"><div id="progressBar"></div><div id="progressCnt"></div></div></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<%
|
||||
Dim pathTreeSQL, fileListSQL
|
||||
pathTreeSQL = ""
|
||||
pathTreeSQL = pathTreeSQL & " SELECT tpath, tidx "
|
||||
pathTreeSQL = pathTreeSQL & " FROM T_DESIGN_TREE "
|
||||
|
||||
fileListSQL = ""
|
||||
fileListSQL = fileListSQL & " SELECT REPLACE('[' + STUFF(( "
|
||||
fileListSQL = fileListSQL & " SELECT "
|
||||
fileListSQL = fileListSQL & " ',{""fpath"":""' + fpath + '""' "
|
||||
fileListSQL = fileListSQL & " + ',""fname"":""' + fname + '""' "
|
||||
fileListSQL = fileListSQL & " + ',""fext"":""' + fext + '""' "
|
||||
fileListSQL = fileListSQL & " +'}' "
|
||||
fileListSQL = fileListSQL & " FROM T_DESIGN_FILE "
|
||||
fileListSQL = fileListSQL & " FOR XML PATH('')), 1, 1, '') + ']', '&', '&') AS jsonStr "
|
||||
%>
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
var pathTree = <%= queryToJson(pathTreeSQL) %>;
|
||||
<%
|
||||
Rs.open fileListSQL, adoConn, 1
|
||||
%>
|
||||
var fileList = <%= Rs("jsonStr") %>;
|
||||
<%
|
||||
Rs.Close
|
||||
%>
|
||||
var sid = "";
|
||||
var rootName = "design library";
|
||||
var setTimeoutObj = undefined;
|
||||
var treeDiv = undefined;
|
||||
|
||||
var totalCnt = 0;
|
||||
var nowCnt = 0;
|
||||
$(function(){
|
||||
var knasID = "admin";
|
||||
var knasPW = "krco#51304";
|
||||
var loginSrc = "auth.cgi?api=SYNO.API.Auth&version=3&method=login&account="+knasID+"&passwd="+encodeURIComponent(knasPW)+"&session=FileStation&format=sid";
|
||||
$.ajax({
|
||||
url : "/knas_api.asp?call=" + encodeURIComponent(loginSrc),
|
||||
dataType : 'json',
|
||||
success:function(response) {
|
||||
sid = response[1].data.sid;
|
||||
}
|
||||
});
|
||||
|
||||
createTree();
|
||||
$("#refreshLib").on("click", function(){
|
||||
if(confirm("Degisn Library<72><79> <20>ֽ<EFBFBD>ȭ<EFBFBD>Ͻðڽ<C3B0><DABD>ϱ<EFBFBD>?\n(<28>ҿ<EFBFBD><D2BF>ð<EFBFBD> 1~10<31><30> <20>ҿ<EFBFBD>)")){
|
||||
refreshLib();
|
||||
}
|
||||
});
|
||||
$("#searchKeyword").on("keyup", function(e){
|
||||
var keycode = e.which ? e.which : e.keyCode;
|
||||
if(keycode == 13){
|
||||
if($.trim($("#searchKeyword").val()).length >= 2){
|
||||
var searchFiles = $.grep(fileList, function(obj, idx){ return obj.fname.indexOf($("#searchKeyword").val()) > -1; });
|
||||
fileListView(searchFiles, "Search Keyword: <i>" + $("#searchKeyword").val() + "</i>", true, "search");
|
||||
}else{
|
||||
alert("<22>α<EFBFBD><CEB1><EFBFBD> <20>̻<EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD><EFBFBD>ּ<EFBFBD><D6BC><EFBFBD>.");
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
function createTree(){
|
||||
var cPathTree = $.map(pathTree, function(obj){
|
||||
return {
|
||||
"parentNode":obj.tpath.substr(0, obj.tpath.lastIndexOf("/")),
|
||||
"nodeName":obj.tpath.split("/")[obj.tidx],
|
||||
"nodeObj": new TreeNode(obj.tpath.split("/")[obj.tidx], {
|
||||
expanded : false
|
||||
})
|
||||
};
|
||||
});
|
||||
cPathTree.push({
|
||||
"parentNode":"",
|
||||
"nodeName":rootName,
|
||||
"nodeObj": new TreeNode(rootName)
|
||||
});
|
||||
var cPathTreeClone = cPathTree;
|
||||
$.each(cPathTreeClone, function(idx, obj){
|
||||
if(obj.parentNode != ""){
|
||||
var tmpNode = $.grep(cPathTree, function(o, i){ return (o.parentNode + "/" + o.nodeName) == obj.parentNode; })[0];
|
||||
obj.nodeObj.on("click", selectNode);
|
||||
tmpNode.nodeObj.addChild(obj.nodeObj);
|
||||
}
|
||||
});
|
||||
|
||||
var root = $.grep(cPathTree, function(o, i){ return o.parentNode == ""; })[0].nodeObj;
|
||||
|
||||
treeDiv = new TreeView(root, "#pathTree", {
|
||||
leaf_icon: '<i class="fas fa-folder-open"></i>',
|
||||
parent_icon: '<i class="fas fa-folder"></i>',
|
||||
open_icon: '<i class="fas fa-angle-down"></i>',
|
||||
close_icon: '<i class="fas fa-angle-right"></i>'
|
||||
});
|
||||
|
||||
browserChk();
|
||||
}
|
||||
|
||||
function selectNode(e, node){
|
||||
var treePath = new TreePath(treeDiv.getRoot(), node);
|
||||
var fullpath = $.map(treePath.getPath(), function(obj){ return obj.getUserObject(); }).join("/");
|
||||
var selFolderFiles = $.grep(fileList, function(obj, idx){ return obj.fpath.substr(1, obj.fpath.lastIndexOf("/")-1) == fullpath; });
|
||||
fileListView(selFolderFiles, fullpath + "/", node.isLeaf(), "select");
|
||||
}
|
||||
|
||||
function fileListView(files, path, isLeaf, stype){
|
||||
if(files.length > 0){
|
||||
var htmlContents = "";
|
||||
setProg(files.length);
|
||||
$.each(files, function(idx, obj){
|
||||
var tmpHtml = "";
|
||||
var thumbnailURL = "";
|
||||
var transBack = false;
|
||||
if("jpg,jpeg,jpe,bmp,png,tif,tiff,gif".indexOf(obj.fext.toLowerCase()) > -1){
|
||||
thumbnailURL = "/knas_api.asp?type=thumb&call=" + encodeURIComponent("entry.cgi?api=SYNO.Finder.File.Thumbnail&version=1&method=get&_sid="+sid+"&full_path=" + encodeURIComponent(obj.fpath));
|
||||
if("png,tif,tiff,gif".indexOf(obj.fext.toLowerCase()) > -1){
|
||||
transBack = true;
|
||||
}
|
||||
}else if("ppt,pptx".indexOf(obj.fext.toLowerCase()) > -1){
|
||||
thumbnailURL = "/images/knowledge/ppt_icon.png";
|
||||
}else if("xls,xlsx".indexOf(obj.fext.toLowerCase()) > -1){
|
||||
thumbnailURL = "/images/knowledge/xls_icon.png";
|
||||
}else if("zip".indexOf(obj.fext.toLowerCase()) > -1){
|
||||
thumbnailURL = "/images/knowledge/zip_icon.png";
|
||||
}else{
|
||||
thumbnailURL = "/images/knowledge/etc_icon.png";
|
||||
}
|
||||
|
||||
tmpHtml += "<div class='filePreview'>";
|
||||
tmpHtml += "<a href='/knas_api.asp?type=down&call=" + encodeURIComponent("entry.cgi?api=SYNO.FileStation.Download&version=1&method=download&_sid="+sid+"&mode=download&path=" + encodeURIComponent(obj.fpath)) + "'>";
|
||||
tmpHtml += "<div><img src='" + thumbnailURL + "' alt='" + obj.fname + "' onload='progPlus();' class='" + (transBack ? "transBack" : "") + "'/></div>";
|
||||
tmpHtml += "<span>" + obj.fname + "</span>";
|
||||
tmpHtml += "</a>";
|
||||
tmpHtml += "</div>";
|
||||
if(thumbnailURL.indexOf("amp") > -1){
|
||||
console.log(obj.fpath);
|
||||
console.log(thumbnailURL);
|
||||
}
|
||||
htmlContents += tmpHtml;
|
||||
});
|
||||
$("#pathInfo").html(path);
|
||||
$("#fileContents").html(htmlContents);
|
||||
}else{
|
||||
if(isLeaf){
|
||||
$("#pathInfo").html(path);
|
||||
var tmpMent = stype == 'search' ? '<27>˻<EFBFBD><CBBB><EFBFBD><EFBFBD><EFBFBD> -' : '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
|
||||
$("#fileContents").html('<div id="baseMessage">' + tmpMent + ' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD>.</div>');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function refreshLib(){
|
||||
$("#loadingDiv").show();
|
||||
pathTree = [];
|
||||
fileList = [];
|
||||
var rootFolder = "/" + rootName;
|
||||
callPathList(rootFolder, 1);
|
||||
}
|
||||
|
||||
function findLastFiles(pathList, tidx){
|
||||
$.each(pathList, function(idx, obj){
|
||||
if(obj.isdir == true){
|
||||
pathTree.push({"tidx":tidx+1, "path":obj.path});
|
||||
callPathList(obj.path, tidx+1);
|
||||
}else{
|
||||
obj.ext = obj.additional.type.toLowerCase();
|
||||
delete obj.additional;
|
||||
delete obj.isdir;
|
||||
fileList.push(obj);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function callPathList(folderPath, tidx){
|
||||
var folderTreeSrc = "entry.cgi?api=SYNO.FileStation.List&version=1&method=list&additional=type&_sid="+sid+"&folder_path="+encodeURIComponent(folderPath);
|
||||
$.ajax({
|
||||
url : "/knas_api.asp?call=" + encodeURIComponent(folderTreeSrc),
|
||||
dataType : 'json',
|
||||
success:function(response) {
|
||||
findLastFiles(response[1].data.files, tidx);
|
||||
if(setTimeoutObj != undefined){
|
||||
clearTimeout(setTimeoutObj);
|
||||
}
|
||||
setTimeoutObj = setTimeout(function(){
|
||||
updateDB();
|
||||
}, 1000);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function updateDB(){
|
||||
var param = {
|
||||
"tarr" : JSON.stringify(pathTree),
|
||||
"farr" : JSON.stringify(fileList)
|
||||
};
|
||||
$.ajax({
|
||||
url : "./design_library_update.asp",
|
||||
type : "POST",
|
||||
data : param,
|
||||
dataType : 'json',
|
||||
success : function(response){
|
||||
if(response.status == "1"){
|
||||
alert("Update Complete!!");
|
||||
}else{
|
||||
alert("Web Service Error!");
|
||||
}
|
||||
},
|
||||
error : function(){
|
||||
alert("web Service Error!");
|
||||
},
|
||||
complete : function(){
|
||||
$("#loadingDiv").hide();
|
||||
$(location).attr("href", $(location).attr("href"));
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function setProg(cnt){
|
||||
totalCnt = cnt;
|
||||
nowCnt = 0;
|
||||
$("#progress").show();
|
||||
}
|
||||
|
||||
function progPlus(){
|
||||
nowCnt++;
|
||||
$("#progressCnt").text("Loading... (" + nowCnt + "/" + totalCnt + ")");
|
||||
$("#progressBar").css("width", (nowCnt / totalCnt * 100) + "%");
|
||||
if(nowCnt == totalCnt){
|
||||
$("#progressCnt").text("Complete!!!");
|
||||
setTimeout(function(){
|
||||
endProg();
|
||||
}, 500);
|
||||
}
|
||||
}
|
||||
|
||||
function endProg(){
|
||||
totalCnt = 0;
|
||||
nowCnt = 0;
|
||||
$("#progressCnt").text("");
|
||||
$("#progress").hide();
|
||||
}
|
||||
|
||||
function browserChk(){
|
||||
var agent = navigator.userAgent.toLowerCase();
|
||||
if ( (navigator.appName == 'Netscape' && navigator.userAgent.search('Trident') != -1) || (agent.indexOf("msie") != -1) ) {
|
||||
alert("Internet Explorer<65><72><EFBFBD><EFBFBD><EFBFBD><EFBFBD> \n<><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>۵<EFBFBD><DBB5><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><> <20>ֽ<EFBFBD><D6BD>ϴ<EFBFBD>.\n\nChrome<6D><65> <20>̿<EFBFBD><CCBF><EFBFBD><EFBFBD>ּ<EFBFBD><D6BC><EFBFBD>.");
|
||||
} else {
|
||||
//alert("<22><><EFBFBD>ͳ<EFBFBD> <20>ͽ<EFBFBD><CDBD>÷η<C3B7> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ƴմϴ<D5B4>.");
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
54
knowledge/design_library_update.asp
Normal file
54
knowledge/design_library_update.asp
Normal file
@@ -0,0 +1,54 @@
|
||||
<!-- #include virtual = "lib/config.asp" -->
|
||||
<!-- #include virtual = "lib/json2.asp" -->
|
||||
<%
|
||||
|
||||
set dbin = server.CreateObject("ADODB.CONNECTION")
|
||||
dbin.Open adoConn
|
||||
Response.CodePage = "65001"
|
||||
Response.CharSet = "UTF-8" '<27>ѱ<EFBFBD>
|
||||
|
||||
dim tarr : set tarr = JSON.parse(request.form("tarr"))
|
||||
dim farr : set farr = JSON.parse(request.form("farr"))
|
||||
|
||||
dim query, subQuery, i
|
||||
dim subExec : subExec = 200
|
||||
|
||||
query = ""
|
||||
query = query & " DELETE FROM T_DESIGN_TREE; "
|
||||
query = query & " DELETE FROM T_DESIGN_FILE; "
|
||||
dbin.Execute query
|
||||
|
||||
subQuery = ""
|
||||
query = ""
|
||||
query = query & " INSERT INTO T_DESIGN_TREE (tpath, tidx, insert_dt, insert_user) VALUES "
|
||||
For i = 0 To tarr.length - 1
|
||||
subQuery = subQuery & "('" & tarr.get(i).path & "', '" & tarr.get(i).tidx & "', CONVERT(VARCHAR(19), GETDATE(), 20), '" & session("User_Number") & "'),"
|
||||
|
||||
if (i+1) Mod subExec = 0 Then
|
||||
dbin.Execute query & Mid(subQuery, 1, Len(subQuery)-1)
|
||||
subQuery = ""
|
||||
End If
|
||||
Next
|
||||
if subQuery <> "" Then
|
||||
dbin.Execute query & Mid(subQuery, 1, Len(subQuery)-1)
|
||||
End If
|
||||
|
||||
subQuery = ""
|
||||
query = ""
|
||||
query = query & " INSERT INTO T_DESIGN_FILE (fpath, fname, fext, insert_dt, insert_user) VALUES "
|
||||
For i = 0 To farr.length - 1
|
||||
subQuery = subQuery & "('" & farr.get(i).path & "', '" & farr.get(i).name & "', '" & farr.get(i).ext & "', CONVERT(VARCHAR(19), GETDATE(), 20), '" & session("User_Number") & "'),"
|
||||
|
||||
if (i+1) Mod subExec = 0 Then
|
||||
dbin.Execute query & Mid(subQuery, 1, Len(subQuery)-1)
|
||||
subQuery = ""
|
||||
End If
|
||||
Next
|
||||
if subQuery <> "" Then
|
||||
dbin.Execute query & Mid(subQuery, 1, Len(subQuery)-1)
|
||||
End If
|
||||
|
||||
Response.Write "{""status"":""" & "1" & """}"
|
||||
|
||||
dbin.Close
|
||||
%>
|
||||
133
knowledge/staff_list.asp
Normal file
133
knowledge/staff_list.asp
Normal file
@@ -0,0 +1,133 @@
|
||||
<!-- #include virtual = "include/header.asp" -->
|
||||
<!-- #include virtual = "include/left.asp" -->
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="content-header">
|
||||
<h1><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD></h1>
|
||||
</div>
|
||||
<!-- /.content-header -->
|
||||
<!-- Main content -->
|
||||
<div class="content-body">
|
||||
<div class="content">
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<table width="100%" cellpadding="0" cellspacing="0" border="0">
|
||||
<%
|
||||
Query = ""
|
||||
Query = Query & " SELECT p_name, p_team_name, p_rank_name, p_tel2, p_tel3, birthday, jumin "
|
||||
Query = Query & " FROM V_PERSON "
|
||||
Query = Query & " WHERE p_resign = '0' AND ISNULL(krc_in_date, '') != '' "
|
||||
query = query & " ORDER BY p_name "
|
||||
|
||||
Adors.open Query, adoconn, 1
|
||||
%>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<font class="brown"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ<EFBFBD>Դϴ<D4B4>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<%=Adors.recordcount%>)<29><> - <20><><EFBFBD><EFBFBD><EFBFBD>ټ<EFBFBD></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" colspan="2">
|
||||
<div class="card-deck">
|
||||
<% Do until Adors.EOF %>
|
||||
<% If Adors.AbsolutePosition Mod 8 = 1 And Adors.AbsolutePosition <> 1 Then %>
|
||||
</div>
|
||||
<div class="card-deck">
|
||||
<% End If %>
|
||||
<div class="card m-2 p-1">
|
||||
<img class="card-img-top p-2" src="/images/management/img/<%=replace(left(decode(Adors("jumin"),0),8),"-" ,"_")%>_<%=Adors("p_name")%>.jpg?ver=3" onerror="this.src='/images/management/no_img.gif'" alt="<22><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>">
|
||||
<div class="card-body p-1">
|
||||
<h5 class="card-title m-0"><%=Adors("p_name")%></h5>
|
||||
</div>
|
||||
<ul class="list-group list-group-flush">
|
||||
<li class="list-group-item p-0"><%=Adors("p_team_name")%></li>
|
||||
<li class="list-group-item p-0"><%=Adors("p_rank_name")%></li>
|
||||
<li class="list-group-item p-0"><%=Adors("p_tel2")%></li>
|
||||
<li class="list-group-item p-0"><%=Right(Adors("p_tel3"), 4)%></li>
|
||||
<li class="list-group-item p-0"><%=Mid(Adors("birthday"), 6)%></li>
|
||||
</ul>
|
||||
</div>
|
||||
<% Adors.MoveNext %>
|
||||
<% Loop %>
|
||||
<% If Adors.recordCount Mod 8 <> 0 Then %>
|
||||
<% For i=1 To 8 - Adors.recordCount Mod 8 %>
|
||||
<div class="card m-2 p-1 invisible"></div>
|
||||
<% Next %>
|
||||
<% End If %>
|
||||
<% Adors.Close %>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<% '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
if session("Depart_Code") = 0 or session("job_code") = "10" or tmp_admin_chk = "1" then
|
||||
Query = ""
|
||||
Query = Query & " SELECT P.p_name, p_tel2, p_tel3, birthday, jumin, ISNULL(D.d_name, '<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>') AS d_name, O.p_name AS position_nm "
|
||||
Query = Query & " FROM PERSON P LEFT JOIN Depart D ON P.p_depart = D.d_code "
|
||||
Query = Query & " LEFT JOIN [Position] O ON P.p_pos = O.p_code "
|
||||
Query = Query & " WHERE p_resign = '1' AND len(p_no) = 8 AND krc_in_date IS NOT NULL "
|
||||
Query = Query & " ORDER BY P.p_name "
|
||||
Adors.open Query, adoconn, 1
|
||||
%>
|
||||
<tr>
|
||||
<td colspan ="2"><div class='py-5'></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan ="2">
|
||||
<font class="brown"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ<EFBFBD>Դϴ<D4B4>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<%=Adors.recordcount%>)<29><> - <20><><EFBFBD><EFBFBD><EFBFBD>ټ<EFBFBD></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" colspan="2">
|
||||
<div class="card-deck">
|
||||
<% Do until Adors.EOF %>
|
||||
<% If Adors.AbsolutePosition Mod 8 = 1 And Adors.AbsolutePosition <> 1 Then %>
|
||||
</div>
|
||||
<div class="card-deck">
|
||||
<% End If %>
|
||||
<div class="card m-2 p-1">
|
||||
<img class="card-img-top p-2" src="/images/management/img/<%=replace(left(decode(Adors("jumin"),0),8),"-" ,"_")%>_<%=Adors("p_name")%>.jpg" onerror="this.src='/images/management/no_img.gif'" alt="<22><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>">
|
||||
<div class="card-body p-1">
|
||||
<h5 class="card-title m-0"><%=Adors("p_name")%></h5>
|
||||
</div>
|
||||
<ul class="list-group list-group-flush">
|
||||
<li class="list-group-item p-0"><%=Adors("d_name")%></li>
|
||||
<li class="list-group-item p-0"><%=Adors("position_nm")%></li>
|
||||
<li class="list-group-item p-0"><%=Adors("p_tel2")%></li>
|
||||
<li class="list-group-item p-0"><%=Mid(Adors("p_tel3"), 9, 4)%></li>
|
||||
<li class="list-group-item p-0"><%=Mid(Adors("birthday"), 6)%></li>
|
||||
</ul>
|
||||
</div>
|
||||
<% Adors.MoveNext %>
|
||||
<% Loop %>
|
||||
<% If Adors.recordCount Mod 8 <> 0 Then %>
|
||||
<% For i=1 To 8 - Adors.recordCount Mod 8 %>
|
||||
<div class="card m-2 p-1 invisible"></div>
|
||||
<% Next %>
|
||||
<% End If %>
|
||||
<% Adors.Close %>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<%end if%>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.content -->
|
||||
<!-- REQUIRED SCRIPTS -->
|
||||
<script>
|
||||
function downEmail() {
|
||||
location.href= "./downcsv.asp";
|
||||
}
|
||||
|
||||
function person_info() {
|
||||
location.href= "./down_person_info.asp";
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- #include virtual = "include/footer.asp" -->
|
||||
Reference in New Issue
Block a user