From 6dedfa9ea4ce951addca71943dbdcaa0e042ce07 Mon Sep 17 00:00:00 2001 From: yuezhihang Date: Wed, 10 Nov 2021 09:32:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E7=BB=84=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/adc/da/slrs/wgDept/dao/WgDeptDao.java | 3 +- .../com/adc/da/slrs/wgDept/entity/WgDept.java | 10 ++- .../adc/da/slrs/wgDept/entity/WgDeptShow.java | 75 +++++++++++++++++ .../wgMeetingInfo/entity/WgMeetingInfo.java | 33 +++++--- .../WgMeetingUserRelationController.java | 23 +++++ .../dao/WgMeetingUserRelationDao.java | 20 +++++ .../entity/WgMeetingUserRelation.java | 34 ++++++++ .../entity/WgMeetingUserRelationShow.java | 45 ++++++++++ .../IWgMeetingUserRelationService.java | 16 ++++ .../WgMeetingUserRelationServiceImpl.java | 20 +++++ .../da/slrs/wgNetInfo/dao/WgNetInfoDao.java | 3 +- .../da/slrs/wgNetInfo/entity/WgNetInfo.java | 4 + .../slrs/wgNetInfo/entity/WgNetInfoDTO.java | 64 ++++++++++++++ .../da/slrs/wgPayInfo/entity/WgPayInfo.java | 7 +- .../slrs/wgWorkGroup/entity/WgWorkGroup.java | 4 +- .../entity/WgWorkGroupShowDTO.java | 3 +- .../service/impl/WgWorkGroupServiceImpl.java | 84 +++++++++++++++---- .../mybatis/mapper/wgDept/WgDeptMapper.xml | 8 +- .../wgMeetingInfo/WgMeetingInfoMapper.xml | 16 +++- .../WgMeetingUserRelationMapper.xml | 12 +++ .../mapper/wgNetInfo/WgNetInfoMapper.xml | 8 +- 21 files changed, 449 insertions(+), 43 deletions(-) create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDeptShow.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/controller/WgMeetingUserRelationController.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/dao/WgMeetingUserRelationDao.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelation.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelationShow.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/IWgMeetingUserRelationService.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/impl/WgMeetingUserRelationServiceImpl.java create mode 100644 adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfoDTO.java create mode 100644 adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingUserRelation/WgMeetingUserRelationMapper.xml diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/dao/WgDeptDao.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/dao/WgDeptDao.java index a8477a26..5cb113d5 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/dao/WgDeptDao.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/dao/WgDeptDao.java @@ -1,6 +1,7 @@ package com.adc.da.slrs.wgDept.dao; import com.adc.da.slrs.wgDept.entity.WgDept; +import com.adc.da.slrs.wgDept.entity.WgDeptShow; import com.adc.da.slrs.wgMeetingInfo.entity.WgMeetingInfo; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import org.apache.ibatis.annotations.Param; @@ -16,5 +17,5 @@ import java.util.List; * @since 2021-11-04 */ public interface WgDeptDao extends BaseMapper { - List researchDatas(@Param(value = "data") String data); + List researchDatas(@Param(value = "data") String data); } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDept.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDept.java index 07b6d5b0..0566b276 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDept.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDept.java @@ -11,6 +11,8 @@ import lombok.Data; import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; +import java.util.List; + /** *

* 集团参与情况 @@ -49,8 +51,12 @@ public class WgDept extends BaseEntity { private String identity; @ApiModelProperty(value = "资料") - @TableField("datum") - private String datum; + @TableField("joinfile") + private String joinfile; + + @ApiModelProperty(value = "前端id") + @TableField("join_id") + private String joinId; } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDeptShow.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDeptShow.java new file mode 100644 index 00000000..db6423e3 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgDept/entity/WgDeptShow.java @@ -0,0 +1,75 @@ +package com.adc.da.slrs.wgDept.entity; + +import com.adc.da.base.entity.BaseEntity; +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableField; +import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 集团参与情况 + *

+ * + * @author super_liu + * @since 2021-11-04 + */ +@Data +@EqualsAndHashCode(callSuper = true) +@Accessors(chain = true) +@ApiModel(value="WgDept对象", description="集团参与情况") +public class WgDeptShow extends BaseEntity { + + private static final long serialVersionUID = 1L; + + @ApiModelProperty(value = "id") + @TableId(value = "id",type = IdType.UUID) + private String id; + + @ApiModelProperty(value = "工作组id") + @TableField("wg_id") + private String wgId; + + @ApiModelProperty(value = "我司在工作组排名顺序") + @TableField("dept_order") + private String deptOrder; + + @ApiModelProperty(value = "我司人员") + @TableField("dept_people_id") + private String deptPeopleId; + + @ApiModelProperty(value = "身份") + @TableField("identity") + private String identity; + + @ApiModelProperty(value = "资料") + @TableField("joinfile") + private String joinfile; + + @ApiModelProperty(value = "中文名") + private String name; + + @ApiModelProperty(value = "单位") + private String unit; + + @ApiModelProperty(value = "单位名称") + private String unitName; + + @ApiModelProperty(value = "电话") + private String phone; + + @ApiModelProperty(value = "邮箱") + private String email; + + @ApiModelProperty(value = "部门Id") + private String deptId; + + @ApiModelProperty(value = "部门名称") + private String deptName; + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingInfo/entity/WgMeetingInfo.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingInfo/entity/WgMeetingInfo.java index 4fa0854a..5c6d33cd 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingInfo/entity/WgMeetingInfo.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingInfo/entity/WgMeetingInfo.java @@ -2,16 +2,21 @@ package com.adc.da.slrs.wgMeetingInfo.entity; import com.adc.da.base.entity.BaseEntity; import java.time.LocalDateTime; +import java.util.Date; +import java.util.List; +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelationShow; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; +import org.springframework.format.annotation.DateTimeFormat; /** *

@@ -40,27 +45,33 @@ public class WgMeetingInfo extends BaseEntity { @ApiModelProperty(value = "参会时间") @TableField("meeting_time") - private LocalDateTime meetingTime; + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") + private Date meetingTime; @ApiModelProperty(value = "会议名称") - @TableField("meet_name") + @TableField("meeting_name") private String meetingName; - @ApiModelProperty(value = "会议人员") - @TableField("meeting_people") - private String meetingPeople; - - @ApiModelProperty(value = "会议人员名称") - @TableField("meeting_people_name") - private String meetingPeopleName; @ApiModelProperty(value = "会议报告") @TableField("meeting_report") private String meetingReport; @ApiModelProperty(value = "会议资料") - @TableField("meeting_datum") - private String meetingDatum; + @TableField("joinfile") + private String joinfile; + + @ApiModelProperty(value = "前端id") + @TableField("join_id") + private String joinId; + + @ApiModelProperty(value = "人员信息") + @TableField(exist = false) + private List meetingPeople; + + @TableField(exist = false) + private List joinMeetingPeopleInfo; } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/controller/WgMeetingUserRelationController.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/controller/WgMeetingUserRelationController.java new file mode 100644 index 00000000..933b7dc8 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/controller/WgMeetingUserRelationController.java @@ -0,0 +1,23 @@ +package com.adc.da.slrs.wgMeetingUserRelation.controller; + + +import org.springframework.web.bind.annotation.RequestMapping; +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelation; +import io.swagger.annotations.Api; +import org.springframework.web.bind.annotation.RestController; +import com.adc.da.base.web.BaseController; + +/** +*

+ * 前端控制器 + *

+* +* @author super_liu +* @since 2021-11-09 +*/ +@RestController +@Api(description = "|WgMeetingUserRelation|") +@RequestMapping("/wgMeetingUserRelation") +public class WgMeetingUserRelationController extends BaseController { + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/dao/WgMeetingUserRelationDao.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/dao/WgMeetingUserRelationDao.java new file mode 100644 index 00000000..0047c965 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/dao/WgMeetingUserRelationDao.java @@ -0,0 +1,20 @@ +package com.adc.da.slrs.wgMeetingUserRelation.dao; + +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelation; +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelationShow; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import org.apache.ibatis.annotations.Param; + +import java.util.List; + +/** + *

+ * Mapper 接口 + *

+ * + * @author super_liu + * @since 2021-11-09 + */ +public interface WgMeetingUserRelationDao extends BaseMapper { + List getMeetingPeoples(@Param("meetId") String meetingId); +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelation.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelation.java new file mode 100644 index 00000000..49782efe --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelation.java @@ -0,0 +1,34 @@ +package com.adc.da.slrs.wgMeetingUserRelation.entity; + +import com.adc.da.base.entity.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * + *

+ * + * @author super_liu + * @since 2021-11-09 + */ +@Data +@EqualsAndHashCode(callSuper = true) +@Accessors(chain = true) +@ApiModel(value="WgMeetingUserRelation对象", description="") +public class WgMeetingUserRelation extends BaseEntity { + + private static final long serialVersionUID = 1L; + + @ApiModelProperty(value = "会议id") + private String meetingId; + + @ApiModelProperty(value = "人员id") + private String userId; + + + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelationShow.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelationShow.java new file mode 100644 index 00000000..d30cf59a --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/entity/WgMeetingUserRelationShow.java @@ -0,0 +1,45 @@ +package com.adc.da.slrs.wgMeetingUserRelation.entity; + +import com.adc.da.base.entity.BaseEntity; +import com.adc.da.slrs.sarInstitution.entity.TsUserVO; +import com.adc.da.slrs.sarPosition.entity.TsPosition; +import com.baomidou.mybatisplus.annotation.TableField; +import com.fasterxml.jackson.annotation.JsonFormat; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; +import org.springframework.format.annotation.DateTimeFormat; + +import javax.validation.constraints.NotNull; +import java.sql.Timestamp; +import java.util.List; + +/** + *

+ * + *

+ * + * @author super_liu + * @since 2021-11-09 + */ +@Data +@EqualsAndHashCode(callSuper = true) +@Accessors(chain = true) +@ApiModel(value="WgMeetingUserRelation对象", description="") +public class WgMeetingUserRelationShow extends BaseEntity { + + private static final long serialVersionUID = 1L; + + @ApiModelProperty(value = "会议id") + private String meetingId; + + @ApiModelProperty(value = "人员id") + private String userId; + + @ApiModelProperty(value = "人员名称") + private String name; + + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/IWgMeetingUserRelationService.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/IWgMeetingUserRelationService.java new file mode 100644 index 00000000..b3345ab0 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/IWgMeetingUserRelationService.java @@ -0,0 +1,16 @@ +package com.adc.da.slrs.wgMeetingUserRelation.service; + +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelation; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 服务类 + *

+ * + * @author super_liu + * @since 2021-11-09 + */ +public interface IWgMeetingUserRelationService extends IService { + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/impl/WgMeetingUserRelationServiceImpl.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/impl/WgMeetingUserRelationServiceImpl.java new file mode 100644 index 00000000..86963f88 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgMeetingUserRelation/service/impl/WgMeetingUserRelationServiceImpl.java @@ -0,0 +1,20 @@ +package com.adc.da.slrs.wgMeetingUserRelation.service.impl; + +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelation; +import com.adc.da.slrs.wgMeetingUserRelation.dao.WgMeetingUserRelationDao; +import com.adc.da.slrs.wgMeetingUserRelation.service.IWgMeetingUserRelationService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 服务实现类 + *

+ * + * @author super_liu + * @since 2021-11-09 + */ +@Service +public class WgMeetingUserRelationServiceImpl extends ServiceImpl implements IWgMeetingUserRelationService { + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/dao/WgNetInfoDao.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/dao/WgNetInfoDao.java index cdcaf3d2..1bf05b94 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/dao/WgNetInfoDao.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/dao/WgNetInfoDao.java @@ -1,6 +1,7 @@ package com.adc.da.slrs.wgNetInfo.dao; import com.adc.da.slrs.wgNetInfo.entity.WgNetInfo; +import com.adc.da.slrs.wgNetInfo.entity.WgNetInfoDTO; import com.adc.da.slrs.wgWorkGroup.entity.WgWorkGroupShowDTO; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import org.apache.ibatis.annotations.Param; @@ -17,6 +18,6 @@ import java.util.List; */ public interface WgNetInfoDao extends BaseMapper { - List researchDatas(@Param(value = "data") String data); + List researchDatas(@Param(value = "data") String data); } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfo.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfo.java index f36b8e5d..12b1edec 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfo.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfo.java @@ -40,5 +40,9 @@ public class WgNetInfo extends BaseEntity { @TableField("net_id") private String netId; + @ApiModelProperty(value = "前端id") + @TableField("join_id") + private String joinId; + } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfoDTO.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfoDTO.java new file mode 100644 index 00000000..cdf47254 --- /dev/null +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgNetInfo/entity/WgNetInfoDTO.java @@ -0,0 +1,64 @@ +package com.adc.da.slrs.wgNetInfo.entity; + +import com.adc.da.base.entity.BaseEntity; +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableField; +import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 工作组秘书联系方式 + *

+ * + * @author super_liu + * @since 2021-11-04 + */ +@Data +@EqualsAndHashCode(callSuper = true) +@Accessors(chain = true) +@ApiModel(value="WgNetInfo对象", description="工作组秘书联系方式") +@TableName("wg_net_info") +public class WgNetInfoDTO extends BaseEntity { + + private static final long serialVersionUID = 1L; + + @ApiModelProperty(value = "id") + @TableId(value = "id",type = IdType.UUID) + private String id; + + @ApiModelProperty(value = "工作组id") + @TableField("wg_id") + private String wgId; + + @ApiModelProperty(value = "人员id") + @TableField("net_id") + private String netId; + + + @ApiModelProperty(value = "前端id") + @TableField("join_id") + private String joinId; + + @ApiModelProperty(value = "中文名") + private String name; + + @ApiModelProperty(value = "单位") + private String unit; + + @ApiModelProperty(value = "单位名称") + private String unitName; + + @ApiModelProperty(value = "电话") + private String phone; + + @ApiModelProperty(value = "邮箱") + private String email; + + +} diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgPayInfo/entity/WgPayInfo.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgPayInfo/entity/WgPayInfo.java index 81876bc2..01a25d53 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgPayInfo/entity/WgPayInfo.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgPayInfo/entity/WgPayInfo.java @@ -59,12 +59,15 @@ public class WgPayInfo extends BaseEntity { private String payWay; @ApiModelProperty(value = "支付资料") - @TableField("pay_datum") - private String payDatum; + @TableField("joinfile") + private String joinfile; @ApiModelProperty(value = "费用列支") @TableField("pay_info") private String payInfo; + @ApiModelProperty(value = "前端id") + @TableField("join_id") + private String joinId; } diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroup.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroup.java index 113ce616..fdf5426e 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroup.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroup.java @@ -25,12 +25,12 @@ import lombok.experimental.Accessors; @EqualsAndHashCode(callSuper = true) @Accessors(chain = true) @ApiModel(value="WgWorkGroup对象", description="工作组主表") -@TableName("wgWorkGroup") +@TableName("wg_work_group") public class WgWorkGroup extends BaseEntity { private static final long serialVersionUID = 1L; - @ApiModelProperty(value = "工作组id") + @ApiModelProperty(value = "id") @TableId(value = "id",type = IdType.UUID) private String id; diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroupShowDTO.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroupShowDTO.java index b66eea02..2c38d90d 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroupShowDTO.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/entity/WgWorkGroupShowDTO.java @@ -4,6 +4,7 @@ import com.adc.da.base.entity.BaseEntity; import com.adc.da.slrs.wgDept.entity.WgDept; import com.adc.da.slrs.wgMeetingInfo.entity.WgMeetingInfo; import com.adc.da.slrs.wgNetInfo.entity.WgNetInfo; +import com.adc.da.slrs.wgNetInfo.entity.WgNetInfoDTO; import com.adc.da.slrs.wgPayInfo.entity.WgPayInfo; import com.adc.da.slrs.wgStandorpolicyInfo.entity.WgStandorpolicyInfo; import io.swagger.annotations.ApiModel; @@ -74,7 +75,7 @@ public class WgWorkGroupShowDTO extends BaseEntity { List wgDepts; //秘书联系方式 - List wgNetInfos; + List wgNetInfos; //参会记录及资料 List wgMeetingInfos; diff --git a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/service/impl/WgWorkGroupServiceImpl.java b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/service/impl/WgWorkGroupServiceImpl.java index c5087f22..cf2c086e 100644 --- a/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/service/impl/WgWorkGroupServiceImpl.java +++ b/adc-da-slrs/src/main/java/com/adc/da/slrs/wgWorkGroup/service/impl/WgWorkGroupServiceImpl.java @@ -4,6 +4,10 @@ import com.adc.da.http.ResponseMessage; import com.adc.da.http.Result; import com.adc.da.slrs.wgDept.service.IWgDeptService; import com.adc.da.slrs.wgMeetingInfo.service.IWgMeetingInfoService; +import com.adc.da.slrs.wgMeetingUserRelation.entity.WgMeetingUserRelation; +import com.adc.da.slrs.wgMeetingUserRelation.service.IWgMeetingUserRelationService; +import com.adc.da.slrs.wgMeetingUserRelation.service.impl.WgMeetingUserRelationServiceImpl; +import com.adc.da.slrs.wgNetInfo.entity.WgNetInfo; import com.adc.da.slrs.wgNetInfo.service.IWgNetInfoService; import com.adc.da.slrs.wgPayInfo.service.IWgPayInfoService; import com.adc.da.slrs.wgStandorpolicyInfo.service.IWgStandorpolicyInfoService; @@ -18,10 +22,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; +import java.util.*; /** *

@@ -48,6 +49,8 @@ public class WgWorkGroupServiceImpl extends ServiceImpl {wgDept.setWgId(wgWorkGroup.getId()); + }); + flag=wgDeptService.saveBatch(wgWorkGroupDTO.getWgDepts()); + } //存储会议信息 - boolean flag2=wgMeetingInfoService.saveBatch(wgWorkGroupDTO.getWgMeetingInfos()); + if (null!=wgWorkGroupDTO.getWgMeetingInfos()) { + List wgMeetingUserRelations = new ArrayList<>(); + wgWorkGroupDTO.getWgMeetingInfos().forEach(wgMeetingInfo -> { + wgMeetingInfo.setWgId(wgWorkGroup.getId()); + wgMeetingInfo.getMeetingPeople().forEach(s -> { + WgMeetingUserRelation wgMeetingUserRelation=new WgMeetingUserRelation(); + wgMeetingUserRelation.setMeetingId(wgMeetingInfo.getId()); + wgMeetingUserRelation.setUserId(s); + }); + }); + flag = wgMeetingUserRelationService.saveBatch(wgMeetingUserRelations); + flag = wgMeetingInfoService.saveBatch(wgWorkGroupDTO.getWgMeetingInfos()); + } //存储秘书联系方式信息 - boolean flag3=wgNetInfoService.saveBatch(wgWorkGroupDTO.getWgNetInfos()); + if (null!=wgWorkGroupDTO.getWgNetInfos()) { + wgWorkGroupDTO.getWgNetInfos().forEach(wgNetInfo -> {wgNetInfo.setWgId(wgWorkGroup.getId());}); + flag = wgNetInfoService.saveBatch(wgWorkGroupDTO.getWgNetInfos()); + } //支付信息 - boolean flag4=wgPayInfoService.saveBatch(wgWorkGroupDTO.getWgPayInfos()); + if (null!=wgWorkGroupDTO.getWgPayInfos()) { + wgWorkGroupDTO.getWgPayInfos().forEach(wgPayInfo -> {wgPayInfo.setWgId(wgWorkGroup.getId());}); + flag = wgPayInfoService.saveBatch(wgWorkGroupDTO.getWgPayInfos()); + } //标准政策信息 - boolean flag5=wgStandorpolicyInfoService.saveBatch(wgWorkGroupDTO.getWgStandorpolicyInfos()); + if (null!=wgWorkGroupDTO.getWgStandorpolicyInfos()) { + wgWorkGroupDTO.getWgStandorpolicyInfos().forEach(wgStandorpolicyInfo -> {wgStandorpolicyInfo.setWgId(wgWorkGroup.getId());}); + flag = wgStandorpolicyInfoService.saveBatch(wgWorkGroupDTO.getWgStandorpolicyInfos()); + } //先存储主数据 - boolean flag6=wgWorkGroupService.save(wgWorkGroup); - if (flag1 && flag2 && flag3 && flag4 && flag5 && flag6 ) { + if (flag ) { return "添加成功"; }else { return "数据错误,添加失败"; @@ -116,13 +146,31 @@ public class WgWorkGroupServiceImpl extends ServiceImpl wgNetInfos=new ArrayList<>(); + wgWorkGroupShowDTO.getWgNetInfos().forEach(wgNetInfoDTO -> { + WgNetInfo wgNetInfo=new WgNetInfo(); + BeanUtils.copyProperties(wgNetInfoDTO,wgNetInfo); + wgNetInfos.add(wgNetInfo); + }); + flag = wgNetInfoService.saveOrUpdateBatch(wgNetInfos); + } + if (null!=wgWorkGroupShowDTO.getWgPayInfos()){ + flag = wgPayInfoService.saveOrUpdateBatch(wgWorkGroupShowDTO.getWgPayInfos()); + } + if (null!=wgWorkGroupShowDTO.getWgStandorpolicyInfos()) { + flag = wgStandorpolicyInfoService.saveOrUpdateBatch(wgWorkGroupShowDTO.getWgStandorpolicyInfos()); + } + + if (flag){ return Result.success("更新成功"); }else { return Result.error("无法更新"); diff --git a/adc-da-slrs/src/main/resources/mybatis/mapper/wgDept/WgDeptMapper.xml b/adc-da-slrs/src/main/resources/mybatis/mapper/wgDept/WgDeptMapper.xml index 619b63a0..edd82ba9 100644 --- a/adc-da-slrs/src/main/resources/mybatis/mapper/wgDept/WgDeptMapper.xml +++ b/adc-da-slrs/src/main/resources/mybatis/mapper/wgDept/WgDeptMapper.xml @@ -2,8 +2,12 @@ - + select wg_dept.* ,ts_user.UNAME as name ,ts_user.PHONE as phone ,ts_user.EMAIL as email,ts_user.INSTITUTION_ID as deptId + ,ts_user.INSTITUTION_NAME as deptName + from wg_dept + left join ts_user on ts_user.ACCOUNT = wg_dept.dept_people_id + where wg_dept.wg_id =#{data} diff --git a/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingInfo/WgMeetingInfoMapper.xml b/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingInfo/WgMeetingInfoMapper.xml index 986f3f0c..5762a95a 100644 --- a/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingInfo/WgMeetingInfoMapper.xml +++ b/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingInfo/WgMeetingInfoMapper.xml @@ -2,7 +2,21 @@ - select * from wg_meeting_info where wg_meeting_info.wg_id = #{data} diff --git a/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingUserRelation/WgMeetingUserRelationMapper.xml b/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingUserRelation/WgMeetingUserRelationMapper.xml new file mode 100644 index 00000000..016b6723 --- /dev/null +++ b/adc-da-slrs/src/main/resources/mybatis/mapper/wgMeetingUserRelation/WgMeetingUserRelationMapper.xml @@ -0,0 +1,12 @@ + + + + + + + diff --git a/adc-da-slrs/src/main/resources/mybatis/mapper/wgNetInfo/WgNetInfoMapper.xml b/adc-da-slrs/src/main/resources/mybatis/mapper/wgNetInfo/WgNetInfoMapper.xml index f6322188..dd9896b6 100644 --- a/adc-da-slrs/src/main/resources/mybatis/mapper/wgNetInfo/WgNetInfoMapper.xml +++ b/adc-da-slrs/src/main/resources/mybatis/mapper/wgNetInfo/WgNetInfoMapper.xml @@ -2,8 +2,12 @@ - + select wg_net_info.net_id,ts_user.UNAME as name ,ts_user.PHONE as phone, ts_user.EMAIL as email + ,wg_net_info.id,wg_net_info.wg_id , wg_net_info.join_id + from wg_net_info + left join ts_user on ts_user.ACCOUNT = wg_net_info.net_id + where wg_net_info.wg_id =#{data}