Commit 16e3d1a9 authored by zhuwei's avatar zhuwei

新增-客户电话跟进

parent a5d588d8
...@@ -12,6 +12,7 @@ namespace app\api_broker\controller; ...@@ -12,6 +12,7 @@ namespace app\api_broker\controller;
use app\api\untils\JwtUntils; use app\api\untils\JwtUntils;
use app\api_broker\extend\Basic; use app\api_broker\extend\Basic;
use app\model\AAgents; use app\model\AAgents;
use app\model\UPhoneFollowPp;
use think\Request; use think\Request;
class Broker extends Basic class Broker extends Basic
...@@ -75,7 +76,7 @@ class Broker extends Basic ...@@ -75,7 +76,7 @@ class Broker extends Basic
/** /**
* 获取经纪人列表 * 获取经纪人列表
* *
* @return \think\Response phone_follow_up * @return \think\Response
*/ */
public function getBroker() { public function getBroker() {
$data['status'] = 200; $data['status'] = 200;
...@@ -103,4 +104,37 @@ class Broker extends Basic ...@@ -103,4 +104,37 @@ class Broker extends Basic
return $this->response($data['status'], $data['msg'], $data['data']); return $this->response($data['status'], $data['msg'], $data['data']);
} }
/**
* 新增-客户电话跟进
* @return \think\Response
*/
public function add_phone_follow_up()
{
$params = $this->params;
/*$params['content']='跟进内容';//跟进内容
$params['labels_id']=1;//g_labels表主键
$params['user_id']=1;//u_users ID用户表id*/
if (!isset($params['content']) || !isset($params['labels_id']) || !isset($params['user_id'])) {
return $this->response("300", "参数不全", [ 'remote_groupid' => '' ]);
}
$content = $params['content'];
$labels_id = $params['labels_id'];
$user_id = $params['user_id'];
//主表查询商铺详细信息
$UPhoneFollowPp = new UPhoneFollowPp();
$UPhoneFollowPp->content =$content;
$UPhoneFollowPp->labels_id = $labels_id;
$UPhoneFollowPp->user_id =$user_id;
$UPhoneFollowPp->save();
//dump($UPhoneFollowPp->id);exit;
if ($UPhoneFollowPp->id) {
return $this->response("200", "success!", $UPhoneFollowPp->id);
} else {
return $this->response("101", "失败!");
}
}
} }
\ No newline at end of file
<?php
namespace app\model;
class UPhoneFollowPp extends BaseModel
{
protected $table = 'u_phone_follow_up';
protected $UPhoneFollowPp;
function __construct()
{
$this->UPhoneFollowPp = Db($this->table);
}
public function getall()
{
return $this->UPhoneFollowPp->find();
}
}
...@@ -222,6 +222,8 @@ Route::group('broker', [ ...@@ -222,6 +222,8 @@ Route::group('broker', [
'getBroker' => ['api_broker/broker/getBroker',['method'=>'get']],//获取经纪人列表 'getBroker' => ['api_broker/broker/getBroker',['method'=>'get']],//获取经纪人列表
'labelEdit' => ['index/label/index',['method'=>'get|post']], //编辑标签 'labelEdit' => ['index/label/index',['method'=>'get|post']], //编辑标签
'getLabelsList' => ['index/label/getLabelsList',['method'=>'get']], //标签列表 'getLabelsList' => ['index/label/getLabelsList',['method'=>'get']], //标签列表
'add_phone_follow_up' => ['api_broker/broker/add_phone_follow_up',['method'=>'get|post']],//新增-客户电话跟进
]); ]);
//Route::miss('api/index/miss');//处理错误的url //Route::miss('api/index/miss');//处理错误的url
\ 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