shiqian 3 vuotta sitten
vanhempi
commit
ac9a5bba87

+ 26 - 0
boman-api/boman-domain/src/main/java/com/boman/domain/entity/StatisticReport.java

@@ -0,0 +1,26 @@
+package com.boman.domain.entity;
+
+import lombok.Builder;
+import lombok.Data;
+
+@Data
+@Builder
+public class StatisticReport {
+
+  private Long id;
+  private String reportName;
+  private String reportId;
+  private String templateName;
+  private java.sql.Date startTime;
+  private java.sql.Date endTime;
+  private String reportStatus;
+  private String status;
+  private String repUploadFile;
+  private String remark;
+  private String createBy;
+  private java.sql.Timestamp createTime;
+  private String updateBy;
+  private java.sql.Timestamp updateTime;
+
+
+}

+ 24 - 0
boman-api/boman-domain/src/main/java/com/boman/domain/entity/StatisticReportPersonnel.java

@@ -0,0 +1,24 @@
+package com.boman.domain.entity;
+
+import lombok.Builder;
+import lombok.Data;
+
+@Data
+@Builder
+public class StatisticReportPersonnel {
+
+  private Long id;
+  private String reportName;
+  private Long statisticId;
+  private Long deptId;
+  private String deptName;
+  private Long userId;
+  private String userName;
+  private String isDel;
+  private String status;
+  private String createBy;
+  private java.sql.Timestamp createTime;
+  private String updateBy;
+  private java.sql.Timestamp updateTime;
+
+}

+ 9 - 0
boman-report/src/main/java/com/boman/report/mapper/StatisticReportMapper.java

@@ -0,0 +1,9 @@
+package com.boman.report.mapper;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:09
+ **/
+public interface StatisticReportMapper {
+
+}

+ 8 - 0
boman-report/src/main/java/com/boman/report/mapper/StatisticReportPersonnelMapper.java

@@ -0,0 +1,8 @@
+package com.boman.report.mapper;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:09
+ **/
+public interface StatisticReportPersonnelMapper {
+}

+ 8 - 0
boman-report/src/main/java/com/boman/report/service/StatisticReportPersonnelService.java

@@ -0,0 +1,8 @@
+package com.boman.report.service;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:09
+ **/
+public interface StatisticReportPersonnelService {
+}

+ 8 - 0
boman-report/src/main/java/com/boman/report/service/StatisticReportService.java

@@ -0,0 +1,8 @@
+package com.boman.report.service;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:10
+ **/
+public interface StatisticReportService {
+}

+ 15 - 0
boman-report/src/main/java/com/boman/report/service/impl/StatisticReportPersonnelImpl.java

@@ -0,0 +1,15 @@
+package com.boman.report.service.impl;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import static com.boman.common.core.utils.obj.ObjectUtils.*;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:11
+ **/
+public class StatisticReportPersonnelImpl {
+
+    private static final Logger LOGGER = LoggerFactory.getLogger(StatisticReportPersonnelImpl.class);
+}

+ 13 - 0
boman-report/src/main/java/com/boman/report/service/impl/StatisticReportServiceImpl.java

@@ -0,0 +1,13 @@
+package com.boman.report.service.impl;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author shiqian
+ * @date 2021年08月24日 11:10
+ **/
+public class StatisticReportServiceImpl {
+
+    private static final Logger LOGGER = LoggerFactory.getLogger(ImportServiceImpl.class);
+}

+ 0 - 115
boman-report/src/main/resources/mapper/BomanReportMapper.xml

@@ -1,115 +0,0 @@
-<?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.boman.system.mapper.BomanGroupMapper">
-
-    <resultMap type="com.boman.domain.BomanGroup" id="BomanGroupResult">
-        <id property="id" column="id"/>
-        <result property="groupName" column="group_name"/>
-        <result property="status" column="status"/>
-        <result property="number" column="number"/>
-        <result property="createBy" column="create_by"/>
-        <result property="createTime" column="create_time"/>
-        <result property="updateBy" column="update_by"/>
-        <result property="updateTime" column="update_time"/>
-        <result property="isDel" column="is_del"/>
-        <collection  property="bomanGroupUserList"   javaType="java.util.List" resultMap="BomanGroupUserResult" />
-    </resultMap>
-
-    <resultMap type="com.boman.domain.BomanGroupUser" id="BomanGroupUserResult">
-        <id property="id" column="g_u_id"/>
-        <result property="userId" column="user_id"/>
-        <result property="userName" column="user_name"/>
-        <result property="groupId" column="group_id"/>
-        <result property="status" column="status"/>
-        <result property="createBy" column="create_by"/>
-        <result property="createTime" column="create_time"/>
-        <result property="updateBy" column="update_by"/>
-        <result property="updateTime" column="update_time"/>
-        <result property="isDel" column="is_del"/>
-    </resultMap>
-
-
-    <sql id="selectGroupVo">
-        select g.id, g.group_name, g.status, g.number, g.create_by, g.create_time, g.is_del
-        from boman_group g
-    </sql>
-
-    <select id="selectGroupList" parameterType="com.boman.domain.BomanGroup" resultMap="BomanGroupResult">
-        select g.id, g.group_name, g.status, g.number,  g.create_by, g.create_time, g.is_del, gu.user_name , gu.id as g_u_id
-        from boman_group g
-        left join boman_group_user gu on gu.group_id = g.id and gu.is_del = 'N'
-        where
-        g.is_del = 'N'
-        <if test="groupName != null and groupName != ''">
-            AND g.group_name like concat('%', #{groupName}, '%')
-        </if>
-        <!-- 数据范围过滤 -->
-        ${params.dataScope}
-        order by g.number
-    </select>
-
-    <select id="selectGroupById" parameterType="Long" resultMap="BomanGroupResult">
-        select g.id, g.group_name, g.status, g.number,  g.create_by, g.create_time, g.is_del, gu.user_name , gu.id
-        from boman_group g
-        left join boman_group_user gu on gu.group_id = g.id and gu.is_del = 'N'
-        where g.is_del = 'N'
-        and g.id = #{id}
-    </select>
-
-    <select id="checkGroupNameUnique" resultMap="BomanGroupResult">
-        <include refid="selectGroupVo"/>
-        where g.group_name=#{groupName} and g.is_del = 'N' limit 1
-    </select>
-
-    <insert id="insertGroup" parameterType="com.boman.domain.BomanGroup">
-        insert into boman_group(
-        <if test="id != null and id != 0">id,</if>
-        <if test="groupName != null and groupName != ''">group_name,</if>
-        <if test="number != null and number != ''">number,</if>
-        <if test="status != null">status,</if>
-        <if test="createBy != null and createBy != ''">create_by,</if>
-        <if test="isDel != null and isDel != ''">is_del,</if>
-        create_time
-        )values(
-        <if test="id != null and id != 0">#{id},</if>
-        <if test="groupName != null and groupName != ''">#{groupName},</if>
-        <if test="number != null and number != ''">#{number},</if>
-        <if test="status != null">#{status},</if>
-        <if test="createBy != null and createBy != ''">#{createBy},</if>
-        <if test="isDel != null and isDel != ''">#{isDel},</if>
-        sysdate()
-        )
-    </insert>
-
-    <update id="updateGroup" parameterType="com.boman.domain.BomanGroup">
-        update boman_group
-        <set>
-            <if test="groupName != null and groupName != ''">group_name = #{groupName},</if>
-            <if test="number != null and number != ''">number = #{number},</if>
-            <if test="status != null and status != ''">status = #{status},</if>
-            <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
-            <if test="isDel != null and isDel != ''">is_del = #{isDel},</if>
-            update_time = sysdate()
-        </set>
-        where id = #{id}
-    </update>
-
-
-    <select id="checkGroupExistUser" parameterType="Long" resultType="int">
-        select count(1) from boman_group_user where group_id in
-        <foreach collection="array" item="id" open="(" separator="," close=")">
-            #{id}
-        </foreach>
-        and is_del = 'N'
-    </select>
-
-
-	<update id="deleteGroupById" parameterType="Long">
-		update  boman_group set is_del = 'Y' where id in
-		<foreach collection="array" item="id" open="(" separator="," close=")">
-			#{id}
-		</foreach>
-	</update>
-</mapper> 

+ 24 - 0
boman-report/src/main/resources/mapper/StatisticReportMapper.xml

@@ -0,0 +1,24 @@
+<?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.boman.report.mapper.StatisticReportMapper">
+
+    <resultMap type="com.boman.domain.entity.StatisticReport" id="StatisticReportResult">
+        <id property="id" column="id"/>
+        <result property="reportName" column="report_name"/>
+        <result property="reportId" column="report_id"/>
+        <result property="templateName" column="template_name"/>
+        <result property="startTime" column="start_time"/>
+        <result property="endTime" column="end_time"/>
+        <result property="reportStatus" column="report_status"/>
+        <result property="status" column="status"/>
+        <result property="repUploadFile" column="rep_upload_file"/>
+        <result property="remark" column="remark"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+</mapper> 

+ 23 - 0
boman-report/src/main/resources/mapper/StatisticReportPersonnelMapper.xml

@@ -0,0 +1,23 @@
+<?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.boman.report.mapper.StatisticReportPersonnelMapper">
+
+    <resultMap type="com.boman.domain.entity.StatisticReportPersonnel" id="StatisticReportPersonnelResult">
+        <id property="id" column="id"/>
+        <result property="reportName" column="report_name"/>
+        <result property="statisticId" column="statistic_id"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="userId" column="user_id"/>
+        <result property="userName" column="user_name"/>
+        <result property="status" column="status"/>
+        <result property="isDel" column="is_del"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+</mapper> 

+ 17 - 0
src/main/java/com/boman/report/mapper/StatisticReportMapper.java

@@ -0,0 +1,17 @@
+package com.boman.report.mapper;
+
+import generator.StatisticReport;
+
+public interface StatisticReportMapper {
+    int deleteByPrimaryKey(Long id);
+
+    int insert(StatisticReport record);
+
+    int insertSelective(StatisticReport record);
+
+    StatisticReport selectByPrimaryKey(Long id);
+
+    int updateByPrimaryKeySelective(StatisticReport record);
+
+    int updateByPrimaryKey(StatisticReport record);
+}

+ 84 - 0
src/main/java/generator/StatisticReport.java

@@ -0,0 +1,84 @@
+package generator;
+
+import java.io.Serializable;
+import java.util.Date;
+import lombok.Data;
+
+/**
+ * statistic_report
+ * @author 
+ */
+@Data
+public class StatisticReport implements Serializable {
+    /**
+     * 主键
+     */
+    private Long id;
+
+    /**
+     * 报表名称
+     */
+    private String reportName;
+
+    /**
+     * 积木报表id
+     */
+    private String reportId;
+
+    /**
+     * 模板名称
+     */
+    private String templateName;
+
+    /**
+     * 开始时间
+     */
+    private Date startTime;
+
+    /**
+     * 结束时间
+     */
+    private Date endTime;
+
+    /**
+     * 当前状态(1:未开始,2:进行中,3:已结束)
+     */
+    private String reportStatus;
+
+    /**
+     * 状态(1:无效,2:有效)
+     */
+    private String status;
+
+    /**
+     * 模板文件
+     */
+    private String repUploadFile;
+
+    /**
+     * 注意事项
+     */
+    private String remark;
+
+    /**
+     * 创建者
+     */
+    private String createBy;
+
+    /**
+     * 创建时间
+     */
+    private Date createTime;
+
+    /**
+     * 更新者
+     */
+    private String updateBy;
+
+    /**
+     * 更新时间
+     */
+    private Date updateTime;
+
+    private static final long serialVersionUID = 1L;
+}

+ 193 - 0
src/main/resources/mapper/generator/StatisticReportMapper.xml

@@ -0,0 +1,193 @@
+<?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.boman.report.mapper.StatisticReportMapper">
+  <resultMap id="BaseResultMap" type="generator.StatisticReport">
+    <id column="id" jdbcType="BIGINT" property="id" />
+    <result column="report_name" jdbcType="VARCHAR" property="reportName" />
+    <result column="report_id" jdbcType="VARCHAR" property="reportId" />
+    <result column="template_name" jdbcType="VARCHAR" property="templateName" />
+    <result column="start_time" jdbcType="DATE" property="startTime" />
+    <result column="end_time" jdbcType="DATE" property="endTime" />
+    <result column="report_status" jdbcType="VARCHAR" property="reportStatus" />
+    <result column="status" jdbcType="CHAR" property="status" />
+    <result column="rep_upload_file" jdbcType="VARCHAR" property="repUploadFile" />
+    <result column="remark" jdbcType="VARCHAR" property="remark" />
+    <result column="create_by" jdbcType="VARCHAR" property="createBy" />
+    <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
+    <result column="update_by" jdbcType="VARCHAR" property="updateBy" />
+    <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
+  </resultMap>
+  <sql id="Base_Column_List">
+    id, report_name, report_id, template_name, start_time, end_time, report_status, `status`, 
+    rep_upload_file, remark, create_by, create_time, update_by, update_time
+  </sql>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+    select 
+    <include refid="Base_Column_List" />
+    from statistic_report
+    where id = #{id,jdbcType=BIGINT}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+    delete from statistic_report
+    where id = #{id,jdbcType=BIGINT}
+  </delete>
+  <insert id="insert" keyColumn="id" keyProperty="id" parameterType="generator.StatisticReport" useGeneratedKeys="true">
+    insert into statistic_report (report_name, report_id, template_name, 
+      start_time, end_time, report_status, 
+      `status`, rep_upload_file, remark, 
+      create_by, create_time, update_by, 
+      update_time)
+    values (#{reportName,jdbcType=VARCHAR}, #{reportId,jdbcType=VARCHAR}, #{templateName,jdbcType=VARCHAR}, 
+      #{startTime,jdbcType=DATE}, #{endTime,jdbcType=DATE}, #{reportStatus,jdbcType=VARCHAR}, 
+      #{status,jdbcType=CHAR}, #{repUploadFile,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, 
+      #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, 
+      #{updateTime,jdbcType=TIMESTAMP})
+  </insert>
+  <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="generator.StatisticReport" useGeneratedKeys="true">
+    insert into statistic_report
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="reportName != null">
+        report_name,
+      </if>
+      <if test="reportId != null">
+        report_id,
+      </if>
+      <if test="templateName != null">
+        template_name,
+      </if>
+      <if test="startTime != null">
+        start_time,
+      </if>
+      <if test="endTime != null">
+        end_time,
+      </if>
+      <if test="reportStatus != null">
+        report_status,
+      </if>
+      <if test="status != null">
+        `status`,
+      </if>
+      <if test="repUploadFile != null">
+        rep_upload_file,
+      </if>
+      <if test="remark != null">
+        remark,
+      </if>
+      <if test="createBy != null">
+        create_by,
+      </if>
+      <if test="createTime != null">
+        create_time,
+      </if>
+      <if test="updateBy != null">
+        update_by,
+      </if>
+      <if test="updateTime != null">
+        update_time,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="reportName != null">
+        #{reportName,jdbcType=VARCHAR},
+      </if>
+      <if test="reportId != null">
+        #{reportId,jdbcType=VARCHAR},
+      </if>
+      <if test="templateName != null">
+        #{templateName,jdbcType=VARCHAR},
+      </if>
+      <if test="startTime != null">
+        #{startTime,jdbcType=DATE},
+      </if>
+      <if test="endTime != null">
+        #{endTime,jdbcType=DATE},
+      </if>
+      <if test="reportStatus != null">
+        #{reportStatus,jdbcType=VARCHAR},
+      </if>
+      <if test="status != null">
+        #{status,jdbcType=CHAR},
+      </if>
+      <if test="repUploadFile != null">
+        #{repUploadFile,jdbcType=VARCHAR},
+      </if>
+      <if test="remark != null">
+        #{remark,jdbcType=VARCHAR},
+      </if>
+      <if test="createBy != null">
+        #{createBy,jdbcType=VARCHAR},
+      </if>
+      <if test="createTime != null">
+        #{createTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateBy != null">
+        #{updateBy,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKeySelective" parameterType="generator.StatisticReport">
+    update statistic_report
+    <set>
+      <if test="reportName != null">
+        report_name = #{reportName,jdbcType=VARCHAR},
+      </if>
+      <if test="reportId != null">
+        report_id = #{reportId,jdbcType=VARCHAR},
+      </if>
+      <if test="templateName != null">
+        template_name = #{templateName,jdbcType=VARCHAR},
+      </if>
+      <if test="startTime != null">
+        start_time = #{startTime,jdbcType=DATE},
+      </if>
+      <if test="endTime != null">
+        end_time = #{endTime,jdbcType=DATE},
+      </if>
+      <if test="reportStatus != null">
+        report_status = #{reportStatus,jdbcType=VARCHAR},
+      </if>
+      <if test="status != null">
+        `status` = #{status,jdbcType=CHAR},
+      </if>
+      <if test="repUploadFile != null">
+        rep_upload_file = #{repUploadFile,jdbcType=VARCHAR},
+      </if>
+      <if test="remark != null">
+        remark = #{remark,jdbcType=VARCHAR},
+      </if>
+      <if test="createBy != null">
+        create_by = #{createBy,jdbcType=VARCHAR},
+      </if>
+      <if test="createTime != null">
+        create_time = #{createTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateBy != null">
+        update_by = #{updateBy,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        update_time = #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+    </set>
+    where id = #{id,jdbcType=BIGINT}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="generator.StatisticReport">
+    update statistic_report
+    set report_name = #{reportName,jdbcType=VARCHAR},
+      report_id = #{reportId,jdbcType=VARCHAR},
+      template_name = #{templateName,jdbcType=VARCHAR},
+      start_time = #{startTime,jdbcType=DATE},
+      end_time = #{endTime,jdbcType=DATE},
+      report_status = #{reportStatus,jdbcType=VARCHAR},
+      `status` = #{status,jdbcType=CHAR},
+      rep_upload_file = #{repUploadFile,jdbcType=VARCHAR},
+      remark = #{remark,jdbcType=VARCHAR},
+      create_by = #{createBy,jdbcType=VARCHAR},
+      create_time = #{createTime,jdbcType=TIMESTAMP},
+      update_by = #{updateBy,jdbcType=VARCHAR},
+      update_time = #{updateTime,jdbcType=TIMESTAMP}
+    where id = #{id,jdbcType=BIGINT}
+  </update>
+</mapper>