From 3beeb81063a8aed1a0f04c787dbfcc44a2f2798c Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Tue, 12 Jan 2021 11:07:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E4=BC=9A=E4=BF=A1=E6=81=AF=E7=99=BB?= =?UTF-8?q?=E8=AE=B0=E4=BF=A1=E6=81=AF=E8=A1=A5=E5=85=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/SocietyInfoController.class.php | 10 +++++----- Application/Admin/View/SocietyInfo/lists.html | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Application/Admin/Controller/SocietyInfoController.class.php b/Application/Admin/Controller/SocietyInfoController.class.php index 85a72bd25..f64a126c8 100644 --- a/Application/Admin/Controller/SocietyInfoController.class.php +++ b/Application/Admin/Controller/SocietyInfoController.class.php @@ -620,13 +620,13 @@ class SocietyInfoController extends ThinkController //创建PHPExcel对象,注意,不能少了\ $PHPExcel=new \PHPExcel(); //如果excel文件后缀名为.xls,导入这个类 -// if($exts == 'xls'){ + if($exts == 'xls'){ //import("Org.Util.PHPExcel.Reader.Excel5"); $PHPReader=new \PHPExcel_Reader_Excel5(); -// }else if($exts == 'xlsx'){ -// //import("Org.Util.PHPExcel.Reader.Excel2007"); -// $PHPReader=new \PHPExcel_Reader_Excel2007(); -// } + }else if($exts == 'xlsx'){ + //import("Org.Util.PHPExcel.Reader.Excel2007"); + $PHPReader=new \PHPExcel_Reader_Excel2007(); + } //载入文件 $PHPExcel=$PHPReader->load($filename); //获取表中的第一个工作表,如果要获取第二个,把0改为1,依次类推 diff --git a/Application/Admin/View/SocietyInfo/lists.html b/Application/Admin/View/SocietyInfo/lists.html index f17dbc3e8..c7c6e72db 100644 --- a/Application/Admin/View/SocietyInfo/lists.html +++ b/Application/Admin/View/SocietyInfo/lists.html @@ -396,7 +396,7 @@ var oReq = new XMLHttpRequest(); var formFile = new FormData(); - formFile.append("excelData", fileObj,"excelData.xlsx"); //加入文件对象 + formFile.append("excelData", fileObj); //加入文件对象 layer.confirm('【提示】是否确认导入公会信息', { btn: ['确认','取消'],