Commit 532a4892 authored by hujun's avatar hujun

适合业态

parent 39ad74b2
<?php
namespace app\api_broker\controller;
use app\api_broker\extend\Basic;
use app\api_broker\untils\RongDemo;
use app\model\BindingPhone;
use app\model\AliYunPhone;
class RongPhone extends Basic
{
protected $code = 200;
protected $data = [];
protected $msg = "";
/**绑定AXB
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public function rBindAXB(){
$bind = new BindingPhone();
$params = $this->request->param();
$data=array();
$Rong = new RongDemo();
$aliYunPhone = new AliYunPhone();
$code= $Rong->statusCode;
$phone_a = $params['phone_a'];
$phone_b = $params['phone_b'];
/*查询分配的中间号*/
$where['a.status'] = 1;
$where['a.type'] = 2;
$where['a.phone_a'] = $phone_a;
$where['a.phone_b'] = $phone_b;
$phone_x['phone_x'] = $aliYunPhone->getAliYunPhone($phone_a,$phone_b,$type=2);
var_dump($phone_x);
exit;
if(!$phone_x){
}
$data['data'] = $Rong->setNumber($phone_a,$phone_b,$phone_x['phone_x'],$phone_x['area']);
$data['msg']=$code[$data['data']['statusCode']];
/*绑定成功*/
if($data['data']['statusCode']=='000000'){
}
$data2=json_encode($data);
echo $data2;
}
/**
* 解绑AXB
*/
public function rongReleaseNumber(){
$Rong = new RongDemo();
$params = $this->request->param();
// $mappingId = 'NME201201803141740516611729495567817080219070';
$r = $Rong->releaseNumber($params['mappingId']);
echo $r;
}
}
\ No newline at end of file
......@@ -215,6 +215,10 @@ class Shop extends Basic
default:
return $this->response("101", "请求数据异常");
}
if (isset($params['fit_industry_type'])) { //业态
$conditions['fit_industry_type'] = array('like', "%" . trim($params['fit_industry_type']) . "%");
}
if (!empty($conditions)) {
$conditions['status'] = array('eq', 1); //只显示上架
if ($params['site_area'] == 1 || $params['site_area'] == 2) {
......
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