作者 郭盛
1 个管道 的构建 通过 耗费 5 秒

修改接口

... ... @@ -153,9 +153,9 @@ class Order extends Api
"page" => "pages/index/index/",
// 数据
"data" =>[
'keyword1'=>["value"=>$user['nickname']],
'keyword2'=>["value"=>$score],
'keyword3'=>["value"=>"赠送积分成功"]
'key1'=>["value"=>$user['nickname']],
'key2'=>["value"=>$score],
'key3'=>["value"=>"赠送积分成功"]
],
);
$result = json_decode($this->sends($post_data),true);
... ... @@ -173,9 +173,9 @@ class Order extends Api
"page" => "pages/index/index/",
// 数据
"data" =>[
'keyword1'=>["value"=>$receive['nickname']],
'keyword2'=>["value"=>$score],
'keyword3'=>["value"=>"接收积分成功"]
'key1'=>["value"=>$receive['nickname']],
'key2'=>["value"=>$score],
'key3'=>["value"=>"接收积分成功"]
],
);
$result = json_decode($this->sends($post_data),true);
... ...
... ... @@ -551,21 +551,21 @@ class Store extends Api
{
$page = $this->request->param('page', 1, 'intval');
$pageNum = $this->request->param('pageNum', 10, 'intval');
$city_name = $this->request->param('city_name');
if(empty($city_name)){
$this->error('城市名称不能为空');
}
$city_id = Db::name('area')->where('name',$city_name)->value('id');
// $city_name = $this->request->param('city_name');
// if(empty($city_name)){
// $this->error('城市名称不能为空');
// }
// $city_id = Db::name('area')->where('name',$city_name)->value('id');
$type_id = $this->request->param('type_id');
if(empty($type_id)){
$data['total_num'] = Db::name('application')
->field('id,image,name,createtime')
->where('city_id',$city_id)
// ->where('city_id',$city_id)
->where('status',1)
->count();
$data['info'] = Db::name('application')
->field('id,image,name,createtime')
->where('city_id',$city_id)
// ->where('city_id',$city_id)
->where('status',1)
->order('createtime desc')
->page($page,$pageNum)
... ... @@ -578,13 +578,13 @@ class Store extends Api
}else{
$data['total_num'] = Db::name('application')
->field('id,image,name,createtime')
->where('city_id',$city_id)
// ->where('city_id',$city_id)
->where('type_id',$type_id)
->where('status',1)
->count();
$data['info'] = Db::name('application')
->field('id,image,name,createtime')
->where('city_id',$city_id)
// ->where('city_id',$city_id)
->where('status',1)
->where('type_id',$type_id)
->order('createtime desc')
... ...