|
@@ -618,7 +618,6 @@ class Manage
|
|
|
}
|
|
|
|
|
|
public function area_api(){
|
|
|
-
|
|
|
$month = Dever::input('month', date('Y-m'));
|
|
|
$start_time = $month .'-01 00:00:00';
|
|
|
$where = array();
|
|
@@ -632,48 +631,6 @@ class Manage
|
|
|
foreach($shop as $k=>$v){
|
|
|
$data[$v['city']]=$v;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
foreach($data as $k => $v){
|
|
|
$w['month'] = $where['start'];
|
|
|
|
|
@@ -711,23 +668,6 @@ class Manage
|
|
|
$data[$k]['citys']['l_price'] =$shop_area['price'] * 0.01;
|
|
|
$data[$k]['citys']['l_num'] = $shop_area['num'];
|
|
|
$data[$k]['citys']['price'] = $data[$k]['citys']['price'] + $data[$k]['citys']['l_price'];
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
$w['mid'] = $data[$k]['citys']['mid'];
|
|
|
$w['area'] = $data[$k]['citys']['area'];
|
|
|
$w['price'] = $data[$k]['citys']['price'];
|
|
@@ -736,7 +676,7 @@ class Manage
|
|
|
$w['t_num'] = $data[$k]['citys']['t_num'];
|
|
|
$w['t_price'] = $data[$k]['citys']['t_price']['total'];
|
|
|
$w['l_num'] = $data[$k]['citys']['l_num'];
|
|
|
- $w['l_price'] = $data[$k]['citys']['l_price'];
|
|
|
+ $w['l_price'] = $shop_area['price'];
|
|
|
|
|
|
$shop = Dever::db('mail/area_stat')->find(array('month'=>$w['month'],'area'=>$data[$k]['citys']['area']));
|
|
|
if(!$shop){
|
|
@@ -776,23 +716,9 @@ class Manage
|
|
|
|
|
|
|
|
|
$shop_area = $this->ls($where);
|
|
|
- $data[$k]['countys']['l_price'] =$shop_area['price'] * 0.03;
|
|
|
+ $data[$k]['countys']['l_price'] = $shop_area['price'] * 0.03;
|
|
|
$data[$k]['countys']['l_num'] = $shop_area['num'];
|
|
|
$data[$k]['countys']['price'] = $data[$k]['countys']['price'] + $data[$k]['countys']['l_price'];
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
|
|
|
$w['mid'] = $data[$k]['countys']['mid'];
|
|
|
$w['area'] = $data[$k]['countys']['area'];
|
|
@@ -802,7 +728,7 @@ class Manage
|
|
|
$w['t_num'] = $data[$k]['countys']['t_num'];
|
|
|
$w['t_price'] = $data[$k]['countys']['t_price']['total'];
|
|
|
$w['l_num'] = $data[$k]['countys']['l_num'];
|
|
|
- $w['l_price'] = $data[$k]['countys']['l_price'];
|
|
|
+ $w['l_price'] = $shop_area['price'];
|
|
|
$shop = Dever::db('mail/area_stat')->find(array('month'=>$w['month'],'area'=>$data[$k]['countys']['area']));
|
|
|
if(!$shop){
|
|
|
Dever::db('mail/area_stat')->insert($w);
|
|
@@ -844,20 +770,6 @@ class Manage
|
|
|
$data[$k]['towns']['l_price'] =$shop_area['price'] * 0.05;
|
|
|
$data[$k]['towns']['l_num'] = $shop_area['num'];
|
|
|
$data[$k]['towns']['price'] = $data[$k]['towns']['price'] + $data[$k]['towns']['l_price'];
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
|
|
|
$w['mid'] = $data[$k]['towns']['mid'];
|
|
|
$w['area'] = $data[$k]['towns']['area'];
|
|
@@ -867,7 +779,7 @@ class Manage
|
|
|
$w['t_num'] = $data[$k]['towns']['t_num'];
|
|
|
$w['t_price'] = $data[$k]['towns']['t_price']['total'];
|
|
|
$w['l_num'] = $data[$k]['towns']['l_num'];
|
|
|
- $w['l_price'] = $data[$k]['towns']['l_price'];
|
|
|
+ $w['l_price'] = $shop_area['price'];
|
|
|
$shop = Dever::db('mail/area_stat')->find(array('month'=>$w['month'],'area'=>$data[$k]['towns']['area']));
|
|
|
if(!$shop){
|
|
|
Dever::db('mail/area_stat')->insert($w);
|