Commit 4987d99e by 杨树贤

导入csv问题

parent b011c852
......@@ -248,4 +248,5 @@ function makePassword($length)
function isDateTime($dateTime){
$ret = strtotime($dateTime);
return $ret !== FALSE && $ret != -1;
}
\ No newline at end of file
}
<?php
namespace App\Utils;
use PHPExcel_Cell;
use PHPExcel_Cell_DataType;
use PHPExcel_Cell_IValueBinder;
use PHPExcel_Cell_DefaultValueBinder;
class CsvValueBinder extends PHPExcel_Cell_DefaultValueBinder implements PHPExcel_Cell_IValueBinder
{
public function bindValue(PHPExcel_Cell $cell, $value = null)
{
if (is_numeric($value)) {
$cell->setValueExplicit($value, PHPExcel_Cell_DataType::TYPE_STRING);
return true;
}
return parent::bindValue($cell, $value);
}
}
\ No newline at end of file
......@@ -363,7 +363,7 @@ return array(
|
*/
'heading' => 'false',
'heading' => 'true',
/*
|--------------------------------------------------------------------------
......
销售订单号,采购订单号,*检货时间,销售,*采购员,A/B单,*供应商,*型号,*品牌,*数量,批次,产地,入库日期,来货单号,送货单,理货要求,验货要求,*不良数,异常等级,不良现象,*检验结果,备注
1202206066763112,1202206066763133,2020/2/3,123,易敏,123,深圳市华之电科技有限公司,123,123,123,123,123,2020/2/3,123,123,123,123,123,1,特批入库,特批入库,123
1202206066763114444,120220606676313555,2020/2/3,123,易敏,123,深圳市华之电科技有限公司,123,123,123,123,123,2020/2/3,123,123,123,123,123,1,特批入库,特批入库,123
......@@ -64,7 +64,7 @@
{type: 'checkbox'},
{field: 'id', title: 'ID', align: 'center', width: 80},
{field: 'order_sn', title: '销售订单号', align: 'center', width: 150},
{field: 'purchase_sn', title: '采购订单号', align: 'center', width: 150},
{field: 'purchase_sn', title: '采购订单号', align: 'center', width: 160},
{
field: 'examine_time', title: '检货时间', align: 'center', width: 130
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment