mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-06 18:21:39 +09:00
17438345
* 관리 메인페이지에 게시물/댓글 신고 회수 출력 * 상태 각 항목에 해당 페이지 링크 추가 * 어제/오늘 숫자를 잘못 가져오는 문제 수정 git-svn-id: http://xe-core.googlecode.com/svn/sandbox@4859 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
7a26a73088
commit
5a187f2bd0
6 changed files with 172 additions and 36 deletions
|
|
@ -83,7 +83,7 @@
|
|||
$db_info = Context::getDBInfo();
|
||||
Context::set('selected_lang', $db_info->lang_type);
|
||||
|
||||
Context::set('current_version', __ZBXE_VERSION__);
|
||||
Conㄴtext::set('current_version', __ZBXE_VERSION__);
|
||||
Context::set('installed_path', realpath('./'));
|
||||
|
||||
$oModuleModel = &getModel('module');
|
||||
|
|
@ -95,36 +95,106 @@
|
|||
Context::set('addon_list', $addon_list);
|
||||
|
||||
$args->date = date("Ymd000000", time()-60*60*24);
|
||||
$today = date("Ymd");
|
||||
|
||||
// 회원
|
||||
$output = executeQueryArray("admin.getMemberStatus", $args);
|
||||
$status->member->yesterday = number_format($output->data[0]->count);
|
||||
$status->member->today = number_format($output->data[1]->count);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->member->today = $var->count;
|
||||
} else {
|
||||
$status->member->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getMemberCount", $args);
|
||||
$status->member->total = number_format($output->data->count);
|
||||
$status->member->total = $output->data->count;
|
||||
|
||||
// 문서
|
||||
$output = executeQueryArray("admin.getDocumentStatus", $args);
|
||||
$status->document->yesterday = number_format($output->data[0]->count);
|
||||
$status->document->today = number_format($output->data[1]->count);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->document->today = $var->count;
|
||||
} else {
|
||||
$status->document->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getDocumentCount", $args);
|
||||
$status->document->total = number_format($output->data->count);
|
||||
$status->document->total = $output->data->count;
|
||||
|
||||
// 댓글
|
||||
$output = executeQueryArray("admin.getCommentStatus", $args);
|
||||
$status->comment->yesterday = number_format($output->data[0]->count);
|
||||
$status->comment->today = number_format($output->data[1]->count);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->comment->today = $var->count;
|
||||
} else {
|
||||
$status->comment->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getCommentCount", $args);
|
||||
$status->comment->total = number_format($output->data->count);
|
||||
$status->comment->total = $output->data->count;
|
||||
|
||||
// 엮인글
|
||||
$output = executeQueryArray("admin.getTrackbackStatus", $args);
|
||||
$status->trackback->yesterday = number_format($output->data[0]->count);
|
||||
$status->trackback->today = number_format($output->data[1]->count);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->trackback->today = $var->count;
|
||||
} else {
|
||||
$status->trackback->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getTrackbackCount", $args);
|
||||
$status->trackback->total = number_format($output->data->count);
|
||||
$status->trackback->total = $output->data->count;
|
||||
|
||||
// 첨부파일
|
||||
$output = executeQueryArray("admin.getFileStatus", $args);
|
||||
$status->file->yesterday = number_format($output->data[0]->count);
|
||||
$status->file->today = number_format($output->data[1]->count);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->file->today = $var->count;
|
||||
} else {
|
||||
$status->file->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getFileCount", $args);
|
||||
$status->file->total = number_format($output->data->count);
|
||||
$status->file->total = $output->data->count;
|
||||
|
||||
// 게시물 신고
|
||||
$output = executeQueryArray("admin.getDocumentDeclaredStatus", $args);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->documentDeclared->today = $var->count;
|
||||
} else {
|
||||
$status->documentDeclared->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getDocumentDeclaredCount", $args);
|
||||
$status->documentDeclared->total = $output->data->count;
|
||||
|
||||
// 댓글 신고
|
||||
$output = executeQueryArray("admin.getCommentDeclaredStatus", $args);
|
||||
if($output->data) {
|
||||
foreach($output->data as $var) {
|
||||
if($var->date == $today) {
|
||||
$status->commentDeclared->today = $var->count;
|
||||
} else {
|
||||
$status->commentDeclared->yesterday = $var->count;
|
||||
}
|
||||
}
|
||||
}
|
||||
$output = executeQuery("admin.getCommentDeclaredCount", $args);
|
||||
$status->commentDeclared->total = $output->data->count;
|
||||
|
||||
Context::set('status', $status);
|
||||
|
||||
$this->setTemplateFile('index');
|
||||
|
|
|
|||
8
modules/admin/queries/getCommentDeclaredCount.xml
Normal file
8
modules/admin/queries/getCommentDeclaredCount.xml
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<query id="getCommentDeclaredCount" action="select">
|
||||
<tables>
|
||||
<table name="comment_declared_log" />
|
||||
</tables>
|
||||
<columns>
|
||||
<column name="count(*)" alias="count" />
|
||||
</columns>
|
||||
</query>
|
||||
19
modules/admin/queries/getCommentDeclaredStatus.xml
Normal file
19
modules/admin/queries/getCommentDeclaredStatus.xml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<query id="getCommentDeclaredStatus" action="select">
|
||||
<tables>
|
||||
<table name="comment_declared_log" />
|
||||
</tables>
|
||||
<columns>
|
||||
<column name="substr(regdate,1,8)" alias="date" />
|
||||
<column name="count(*)" alias="count" />
|
||||
</columns>
|
||||
<conditions>
|
||||
<condition operation="more" column="regdate" var="date" notnull="notnull"/>
|
||||
</conditions>
|
||||
<navigation>
|
||||
<index var="sort_index" default="substr(regdate,1,8)" order="asc" />
|
||||
<list_count var="list_count" default="2" />
|
||||
</navigation>
|
||||
<groups>
|
||||
<group column="substr(regdate,0,8)" />
|
||||
</groups>
|
||||
</query>
|
||||
8
modules/admin/queries/getDocumentDeclaredCount.xml
Normal file
8
modules/admin/queries/getDocumentDeclaredCount.xml
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<query id="getDocumentDeclaredCount" action="select">
|
||||
<tables>
|
||||
<table name="document_declared_log" />
|
||||
</tables>
|
||||
<columns>
|
||||
<column name="count(*)" alias="count" />
|
||||
</columns>
|
||||
</query>
|
||||
19
modules/admin/queries/getDocumentDeclaredStatus.xml
Normal file
19
modules/admin/queries/getDocumentDeclaredStatus.xml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<query id="getDocumentDeclaredStatus" action="select">
|
||||
<tables>
|
||||
<table name="document_declared_log" />
|
||||
</tables>
|
||||
<columns>
|
||||
<column name="substr(regdate,1,8)" alias="date" />
|
||||
<column name="count(*)" alias="count" />
|
||||
</columns>
|
||||
<conditions>
|
||||
<condition operation="more" column="regdate" var="date" notnull="notnull"/>
|
||||
</conditions>
|
||||
<navigation>
|
||||
<index var="sort_index" default="substr(regdate,1,8)" order="asc" />
|
||||
<list_count var="list_count" default="2" />
|
||||
</navigation>
|
||||
<groups>
|
||||
<group column="substr(regdate,0,8)" />
|
||||
</groups>
|
||||
</query>
|
||||
|
|
@ -125,34 +125,46 @@
|
|||
</thead>
|
||||
<tbody>
|
||||
<tr class="row2">
|
||||
<td class="circle">{$lang->member}</td>
|
||||
<td class="number center">{$status->member->yesterday}</td>
|
||||
<td class="number center">{$status->member->today}</td>
|
||||
<td class="number center">{$status->member->total}</td>
|
||||
<td class="circle"><a href="{getUrl('act','dispMemberAdminList')}">{$lang->member}</a></td>
|
||||
<td class="number center">{number_format($status->member->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->member->today)}</td>
|
||||
<td class="number center">{number_format($status->member->total)}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="circle">{$lang->document}</td>
|
||||
<td class="number center">{$status->document->yesterday}</td>
|
||||
<td class="number center">{$status->document->today}</td>
|
||||
<td class="number center">{$status->document->total}</td>
|
||||
<td class="circle"><a href="{getUrl('act','dispDocumentAdminList')}">{$lang->document}</a></td>
|
||||
<td class="number center">{number_format($status->document->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->document->today)}</td>
|
||||
<td class="number center">{number_format($status->document->total)}</td>
|
||||
</tr>
|
||||
<tr class="row2">
|
||||
<td class="circle">{$lang->comment}</td>
|
||||
<td class="number center">{$status->comment->yesterday}</td>
|
||||
<td class="number center">{$status->comment->today}</td>
|
||||
<td class="number center">{$status->comment->total}</td>
|
||||
<td class="circle"><a href="{getUrl('act','dispCommentAdminList')}">{$lang->comment}</a></td>
|
||||
<td class="number center">{number_format($status->comment->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->comment->today)}</td>
|
||||
<td class="number center">{number_format($status->comment->total)}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="circle">{$lang->trackback}</td>
|
||||
<td class="number center">{$status->trackback->yesterday}</td>
|
||||
<td class="number center">{$status->trackback->today}</td>
|
||||
<td class="number center">{$status->trackback->total}</td>
|
||||
<td class="circle"><a href="{getUrl('act','dispTrackbackAdminList')}">{$lang->trackback}</a></td>
|
||||
<td class="number center">{number_format($status->trackback->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->trackback->today)}</td>
|
||||
<td class="number center">{number_format($status->trackback->total)}</td>
|
||||
</tr>
|
||||
<tr class="row2">
|
||||
<td class="circle">{$lang->file}</td>
|
||||
<td class="number center">{$status->file->yesterday}</td>
|
||||
<td class="number center">{$status->file->today}</td>
|
||||
<td class="number center">{$status->file->total}</td>
|
||||
<td class="circle"><a href="{getUrl('act','dispFileAdminList')}">{$lang->file}</a></td>
|
||||
<td class="number center">{number_format($status->file->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->file->today)}</td>
|
||||
<td class="number center">{number_format($status->file->total)}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="circle"><a href="{getUrl('act','dispDocumentAdminDeclared')}">{$lang->document.' '.$lang->cmd_declare}</a></td>
|
||||
<td class="number center">{number_format($status->documentDeclared->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->documentDeclared->today)}</td>
|
||||
<td class="number center">{number_format($status->documentDeclared->total)}</td>
|
||||
</tr>
|
||||
<tr class="row2">
|
||||
<td class="circle"><a href="{getUrl('act','dispCommentAdminDeclared')}">{$lang->comment.' '.$lang->cmd_declare}</a></td>
|
||||
<td class="number center">{number_format($status->commentDeclared->yesterday)}</td>
|
||||
<td class="number center">{number_format($status->commentDeclared->today)}</td>
|
||||
<td class="number center">{number_format($status->commentDeclared->total)}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue