|
|
@ -1397,10 +1397,27 @@ class DownloadController extends BaseController {
|
|
|
|
* @author sunke
|
|
|
|
* @author sunke
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public function recharge_data_export() {
|
|
|
|
public function recharge_data_export() {
|
|
|
|
|
|
|
|
// 支付到账时间
|
|
|
|
|
|
|
|
$payedBegTime = I("payed_begtime", '');
|
|
|
|
|
|
|
|
if ($payedBegTime) {
|
|
|
|
|
|
|
|
$payedBegTime = strtotime($payedBegTime);
|
|
|
|
|
|
|
|
$payedEndTime = I("payed_endtime", '');
|
|
|
|
|
|
|
|
if ($payedEndTime) {
|
|
|
|
|
|
|
|
$payedEndTime = strtotime($payedEndTime) + 86400;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if ($payedBegTime && !$payedEndTime) {
|
|
|
|
|
|
|
|
$this->error('到账时间有误,请检查。');
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (($payedEndTime - $payedBegTime) > 31 * 24 * 3600) {
|
|
|
|
|
|
|
|
$this->error('到账时间范围不能超过31天');
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 下单时间
|
|
|
|
$beginTime = strtotime(I('begtime') . ' 00:00:00');
|
|
|
|
$beginTime = strtotime(I('begtime') . ' 00:00:00');
|
|
|
|
$endtime = strtotime(I('endtime') . ' 23:59:59');
|
|
|
|
$endtime = strtotime(I('endtime') . ' 23:59:59');
|
|
|
|
if (($endtime - $beginTime) > 31 * 24 * 3600) {
|
|
|
|
if (($endtime - $beginTime) > 31 * 24 * 3600) {
|
|
|
|
$this->error('时间范围不能超过31天');
|
|
|
|
$this->error('下单时间范围不能超过31天');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
|
|
|
|
$map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
|
|
|
|
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
|
|
|
|
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
|
|
|
@ -1462,6 +1479,10 @@ class DownloadController extends BaseController {
|
|
|
|
$map['tab_spend.spend_time'] = ['between',[$initBegTime,$initEndTime]];
|
|
|
|
$map['tab_spend.spend_time'] = ['between',[$initBegTime,$initEndTime]];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ($payedBegTime) {
|
|
|
|
|
|
|
|
$map['tab_spend.payed_time'] = ['between', [$payedBegTime, $payedEndTime - 1]];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
empty(I('relation_game_id')) || $map['tab_game.relation_game_id'] = I('relation_game_id');
|
|
|
|
empty(I('relation_game_id')) || $map['tab_game.relation_game_id'] = I('relation_game_id');
|
|
|
|
empty(I('sdk_version')) || $map['tab_game.sdk_version'] = I('sdk_version');
|
|
|
|
empty(I('sdk_version')) || $map['tab_game.sdk_version'] = I('sdk_version');
|
|
|
|
empty(I('server_id')) || $map['tab_spend.server_id'] = I('server_id');
|
|
|
|
empty(I('server_id')) || $map['tab_spend.server_id'] = I('server_id');
|
|
|
@ -4587,7 +4608,8 @@ public function iosDetailExcelInfo($id,$map) {
|
|
|
|
'部门长',
|
|
|
|
'部门长',
|
|
|
|
'组长',
|
|
|
|
'组长',
|
|
|
|
'推广员',
|
|
|
|
'推广员',
|
|
|
|
'付款时间',
|
|
|
|
'下单时间',
|
|
|
|
|
|
|
|
'到账时间',
|
|
|
|
);
|
|
|
|
);
|
|
|
|
$records = recordPromoteLogs('数据管理','充值明细导出');
|
|
|
|
$records = recordPromoteLogs('数据管理','充值明细导出');
|
|
|
|
$model = M('spend','tab_');
|
|
|
|
$model = M('spend','tab_');
|
|
|
@ -4692,7 +4714,8 @@ public function iosDetailExcelInfo($id,$map) {
|
|
|
|
$csvData["p_p_proinfo"] = $value1["p_p_proinfo"];
|
|
|
|
$csvData["p_p_proinfo"] = $value1["p_p_proinfo"];
|
|
|
|
$csvData["p_proinfo"] = $value1["p_proinfo"];
|
|
|
|
$csvData["p_proinfo"] = $value1["p_proinfo"];
|
|
|
|
$csvData["proinfo"] = $value1["proinfo"];
|
|
|
|
$csvData["proinfo"] = $value1["proinfo"];
|
|
|
|
$csvData["pay_time"] = $value1["pay_time"];
|
|
|
|
$csvData["spend_time"] = $value1["spend_time"];
|
|
|
|
|
|
|
|
$csvData["payed_time"] = $value1["pay_time"];
|
|
|
|
mb_convert_variables('GBK', 'UTF-8', $csvData);
|
|
|
|
mb_convert_variables('GBK', 'UTF-8', $csvData);
|
|
|
|
fputcsv($fp, $csvData);
|
|
|
|
fputcsv($fp, $csvData);
|
|
|
|
$xlsData[] = $csvData;
|
|
|
|
$xlsData[] = $csvData;
|
|
|
@ -4721,7 +4744,8 @@ public function iosDetailExcelInfo($id,$map) {
|
|
|
|
$csvData1["p_p_proinfo"] = "--";
|
|
|
|
$csvData1["p_p_proinfo"] = "--";
|
|
|
|
$csvData1["p_proinfo"] = "--";
|
|
|
|
$csvData1["p_proinfo"] = "--";
|
|
|
|
$csvData1["proinfo"] = "--";
|
|
|
|
$csvData1["proinfo"] = "--";
|
|
|
|
$csvData1["pay_time"] = "--";
|
|
|
|
$csvData1["spend_time"] = "--";
|
|
|
|
|
|
|
|
$csvData1["payed_time"] = "--";
|
|
|
|
mb_convert_variables('GBK', 'UTF-8', $csvData1);
|
|
|
|
mb_convert_variables('GBK', 'UTF-8', $csvData1);
|
|
|
|
fputcsv($fp, $csvData1);
|
|
|
|
fputcsv($fp, $csvData1);
|
|
|
|
$xlsData[] = $csvData1;
|
|
|
|
$xlsData[] = $csvData1;
|
|
|
|