Files
sms_host20170829/content/06mypage/index02.asp
T
2026-02-23 10:01:00 +09:00

164 lines
5.4 KiB
Plaintext

<!--#include virtual="/common/file/head_06mypage.asp"-->
<!--#include virtual = "/common/lib/FusionCharts.asp"-->
<%
Dim qryValue ' 선언해줘야 함!! SetWhere 함수 내에서 사용되는 변수..
Dim curCount(12)
Dim arrData(33,2)
YY = inputvalue(request("YY"))
MM = inputvalue(request("MM"))
If YY = "" Then YY = Year(now)
int_YY = "" : If IsNumeric(YY) Then int_yy = Int(YY)
' 카운터 수의 합을 구한다
sumCount = 0
For i = 1 To 12
'table 존재유무
table = "em_log_" & YY & Right("0" & i, 2)
sql = "select count(*) from information_schema.tables where table_name = '" & table & "'"
Set rs = dbcon.execute( sql )
rscount = rs(0)
Set rs = nothing
If rscount > 0 Then
sql = "select count(*) from " & table & " where tran_id = '" & session("ss_m_id") & "'"
Set rs = dbcon.execute( sql )
sumCount = sumCount + rs(0) '총 합계
curCount(i) = rs(0) '월별 카운트
Set rs = nothing
Else
sumCount = sumCount + 0 '총 합계
curCount(i) = 0 '월별 카운트
End if
next
' 날짜변 데이터를 배열에 담는다
maxCount = 0
minCount = 100000
For i=1 To UBound(curCount)
If sumCount > 0 then
curSize = int((curCount(i)/sumCount) * 540)
curPer = formatnumber((curCount(i)/sumCount) * 100,2)
else
curSize = 0
curPer = 0
End if
if maxCount < curCount(i) then
maxCount = curCount(i)
End if
if minCount > curCount(i) then
minCount = curCount(i)
End if
arrData(i,0) = curCount(i)
arrData(i,1) = curSize
arrData(i,2) = curPer
if arrData(i,0) = 0 then
arrData(i,0) = ""
End if
if arrData(i,2) = 0 then
arrData(i,2) = ""
End if
next
%>
<!-- 컨텐츠 부분-->
<td width="720" align="left" valign="top">
<table width="720" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="560" align="left" valign="top" style="padding-bottom:30px;"><img src="/sms_img/sub/stit_0602.gif" height="69" alt="월별발송현황" /></td>
<td width="300" align="right" valign="bottom" style="padding-bottom:30px;"><img src="/sms_img/sub/home.gif" width="14" height="10" /><img src="/sms_img/sub/arrow.gif" width="14" height="10" /><span class="style9">나의메뉴</span><img src="/sms_img/sub/arrow.gif" width="14" height="10" /><span class="style11">월별발송현황</span></td>
</tr>
<tr>
<td colspan="2" style="width:738px; margin:0 auto; text-align:center; border:1px solid #dcdcdc; background:#f8f8f8; padding:15px 0;">
<!-- 검색 -->
<form id="frm" action="<%=Request.ServerVariables("path_info")%>" method="get">
<select id="YY" name="YY" title="해당 년도 선택" class="stats" tabindex="<%=getTabIndex()%>">
<% For z=2009 To Year(now)%>
<option value="<%=z%>" <%If z=int_YY Then response.write "selected='selected'" End If %>><%=z%>년</option>
<%next%>
</select>
<input type="image" src="/content/board/nninc_simple/img/search_bt.gif" alt="검색" align="middle" />
</form>
<!-- 일자별 통계 -->
<div style="padding:20px 0;">
<strong>월별 발송현황</strong><br /><br />
<%
strXML = "&lt;graph caption='' xAxisName='' yAxisName='' showValues='0' decimalPrecision='0' formatNumberScale='0' showAlternateHGridColor='1' AlternateHGridColor='' divLineColor='F0F0F0' divLineAlpha='' alternateHGridAlpha='5' bgcolor='ffffff' canvasBgColor='ffffff' canvasBaseColor='EAEAEA' canvasBaseDepth='1' canvasBgDepth='0' baseFont='verdana' baseFontSize='9' baseFontColor='999999' hoverCapBgColor='ffffff' hoverCapBorderColor='A6A6A6' hoverCapSepChar=' ' chartLeftMargin='0' chartRightMargin='0' chartTopMargin='5' chartBottomMargin='0'&gt;"
strXML = strXML & "&lt;set name='1月' value='"&arrData(1,0)&"' color='B1D361' /&gt;"
strXML = strXML & "&lt;set name='2月' value='"&arrData(2,0)&"' color='FECC6D' /&gt;"
strXML = strXML & "&lt;set name='3月' value='"&arrData(3,0)&"' color='E94646' /&gt;"
strXML = strXML & "&lt;set name='4月' value='"&arrData(4,0)&"' color='7BDCC5'/&gt;"
strXML = strXML & "&lt;set name='5月' value='"&arrData(5,0)&"' color='74C2E4'/&gt;"
strXML = strXML & "&lt;set name='6月' value='"&arrData(6,0)&"' color='828FE3'/&gt;"
strXML = strXML & "&lt;set name='7月' value='"&arrData(7,0)&"' color='D07CDB'/&gt;"
strXML = strXML & "&lt;set name='8月' value='"&arrData(8,0)&"' color='D8D8D8'/&gt;"
strXML = strXML & "&lt;set name='9月' value='"&arrData(9,0)&"' color='B1D361' /&gt;"
strXML = strXML & "&lt;set name='10月' value='"&arrData(10,0)&"' color='FECC6D' /&gt;"
strXML = strXML & "&lt;set name='11月' value='"&arrData(11,0)&"' color='E94646' /&gt;"
strXML = strXML & "&lt;set name='12月' value='"&arrData(12,0)&"' color='7BDCC5'/&gt;"
strXML = strXML & "&lt;/graph&gt;"
response.write renderChartHTML("/manager/img/swf/main_colum3d.swf", "", strXML, "myNext", 650, 400,"","","")
%>
</div>
<table style="width:650px; text-align:center; margin:0 auto; background:#fff;" class="table9">
<%
For i = 1 To 12
If isnull( arrData(i,0) ) Or arrData(i,0) = "" Then
arrData(i,0) = 0
End if
%>
<tr>
<td width="50%" style="text-align:center;"><%=int_YY%>년 <%=int_MM%>월</td>
<td width="40%" style="text-align:center;"><%=arrData(i,0)%> 건</td>
</tr>
<%
next
%>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<!--#include virtual="/common/file/bottom.asp"-->