mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-04 01:01:41 +09:00
added comments for phpDoc
git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@10756 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
e010c07440
commit
3c609ae06a
4 changed files with 86 additions and 33 deletions
|
|
@ -1,14 +1,16 @@
|
|||
<?php
|
||||
/**
|
||||
* @class counterAdminView
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
* @brief Admin view class of counter module
|
||||
* Admin view class of counter module
|
||||
*
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
**/
|
||||
|
||||
class counterAdminView extends counter {
|
||||
|
||||
/**
|
||||
* @brief Initialization
|
||||
* Initialization
|
||||
*
|
||||
* @return void
|
||||
**/
|
||||
function init() {
|
||||
// set the template path
|
||||
|
|
@ -16,7 +18,9 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Admin page
|
||||
* Admin page
|
||||
*
|
||||
* @return Object
|
||||
**/
|
||||
function dispCounterAdminIndex() {
|
||||
// set today's if no date is given
|
||||
|
|
|
|||
|
|
@ -1,14 +1,15 @@
|
|||
<?php
|
||||
/**
|
||||
* @class counter
|
||||
* High class of counter module
|
||||
*
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
* @brief high class of counter module
|
||||
**/
|
||||
|
||||
class counter extends ModuleObject {
|
||||
|
||||
/**
|
||||
* @brief Implement if additional tasks are necessary when installing
|
||||
* Implement if additional tasks are necessary when installing
|
||||
* @return Object
|
||||
**/
|
||||
function moduleInstall() {
|
||||
$oCounterController = &getController('counter');
|
||||
|
|
@ -21,7 +22,9 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief method if successfully installed
|
||||
* method if successfully installed
|
||||
*
|
||||
* @return bool
|
||||
**/
|
||||
function checkUpdate() {
|
||||
// Add site_srl to the counter
|
||||
|
|
@ -33,7 +36,9 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Update
|
||||
* Module update
|
||||
*
|
||||
* @return Object
|
||||
**/
|
||||
function moduleUpdate() {
|
||||
// Add site_srl to the counter
|
||||
|
|
@ -45,7 +50,9 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief re-generate the cache file
|
||||
* re-generate the cache file
|
||||
*
|
||||
* @return Object
|
||||
**/
|
||||
function recompileCache() {
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,27 +1,33 @@
|
|||
<?php
|
||||
/**
|
||||
* @class counterController
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
* @brief counter module's controller class
|
||||
* Counter module's controller class
|
||||
*
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
**/
|
||||
|
||||
class counterController extends counter {
|
||||
|
||||
/**
|
||||
* @brief Initialization
|
||||
* Initialization
|
||||
*
|
||||
* @return void
|
||||
**/
|
||||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Counter logs
|
||||
* @deprecated, if want use below function, you can use 'counterExecute' function instead this function
|
||||
* Counter logs.
|
||||
* If want use below function, you can use 'counterExecute' function instead this function
|
||||
*
|
||||
* @return void
|
||||
**/
|
||||
function procCounterExecute() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Counter logs
|
||||
* Counter logs
|
||||
*
|
||||
* @return void
|
||||
**/
|
||||
function counterExecute() {
|
||||
$oDB = &DB::getInstance();
|
||||
|
|
@ -52,7 +58,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Leave logs
|
||||
* Leave logs
|
||||
*
|
||||
* @param integer $site_srl
|
||||
* @return Object result of count query
|
||||
**/
|
||||
function insertLog($site_srl=0) {
|
||||
$args->regdate = date("YmdHis");
|
||||
|
|
@ -62,7 +71,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Register the unique visitor
|
||||
* Register the unique visitor
|
||||
*
|
||||
* @param integer $site_srl
|
||||
* @return void
|
||||
**/
|
||||
function insertUniqueVisitor($site_srl=0) {
|
||||
if($site_srl) {
|
||||
|
|
@ -80,7 +92,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Register pageview
|
||||
* Register pageview
|
||||
*
|
||||
* @param integer $site_srl
|
||||
* @return void
|
||||
**/
|
||||
function insertPageView($site_srl=0) {
|
||||
if($site_srl) {
|
||||
|
|
@ -98,7 +113,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Add the total counter status
|
||||
* Add the total counter status
|
||||
*
|
||||
* @param integer $site_srl
|
||||
* @return void
|
||||
**/
|
||||
function insertTotalStatus($site_srl=0) {
|
||||
$args->regdate = 0;
|
||||
|
|
@ -111,7 +129,11 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Add today's counter status
|
||||
* Add today's counter status
|
||||
*
|
||||
* @param integer $regdate date(YYYYMMDD) type
|
||||
* @param integer $site_srl
|
||||
* @return void
|
||||
**/
|
||||
function insertTodayStatus($regdate = 0, $site_srl=0) {
|
||||
if($regdate) $args->regdate = $regdate;
|
||||
|
|
@ -134,7 +156,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Delete counter logs of the specific virtual site
|
||||
* Delete counter logs of the specific virtual site
|
||||
*
|
||||
* @param integer $site_srl
|
||||
* @return void
|
||||
**/
|
||||
function deleteSiteCounterLogs($site_srl) {
|
||||
$args->site_srl = $site_srl;
|
||||
|
|
|
|||
|
|
@ -1,20 +1,25 @@
|
|||
<?php
|
||||
/**
|
||||
* @class counterModel
|
||||
* Model class of counter module
|
||||
*
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
* @brief Model class of counter module
|
||||
**/
|
||||
|
||||
class counterModel extends counter {
|
||||
|
||||
/**
|
||||
* @brief Initialization
|
||||
* Initialization
|
||||
*
|
||||
* @return void
|
||||
**/
|
||||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Verify logs
|
||||
* Verify logs
|
||||
*
|
||||
* @param integer $site_srl Site_srl
|
||||
* @return bool
|
||||
**/
|
||||
function isLogged($site_srl=0) {
|
||||
$args->regdate = date("Ymd");
|
||||
|
|
@ -25,7 +30,10 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Check if a row of today's counter status exists
|
||||
* Check if a row of today's counter status exists
|
||||
*
|
||||
* @param integer $site_srl Site_srl
|
||||
* @return bool
|
||||
**/
|
||||
function isInsertedTodayStatus($site_srl=0) {
|
||||
$args->regdate = date("Ymd");
|
||||
|
|
@ -39,16 +47,20 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Get access statistics for a given date
|
||||
* Get access statistics for a given date
|
||||
*
|
||||
* @param mixed $selected_date Date(YYYYMMDD) list
|
||||
* @param integer $site_srl Site_srl
|
||||
* @return Object
|
||||
**/
|
||||
function getStatus($selected_date, $site_srl=0) {
|
||||
function getStatus($selected_date, $site_srl = 0) {
|
||||
// If more than one date logs are selected
|
||||
if(is_array($selected_date)) {
|
||||
$date_count = count($selected_date);
|
||||
$args->regdate = implode(',',$selected_date);
|
||||
// If a single date log is selected
|
||||
} else {
|
||||
if(strlen($selected_date)==8) $selected_date = $selected_date;
|
||||
if(strlen($selected_date) == 8) $selected_date = $selected_date;
|
||||
$args->regdate = $selected_date;
|
||||
}
|
||||
|
||||
|
|
@ -72,7 +84,12 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief Select hourly logs of a given date
|
||||
* Select hourly logs of a given date
|
||||
*
|
||||
* @param string $type Choice time interval (year, week, month, hour or DEFAULT)
|
||||
* @param integer $selected_date Date(YYYYMMDD)
|
||||
* @param integer $site_srl Site_srl
|
||||
* @return Object
|
||||
**/
|
||||
function getHourlyStatus($type='hour', $selected_date, $site_srl=0) {
|
||||
$max = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue