Commit 744ddebd authored by đinh thị đầm's avatar đinh thị đầm
parents 985bcd08 f7378f37
...@@ -489,16 +489,8 @@ public class CampaignExecuteServiceImp implements CampaignExecuteService { ...@@ -489,16 +489,8 @@ public class CampaignExecuteServiceImp implements CampaignExecuteService {
List<CampaignCustomer> lst = null;//campaignCustomerRepository.getCustomerRecallDate(dto.getCampaignId(), dto.getAgentId(), dto.getCompanySiteId(), ); List<CampaignCustomer> lst = null;//campaignCustomerRepository.getCustomerRecallDate(dto.getCampaignId(), dto.getAgentId(), dto.getCompanySiteId(), );
if (lst != null) {
result.setErrorCode(Constants.ApiErrorCode.SUCCESS);
result.setDescription(Constants.ApiErrorDesc.SUCCESS);
//result.setTotalRow(count);
//result.setListData(campaignExecuteRepository.searchCampaignExecute(requestDto, SQLBuilder.buildPageable(requestDto)));
//result.setData(data);
} else {
result.setErrorCode(Constants.ApiErrorCode.ERROR); result.setErrorCode(Constants.ApiErrorCode.ERROR);
result.setDescription(Constants.ApiErrorDesc.ERROR); result.setDescription(Constants.ApiErrorDesc.ERROR);
}
return result; return result;
} }
......
...@@ -253,6 +253,7 @@ public class ScenarioServiceImpl implements ScenarioService { ...@@ -253,6 +253,7 @@ public class ScenarioServiceImpl implements ScenarioService {
StringBuilder sb = new StringBuilder(); StringBuilder sb = new StringBuilder();
boolean isValid = true; boolean isValid = true;
XSSFWorkbook workbook = null; XSSFWorkbook workbook = null;
FileInputStream fis = null;
try { try {
List<String> fileHeaderList = new ArrayList<>(); List<String> fileHeaderList = new ArrayList<>();
fileHeaderList.add(BundleUtils.getLangString("scenario.template.questionCode", locale)); fileHeaderList.add(BundleUtils.getLangString("scenario.template.questionCode", locale));
...@@ -265,7 +266,7 @@ public class ScenarioServiceImpl implements ScenarioService { ...@@ -265,7 +266,7 @@ public class ScenarioServiceImpl implements ScenarioService {
fileHeaderList.add(BundleUtils.getLangString("scenario.template.mappingQuestion", locale)); fileHeaderList.add(BundleUtils.getLangString("scenario.template.mappingQuestion", locale));
File file = new File(path); File file = new File(path);
FileInputStream fis = new FileInputStream(file); fis = new FileInputStream(file);
workbook = new XSSFWorkbook(fis); workbook = new XSSFWorkbook(fis);
ByteArrayOutputStream os = new ByteArrayOutputStream(); ByteArrayOutputStream os = new ByteArrayOutputStream();
Sheet sheet = workbook.getSheetAt(0); Sheet sheet = workbook.getSheetAt(0);
...@@ -447,6 +448,7 @@ public class ScenarioServiceImpl implements ScenarioService { ...@@ -447,6 +448,7 @@ public class ScenarioServiceImpl implements ScenarioService {
result.put("message", BundleUtils.getLangString("customer.errorValidate", locale)); result.put("message", BundleUtils.getLangString("customer.errorValidate", locale));
}finally { }finally {
if (workbook != null) workbook.close(); if (workbook != null) workbook.close();
if(fis != null) fis.close();
} }
return result; return result;
} }
......
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 to comment