...
|
...
|
@@ -425,6 +425,21 @@ class OrderController extends AdminBaseController |
|
|
if($vs['type'] == 3) {
|
|
|
$objPHPExcel->setActiveSheetIndex(0)
|
|
|
->setCellValueExplicit($vs['cell'] . $i, $vs['user_choose'],\PHPExcel_Cell_DataType::TYPE_STRING);
|
|
|
} elseif($vs['type'] == 8) {
|
|
|
//设置默认行高
|
|
|
$objPHPExcel->getActiveSheet()->getRowDimension($i)->setRowHeight(80);
|
|
|
// 图片生成
|
|
|
$objDrawing[$i] = new \PHPExcel_Worksheet_Drawing();
|
|
|
$objDrawing[$i]->setPath('./upload/'.$vs['user_choose']);
|
|
|
// 设置宽度高度
|
|
|
$objDrawing[$i]->setHeight(80);//照片高度
|
|
|
$objDrawing[$i]->setWidth(80); //照片宽度
|
|
|
/*设置图片要插入的单元格*/
|
|
|
$objDrawing[$i]->setCoordinates($vs['cell'].$i);
|
|
|
// 图片偏移距离
|
|
|
$objDrawing[$i]->setOffsetX(12);
|
|
|
$objDrawing[$i]->setOffsetY(12);
|
|
|
$objDrawing[$i]->setWorksheet($objPHPExcel->getActiveSheet());
|
|
|
} else {
|
|
|
$objPHPExcel->setActiveSheetIndex(0)
|
|
|
->setCellValue($vs['cell'] . $i, $vs['user_choose']);
|
...
|
...
|
|