统计接口
This commit is contained in:
parent
5454364979
commit
a67f782b4d
@ -184,6 +184,7 @@ class Census extends BaseController
|
||||
['name' => '园地','value'=>$sum_69],
|
||||
];
|
||||
$return['qita'] = [
|
||||
['name' => '土地总面积','value'=>$land_area_num],
|
||||
['name' => '农产品销量','value'=>$num_2.'单'],
|
||||
['name' => '农产采购量','value'=>$num_3.'单'],
|
||||
['name' => '已录入商户','value'=>$num_4],
|
||||
|
@ -572,7 +572,30 @@ class Statistics extends BaseController
|
||||
$this->apiSuccess('获取成功',$return);
|
||||
}
|
||||
|
||||
//农业销量
|
||||
// //农业销量
|
||||
// public function get_num15($area_id=0,$street_id=0,$village_id=0){
|
||||
// if ($area_id){
|
||||
// $where[] = ['area_id', '=', $area_id];
|
||||
// }
|
||||
// if ($street_id){
|
||||
// $where[] = ['street_id', '=', $street_id];
|
||||
// }
|
||||
// if ($village_id){
|
||||
// $where[] = ['village_id', '=', $village_id];
|
||||
// }
|
||||
//
|
||||
// $return = [
|
||||
// ['value'=>835,'name'=>'萝卜'],
|
||||
// ['value'=>124,'name'=>'白菜'],
|
||||
// ['value'=>187,'name'=>'芋头'],
|
||||
// ['value'=>251,'name'=>'地瓜'],
|
||||
// ['value'=>902,'name'=>'土豆'],
|
||||
// ['value'=>214,'name'=>'山药'],
|
||||
// ];
|
||||
// $this->apiSuccess('获取成功',$return);
|
||||
// }
|
||||
|
||||
//农产品品牌
|
||||
public function get_num15($area_id=0,$street_id=0,$village_id=0){
|
||||
if ($area_id){
|
||||
$where[] = ['area_id', '=', $area_id];
|
||||
@ -584,14 +607,14 @@ class Statistics extends BaseController
|
||||
$where[] = ['village_id', '=', $village_id];
|
||||
}
|
||||
|
||||
$return = [
|
||||
['value'=>835,'name'=>'萝卜'],
|
||||
['value'=>124,'name'=>'白菜'],
|
||||
['value'=>187,'name'=>'芋头'],
|
||||
['value'=>251,'name'=>'地瓜'],
|
||||
['value'=>902,'name'=>'土豆'],
|
||||
['value'=>214,'name'=>'山药'],
|
||||
];
|
||||
$return['msg'] = [['value'=>835,'name'=>'百合山药企业'],
|
||||
['value'=>124,'name'=>'通滩山药企业'],
|
||||
['value'=>187,'name'=>'百合土豆企业'],
|
||||
['value'=>251,'name'=>'云龙土豆企业'],
|
||||
['value'=>902,'name'=>'奇峰山药企业']];
|
||||
$return['total'] = '62';
|
||||
$return['xl'] = ['43%','1.68'];
|
||||
$return['cgl'] = ['24%','1.21'];
|
||||
$this->apiSuccess('获取成功',$return);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user