|
|
@ -1389,7 +1389,6 @@ class Index extends CI_Controller {
|
|
|
|
$filter_list[] = $row;
|
|
|
|
$filter_list[] = $row;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$export_list = $filter_list;
|
|
|
|
$export_list = $filter_list;
|
|
|
|
// <!$>修改导出的第一条记录, 金额改为剩余金额<!$>
|
|
|
|
// <!$>修改导出的第一条记录, 金额改为剩余金额<!$>
|
|
|
|
if ( ! empty($last_notice_record[0]) && $last_notice_record[0]->TEL_transactionNoticeId==$export_list[0]->pn_sn) {
|
|
|
|
if ( ! empty($last_notice_record[0]) && $last_notice_record[0]->TEL_transactionNoticeId==$export_list[0]->pn_sn) {
|
|
|
@ -1488,16 +1487,25 @@ class Index extends CI_Controller {
|
|
|
|
->SetCellValue('E1', '付款人')
|
|
|
|
->SetCellValue('E1', '付款人')
|
|
|
|
->SetCellValue('F1', '付款人邮箱')
|
|
|
|
->SetCellValue('F1', '付款人邮箱')
|
|
|
|
->SetCellValue('G1', '交易号')
|
|
|
|
->SetCellValue('G1', '交易号')
|
|
|
|
->SetCellValue('H1', '收单时间');
|
|
|
|
->SetCellValue('H1', '收单时间')
|
|
|
|
|
|
|
|
->SetCellValue('I1', '付款人国籍')
|
|
|
|
|
|
|
|
->SetCellValue('J1', '是否重复');
|
|
|
|
$currency_sum = array();
|
|
|
|
$currency_sum = array();
|
|
|
|
bcscale(2);
|
|
|
|
bcscale(2);
|
|
|
|
$rowCount = 2;
|
|
|
|
$rowCount = 2;
|
|
|
|
|
|
|
|
$txn_list = [];
|
|
|
|
foreach ($export_list as $key => $row) {
|
|
|
|
foreach ($export_list as $key => $row) {
|
|
|
|
if( trim($row->pn_mc_currency) != "") {
|
|
|
|
if( trim($row->pn_mc_currency) != "") {
|
|
|
|
$currency_sum[trim($row->pn_mc_currency)] = @ bcadd($currency_sum[trim($row->pn_mc_currency)], $row->pn_mc_gross);
|
|
|
|
$currency_sum[trim($row->pn_mc_currency)] = @ bcadd($currency_sum[trim($row->pn_mc_currency)], $row->pn_mc_gross);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$payer = $row->pn_payer ? ($row->pn_payer . "<" . $row->pn_payer_email . ">") : "退款";
|
|
|
|
$payer = $row->pn_payer ? ($row->pn_payer . "<" . $row->pn_payer_email . ">") : "退款";
|
|
|
|
$orderid = $row->pn_invoice ? $row->pn_invoice : $row->pn_item_number;
|
|
|
|
$orderid = $row->pn_invoice ? $row->pn_invoice : $row->pn_item_number;
|
|
|
|
|
|
|
|
$txn_duplicated = '';
|
|
|
|
|
|
|
|
if (in_array($row->pn_txn_id, $txn_list)) {
|
|
|
|
|
|
|
|
$txn_duplicated = 'X';
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$txn_list[] = $row->pn_txn_id;
|
|
|
|
|
|
|
|
|
|
|
|
$objPHPExcel->getActiveSheet()
|
|
|
|
$objPHPExcel->getActiveSheet()
|
|
|
|
->SetCellValue('A'.$rowCount, ($rowCount-1))
|
|
|
|
->SetCellValue('A'.$rowCount, ($rowCount-1))
|
|
|
|
// ->SetCellValue('A'.$rowCount, $row->pn_sn)
|
|
|
|
// ->SetCellValue('A'.$rowCount, $row->pn_sn)
|
|
|
@ -1507,7 +1515,9 @@ class Index extends CI_Controller {
|
|
|
|
->SetCellValue('E'.$rowCount, $row->pn_payer)
|
|
|
|
->SetCellValue('E'.$rowCount, $row->pn_payer)
|
|
|
|
->SetCellValue('F'.$rowCount, $row->pn_payer_email)
|
|
|
|
->SetCellValue('F'.$rowCount, $row->pn_payer_email)
|
|
|
|
->setCellValueExplicit('G'.$rowCount, $row->pn_txn_id,PHPExcel_Cell_DataType::TYPE_STRING)
|
|
|
|
->setCellValueExplicit('G'.$rowCount, $row->pn_txn_id,PHPExcel_Cell_DataType::TYPE_STRING)
|
|
|
|
->SetCellValue('H'.$rowCount, $row->pn_datetime);
|
|
|
|
->SetCellValue('H'.$rowCount, $row->pn_datetime)
|
|
|
|
|
|
|
|
->SetCellValue('I'.$rowCount, $row->payer_country)
|
|
|
|
|
|
|
|
->setCellValueExplicit('J'.$rowCount, $txn_duplicated,PHPExcel_Cell_DataType::TYPE_STRING);
|
|
|
|
$payer = $orderid = "";
|
|
|
|
$payer = $orderid = "";
|
|
|
|
$rowCount++;
|
|
|
|
$rowCount++;
|
|
|
|
}
|
|
|
|
}
|
|
|
|