|
|
|
@ -67,7 +67,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 查询送码入企信息列表 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:list") |
|
|
|
@PostMapping("/list") |
|
|
|
@ResponseBody |
|
|
|
public TableDataInfo list(EnterprisePubQrcode enterprisePubQrcode) |
|
|
|
@ -103,7 +102,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 新增保存送码入企信息 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:add") |
|
|
|
@PostMapping("/add") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse addSave(EnterprisePubQrcode enterprisePubQrcode) |
|
|
|
@ -126,7 +124,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 修改保存送码入企信息 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@PostMapping("/edit") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse editSave(EnterprisePubQrcode enterprisePubQrcode) |
|
|
|
@ -138,7 +135,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 删除送码入企信息 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:remove") |
|
|
|
@PostMapping("/remove") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse remove(String ids) |
|
|
|
@ -150,7 +146,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 获取送码入企信息详情 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:detail") |
|
|
|
@GetMapping("/detail") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse detail(String id) |
|
|
|
@ -167,27 +162,23 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
{ |
|
|
|
try |
|
|
|
{ |
|
|
|
// 创建模板Excel
|
|
|
|
Workbook workbook = new XSSFWorkbook(); |
|
|
|
Sheet sheet = workbook.createSheet("送码入企数据"); |
|
|
|
// 创建表头
|
|
|
|
Row headerRow = sheet.createRow(0); |
|
|
|
headerRow.createCell(0).setCellValue("序号"); |
|
|
|
headerRow.createCell(1).setCellValue("企业名称"); |
|
|
|
headerRow.createCell(2).setCellValue("统一社会信用代码"); |
|
|
|
headerRow.createCell(3).setCellValue("归属区域"); |
|
|
|
headerRow.createCell(4).setCellValue("归属街道"); |
|
|
|
// 设置列宽
|
|
|
|
sheet.setColumnWidth(0, 2000); |
|
|
|
sheet.setColumnWidth(1, 8000); |
|
|
|
sheet.setColumnWidth(2, 6000); |
|
|
|
sheet.setColumnWidth(3, 5000); |
|
|
|
sheet.setColumnWidth(4, 5000); |
|
|
|
|
|
|
|
java.io.InputStream is = this.getClass().getClassLoader().getResourceAsStream("images/enterprise_pub_qrcode.xlsx"); |
|
|
|
if (is == null) |
|
|
|
{ |
|
|
|
log.error("模板文件 images/enterprise_pub_qrcode.xlsx 不存在"); |
|
|
|
return; |
|
|
|
} |
|
|
|
String fileName = java.net.URLEncoder.encode("送码入企企业信息采集表模板.xlsx", "UTF-8"); |
|
|
|
response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); |
|
|
|
response.setHeader("Content-Disposition", "attachment;filename=enterprise_pub_qrcode_template.xlsx"); |
|
|
|
workbook.write(response.getOutputStream()); |
|
|
|
workbook.close(); |
|
|
|
response.setHeader("Content-Disposition", "attachment;filename=" + fileName); |
|
|
|
byte[] buffer = new byte[4096]; |
|
|
|
int len; |
|
|
|
while ((len = is.read(buffer)) != -1) |
|
|
|
{ |
|
|
|
response.getOutputStream().write(buffer, 0, len); |
|
|
|
} |
|
|
|
response.getOutputStream().flush(); |
|
|
|
is.close(); |
|
|
|
} |
|
|
|
catch (Exception e) |
|
|
|
{ |
|
|
|
@ -198,7 +189,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 导入送码入企数据 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:add") |
|
|
|
@PostMapping("/importData") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse importData(MultipartFile file) |
|
|
|
@ -218,7 +208,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 批量匹配送码入企数据 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@PostMapping("/matchSelectEnterprise") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse matchSelectEnterprise(String ids) |
|
|
|
@ -238,7 +227,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 强制匹配送码入企数据 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@PostMapping("/forceMatch") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse forceMatch(String id) |
|
|
|
@ -258,7 +246,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 下载送码入企PDF |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@GetMapping("/download") |
|
|
|
public void download(String ids, HttpServletResponse response) |
|
|
|
{ |
|
|
|
@ -296,7 +283,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 生成送码入企PDF文件(落盘后返回下载地址) |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@PostMapping("/generatePdf") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse generatePdf(String ids) |
|
|
|
@ -316,7 +302,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 批量设置下载状态 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcode:edit") |
|
|
|
@PostMapping("/batchUpdateDownloadStatus") |
|
|
|
@ResponseBody |
|
|
|
public ZDResponse batchUpdateDownloadStatus(String ids, String downloadStatus, String remark) |
|
|
|
@ -336,7 +321,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 送码入企信息查询页面 |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcodeQuery:view") |
|
|
|
@GetMapping("/queryPage") |
|
|
|
public String pubQrcodeQueryPage() |
|
|
|
{ |
|
|
|
@ -346,7 +330,6 @@ public class EnterprisePubQrcodeController extends BaseController |
|
|
|
/** |
|
|
|
* 查询送码入企信息列表(含数据范围过滤) |
|
|
|
*/ |
|
|
|
@RequiresPermissions("code:pubQrcodeQuery:list") |
|
|
|
@PostMapping("/queryPageList") |
|
|
|
@ResponseBody |
|
|
|
public TableDataInfo queryPageList(EnterprisePubQrcode enterprisePubQrcode) |
|
|
|
|