Ejemplo n.º 1
0
 public function webCountNDAction()
 {
     $date = reqstr('date', '');
     $date = date('Y_m_d', strtotime($date));
     $stationid = reqnum('stationid');
     if (!$date) {
         return array('code' => 0);
     }
     $model = new Psys_StationModel();
     $list = $model->GetOne(array('date' => $date, 'stationid' => $stationid, 'counttype' => 2), 'detail', 'rha_webcount');
     $dt = str_replace('else', 'Else', $list['detail']);
     $dt = str_replace(' ', '', $dt);
     $dt = str_ireplace(array('ad_uv', 'ad_dm', 'ad_qd', 'ad_aqy', 'ad_pkq', 'ad_dtcq', 'reg_uv', 'verify_success', 'verify_error', 'login_success', 'login_error', 'welcome_uv', 'welcome_dm', 'welcome_qd', 'welcome_aqy', 'welcome_pkq', 'sindex_uv', 'station_pv', 'game_pv', 'movie_pv', 'music_pv', 'game_alert', 'movie_alert', 'music_alert', 'sindex_alert', 'game_down', 'movie_down', 'music_down', 'sindex_down', 'dm_alert', 'qd_alert', 'aqy_alert', 'pkq_alert', 'dm_down', 'qd_down', 'aqy_down', 'pkq_down', 'webindexindex_time', 'webindexregister_time', 'webindexwelcome_time', 'webindexsindex_time', 'webstation_time', 'webgameindex_time', 'webmovieindex_time', 'webmusicindex_time'), array('广告页1/uv', '广告1-多米/pv', '广告1-起点/pv', '广告1-爱奇艺/pv', '广告1-皮卡丘/pv', '广告1-刀塔传奇/pv', '注册页/uv', '验证码发送成功/pv', '验证码发送失败/pv', '登录成功(新注册)/uv', '验证码错误/uv', '广告页2/uv', '广告2-多米/pv', '广告2-起点/pv', '广告2-爱奇艺/pv', '广告2-皮卡丘/pv', 'sindex页/uv', '车站页/pv', '游戏页/pv', '电影页/pv', '音乐页/pv', 'train下载弹窗-游戏页/pv', 'train下载弹窗-电影页/pv', 'train下载弹窗-音乐页/pv', 'train下载弹窗-sindex页/pv', 'train下载-游戏页uv', 'train下载-电影页uv', 'train下载-音乐页uv', 'train下载-sindex页/uv', '第三方App下载弹窗-多米/pv', '第三方App下载弹窗-起点/pv', '第三方App下载弹窗-爱奇/pv', '第三方App下载弹窗-皮卡丘/pv', '第三方App下载-多米/pv', '第三方App下载-起点/pv', '第三方App下载-爱奇艺/pv', '第三方App下载-皮卡丘/pv', '广告页1时长/秒', '注册页时长/秒', '广告页2时长/秒', 'sindex页时长', '车站页时长/秒', '游戏页时长/秒', '电影页时长/秒', '音乐页时长/秒'), $dt);
     $data = json_decode($dt, true);
     $arr = array('android' => 0, 'ios' => 0, 'Else' => 0);
     foreach ($data as $m => &$n) {
         $n += $arr;
     }
     return array('code' => 1, 'allrow' => $data);
 }