示例#1
0
 /**
  * 广告pv统计图
  * @param date $date      
  * @param int $show_type 广告位
  */
 public function GraphAdPv($date, $show_type)
 {
     $obj = new Psys_StationRule();
     $data = $obj->GraphAdPv($date, $show_type);
     $result['x_cat'][] = '广告';
     $i = 0;
     foreach ($data as $k => $v) {
         //$result['x_cat'][$i] = $v['ad_name'];
         //拼接分类
         $datas[$i]['name'] = $v['ad_name'];
         $datas[$i]['data'][] = (int) $v['total'];
         $i++;
     }
     $result['y_data'] = $datas;
     return $result;
 }