修复两处bug

This commit is contained in:
2018-03-27 01:26:27 +08:00
parent c0b94d30c5
commit 71a39e4557
2 changed files with 5 additions and 5 deletions

View File

@@ -770,7 +770,7 @@ function execute_action($rules = false, $action_id = null, $user_id = null) {
//检查执行周期
$map = array('action_id' => $action_id, 'user_id' => $user_id);
$map['create_time'] = array('gt', NOW_TIME - intval($rule['cycle']) * 3600);
$map['create_time'] = array('gt', time() - intval($rule['cycle']) * 3600);
$exec_count = db('ActionLog')->where($map)->count();
if ($exec_count > $rule['max']) {
continue;