| @@ -295,7 +295,7 @@ public class AsyncTask { | |||||
| //@Async | //@Async | ||||
| public void importExcelPoiData(File file, MallUserInfo user, String importKey,HttpServletRequest request, HttpServletResponse response) { | public void importExcelPoiData(File file, MallUserInfo user, String importKey,HttpServletRequest request, HttpServletResponse response) { | ||||
| String[] importFields = new String[]{"服务商POI_ID", "POI名称", "省份", "城市", "地址", "经度", "纬度", "高德ID(非必填)", | String[] importFields = new String[]{"服务商POI_ID", "POI名称", "省份", "城市", "地址", "经度", "纬度", "高德ID(非必填)", | ||||
| "已匹配POI_ID", "已匹配POI名称", "已匹配POI省份", "已匹配POI城市", "已匹配POI地址", "未匹配原因", "其他信息","POI导入结果"}; | |||||
| "已匹配POI_ID", "已匹配POI名称", "已匹配POI省份", "已匹配POI城市", "已匹配POI地址", "未匹配原因", "其他信息"}; | |||||
| String[] needFields = new String[]{"服务商POI_ID","已匹配POI_ID"}; | String[] needFields = new String[]{"服务商POI_ID","已匹配POI_ID"}; | ||||
| ExcelImportResult<MerchantPoiT> datalist = handleImportFile(importKey,file,MerchantPoiT.class,importFields,needFields,new AsyncTask.PoiExcelHandler()); | ExcelImportResult<MerchantPoiT> datalist = handleImportFile(importKey,file,MerchantPoiT.class,importFields,needFields,new AsyncTask.PoiExcelHandler()); | ||||
| if (null == datalist) { | if (null == datalist) { | ||||
| @@ -67,8 +67,4 @@ public class MerchantPoiT implements Serializable { | |||||
| @io.swagger.annotations.ApiModelProperty(value="其他信息",name="extra") | @io.swagger.annotations.ApiModelProperty(value="其他信息",name="extra") | ||||
| private String extra; | private String extra; | ||||
| @Excel(name = "POI导入结果", width = 20, orderNum = "16") | |||||
| @io.swagger.annotations.ApiModelProperty(value="POI导入结果",name="importRemark") | |||||
| private String importRemark; | |||||
| } | } | ||||
| @@ -558,11 +558,11 @@ public class TtMerchantPoiServiceImpl implements TtMerchantPoiService { | |||||
| @Override | @Override | ||||
| public void importOneMem(MallUserInfo user, MerchantPoiT poiBase) { | public void importOneMem(MallUserInfo user, MerchantPoiT poiBase) { | ||||
| if (StringUtils.isBlank(poiBase.getMerchantId())) { | if (StringUtils.isBlank(poiBase.getMerchantId())) { | ||||
| poiBase.setImportRemark("导入失败.服务商POI_ID为空"); | |||||
| poiBase.setMismatchStatusDesc("导入失败.服务商POI_ID为空"); | |||||
| return; | return; | ||||
| } | } | ||||
| if (StringUtils.isBlank(poiBase.getPoiId())) { | if (StringUtils.isBlank(poiBase.getPoiId())) { | ||||
| poiBase.setImportRemark("导入失败.已匹配POI_ID为空"); | |||||
| poiBase.setMismatchStatusDesc("导入失败.已匹配POI_ID为空"); | |||||
| return; | return; | ||||
| } | } | ||||
| @@ -596,10 +596,10 @@ public class TtMerchantPoiServiceImpl implements TtMerchantPoiService { | |||||
| }else{ | }else{ | ||||
| ttMerchantPoiMapper.updateById(merchantPoi); | ttMerchantPoiMapper.updateById(merchantPoi); | ||||
| } | } | ||||
| poiBase.setImportRemark("导入成功"); | |||||
| poiBase.setMismatchStatusDesc("导入成功"); | |||||
| } catch (Exception e) { | } catch (Exception e) { | ||||
| logger.error("importOneMem error.",e); | logger.error("importOneMem error.",e); | ||||
| poiBase.setImportRemark("导入失败."+e.getMessage()); | |||||
| poiBase.setMismatchStatusDesc("导入失败."+e.getMessage()); | |||||
| return; | return; | ||||
| } | } | ||||
| } | } | ||||