Commit fa3c9174 authored by clone's avatar clone

被拨打10次不显示

parent 7ad5dbb3
<?php
namespace app\api_broker\service;
use app\model\UPhoneFollowPp;
/**
* Created by PhpStorm.
* User : zw
* Date : 2018/8/1
* Time : 13:50
* Intro:
*/
class ClientService
{
private $uPhoneFollowUpModel;
public function __construct()
{
$this->uPhoneFollowUpModel = new UPhoneFollowPp();
}
public function dialTotal($user_id)
{
//todo 拨打次数统计
$day = 1;
$num = 10;
$start_time = date("Y-m-d H:i:s", strtotime("-$day day"));
$end_time = date("Y-m-d H:i:s", time());
$params["create_time"] = array( "between", array( $start_time, $end_time ) );
$params["user_id"] = $user_id;
$total = $this->uPhoneFollowUpModel->getSearchCount("", $params);
if ($total > $num) {
return false;
} else {
return true;
}
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment