优化公式

master
chenzhi 4 years ago
parent 197e129f04
commit 174219d9d5

@ -1956,9 +1956,9 @@ function excelUpStreamTemplate($data, $all_sum_money, $all_pay_amount, $big_all_
$objPHPExcel->getActiveSheet()->setCellValue('E'.$line, $value['pay_amount']);
// $objPHPExcel->getActiveSheet()->setCellValue('J'.$line, $value['sum_money']);
if ($data['pay_type'] == 2) {
$objPHPExcel->getActiveSheet()->setCellValue('J'.$line, "=E{$line}*(1-H{$line})*G{$line}*(1-I{$line})");
$objPHPExcel->getActiveSheet()->setCellValue('J'.$line, "=ROUND(E{$line}*(1-H{$line})*G{$line}*(1-I{$line}),2)");
}else{
$objPHPExcel->getActiveSheet()->setCellValue('J'.$line, "=E{$line}*(1-H{$line})*F{$line}*(1-I{$line})");
$objPHPExcel->getActiveSheet()->setCellValue('J'.$line, "=ROUND(E{$line}*(1-H{$line})*F{$line}*(1-I{$line}),2)");
}
}
@ -2207,7 +2207,7 @@ function excelDownStreamTemplate($data, $all_sum_money, $all_pay_amount, $big_al
$objPHPExcel->getActiveSheet()->setCellValue('E'.$line, $value['fax_ratio'] . '%');
$objPHPExcel->getActiveSheet()->setCellValue('C'.$line, $value['pay_amount']);
// $objPHPExcel->getActiveSheet()->setCellValue('F'.$line, $value['sum_money']);
$objPHPExcel->getActiveSheet()->setCellValue('F'.$line,"=C{$line}*D{$line}*(1-E{$line})");
$objPHPExcel->getActiveSheet()->setCellValue('F'.$line,"=ROUND(C{$line}*D{$line}*(1-E{$line}),2)");
}
$objPHPExcel->getActiveSheet()->setCellValue('B'.$line, $product_name);
$line++;

Loading…
Cancel
Save