From c06bc0658b1ac7ce356bf490adce9c616691605e Mon Sep 17 00:00:00 2001 From: 21819 Date: Fri, 1 Mar 2024 20:36:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=A1=E4=BB=B6=E6=9F=A5=E8=AF=A2=E5=92=8C?= =?UTF-8?q?=E4=B8=8D=E6=BB=A1=E6=84=8F=E4=BF=A1=E4=BB=B6=E6=B5=81=E7=A8=8B?= =?UTF-8?q?=E8=8A=82=E7=82=B9=E6=98=BE=E7=A4=BA=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/system/MailLabelController.java | 8 ++++++++ .../com/biutag/lan/domain/vo/QueryMailVo.java | 2 +- .../com/biutag/lan/service/IMailLabelService.java | 2 ++ .../lan/service/impl/MailLabelServiceImpl.java | 15 +++++++++++++++ .../src/main/resources/mapper/WorkMapper.xml | 2 +- 5 files changed, 27 insertions(+), 2 deletions(-) diff --git a/mailbox-lan/src/main/java/com/biutag/lan/controller/system/MailLabelController.java b/mailbox-lan/src/main/java/com/biutag/lan/controller/system/MailLabelController.java index b40cf03..a291198 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/controller/system/MailLabelController.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/controller/system/MailLabelController.java @@ -30,6 +30,14 @@ public class MailLabelController { return AjaxResult.success(mailLabelVOList); } + @NotPower + @GetMapping("/detail") + @ApiOperation(value="已选信件标签") + public AjaxResult> checked(@RequestBody String mailId) { + List mailLabelVOList = iMailLabelService.checkedLabels(mailId); + return AjaxResult.success(mailLabelVOList); + } + @NotPower @PostMapping("/add") @ApiOperation(value="信件标签新增") diff --git a/mailbox-lan/src/main/java/com/biutag/lan/domain/vo/QueryMailVo.java b/mailbox-lan/src/main/java/com/biutag/lan/domain/vo/QueryMailVo.java index cc12abd..45cbc19 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/domain/vo/QueryMailVo.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/domain/vo/QueryMailVo.java @@ -78,7 +78,7 @@ public class QueryMailVo { * 信件当前流程节点 */ @ExcelProperty("流程节点") - private String flowBeforeName; + private String flowName; /** * 当前流程剩余多少时间(秒) diff --git a/mailbox-lan/src/main/java/com/biutag/lan/service/IMailLabelService.java b/mailbox-lan/src/main/java/com/biutag/lan/service/IMailLabelService.java index 31508a0..4edba28 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/service/IMailLabelService.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/service/IMailLabelService.java @@ -13,4 +13,6 @@ public interface IMailLabelService { AjaxResult addLabel(MailLabelValidate mailLabel); void insertLabel(MailLabelInsertValidate mailLabel); + + List checkedLabels(String mailId); } diff --git a/mailbox-lan/src/main/java/com/biutag/lan/service/impl/MailLabelServiceImpl.java b/mailbox-lan/src/main/java/com/biutag/lan/service/impl/MailLabelServiceImpl.java index a0cc75b..9e0b70e 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/service/impl/MailLabelServiceImpl.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/service/impl/MailLabelServiceImpl.java @@ -66,4 +66,19 @@ public class MailLabelServiceImpl implements IMailLabelService { mail.setMailLabels(mailLabel.getLabelName()); mailMapper.updateById(mail); } + + @Override + public List checkedLabels(String mailId) { + Mail mail = mailMapper.selectById(mailId); + String[] labels = mail.getMailLabels().split(","); + List result = new ArrayList<>(); + for (String label : labels) { + MailLabel mailLabel = mailLabelMapper.selectOne(new QueryWrapper().eq("id", label)); + MailLabelVO mailLabelVO = new MailLabelVO(); + mailLabelVO.setId(mailLabel.getId()); + mailLabelVO.setLabelName(mailLabel.getLabelName()); + result.add(mailLabelVO); + } + return result; + } } diff --git a/mailbox-lan/src/main/resources/mapper/WorkMapper.xml b/mailbox-lan/src/main/resources/mapper/WorkMapper.xml index 52828a2..3e3f78d 100644 --- a/mailbox-lan/src/main/resources/mapper/WorkMapper.xml +++ b/mailbox-lan/src/main/resources/mapper/WorkMapper.xml @@ -27,7 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"