Commit 2148152a authored by zw's avatar zw

报备

parent 8efb8c1b
......@@ -3,7 +3,7 @@
namespace app\api_broker\controller;
use app\api_broker\extend\Basic;
use app\api_broker\service\FollowUpService;
use app\api_broker\service\ReportService;
/**
* Created by PhpStorm.
......@@ -12,14 +12,14 @@ use app\api_broker\service\FollowUpService;
* Time : 14:24
* Intro:
*/
class FollowUp extends Basic
class Report extends Basic
{
private $service_;
public function __construct($request = null)
{
parent::__construct($request);
$this->service_ = new FollowUpService();
$this->service_ = new ReportService();
}
......
......@@ -2,8 +2,8 @@
namespace app\api_broker\service;
use app\model\OFollowUp;
use app\model\OrderModel;
use app\model\reportModel;
/**
* Created by PhpStorm.
......@@ -12,15 +12,15 @@ use app\model\OrderModel;
* Time : 16:41
* Intro:
*/
class FollowUpService
class ReportService
{
private $followUpModel;
private $reportModel;
private $orderModel;
function __construct()
{
$this->followUpModel = new OFollowUp();
$this->reportModel = new ReportModel();
$this->orderModel = new OrderModel();
}
......@@ -38,7 +38,7 @@ class FollowUpService
public function verifyReport($agent_id, $store_id, $user_id, $house_ids, $vehicle, $intro, $predict_see_time)
{
$id = $this->oFollowUpBin($agent_id, $store_id, $user_id, $vehicle, $intro, $predict_see_time);
$id = $this->reportBin($agent_id, $store_id, $user_id, $vehicle, $intro, $predict_see_time);
if ($id > 0) {
$house_arr = explode(",", $house_ids);
......@@ -75,7 +75,7 @@ class FollowUpService
* @param $predict_see_time
* @return array
*/
private function oFollowUpBin($report_agent_id, $report_store_id, $user_id, $vehicle, $intro, $predict_see_time)
private function reportBin($report_agent_id, $report_store_id, $user_id, $vehicle, $intro, $predict_see_time)
{
$param["report_agent_id"] = $report_agent_id;
$param["report_store_id"] = $report_store_id;
......@@ -86,7 +86,7 @@ class FollowUpService
$param["predict_see_time"] = date("Y-m-d H:i:s", $predict_see_time);
$param["create_time"] = date("Y-m-d H:i:s", time());
$param["update_time"] = date("Y-m-d H:i:s", time());
return $this->followUpModel->addFollowUp($param);
return $this->reportModel->addReport($param);
}
/**
......
......@@ -14,10 +14,10 @@ use think\Model;
use think\helper\Time;
use think\Db;
class OFollowUp extends Model
class reportModel extends Model
{
// 设置当前模型对应的完整数据表名称
protected $table = 'o_follow_up';
protected $table = 'o_report';
protected $db;
function __construct()
......@@ -30,7 +30,7 @@ class OFollowUp extends Model
* @param $params
* @return array
*/
public function addFollowUp($params)
public function addReport($params)
{
Db::startTrans();
try {
......
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