Bläddra i källkod

老人补贴资金受理导入

dongbing 2 år sedan
förälder
incheckning
ab897a1db7

+ 8 - 0
ruoyi-modules/mz-business-btgl/src/main/java/com/ruoyi/business/mapper/ZwywBtglLrbtglMapper.java

@@ -1,11 +1,14 @@
 package com.ruoyi.business.mapper;
 
+import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
 import com.ruoyi.business.domain.ZwywBtglLrbtgl;
 import com.ruoyi.common.datascope.handler.DataColumn;
 import com.ruoyi.common.datascope.handler.DataPermission;
 import com.ruoyi.common.datascope.utils.BaseMapperPlus;
+import org.apache.ibatis.annotations.Param;
 
 import java.util.List;
+import java.util.Map;
 
 /**
  * 老人补贴资金受理Mapper接口
@@ -28,4 +31,9 @@ public interface ZwywBtglLrbtglMapper extends BaseMapperPlus<ZwywBtglLrbtgl> {
    List<ZwywBtglLrbtgl> selectSpList (ZwywBtglLrbtgl zwywBtglLrbtgl);
 
    List<ZwywBtglLrbtgl> selectHcList (ZwywBtglLrbtgl zwywBtglLrbtgl);
+
+   void saveBaths(List<ZwywBtglLrbtgl> zwywBtglLrbtglList);
+
+   @InterceptorIgnore(tenantLine = "true")
+   ZwywBtglLrbtgl getZwywBtglLrbtgl( @Param("type")String type,@Param("number") String number, @Param("status") String status);
 }

+ 8 - 0
ruoyi-modules/mz-business-btgl/src/main/java/com/ruoyi/business/service/IZwywBtglLrbtglService.java

@@ -1,5 +1,6 @@
 package com.ruoyi.business.service;
 
+import com.baomidou.mybatisplus.extension.service.IService;
 import com.ruoyi.business.domain.ZwywBtglLrbtgl;
 import com.ruoyi.common.datasource.annotation.Slave;
 
@@ -72,4 +73,11 @@ public interface IZwywBtglLrbtglService
      */
     public int deleteZwywBtglLrbtglByIds(String[] ids);
 
+    /**
+     * 老人补贴资金受理 导入
+     * @param zwywBtglLrbtglList
+     * @return
+     */
+    public String importZwywBtglLrbtgl(List<ZwywBtglLrbtgl> zwywBtglLrbtglList);
+
 }

+ 106 - 5
ruoyi-modules/mz-business-btgl/src/main/java/com/ruoyi/business/service/impl/ZwywBtglLrbtglServiceImpl.java

@@ -1,6 +1,9 @@
 package com.ruoyi.business.service.impl;
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.ruoyi.business.domain.ZwywBtglLrbtgl;
 import com.ruoyi.business.domain.ZwywBtglXmgl;
 import com.ruoyi.business.mapper.ZwywBtglLrbtglMapper;
@@ -8,18 +11,18 @@ import com.ruoyi.business.mapper.ZwywBtglXmglMapper;
 import com.ruoyi.business.service.IZwywBtglLrbtglService;
 import com.ruoyi.common.core.exception.ServiceException;
 import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
 import com.ruoyi.common.security.utils.AmountUtils;
 import com.ruoyi.common.security.utils.SecurityUtils;
 import com.ruoyi.system.api.enums.DataStatus;
 import com.ruoyi.system.utils.SubCodeUtil;
 import org.apache.commons.lang3.ObjectUtils;
+import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import sun.nio.cs.ext.MacArabic;
 
-import java.util.Arrays;
-import java.util.List;
-import java.util.Map;
-import java.util.Objects;
+import java.util.*;
 
 /**
  * 老人补贴资金受理Service业务层处理
@@ -28,7 +31,7 @@ import java.util.Objects;
  * @date 2022-05-24
  */
 @Service
-public class ZwywBtglLrbtglServiceImpl implements IZwywBtglLrbtglService
+public class ZwywBtglLrbtglServiceImpl  implements IZwywBtglLrbtglService
 {
     @Autowired
     private ZwywBtglLrbtglMapper zwywBtglLrbtglMapper;
@@ -177,4 +180,102 @@ public class ZwywBtglLrbtglServiceImpl implements IZwywBtglLrbtglService
         return zwywBtglLrbtglMapper.deleteBatchIds(Arrays.asList(ids));
     }
 
+    @Override
+    public String importZwywBtglLrbtgl(List<ZwywBtglLrbtgl> zwywBtglLrbtglList) {
+
+        if (com.ruoyi.common.core.utils.StringUtils.isNull(zwywBtglLrbtglList) || zwywBtglLrbtglList.size() == 0) {
+            throw new ServiceException("导入数据不能为空!");
+        }
+        for (ZwywBtglLrbtgl n:zwywBtglLrbtglList){
+            if (StringUtils.isEmpty(n.getZjhm())) {
+                throw new ServiceException("证件号码不能为空");
+            }
+        }
+        //list数据去重
+        Long count = zwywBtglLrbtglList.stream().distinct().count();
+        boolean isRepeat = count < zwywBtglLrbtglList.size();
+        if (isRepeat) {
+            throw new ServiceException("导入的Excel有重复信息,请检查。");
+        }
+        int successNum = 0;
+        int failureNum= 0;
+        StringBuilder successMsg = new StringBuilder();
+        StringBuilder failureMsg = new StringBuilder();
+        for (ZwywBtglLrbtgl z:zwywBtglLrbtglList){
+           //证件号码 证件类型 数据状态 status  DataStatus.NORMAL.getCode
+            ZwywBtglLrbtgl one = zwywBtglLrbtglMapper.getZwywBtglLrbtgl(z.getZjlx(),z.getZjhm(),DataStatus.NORMAL.getCode());
+            if (one != null){
+                failureNum++;
+                failureMsg.append("<br/>" + failureNum + "<" + "证件号码:" +z.getZjhm()+ " >已存在,请修改。");
+            }
+        }
+
+        List<ZwywBtglLrbtgl> insertList = new ArrayList<>();
+        for (int i=0;i<zwywBtglLrbtglList.size();i++){
+            //开始导入
+            ZwywBtglLrbtgl zwywBtglLrbtgl = new ZwywBtglLrbtgl();
+
+            zwywBtglLrbtgl.setId(IdUtils.simpleUUID());
+            zwywBtglLrbtgl.setXm(zwywBtglLrbtglList.get(i).getXm());
+            zwywBtglLrbtgl.setZjlx(zwywBtglLrbtglList.get(i).getZjlx());
+            zwywBtglLrbtgl.setZjhm(zwywBtglLrbtglList.get(i).getZjhm());
+            zwywBtglLrbtgl.setCsrq(zwywBtglLrbtglList.get(i).getCsrq());
+            zwywBtglLrbtgl.setXb(zwywBtglLrbtglList.get(i).getXb());
+            zwywBtglLrbtgl.setGj(zwywBtglLrbtglList.get(i).getGj());
+            zwywBtglLrbtgl.setMz(zwywBtglLrbtglList.get(i).getMz());
+            zwywBtglLrbtgl.setWhcd(zwywBtglLrbtglList.get(i).getWhcd());
+            zwywBtglLrbtgl.setHyzk(zwywBtglLrbtglList.get(i).getHyzk());
+            zwywBtglLrbtgl.setZzmm(zwywBtglLrbtglList.get(i).getZzmm());
+            zwywBtglLrbtgl.setRjsr(zwywBtglLrbtglList.get(i).getRjsr());
+            zwywBtglLrbtgl.setSjhm(zwywBtglLrbtglList.get(i).getSjhm());
+            zwywBtglLrbtgl.setGddh(zwywBtglLrbtglList.get(i).getGddh());
+            zwywBtglLrbtgl.setSxsfbq(zwywBtglLrbtglList.get(i).getSxsfbq());
+            zwywBtglLrbtgl.setBtlx(zwywBtglLrbtglList.get(i).getBtlx());
+            zwywBtglLrbtgl.setFfzq(zwywBtglLrbtglList.get(i).getFfzq());
+            zwywBtglLrbtgl.setXqpglx(zwywBtglLrbtglList.get(i).getXqpglx());
+            zwywBtglLrbtgl.setHjlb(zwywBtglLrbtglList.get(i).getHjlb());
+            zwywBtglLrbtgl.setHjszd(zwywBtglLrbtglList.get(i).getHjszd());
+            zwywBtglLrbtgl.setHjdzms(zwywBtglLrbtglList.get(i).getHjdzms());
+            zwywBtglLrbtgl.setJg(zwywBtglLrbtglList.get(i).getJg());
+            zwywBtglLrbtgl.setXjd(zwywBtglLrbtglList.get(i).getXjd());
+            zwywBtglLrbtgl.setJzdzms(zwywBtglLrbtglList.get(i).getJzdzms());
+            zwywBtglLrbtgl.setCjlb(zwywBtglLrbtglList.get(i).getCjlb());
+            zwywBtglLrbtgl.setCjdj(zwywBtglLrbtglList.get(i).getCjdj());
+            zwywBtglLrbtgl.setCjzh(zwywBtglLrbtglList.get(i).getCjzh());
+            zwywBtglLrbtgl.setSfxschx(zwywBtglLrbtglList.get(i).getSfxschx());
+            zwywBtglLrbtgl.setSfcjsb(zwywBtglLrbtglList.get(i).getSfcjsb());
+            zwywBtglLrbtgl.setSbkh(zwywBtglLrbtglList.get(i).getSbkh());
+            zwywBtglLrbtgl.setYblb(zwywBtglLrbtglList.get(i).getYblb());
+            zwywBtglLrbtgl.setPgdj(zwywBtglLrbtglList.get(i).getPgdj());
+            zwywBtglLrbtgl.setJhrxm(zwywBtglLrbtglList.get(i).getJhrxm());
+            zwywBtglLrbtgl.setJhrsjhm(zwywBtglLrbtglList.get(i).getJhrsjhm());
+            zwywBtglLrbtgl.setJhrgx(zwywBtglLrbtglList.get(i).getJhrgx());
+            zwywBtglLrbtgl.setKhyh(zwywBtglLrbtglList.get(i).getKhyh());
+            zwywBtglLrbtgl.setYhzh(zwywBtglLrbtglList.get(i).getYhzh());
+            zwywBtglLrbtgl.setKhmc(zwywBtglLrbtglList.get(i).getKhmc());
+            zwywBtglLrbtgl.setDbrxm(zwywBtglLrbtglList.get(i).getDbrxm());
+            zwywBtglLrbtgl.setDbrdh(zwywBtglLrbtglList.get(i).getDbrdh());
+            zwywBtglLrbtgl.setSljg(zwywBtglLrbtglList.get(i).getSljg());
+            zwywBtglLrbtgl.setSlyj(zwywBtglLrbtglList.get(i).getSlyj());
+            zwywBtglLrbtgl.setShjg(zwywBtglLrbtglList.get(i).getShjg());
+            zwywBtglLrbtgl.setShyj(zwywBtglLrbtglList.get(i).getShyj());
+            zwywBtglLrbtgl.setSpjg(zwywBtglLrbtglList.get(i).getSpjg());
+            zwywBtglLrbtgl.setShyj(zwywBtglLrbtglList.get(i).getShyj());
+            insertList.add(zwywBtglLrbtgl);
+            successNum++;
+            successMsg.append("<br/>"+ successNum + "、姓名: " + zwywBtglLrbtglList.get(i).getXm() + " 导入成功");
+        }
+        if (failureNum > 0) {
+            failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
+            throw new ServiceException(failureMsg.toString());
+        }else
+        {
+            successMsg.insert(0, "恭喜您,数据已全部导入成功!共 " + successNum + " 条,数据如下:");
+        }
+        if (insertList.size()>0){
+            zwywBtglLrbtglMapper.saveBaths(insertList);
+        }
+        return successMsg.toString();
+    }
+
 }

+ 23 - 0
ruoyi-modules/mz-business-btgl/src/main/resources/mapper/business/ZwywBtglLrbtgl.xml

@@ -451,4 +451,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                 <if test="ffdq != null  and ffdq != ''"> and ffdq = #{ffdq}</if>
             </where>
     </select>
+
+
+    <insert id="saveBaths" parameterType="ZwywBtglLrbtgl">
+        insert into zwyw_btgl_lrbtgl (id, xm, zjlx, zjhm, csrq, xb, gj, mz, whcd, hyzk, zzmm, rjsr, sjhm, gddh, sxsfbq, btlx,ffzq, xqpglx, hjlb, hjszd, hjdzms,
+         jg, xjd, jzdzms, cjlb, cjdj, cjzh, sfxschx, sfcjsb, sbkh, yblb, pgdj, jhrxm, jhrsjhm, jhrgx, khyh, yhzh, khmc, dbrxm, dbrdh, sljg, slyj, shjg, shyj, spjg,
+         spyj, create_time_str, create_user_id, create_by, create_user_type,create_area_code, create_unit, create_unit_name)
+        values
+        <foreach item="item" index="index" collection="list" separator=",">
+        ( #{item.id},#{item.xm},#{item.zjlx},#{item.zjhm},#{item.csrq},#{item.xb},#{item.gj},#{item.mz},#{item.whcd},#{item.hyzk},#{item.zzmm},#{item.rjsr},#{item.sjhm},#{item.gddh},#{item.sxsfbq},#{item.btlx},#{item.ffzq},
+            #{item.xqpglx},#{item.hjlb},#{item.hjszd},#{item.hjdzms},
+            #{item.jg},#{item.xjd},#{item.jzdzms},#{item.cjlb},#{item.cjdj},#{item.cjzh},#{item.sfxschx},#{item.sfcjsb},#{item.sbkh},#{item.yblb},#{item.pgdj},#{item.jhrxm},#{item.jhrsjhm},#{item.jhrgx},#{item.khyh},
+            #{item.yhzh},#{item.khmc},#{item.dbrxm},#{item.dbrdh},#{item.sljg},#{item.slyj},#{item.shjg},#{item.shyj},#{item.spjg},#{item.spyj},
+            #{item.createTimeStr},#{item.createUserId},#{item.createBy},#{item.createUserType},
+            #{item.createAreaCode},#{item.createUnit},#{item.createUnitName})
+        </foreach>
+    </insert>
+
+    <select id="getZwywBtglLrbtgl" resultType="ZwywBtglLrbtgl">
+        select * from zwyw_btgl_lrbtgl
+        where zjlx = #{type}
+        and zjhm = #{number}
+        and status = #{status}
+    </select>
 </mapper>

+ 4 - 0
ruoyi-modules/mz-business-tsxdxm/src/main/java/com/ruoyi/business/mapper/ZwywTsxdSmfwMapper.java

@@ -1,5 +1,6 @@
 package com.ruoyi.business.mapper;
 
+import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
 import com.ruoyi.business.domain.ZwywTsxdSmfw;
 import com.ruoyi.common.datascope.handler.DataColumn;
 import com.ruoyi.common.datascope.handler.DataPermission;
@@ -25,4 +26,7 @@ public interface ZwywTsxdSmfwMapper extends BaseMapperPlus<ZwywTsxdSmfw> {
   public int batchSmfw(List<ZwywTsxdSmfw> zwywTsxdSmfwList);
 
   List<Map<String,Object>> selectSmfwLists();
+
+  @InterceptorIgnore(tenantLine = "true")
+  ZwywTsxdSmfw getZwywTsxdSmfw(String projectName,String card);
 }

+ 17 - 12
ruoyi-modules/mz-business-tsxdxm/src/main/java/com/ruoyi/business/service/impl/ZwywTsxdSmfwServiceImpl.java

@@ -167,20 +167,25 @@ public class ZwywTsxdSmfwServiceImpl implements IZwywTsxdSmfwService
         int failureNum= 0;
         StringBuilder successMsg = new StringBuilder();
         StringBuilder failureMsg = new StringBuilder();
-        List<Map<String, Object>> list1 = zwywTsxdSmfwMapper.selectSmfwLists();
+        //List<Map<String, Object>> list1 = zwywTsxdSmfwMapper.selectSmfwLists();
         int index =0;
         for (ZwywTsxdSmfw zwywTsxdSmfw :zwywTsxdSmfwList){
-            index++;
-            Map<String,Object> map = new HashMap<>();
-            map.put("sqrsfzh",zwywTsxdSmfw.getSqrsfzh());
-            map.put("sqrxm",zwywTsxdSmfw.getSqrxm());
-            map.put("yjkzpsr",zwywTsxdSmfw.getYjkzpsr());
-            map.put("snqk",zwywTsxdSmfw.getSnqk());
-            map.put("jdshrxm",zwywTsxdSmfw.getJdshrxm());
-            map.put("jdshyj",zwywTsxdSmfw.getJdshyj());
-            map.put("mzsprxm",zwywTsxdSmfw.getMzsprxm());
-            map.put("mzspyj",zwywTsxdSmfw.getMzspyj());
-            if (list1.contains(map)){
+//            index++;
+//            Map<String,Object> map = new HashMap<>();
+//            map.put("sqrsfzh",zwywTsxdSmfw.getSqrsfzh());
+//            map.put("sqrxm",zwywTsxdSmfw.getSqrxm());
+//            map.put("yjkzpsr",zwywTsxdSmfw.getYjkzpsr());
+//            map.put("snqk",zwywTsxdSmfw.getSnqk());
+//            map.put("jdshrxm",zwywTsxdSmfw.getJdshrxm());
+//            map.put("jdshyj",zwywTsxdSmfw.getJdshyj());
+//            map.put("mzsprxm",zwywTsxdSmfw.getMzsprxm());
+//            map.put("mzspyj",zwywTsxdSmfw.getMzspyj());
+            //项目名称
+            String projectName = zwywTsxdSmfw.getMc();
+            //身份证号
+            String card = zwywTsxdSmfw.getSqrsfzh();
+            ZwywTsxdSmfw getZwywTsxdSmfw = zwywTsxdSmfwMapper.getZwywTsxdSmfw(projectName,card);
+            if (getZwywTsxdSmfw != null){
                 failureNum++;
                 failureMsg.append("<br/>" + failureNum + "<" + "项目名称:" + zwywTsxdSmfw.getMc()  + " 已存在,请修改。");
             }

+ 4 - 0
ruoyi-modules/mz-business-tsxdxm/src/main/resources/mapper/business/smfwMapper.xml

@@ -193,4 +193,8 @@
         select id,xm_id,sqrsfzh,sqrxm,yjkzpsr,snqk,jdshrxm,jdshyj,mzsprxm,mzspyj,
         create_time_str, create_user_id, create_by, create_user_type,create_area_code, create_unit, create_unit_name from zwyw_tsxd_smfw
     </select>
+
+    <select id="getZwywTsxdSmfw" resultType="ZwywTsxdSmfw">
+        select * from zwyw_tsxd_smfw where mc = #{projectName} and sqrsfzh = #{card}
+    </select>
 </mapper>

+ 11 - 0
ruoyi-modules/mz-business/src/main/java/com/ruoyi/business/controller/ZwywBtglLrbtglController.java

@@ -16,6 +16,7 @@ import com.ruoyi.system.validate.group.AddGroup;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.validation.annotation.Validated;
 import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
 
 import javax.servlet.http.HttpServletResponse;
 import java.util.List;
@@ -172,4 +173,14 @@ public class ZwywBtglLrbtglController extends BaseController
     {
         return toAjax(zwywBtglLrbtglService.deleteZwywBtglLrbtglByIds(ids));
     }
+
+    @Log(title = "老人补贴资金受理导入",businessType = BusinessType.IMPORT)
+    @RequiresPermissions("business:lrbtgl:importData")
+    @PostMapping("/importData")
+    public AjaxResult importData(MultipartFile file) throws Exception{
+        ExcelUtil<ZwywBtglLrbtgl> util = new ExcelUtil<>(ZwywBtglLrbtgl.class);
+        List<ZwywBtglLrbtgl> ZwywBtglLrbtglList = util.importExcel(file.getInputStream());
+        String message = zwywBtglLrbtglService.importZwywBtglLrbtgl(ZwywBtglLrbtglList);
+        return AjaxResult.success(message);
+    }
 }

+ 72 - 1
ruoyi-ui/src/views/business/btgl/lrbtgl/index.vue

@@ -19,6 +19,8 @@
           v-hasPermi="['business:lrbtgl:add']">新增</el-button>
       </el-col>
       <el-col :span="1.5">
+        <el-button type="info" plain icon="el-icon-upload2" size="mini" @click="handleImport"
+                   v-has-permi="['business:lrbtgl:importData']">导入</el-button>
       </el-col>
       <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
@@ -349,6 +351,33 @@
       </div>
     </el-dialog>
 
+    <!-- 用户导入对话框 -->
+    <el-dialog v-dialog-drag :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
+      <el-upload
+        ref="upload"
+        :limit="1"
+        accept=".xlsx, .xls"
+        :headers="upload.headers"
+        :action="upload.url"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
+        <div class="el-upload__tip text-center" slot="tip">
+          <span>仅允许导入xls、xlsx格式文件。</span>
+          <!--          <el-link type="primary" :underline="false" style="font-size:12px;vertical-align: baseline;" @click="importTemplate">下载模板</el-link>-->
+        </div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">确 定</el-button>
+        <el-button @click="upload.open = false">取 消</el-button>
+      </div>
+    </el-dialog>
+
     <!--老人补贴资金受理详情-->
     <el-dialog :before-close="dialogClosed" v-dialog-drag title="老人补贴资金受理详情" :visible.sync="openXQ" width="1000px"
       custom-class="custom2" :append-to-body="true">
@@ -515,7 +544,7 @@
 import { addLrbtgl, delLrbtgl, getLrbtgl, listLrbtgl, updateLrbtgl } from '@/api/business/btgl/lrbtgl'
 import { chineseOne, idCard, Regular } from '@/utils/regular'
 import { Constant } from '@/utils/constant'
-
+import { getToken } from '@/utils/auth';
 export default {
   name: 'Lrbtgl',
   dicts: ['C0009', 'CZ036', 'XZ002', 'C0008', 'CZ035', 'CZ002', 'CZ004', 'C0015', 'C0007', 'XZ021', 'C0044', 'CH016', 'C0025', 'C0013', 'C0024', 'XZ074', 'XZ073', 'C0010', 'C0032', 'C0031', 'CH045', 'CH019'],
@@ -544,6 +573,21 @@ export default {
       title: '',
       // 是否显示弹出层
       open: false,
+      // 用户导入参数
+      upload: {
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: { Authorization: "Bearer " + getToken() },
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/business/lrbtgl/importData"
+      },
       // 查询参数
       queryParams: {
         pageNum: 1,
@@ -822,6 +866,33 @@ export default {
         }
       })
     },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "老人补贴资金受理导入";
+      this.upload.open = true;
+    },
+    // /** 下载模板操作 */
+    // importTemplate() {
+    //   this.download('organization/ygJbxx/importTemplate', {
+    //   }, `员工基本信息_模板_${new Date().getTime()}.xlsx`)
+    // },
+// 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+// 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      this.$alert("<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" + response.msg + "</div>", "导入结果", { dangerouslyUseHTMLString: true });
+      this.getList();
+    },
+// 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    },
+
     /** 删除按钮操作 */
     handleDelete(row, index) {
       const ids = row.id || this.ids