表合并
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.controller;
|
||||
|
||||
|
||||
import com.chinaunicom.mall.ebtp.common.base.entity.BasePageResponse;
|
||||
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
|
||||
import com.chinaunicom.mall.ebtp.common.poiExport.constant.ExportConstant;
|
||||
import com.chinaunicom.mall.ebtp.common.poiExport.entity.ExcelTable;
|
||||
@ -31,8 +32,6 @@ public class PartyEventMaintainController {
|
||||
@Resource
|
||||
private EventPartyBranchService eventPartyBranchService;
|
||||
@Resource
|
||||
private EventSubjectService eventSubjectService;
|
||||
@Resource
|
||||
private EventContactService eventContactService;
|
||||
@Resource
|
||||
private EventContactSuggestionService eventContactSuggestionService;
|
||||
@ -48,8 +47,8 @@ public class PartyEventMaintainController {
|
||||
|
||||
@ApiOperation("保存攻坚项目")
|
||||
@PostMapping("/save/subject")
|
||||
public BaseResponse<Boolean> saveSubject(@RequestBody EventSubject inVO) {
|
||||
return BaseResponse.success(eventSubjectService.saveSubject(inVO));
|
||||
public BaseResponse<Boolean> saveSubject(@RequestBody EventStyle inVO) {
|
||||
return BaseResponse.success(eventStyleService.saveSubject(inVO));
|
||||
}
|
||||
|
||||
|
||||
@ -87,8 +86,8 @@ public class PartyEventMaintainController {
|
||||
|
||||
@ApiOperation("后台查询列表")
|
||||
@PostMapping("/styleProject/list")
|
||||
public BaseResponse<List<EventMaintainOutVO>> queryStyleAndProject(@RequestBody(required = false) EventMaintainInVO inVO) {
|
||||
return BaseResponse.success(eventStyleService.queryStyleAndProject(inVO));
|
||||
public BasePageResponse<EventMaintainOutVO> queryStyleAndProject(@RequestBody(required = false) EventMaintainInVO inVO) {
|
||||
return BasePageResponse.success(eventStyleService.queryStyleAndProject(inVO));
|
||||
}
|
||||
|
||||
|
||||
@ -113,8 +112,8 @@ public class PartyEventMaintainController {
|
||||
|
||||
@ApiOperation("后台查询列表")
|
||||
@PostMapping("/suggestion/list")
|
||||
public BaseResponse<List<EventContactSuggestion>> querySuggestion(@RequestBody(required = false) EventMaintainInVO inVO) {
|
||||
return BaseResponse.success(eventContactSuggestionService.querySuggestion(inVO));
|
||||
public BasePageResponse<EventContactSuggestion> querySuggestion(@RequestBody(required = false) EventMaintainInVO inVO) {
|
||||
return BasePageResponse.success(eventContactSuggestionService.querySuggestion(inVO));
|
||||
}
|
||||
|
||||
@GetMapping(value = "/suggestion/export/")
|
||||
|
@ -25,8 +25,6 @@ public class PartyMemberEventController {
|
||||
@Resource
|
||||
private EventPartyBranchService eventPartyBranchService;
|
||||
@Resource
|
||||
private EventSubjectService eventSubjectService;
|
||||
@Resource
|
||||
private EventContactService eventContactService;
|
||||
@Resource
|
||||
private EventContactSuggestionService eventContactSuggestionService;
|
||||
@ -103,8 +101,8 @@ public class PartyMemberEventController {
|
||||
|
||||
@ApiOperation("活动课题列表")
|
||||
@PostMapping("/eventSubject/list")
|
||||
public BaseResponse<List<EventSubject>> getEventSubjectList(@RequestBody(required = false) EventQueryInVO inVO) {
|
||||
return BaseResponse.success(eventSubjectService.getEventSubjectList(inVO));
|
||||
public BaseResponse<List<EventStyle>> getEventSubjectList(@RequestBody(required = false) EventQueryInVO inVO) {
|
||||
return BaseResponse.success(eventStyleService.getEventSubjectList(inVO));
|
||||
}
|
||||
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
|
||||
public interface EventSubjectMapper extends BaseMapper<EventSubject> {
|
||||
|
||||
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
//
|
||||
//public interface EventSubjectMapper extends BaseMapper<EventSubject> {
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
@ -1,9 +1,9 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
|
||||
public interface EventSubjectTimeMapper extends BaseMapper<EventSubjectTime> {
|
||||
|
||||
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
//
|
||||
//public interface EventSubjectTimeMapper extends BaseMapper<EventSubjectTime> {
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
@ -1,27 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<!--<?xml version="1.0" encoding="UTF-8" ?>-->
|
||||
<!--<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">-->
|
||||
|
||||
<mapper namespace="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectMapper">
|
||||
<resultMap id="BaseResultMap"
|
||||
type="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject">
|
||||
<result column="id" jdbcType="BIGINT" property="id"/>
|
||||
<result column="title" jdbcType="VARCHAR" property="title"/>
|
||||
<result column="category" jdbcType="VARCHAR" property="category"/>
|
||||
<result column="content" jdbcType="VARCHAR" property="content"/>
|
||||
<result column="image" jdbcType="VARCHAR" property="image"/>
|
||||
<result column="sort" jdbcType="INTEGER" property="sort"/>
|
||||
<result column="status" jdbcType="VARCHAR" property="status"/>
|
||||
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
|
||||
<result column="send_time" jdbcType="TIMESTAMP" property="sendTime"/>
|
||||
<result column="project_name" jdbcType="VARCHAR" property="projectName"/>
|
||||
<result column="unit_name" jdbcType="VARCHAR" property="unitName"/>
|
||||
<result column="team_leader" jdbcType="VARCHAR" property="teamLeader"/>
|
||||
<result column="team_menber" jdbcType="VARCHAR" property="teamMenber"/>
|
||||
<result column="project_content_problem" jdbcType="VARCHAR" property="projectContentProblem"/>
|
||||
<result column="project_content_solve" jdbcType="VARCHAR" property="projectContentSolve"/>
|
||||
<result column="project_content_result" jdbcType="VARCHAR" property="projectContentResult"/>
|
||||
<result column="support_resources" jdbcType="VARCHAR" property="supportResources"/>
|
||||
</resultMap>
|
||||
<!--<mapper namespace="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectMapper">-->
|
||||
<!-- <resultMap id="BaseResultMap"-->
|
||||
<!-- type="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject">-->
|
||||
<!-- <result column="id" jdbcType="BIGINT" property="id"/>-->
|
||||
<!-- <result column="title" jdbcType="VARCHAR" property="title"/>-->
|
||||
<!-- <result column="category" jdbcType="VARCHAR" property="category"/>-->
|
||||
<!-- <result column="content" jdbcType="VARCHAR" property="content"/>-->
|
||||
<!-- <result column="image" jdbcType="VARCHAR" property="image"/>-->
|
||||
<!-- <result column="sort" jdbcType="INTEGER" property="sort"/>-->
|
||||
<!-- <result column="status" jdbcType="VARCHAR" property="status"/>-->
|
||||
<!-- <result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>-->
|
||||
<!-- <result column="send_time" jdbcType="TIMESTAMP" property="sendTime"/>-->
|
||||
<!-- </resultMap>-->
|
||||
|
||||
|
||||
</mapper>
|
||||
<!--</mapper>-->
|
@ -1,17 +1,17 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<!--<?xml version="1.0" encoding="UTF-8" ?>-->
|
||||
<!--<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">-->
|
||||
|
||||
<mapper namespace="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectTimeMapper">
|
||||
<resultMap id="BaseResultMap"
|
||||
type="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime">
|
||||
<result column="id" jdbcType="BIGINT" property="id"/>
|
||||
<result column="subject_id" jdbcType="VARCHAR" property="subjectId"/>
|
||||
<result column="milestone" jdbcType="VARCHAR" property="milestone"/>
|
||||
<result column="milestone_time" jdbcType="TIMESTAMP" property="milestoneTime"/>
|
||||
<result column="milestone_target" jdbcType="VARCHAR" property="milestoneTarget"/>
|
||||
<result column="sort" jdbcType="INTEGER" property="sort"/>
|
||||
<result column="status" jdbcType="VARCHAR" property="status"/>
|
||||
</resultMap>
|
||||
<!--<mapper namespace="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectTimeMapper">-->
|
||||
<!-- <resultMap id="BaseResultMap"-->
|
||||
<!-- type="com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime">-->
|
||||
<!-- <result column="id" jdbcType="BIGINT" property="id"/>-->
|
||||
<!-- <result column="subject_id" jdbcType="VARCHAR" property="subjectId"/>-->
|
||||
<!-- <result column="milestone" jdbcType="VARCHAR" property="milestone"/>-->
|
||||
<!-- <result column="milestone_time" jdbcType="TIMESTAMP" property="milestoneTime"/>-->
|
||||
<!-- <result column="milestone_target" jdbcType="VARCHAR" property="milestoneTarget"/>-->
|
||||
<!-- <result column="sort" jdbcType="INTEGER" property="sort"/>-->
|
||||
<!-- <result column="status" jdbcType="VARCHAR" property="status"/>-->
|
||||
<!-- </resultMap>-->
|
||||
|
||||
|
||||
</mapper>
|
||||
<!--</mapper>-->
|
@ -11,7 +11,10 @@ import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 实体类 EventMaintainInVO
|
||||
@ -63,5 +66,14 @@ public class EventMaintainInVO implements Serializable {
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
private java.time.LocalDateTime endTime;
|
||||
private LocalDateTime endTime;
|
||||
|
||||
@ApiModelProperty("当前页")
|
||||
@NotNull
|
||||
@Min(0L)
|
||||
private Integer pageNo;
|
||||
@ApiModelProperty("每页显示条数")
|
||||
@NotNull
|
||||
@Min(0L)
|
||||
private Integer pageSize;
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ public class EventStyle implements Serializable {
|
||||
/**
|
||||
* 类别
|
||||
*/
|
||||
@ApiModelProperty(value = "类别")
|
||||
@ApiModelProperty(value = "类别 1-首页,2-活动风采,3-攻坚克难")
|
||||
private String category;
|
||||
|
||||
/**
|
||||
|
@ -1,177 +1,108 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.chinaunicom.mall.ebtp.common.config.CustomLocalDateTimeTypeHandler;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 实体类 EventSubject
|
||||
*
|
||||
* @auto.generated
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
@ApiModel
|
||||
@TableName(value = "event_subject", autoResultMap = true)
|
||||
public class EventSubject implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@TableId
|
||||
@ApiModelProperty(value = "id")
|
||||
private String id;
|
||||
|
||||
/**
|
||||
* 活动标题
|
||||
*/
|
||||
@ApiModelProperty(value = "活动标题")
|
||||
private String title;
|
||||
|
||||
/**
|
||||
* 类别
|
||||
*/
|
||||
@ApiModelProperty(value = "类别")
|
||||
private String category;
|
||||
|
||||
/**
|
||||
* 活动内容正文
|
||||
*/
|
||||
@ApiModelProperty(value = "活动内容正文")
|
||||
private String content;
|
||||
|
||||
/**
|
||||
* 正文图片id
|
||||
*/
|
||||
@ApiModelProperty(value = "正文图片id")
|
||||
private String contentImageId;
|
||||
|
||||
/**
|
||||
* 活动图片
|
||||
*/
|
||||
@ApiModelProperty(value = "活动图片")
|
||||
private String image;
|
||||
|
||||
/**
|
||||
* 显示排序
|
||||
*/
|
||||
@ApiModelProperty(value = "显示排序")
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 页面显示状态 0-隐藏 1-显示
|
||||
*/
|
||||
@ApiModelProperty(value = "页面显示状态 0-隐藏 1-显示")
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
private java.time.LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 发布时间
|
||||
*/
|
||||
@ApiModelProperty(value = "发布时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
private java.time.LocalDateTime sendTime;
|
||||
|
||||
/**
|
||||
* 发布人
|
||||
*/
|
||||
@ApiModelProperty(value = "发布人")
|
||||
private String createBy;
|
||||
|
||||
|
||||
/**
|
||||
* 删除标识
|
||||
*/
|
||||
@ApiModelProperty(value = "删除标识")
|
||||
private String deleteFlag;
|
||||
/**
|
||||
* 项目名称
|
||||
*/
|
||||
@ApiModelProperty(value = "项目名称")
|
||||
private String projectName;
|
||||
|
||||
/**
|
||||
* 实施单位
|
||||
*/
|
||||
@ApiModelProperty(value = "实施单位")
|
||||
private String unitName;
|
||||
|
||||
/**
|
||||
* 团队牵头人
|
||||
*/
|
||||
@ApiModelProperty(value = "团队牵头人")
|
||||
private String teamLeader;
|
||||
|
||||
/**
|
||||
* 团队成员
|
||||
*/
|
||||
@ApiModelProperty(value = "团队成员")
|
||||
private String teamMenber;
|
||||
|
||||
/**
|
||||
* 项目内容-针对的痛点难点问题
|
||||
*/
|
||||
@ApiModelProperty(value = "项目内容-针对的痛点难点问题")
|
||||
private String projectContentProblem;
|
||||
|
||||
/**
|
||||
* 项目内容-解决问题的主要思路和措施
|
||||
*/
|
||||
@ApiModelProperty(value = "项目内容-解决问题的主要思路和措施")
|
||||
private String projectContentSolve;
|
||||
|
||||
/**
|
||||
* 项目内容-预计达到的可感知可量化的效果
|
||||
*/
|
||||
@ApiModelProperty(value = "项目内容-预计达到的可感知可量化的效果")
|
||||
private String projectContentResult;
|
||||
|
||||
/**
|
||||
* 需要集团公司提供的供应链平台开发及运营支撑资源(若有)
|
||||
*/
|
||||
@ApiModelProperty(value = "需要集团公司提供的供应链平台开发及运营支撑资源(若有)")
|
||||
private String supportResources;
|
||||
|
||||
/**
|
||||
* 团队牵头人信息
|
||||
*/
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "团队牵头人信息")
|
||||
private EventContact teamLeaderInfo;
|
||||
|
||||
/**
|
||||
* 相关人员信息
|
||||
*/
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "相关人员信息")
|
||||
private List<EventContact> teamMenberInfo;
|
||||
|
||||
/**
|
||||
* 项目推进计划及成果目标
|
||||
*/
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "项目推进计划及成果目标")
|
||||
private List<EventSubjectTime> subjectTimeList;
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.annotation.TableField;
|
||||
//import com.baomidou.mybatisplus.annotation.TableId;
|
||||
//import com.baomidou.mybatisplus.annotation.TableName;
|
||||
//import com.chinaunicom.mall.ebtp.common.config.CustomLocalDateTimeTypeHandler;
|
||||
//import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
//import io.swagger.annotations.ApiModel;
|
||||
//import io.swagger.annotations.ApiModelProperty;
|
||||
//import lombok.Data;
|
||||
//import lombok.experimental.Accessors;
|
||||
//import org.springframework.format.annotation.DateTimeFormat;
|
||||
//
|
||||
//import java.io.Serializable;
|
||||
//
|
||||
///**
|
||||
// * 实体类 EventSubject
|
||||
// *
|
||||
// * @auto.generated
|
||||
// */
|
||||
//@Data
|
||||
//@Accessors(chain = true)
|
||||
//@ApiModel
|
||||
//@TableName(value = "event_subject", autoResultMap = true)
|
||||
//public class EventSubject implements Serializable {
|
||||
//
|
||||
// private static final long serialVersionUID = 1L;
|
||||
//
|
||||
// /**
|
||||
// * id
|
||||
// */
|
||||
// @TableId
|
||||
// @ApiModelProperty(value = "id")
|
||||
// private String id;
|
||||
//
|
||||
// /**
|
||||
// * 活动标题
|
||||
// */
|
||||
// @ApiModelProperty(value = "活动标题")
|
||||
// private String title;
|
||||
//
|
||||
// /**
|
||||
// * 类别
|
||||
// */
|
||||
// @ApiModelProperty(value = "类别")
|
||||
// private String category;
|
||||
//
|
||||
// /**
|
||||
// * 活动内容正文
|
||||
// */
|
||||
// @ApiModelProperty(value = "活动内容正文")
|
||||
// private String content;
|
||||
//
|
||||
// /**
|
||||
// * 正文图片id
|
||||
// */
|
||||
// @ApiModelProperty(value = "正文图片id")
|
||||
// private String contentImageId;
|
||||
//
|
||||
// /**
|
||||
// * 活动图片
|
||||
// */
|
||||
// @ApiModelProperty(value = "活动图片")
|
||||
// private String image;
|
||||
//
|
||||
// /**
|
||||
// * 显示排序
|
||||
// */
|
||||
// @ApiModelProperty(value = "显示排序")
|
||||
// private Integer sort;
|
||||
//
|
||||
// /**
|
||||
// * 页面显示状态 0-隐藏 1-显示
|
||||
// */
|
||||
// @ApiModelProperty(value = "页面显示状态 0-隐藏 1-显示")
|
||||
// private String status;
|
||||
//
|
||||
// /**
|
||||
// * 创建时间
|
||||
// */
|
||||
// @ApiModelProperty(value = "创建时间")
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
// @TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
// private java.time.LocalDateTime createTime;
|
||||
//
|
||||
// /**
|
||||
// * 发布时间
|
||||
// */
|
||||
// @ApiModelProperty(value = "发布时间")
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
// @TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
// private java.time.LocalDateTime sendTime;
|
||||
//
|
||||
// /**
|
||||
// * 发布人
|
||||
// */
|
||||
// @ApiModelProperty(value = "发布人")
|
||||
// private String createBy;
|
||||
//
|
||||
// /**
|
||||
// * 删除标识
|
||||
// */
|
||||
// @ApiModelProperty(value = "删除标识")
|
||||
// private String deleteFlag;
|
||||
//
|
||||
//}
|
||||
|
@ -1,75 +1,75 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.chinaunicom.mall.ebtp.common.config.CustomLocalDateTimeTypeHandler;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 实体类 EventSubjectTime
|
||||
*
|
||||
* @auto.generated
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
@ApiModel
|
||||
@TableName(value = "event_subject_time", autoResultMap = true)
|
||||
public class EventSubjectTime implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@ApiModelProperty(value = "id")
|
||||
private String id;
|
||||
|
||||
/**
|
||||
* 活动标题表id
|
||||
*/
|
||||
@ApiModelProperty(value = "活动标题表id")
|
||||
private String subjectId;
|
||||
|
||||
/**
|
||||
* 里程碑
|
||||
*/
|
||||
@ApiModelProperty(value = "里程碑")
|
||||
private String milestone;
|
||||
|
||||
/**
|
||||
* 里程碑时间
|
||||
*/
|
||||
@ApiModelProperty(value = "里程碑时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
private java.time.LocalDateTime milestoneTime;
|
||||
|
||||
/**
|
||||
* 里程碑预期目标
|
||||
*/
|
||||
@ApiModelProperty(value = "里程碑预期目标")
|
||||
private String milestoneTarget;
|
||||
|
||||
/**
|
||||
* 显示排序
|
||||
*/
|
||||
@ApiModelProperty(value = "显示排序")
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 页面显示状态 0-隐藏 1-显示
|
||||
*/
|
||||
@ApiModelProperty(value = "页面显示状态 0-隐藏 1-显示")
|
||||
private String status;
|
||||
|
||||
|
||||
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.annotation.TableField;
|
||||
//import com.baomidou.mybatisplus.annotation.TableName;
|
||||
//import com.chinaunicom.mall.ebtp.common.config.CustomLocalDateTimeTypeHandler;
|
||||
//import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
//import io.swagger.annotations.ApiModel;
|
||||
//import io.swagger.annotations.ApiModelProperty;
|
||||
//import lombok.Data;
|
||||
//import lombok.experimental.Accessors;
|
||||
//import org.springframework.format.annotation.DateTimeFormat;
|
||||
//
|
||||
//import java.io.Serializable;
|
||||
//
|
||||
///**
|
||||
// * 实体类 EventSubjectTime
|
||||
// *
|
||||
// * @auto.generated
|
||||
// */
|
||||
//@Data
|
||||
//@Accessors(chain = true)
|
||||
//@ApiModel
|
||||
//@TableName(value = "event_subject_time", autoResultMap = true)
|
||||
//public class EventSubjectTime implements Serializable {
|
||||
//
|
||||
// private static final long serialVersionUID = 1L;
|
||||
//
|
||||
// /**
|
||||
// * id
|
||||
// */
|
||||
// @ApiModelProperty(value = "id")
|
||||
// private String id;
|
||||
//
|
||||
// /**
|
||||
// * 活动标题表id
|
||||
// */
|
||||
// @ApiModelProperty(value = "活动标题表id")
|
||||
// private String subjectId;
|
||||
//
|
||||
// /**
|
||||
// * 里程碑
|
||||
// */
|
||||
// @ApiModelProperty(value = "里程碑")
|
||||
// private String milestone;
|
||||
//
|
||||
// /**
|
||||
// * 里程碑时间
|
||||
// */
|
||||
// @ApiModelProperty(value = "里程碑时间")
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
// @TableField(typeHandler = CustomLocalDateTimeTypeHandler.class)
|
||||
// private java.time.LocalDateTime milestoneTime;
|
||||
//
|
||||
// /**
|
||||
// * 里程碑预期目标
|
||||
// */
|
||||
// @ApiModelProperty(value = "里程碑预期目标")
|
||||
// private String milestoneTarget;
|
||||
//
|
||||
// /**
|
||||
// * 显示排序
|
||||
// */
|
||||
// @ApiModelProperty(value = "显示排序")
|
||||
// private Integer sort;
|
||||
//
|
||||
// /**
|
||||
// * 页面显示状态 0-隐藏 1-显示
|
||||
// */
|
||||
// @ApiModelProperty(value = "页面显示状态 0-隐藏 1-显示")
|
||||
// private String status;
|
||||
//
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.chinaunicom.mall.ebtp.common.poiExport.entity.ExcelTable;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventContactSuggestion;
|
||||
@ -17,7 +18,7 @@ public interface EventContactSuggestionService extends IService<EventContactSugg
|
||||
|
||||
Boolean submitSuggestion(EventContactSuggestion suggestion);
|
||||
|
||||
List<EventContactSuggestion> querySuggestion(EventMaintainInVO inVO);
|
||||
IPage<EventContactSuggestion> querySuggestion(EventMaintainInVO inVO);
|
||||
|
||||
ExcelTable export(List<String> ids);
|
||||
}
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventMaintainInVO;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventMaintainOutVO;
|
||||
@ -20,11 +21,15 @@ public interface EventStyleService extends IService<EventStyle>{
|
||||
|
||||
boolean saveStyle(EventStyle inVO);
|
||||
|
||||
List<EventMaintainOutVO> queryStyleAndProject(EventMaintainInVO inVO);
|
||||
IPage<EventMaintainOutVO> queryStyleAndProject(EventMaintainInVO inVO);
|
||||
|
||||
boolean saveStyleOrProject(EventMaintainOutVO inVO);
|
||||
|
||||
boolean sendStyleOrProject(String id,String status);
|
||||
|
||||
boolean deleteStyleOrProject(String id);
|
||||
|
||||
List<EventStyle> getEventSubjectList(EventQueryInVO inVO);
|
||||
|
||||
boolean saveSubject(EventStyle inVO);
|
||||
}
|
||||
|
@ -1,20 +1,20 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventQueryInVO;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 对数据表 event_subject 操作的 service
|
||||
* @author Auto create
|
||||
*
|
||||
*/
|
||||
public interface EventSubjectService extends IService<EventSubject>{
|
||||
|
||||
|
||||
List<EventSubject> getEventSubjectList(EventQueryInVO inVO);
|
||||
|
||||
boolean saveSubject(EventSubject inVO);
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.extension.service.IService;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventQueryInVO;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
//
|
||||
//import java.util.List;
|
||||
//
|
||||
///**
|
||||
// * 对数据表 event_subject 操作的 service
|
||||
// * @author Auto create
|
||||
// *
|
||||
// */
|
||||
//public interface EventSubjectService extends IService<EventSubject>{
|
||||
//
|
||||
//
|
||||
// List<EventSubject> getEventSubjectList(EventQueryInVO inVO);
|
||||
//
|
||||
// boolean saveSubject(EventSubject inVO);
|
||||
//}
|
||||
|
@ -1,15 +1,15 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
|
||||
/**
|
||||
* 对数据表 event_subject_time 操作的 service
|
||||
* @author Auto create
|
||||
*
|
||||
*/
|
||||
public interface EventSubjectTimeService extends IService<EventSubjectTime>{
|
||||
|
||||
|
||||
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service;
|
||||
//
|
||||
//import com.baomidou.mybatisplus.extension.service.IService;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
//
|
||||
///**
|
||||
// * 对数据表 event_subject_time 操作的 service
|
||||
// * @author Auto create
|
||||
// *
|
||||
// */
|
||||
//public interface EventSubjectTimeService extends IService<EventSubjectTime>{
|
||||
//
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
@ -4,9 +4,10 @@ package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.chinaunicom.mall.ebtp.common.base.entity.BaseCacheUser;
|
||||
import com.chinaunicom.mall.ebtp.common.base.service.IBaseCacheUserService;
|
||||
import com.chinaunicom.mall.ebtp.common.poiExport.entity.ExcelTable;
|
||||
@ -16,7 +17,6 @@ import com.chinaunicom.mall.ebtp.common.util.PropertyUtils;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventContactSuggestionMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventContactSuggestion;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventMaintainInVO;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventContactSuggestionService;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
@ -25,10 +25,7 @@ import javax.annotation.Resource;
|
||||
import java.text.DateFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.Date;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
/**
|
||||
@ -57,10 +54,10 @@ public class EventContactSuggestionServiceImpl extends ServiceImpl<EventContactS
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<EventContactSuggestion> querySuggestion(EventMaintainInVO inVO) {
|
||||
if (ObjectUtil.isNull(inVO)) {
|
||||
return this.list();
|
||||
}
|
||||
public IPage<EventContactSuggestion> querySuggestion(EventMaintainInVO inVO) {
|
||||
|
||||
Page<EventContactSuggestion> page = new Page<>(inVO.getPageNo(), inVO.getPageSize());
|
||||
|
||||
LambdaQueryWrapper<EventContactSuggestion> query = Wrappers.lambdaQuery();
|
||||
if (ObjectUtil.isNotNull(inVO.getStartTime())) {
|
||||
query.gt(EventContactSuggestion::getCreateTime, inVO.getStartTime());
|
||||
@ -72,7 +69,7 @@ public class EventContactSuggestionServiceImpl extends ServiceImpl<EventContactS
|
||||
if (StrUtil.isNotBlank(inVO.getType())) {
|
||||
query.eq(EventContactSuggestion::getSuggestionType, inVO.getType());
|
||||
}
|
||||
return this.list(query);
|
||||
return this.page(page, query);
|
||||
}
|
||||
|
||||
|
||||
@ -128,3 +125,4 @@ public class EventContactSuggestionServiceImpl extends ServiceImpl<EventContactS
|
||||
return table;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,6 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventContact;
|
||||
import com.google.common.collect.Lists;
|
||||
|
||||
@ -16,7 +18,7 @@ import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventStyleMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.*;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.enums.PartyEventExceptionEnum;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventStyleService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectService;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@ -40,8 +42,7 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
|
||||
@Resource
|
||||
private DocumentCenterService documentCenterService;
|
||||
@Resource
|
||||
private EventSubjectService eventSubjectService;
|
||||
|
||||
|
||||
@Override
|
||||
public List<EventStyle> getEventStyle(String type, EventQueryInVO inVO) {
|
||||
@ -83,64 +84,62 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
inVO.setCreateTime(LocalDateTime.now());
|
||||
return this.save(inVO);
|
||||
}
|
||||
@Override
|
||||
public List<EventStyle> getEventSubjectList(EventQueryInVO inVO) {
|
||||
LambdaQueryWrapper<EventStyle> query = Wrappers.lambdaQuery();
|
||||
query.eq(EventStyle::getStatus, "1");
|
||||
query.eq(EventStyle::getCategory, "3");
|
||||
if (ObjectUtil.isNotNull(inVO)) {
|
||||
query.like(StrUtil.isNotBlank(inVO.getParam()), EventStyle::getTitle, inVO.getParam());
|
||||
}
|
||||
query.ne(EventStyle::getDeleteFlag, "1");
|
||||
query.orderByDesc(EventStyle::getCreateTime);
|
||||
|
||||
return this.list(query);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<EventMaintainOutVO> queryStyleAndProject(EventMaintainInVO inVO) {
|
||||
List<EventStyle> styleList = new ArrayList<>();
|
||||
List<EventSubject> subjectList = new ArrayList<>();
|
||||
public boolean saveSubject(EventStyle inVO) {
|
||||
if (StrUtil.isNotBlank(inVO.getId())) {
|
||||
return this.updateById(inVO);
|
||||
}
|
||||
inVO.setId(PropertyUtils.getSnowflakeId());
|
||||
inVO.setStatus("1");
|
||||
inVO.setCreateTime(LocalDateTime.now());
|
||||
return this.save(inVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public IPage<EventMaintainOutVO> queryStyleAndProject(EventMaintainInVO inVO) {
|
||||
|
||||
LambdaQueryWrapper<EventStyle> queryStyle = Wrappers.lambdaQuery();
|
||||
queryStyle.ne(EventStyle::getDeleteFlag, "1");
|
||||
|
||||
LambdaQueryWrapper<EventSubject> queryProject = Wrappers.lambdaQuery();
|
||||
queryProject.ne(EventSubject::getDeleteFlag, "1");
|
||||
if (ObjectUtil.isNull(inVO)) {
|
||||
styleList = this.list(queryStyle);
|
||||
subjectList = eventSubjectService.list(queryProject);
|
||||
} else {
|
||||
if (StrUtil.isNotBlank(inVO.getType()) && !"3".equals(inVO.getType()) ) {
|
||||
if (StrUtil.isNotBlank(inVO.getTitle())) {
|
||||
queryStyle.like(EventStyle::getTitle, inVO.getTitle());
|
||||
}
|
||||
if (StrUtil.isNotBlank(inVO.getType())) {
|
||||
queryStyle.eq(EventStyle::getBanner, "1".equals(inVO.getType()) ? "1" : "0");
|
||||
}
|
||||
if (StrUtil.isNotBlank(inVO.getStatus())) {
|
||||
queryStyle.eq(EventStyle::getStatus, inVO.getStatus());
|
||||
}
|
||||
if (ObjectUtil.isNotNull(inVO.getStartTime())) {
|
||||
queryStyle.gt(EventStyle::getSendTime, inVO.getStartTime());
|
||||
}
|
||||
|
||||
if (ObjectUtil.isNotNull(inVO.getEndTime())) {
|
||||
queryStyle.lt(EventStyle::getSendTime, inVO.getEndTime());
|
||||
}
|
||||
styleList = this.list(queryStyle);
|
||||
}
|
||||
|
||||
|
||||
if (StrUtil.isNotBlank(inVO.getType()) && !"1".equals(inVO.getType()) && !"2".equals(inVO.getType())) {
|
||||
|
||||
if (StrUtil.isNotBlank(inVO.getTitle())) {
|
||||
queryProject.like(EventSubject::getTitle, inVO.getTitle());
|
||||
}
|
||||
|
||||
if (StrUtil.isNotBlank(inVO.getStatus())) {
|
||||
queryProject.eq(EventSubject::getStatus, inVO.getStatus());
|
||||
}
|
||||
if (ObjectUtil.isNotNull(inVO.getStartTime())) {
|
||||
queryProject.gt(EventSubject::getSendTime, inVO.getStartTime());
|
||||
}
|
||||
|
||||
if (ObjectUtil.isNotNull(inVO.getEndTime())) {
|
||||
queryProject.lt(EventSubject::getSendTime, inVO.getEndTime());
|
||||
}
|
||||
subjectList = eventSubjectService.list(queryProject);
|
||||
}
|
||||
if (StrUtil.isNotBlank(inVO.getTitle())) {
|
||||
queryStyle.like(EventStyle::getTitle, inVO.getTitle());
|
||||
}
|
||||
if (StrUtil.isNotBlank(inVO.getType())) {
|
||||
queryStyle.eq(EventStyle::getCategory, inVO.getType());
|
||||
}
|
||||
if (StrUtil.isNotBlank(inVO.getStatus())) {
|
||||
queryStyle.eq(EventStyle::getStatus, inVO.getStatus());
|
||||
}
|
||||
if (ObjectUtil.isNotNull(inVO.getStartTime())) {
|
||||
queryStyle.gt(EventStyle::getSendTime, inVO.getStartTime());
|
||||
}
|
||||
|
||||
if (ObjectUtil.isNotNull(inVO.getEndTime())) {
|
||||
queryStyle.lt(EventStyle::getSendTime, inVO.getEndTime());
|
||||
}
|
||||
|
||||
Page<EventStyle> page = new Page<>(inVO.getPageNo(), inVO.getPageSize());
|
||||
|
||||
Page<EventStyle> stylePage = this.page(page, queryStyle);
|
||||
|
||||
List<EventMaintainOutVO> outVOList = new ArrayList<>();
|
||||
|
||||
if (!styleList.isEmpty()) {
|
||||
styleList.forEach(s -> outVOList.add(
|
||||
if (!stylePage.getRecords().isEmpty()) {
|
||||
stylePage.getRecords().forEach(s -> outVOList.add(
|
||||
EventMaintainOutVO.builder()
|
||||
.id(s.getId())
|
||||
.sort(s.getSort())
|
||||
@ -149,28 +148,20 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
.title(s.getTitle())
|
||||
.secordTitle(s.getSecordTitle())
|
||||
.content(s.getContent())
|
||||
.type("1".equals(s.getBanner())? "1" : "2")
|
||||
.type(s.getCategory())
|
||||
.createTime(s.getCreateTime())
|
||||
.createBy(s.getCreateBy())
|
||||
.sendTime(s.getSendTime())
|
||||
.build()));
|
||||
}
|
||||
if (!subjectList.isEmpty()) {
|
||||
subjectList.forEach(s -> outVOList.add(
|
||||
EventMaintainOutVO.builder()
|
||||
.id(s.getId())
|
||||
.sort(s.getSort())
|
||||
.status(s.getStatus())
|
||||
.image(s.getImage())
|
||||
.title(s.getTitle())
|
||||
.content(s.getContent())
|
||||
.type("3")
|
||||
.createTime(s.getCreateTime())
|
||||
.createBy(s.getCreateBy())
|
||||
.sendTime(s.getSendTime())
|
||||
.build()));
|
||||
}
|
||||
return outVOList.stream().sorted(Comparator.comparing(EventMaintainOutVO::getSendTime, Comparator.nullsLast(LocalDateTime::compareTo)).reversed()).collect(Collectors.toList());
|
||||
List<EventMaintainOutVO> collect = outVOList.stream().sorted(Comparator.comparing(EventMaintainOutVO::getSendTime, Comparator.nullsLast(LocalDateTime::compareTo)).reversed()).collect(Collectors.toList());
|
||||
IPage<EventMaintainOutVO> iPage = new Page<>();
|
||||
iPage.setTotal(stylePage.getTotal());
|
||||
iPage.setPages(stylePage.getPages());
|
||||
iPage.setCurrent(stylePage.getCurrent());
|
||||
iPage.setSize(stylePage.getSize());
|
||||
iPage.setRecords(collect);
|
||||
return iPage;
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -182,25 +173,14 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
if (StrUtil.isBlank(inVO.getId())) {
|
||||
inVO.setId(PropertyUtils.getSnowflakeId());
|
||||
}
|
||||
if ("3".equals(inVO.getType())) {
|
||||
EventSubject subject = new EventSubject();
|
||||
subject.setId(inVO.getId());
|
||||
subject.setTitle(inVO.getTitle());
|
||||
subject.setContent(inVO.getContent());
|
||||
subject.setSort(1);
|
||||
subject.setStatus("0");
|
||||
subject.setCreateTime(LocalDateTime.now());
|
||||
subject.setCreateBy(inVO.getCreateBy());
|
||||
subject.setContentImageId(inVO.getContentImageId());
|
||||
return eventSubjectService.saveOrUpdate(subject);
|
||||
}
|
||||
|
||||
EventStyle style = new EventStyle();
|
||||
style.setId(inVO.getId());
|
||||
style.setTitle(inVO.getTitle());
|
||||
style.setSecordTitle(inVO.getSecordTitle());
|
||||
style.setImageWord(inVO.getTitle());
|
||||
style.setTitleImage(inVO.getImage());
|
||||
style.setCategory("1");
|
||||
style.setCategory(inVO.getType());
|
||||
style.setContent(inVO.getContent());
|
||||
style.setImage(inVO.getImage());
|
||||
style.setSort(1);
|
||||
@ -215,12 +195,7 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
|
||||
@Override
|
||||
public boolean sendStyleOrProject(String id, String status) {
|
||||
EventSubject subject = eventSubjectService.getById(id);
|
||||
if (ObjectUtil.isNotNull(subject) && StrUtil.isNotBlank(subject.getId())) {
|
||||
subject.setStatus(status);
|
||||
subject.setSendTime(LocalDateTime.now());
|
||||
return eventSubjectService.updateById(subject);
|
||||
}
|
||||
|
||||
EventStyle style = this.getById(id);
|
||||
if (ObjectUtil.isNotNull(style) && StrUtil.isNotBlank(style.getId())) {
|
||||
style.setStatus(status);
|
||||
@ -232,14 +207,10 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
|
||||
@Override
|
||||
public boolean deleteStyleOrProject(String id) {
|
||||
EventSubject subject = eventSubjectService.getById(id);
|
||||
if (ObjectUtil.isNotNull(subject) && StrUtil.isNotBlank(subject.getId())) {
|
||||
subject.setDeleteFlag("1");
|
||||
return eventSubjectService.updateById(subject);
|
||||
}
|
||||
|
||||
EventStyle style = this.getById(id);
|
||||
if (ObjectUtil.isNotNull(style) && StrUtil.isNotBlank(style.getId())) {
|
||||
subject.setDeleteFlag("1");
|
||||
style.setDeleteFlag("1");
|
||||
return this.updateById(style);
|
||||
}
|
||||
return false;
|
||||
|
@ -1,93 +1,93 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.chinaunicom.mall.ebtp.common.util.PropertyUtils;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventContact;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventQueryInVO;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventContactService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectService;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectTimeService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
/**
|
||||
* 对数据表 event_subject 操作的 serviceImpl
|
||||
* @author Auto create
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
public class EventSubjectServiceImpl extends ServiceImpl<EventSubjectMapper, EventSubject> implements EventSubjectService {
|
||||
|
||||
@Resource
|
||||
private EventSubjectTimeService eventSubjectTimeService;
|
||||
@Resource
|
||||
private EventContactService contactService;
|
||||
|
||||
@Override
|
||||
public List<EventSubject> getEventSubjectList(EventQueryInVO inVO) {
|
||||
LambdaQueryWrapper<EventSubject> query = Wrappers.lambdaQuery();
|
||||
query.eq(EventSubject::getStatus, "1");
|
||||
if (ObjectUtil.isNotNull(inVO)) {
|
||||
query.like(StrUtil.isNotBlank(inVO.getParam()), EventSubject::getTitle, inVO.getParam());
|
||||
}
|
||||
query.ne(EventSubject::getDeleteFlag, "1");
|
||||
query.orderByDesc(EventSubject::getCreateTime);
|
||||
// List<EventSubject> list = this.list(query);
|
||||
// List<String> subjectIdList = list.stream().map(EventSubject::getId).collect(Collectors.toList());
|
||||
// List<String> teamLeaderIdList = list.stream().map(EventSubject::getTeamLeader).distinct().collect(Collectors.toList());
|
||||
// List<String> teamMemberIdList = new ArrayList<>();
|
||||
// list.forEach(f -> teamMemberIdList.addAll(Stream.of(f.getTeamMenber().split(",")).collect(Collectors.toList())));
|
||||
|
||||
// LambdaQueryWrapper<EventSubjectTime> querySubjectTime = Wrappers.lambdaQuery();
|
||||
// querySubjectTime.eq(EventSubjectTime::getStatus, "1").in(EventSubjectTime::getSubjectId, subjectIdList);
|
||||
// List<EventSubjectTime> subjectTimeList = eventSubjectTimeService.list(querySubjectTime);
|
||||
// Map<String, List<EventSubjectTime>> timeMap = subjectTimeList.stream().collect(Collectors.groupingBy(EventSubjectTime::getSubjectId));
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
//
|
||||
// List<EventContact> eventContacts = contactService.listByIds(teamLeaderIdList);
|
||||
// Map<String, EventContact> leaderMap = eventContacts.stream().collect(Collectors.toMap(EventContact::getId, Function.identity()));
|
||||
//
|
||||
// LambdaQueryWrapper<EventContact> contactLambdaQuery = new LambdaQueryWrapper<>();
|
||||
// contactLambdaQuery.eq(EventContact::getStatus, "1").in(EventContact::getId, teamMemberIdList.stream().distinct().collect(Collectors.toList()));
|
||||
// List<EventContact> eventContactList = contactService.list(contactLambdaQuery);
|
||||
// Map<String, EventContact> eventContactMap = eventContactList.stream().collect(Collectors.toMap(EventContact::getId, Function.identity()));
|
||||
// list.forEach(f -> {
|
||||
// List<EventContact> contactList = new ArrayList<>();
|
||||
// List<String> collect = Stream.of(f.getTeamMenber().split(",")).collect(Collectors.toList());
|
||||
// collect.forEach(c -> contactList.add(eventContactMap.get(c)));
|
||||
// f.setTeamMenberInfo(contactList);
|
||||
// f.setSubjectTimeList(timeMap.get(f.getId()));
|
||||
// f.setTeamLeaderInfo(leaderMap.get(f.getTeamLeader()));
|
||||
// });
|
||||
|
||||
return this.list(query);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean saveSubject(EventSubject inVO) {
|
||||
if (StrUtil.isNotBlank(inVO.getId())) {
|
||||
return this.updateById(inVO);
|
||||
}
|
||||
inVO.setId(PropertyUtils.getSnowflakeId());
|
||||
inVO.setStatus("1");
|
||||
inVO.setCreateTime(LocalDateTime.now());
|
||||
return this.save(inVO);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
//import cn.hutool.core.util.ObjectUtil;
|
||||
//import cn.hutool.core.util.StrUtil;
|
||||
//import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
//import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
//import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
//import com.chinaunicom.mall.ebtp.common.util.PropertyUtils;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectMapper;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventContact;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventQueryInVO;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubject;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventContactService;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectService;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectTimeService;
|
||||
//import org.springframework.stereotype.Service;
|
||||
//
|
||||
//import javax.annotation.Resource;
|
||||
//import java.time.LocalDateTime;
|
||||
//import java.util.ArrayList;
|
||||
//import java.util.List;
|
||||
//import java.util.Map;
|
||||
//import java.util.function.Function;
|
||||
//import java.util.stream.Collectors;
|
||||
//import java.util.stream.Stream;
|
||||
//
|
||||
///**
|
||||
// * 对数据表 event_subject 操作的 serviceImpl
|
||||
// * @author Auto create
|
||||
// *
|
||||
// */
|
||||
//@Service
|
||||
//public class EventSubjectServiceImpl extends ServiceImpl<EventSubjectMapper, EventSubject> implements EventSubjectService {
|
||||
//
|
||||
// @Resource
|
||||
// private EventSubjectTimeService eventSubjectTimeService;
|
||||
// @Resource
|
||||
// private EventContactService contactService;
|
||||
//
|
||||
// @Override
|
||||
// public List<EventSubject> getEventSubjectList(EventQueryInVO inVO) {
|
||||
// LambdaQueryWrapper<EventSubject> query = Wrappers.lambdaQuery();
|
||||
// query.eq(EventSubject::getStatus, "1");
|
||||
// if (ObjectUtil.isNotNull(inVO)) {
|
||||
// query.like(StrUtil.isNotBlank(inVO.getParam()), EventSubject::getTitle, inVO.getParam());
|
||||
// }
|
||||
// query.ne(EventSubject::getDeleteFlag, "1");
|
||||
// query.orderByDesc(EventSubject::getCreateTime);
|
||||
//// List<EventSubject> list = this.list(query);
|
||||
//// List<String> subjectIdList = list.stream().map(EventSubject::getId).collect(Collectors.toList());
|
||||
//// List<String> teamLeaderIdList = list.stream().map(EventSubject::getTeamLeader).distinct().collect(Collectors.toList());
|
||||
//// List<String> teamMemberIdList = new ArrayList<>();
|
||||
//// list.forEach(f -> teamMemberIdList.addAll(Stream.of(f.getTeamMenber().split(",")).collect(Collectors.toList())));
|
||||
//
|
||||
//// LambdaQueryWrapper<EventSubjectTime> querySubjectTime = Wrappers.lambdaQuery();
|
||||
//// querySubjectTime.eq(EventSubjectTime::getStatus, "1").in(EventSubjectTime::getSubjectId, subjectIdList);
|
||||
//// List<EventSubjectTime> subjectTimeList = eventSubjectTimeService.list(querySubjectTime);
|
||||
//// Map<String, List<EventSubjectTime>> timeMap = subjectTimeList.stream().collect(Collectors.groupingBy(EventSubjectTime::getSubjectId));
|
||||
////
|
||||
//// List<EventContact> eventContacts = contactService.listByIds(teamLeaderIdList);
|
||||
//// Map<String, EventContact> leaderMap = eventContacts.stream().collect(Collectors.toMap(EventContact::getId, Function.identity()));
|
||||
////
|
||||
//// LambdaQueryWrapper<EventContact> contactLambdaQuery = new LambdaQueryWrapper<>();
|
||||
//// contactLambdaQuery.eq(EventContact::getStatus, "1").in(EventContact::getId, teamMemberIdList.stream().distinct().collect(Collectors.toList()));
|
||||
//// List<EventContact> eventContactList = contactService.list(contactLambdaQuery);
|
||||
//// Map<String, EventContact> eventContactMap = eventContactList.stream().collect(Collectors.toMap(EventContact::getId, Function.identity()));
|
||||
//// list.forEach(f -> {
|
||||
//// List<EventContact> contactList = new ArrayList<>();
|
||||
//// List<String> collect = Stream.of(f.getTeamMenber().split(",")).collect(Collectors.toList());
|
||||
//// collect.forEach(c -> contactList.add(eventContactMap.get(c)));
|
||||
//// f.setTeamMenberInfo(contactList);
|
||||
//// f.setSubjectTimeList(timeMap.get(f.getId()));
|
||||
//// f.setTeamLeaderInfo(leaderMap.get(f.getTeamLeader()));
|
||||
//// });
|
||||
//
|
||||
// return this.list(query);
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public boolean saveSubject(EventSubject inVO) {
|
||||
// if (StrUtil.isNotBlank(inVO.getId())) {
|
||||
// return this.updateById(inVO);
|
||||
// }
|
||||
// inVO.setId(PropertyUtils.getSnowflakeId());
|
||||
// inVO.setStatus("1");
|
||||
// inVO.setCreateTime(LocalDateTime.now());
|
||||
// return this.save(inVO);
|
||||
// }
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
@ -1,18 +1,18 @@
|
||||
package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
|
||||
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectTimeMapper;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectTimeService;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
/**
|
||||
* 对数据表 event_subject_time 操作的 serviceImpl
|
||||
* @author Auto create
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
public class EventSubjectTimeServiceImpl extends ServiceImpl<EventSubjectTimeMapper, EventSubjectTime> implements EventSubjectTimeService {
|
||||
|
||||
|
||||
}
|
||||
//package com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.impl;
|
||||
//
|
||||
//
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.dao.EventSubjectTimeMapper;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.entity.EventSubjectTime;
|
||||
//import com.chinaunicom.mall.ebtp.extend.partyMemberEvent.service.EventSubjectTimeService;
|
||||
//import org.springframework.stereotype.Service;
|
||||
//import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
///**
|
||||
// * 对数据表 event_subject_time 操作的 serviceImpl
|
||||
// * @author Auto create
|
||||
// *
|
||||
// */
|
||||
//@Service
|
||||
//public class EventSubjectTimeServiceImpl extends ServiceImpl<EventSubjectTimeMapper, EventSubjectTime> implements EventSubjectTimeService {
|
||||
//
|
||||
//
|
||||
//}
|
||||
|
Reference in New Issue
Block a user