From cb4c9a389d4ee00bb4504640aeff0a27ba2a9970 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E6=80=A1=E6=A0=8B?= Date: Thu, 19 Aug 2021 19:49:21 +0800 Subject: [PATCH] * Adjust entry code. --- module/common/model.php | 2 +- module/entry/control.php | 2 +- module/entry/model.php | 52 ++++++++++++++++++++-------------------- 3 files changed, 28 insertions(+), 28 deletions(-) diff --git a/module/common/model.php b/module/common/model.php index ad49aab73e..f53d13e12b 100644 --- a/module/common/model.php +++ b/module/common/model.php @@ -2177,7 +2177,7 @@ EOD; if($result) { if($timestamp <= $entry->calledTime) $this->response('CALLED_TIME'); - $this->loadModel('entry')->updateTime($entry->code, $timestamp); + $this->loadModel('entry')->updateCalledTime($entry->code, $timestamp); unset($_GET['time']); return $result; } diff --git a/module/entry/control.php b/module/entry/control.php index 3d42653b1a..a5aa18d2ef 100644 --- a/module/entry/control.php +++ b/module/entry/control.php @@ -126,7 +126,7 @@ class entry extends control $entry = $this->entry->getByID($id); $this->view->title = $this->lang->entry->log . $this->lang->colon . $entry->name; - $this->view->logs = $this->entry->getLogList($id, $orderBy, $pager); + $this->view->logs = $this->entry->getLogs($id, $orderBy, $pager); $this->view->position[] = html::a(inlink('browse'), $this->lang->entry->api); $this->view->position[] = html::a(inlink('browse'), $this->lang->entry->common); $this->view->position[] = $this->lang->entry->log; diff --git a/module/entry/model.php b/module/entry/model.php index ccc4ebfb65..638ac3bad8 100644 --- a/module/entry/model.php +++ b/module/entry/model.php @@ -5,18 +5,18 @@ * @copyright Copyright 2009-2017 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com) * @license ZPL (http://zpl.pub/page/zplv12.html) * @author Gang Liu - * @package entry + * @package entry * @version $Id$ * @link http://www.zentao.net */ class entryModel extends model { /** - * Get an entry by id. - * - * @param int $entryID + * Get an entry by id. + * + * @param int $entryID * @access public - * @return object + * @return object */ public function getById($entryID) { @@ -24,11 +24,11 @@ class entryModel extends model } /** - * Get an entry by code. - * - * @param string $code + * Get an entry by code. + * + * @param string $code * @access public - * @return object + * @return object */ public function getByCode($code) { @@ -48,8 +48,8 @@ class entryModel extends model } /** - * Get entry list. - * + * Get entry list. + * * @param string $orderBy * @param object $pager * @access public @@ -61,15 +61,15 @@ class entryModel extends model } /** - * Get log list of an entry . - * + * Get log list of an entry . + * * @param int $id - * @param string $orderBy - * @param object $pager + * @param string $orderBy + * @param object $pager * @access public - * @return array + * @return array */ - public function getLogList($id, $orderBy = 'date_desc', $pager = null) + public function getLogs($id, $orderBy = 'date_desc', $pager = null) { return $this->dao->select('*')->from(TABLE_LOG) ->where('objectType')->eq('entry') @@ -80,8 +80,8 @@ class entryModel extends model } /** - * Create an entry. - * + * Create an entry. + * * @access public * @return bool | int */ @@ -109,9 +109,9 @@ class entryModel extends model } /** - * Update an entry. - * - * @param int $entryID + * Update an entry. + * + * @param int $entryID * @access public * @return bool | array */ @@ -143,13 +143,13 @@ class entryModel extends model /** * Update called time. - * - * @param string $code - * @param int $time + * + * @param string $code + * @param int $time * @access public * @return bool */ - public function updateTime($code, $time) + public function updateCalledTime($code, $time) { $this->dao->update(TABLE_ENTRY)->set('calledTime')->eq($time)->where('code')->eq($code)->exec(); return !dao::isError();