Bläddra i källkod

提案单位答复

LIVE_YE 1 år sedan
förälder
incheckning
e97a2bc0fe

+ 12 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/proposal/ProposalInfoController.java

@@ -60,6 +60,18 @@ public class ProposalInfoController extends BaseController
         return getDataTable(list);
     }
 
+    /**
+     * 根据单位查询
+     */
+    @PreAuthorize("@ss.hasPermi('proposalInfo:info:unitList')")
+    @GetMapping("/unitList")
+    public TableDataInfo unitList(ProposalInfo proposalInfo)
+    {
+        startPage();
+        List<ProposalInfo> list = proposalInfoService.unitList(proposalInfo);
+        return getDataTable(list);
+    }
+
 
     /**
      * 导出提案信息列表

+ 21 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/ProposalInfo.java

@@ -173,6 +173,27 @@ public class ProposalInfo extends BaseEntity
     /** 是否同意联名 */
     private String isAgree;
 
+    /** 部门id */
+    private Long deptId;
+
+    /** 单位类型 */
+    private String dwType;
+
+    public String getDwType() {
+        return dwType;
+    }
+
+    public void setDwType(String dwType) {
+        this.dwType = dwType;
+    }
+
+    public Long getDeptId() {
+        return deptId;
+    }
+
+    public void setDeptId(Long deptId) {
+        this.deptId = deptId;
+    }
 
     public String getIsAgree() {
         return isAgree;

+ 57 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/ProposalUnitReply.java

@@ -1,10 +1,12 @@
 package com.ruoyi.system.domain;
 
+import com.fasterxml.jackson.annotation.JsonFormat;
 import org.apache.commons.lang3.builder.ToStringBuilder;
 import org.apache.commons.lang3.builder.ToStringStyle;
 import com.ruoyi.common.annotation.Excel;
 import com.ruoyi.common.core.domain.BaseEntity;
 
+import java.util.Date;
 import java.util.List;
 
 /**
@@ -45,6 +47,25 @@ public class ProposalUnitReply extends BaseEntity
     @Excel(name = "单位类型 1:答复单位,2:主办单位,3:协办单位")
     private String type;
 
+    /** 接收时间 */
+    @Excel(name = "接收时间")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    private Date startTime;
+
+    /** 办结时间 */
+    @Excel(name = "办结时间")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    private Date endTime;
+
+    /** 处理方式 */
+    @Excel(name = "处理方式")
+    private String handling;
+
+    /** 办理程度 */
+    @Excel(name = "办理程度")
+    private String degree;
+
+
     /** 附件 */
     private List<ZxFj> zxFjList;
 
@@ -114,6 +135,42 @@ public class ProposalUnitReply extends BaseEntity
         this.deptName = deptName;
     }
 
+    public String getIsReply() {
+        return isReply;
+    }
+
+    public Date getStartTime() {
+        return startTime;
+    }
+
+    public void setStartTime(Date startTime) {
+        this.startTime = startTime;
+    }
+
+    public Date getEndTime() {
+        return endTime;
+    }
+
+    public void setEndTime(Date endTime) {
+        this.endTime = endTime;
+    }
+
+    public String getHandling() {
+        return handling;
+    }
+
+    public void setHandling(String handling) {
+        this.handling = handling;
+    }
+
+    public String getDegree() {
+        return degree;
+    }
+
+    public void setDegree(String degree) {
+        this.degree = degree;
+    }
+
     @Override
     public String toString() {
         return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)

+ 2 - 0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/ProposalInfoMapper.java

@@ -60,4 +60,6 @@ public interface ProposalInfoMapper
     public int deleteProposalInfoByProposalIds(Long[] proposalIds);
 
     List<ProposalInfo> selectProposalInfoListByUser(ProposalInfo proposalInfo);
+
+    List<ProposalInfo> selectProposalInfoListByUnit(ProposalInfo proposalInfo);
 }

+ 2 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/IProposalInfoService.java

@@ -76,4 +76,6 @@ public interface IProposalInfoService
     AjaxResult zxIdea(ProposalInfo proposalInfo);
 
     AjaxResult assignsh(ProposalInfo proposalInfo);
+
+    List<ProposalInfo> unitList(ProposalInfo proposalInfo);
 }

+ 6 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/ProposalInfoServiceImpl.java

@@ -279,4 +279,10 @@ public class ProposalInfoServiceImpl implements IProposalInfoService
         return i > 0 ? AjaxResult.success() : AjaxResult.error();
     }
 
+    @Override
+    public List<ProposalInfo> unitList(ProposalInfo proposalInfo) {
+        SysUser user = SecurityUtils.getLoginUser().getUser();
+        proposalInfo.setDeptId(user.getDeptId());
+        return proposalInfoMapper.selectProposalInfoListByUnit(proposalInfo);
+    }
 }

+ 9 - 4
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/ZxConferenceServiceImpl.java

@@ -58,12 +58,17 @@ public class ZxConferenceServiceImpl implements IZxConferenceService {
         //查询是否答复,不答复算未读
         List<ZxConference> zxConferences = zxConferenceMapper.selectZxConferenceList(zxConference);
         if (zxConferences != null && zxConferences.size() > 0) {
+            long count;
             for (ZxConference conference : zxConferences) {
                 List<ZxConferenceUser> zxConferenceUserList = conference.getZxConferenceUserList();
-                //找出答复字段不是null的
-                long count = zxConferenceUserList.stream().filter(e -> e.getIsJoin() != null).count();
-                conference.setRead(count + "");
-                conference.setNoRead(String.valueOf(zxConferenceUserList.size() - count));
+                conference.setRead("0");
+                conference.setNoRead("0");
+                if (zxConferenceUserList != null && zxConferenceUserList.size() > 0) {
+                    //找出答复字段不是null的
+                    count = zxConferenceUserList.stream().filter(e -> e.getIsJoin() != null).count();
+                    conference.setRead(count + "");
+                    conference.setNoRead(String.valueOf(zxConferenceUserList.size() - count));
+                }
             }
         }
         return zxConferences;

+ 50 - 1
ruoyi-system/src/main/resources/mapper/system/ProposalInfoMapper.xml

@@ -53,6 +53,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
 
         <result property="isAgree"    column="isAgree"    />
+        <result property="deptId"    column="deptId"    />
+        <result property="dwType"    column="dwType"    />
     </resultMap>
 
     <sql id="selectProposalInfoVo">
@@ -111,7 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                p.is_survey, p.is_first, p.is_person, p.is_record, p.negotiate_type, p.proposed_contractor, p.proposal_progress, p.rolling_process, p.complex_type,
                p.is_cases_together, p.unite_proposal_id, p.satisfaction, p.members_opinion,p.cbdwdfwy,
                p.zx_satisfaction,p.zx_opinion,p.is_key_point,p.key_point_argument,p.is_outstanding,p.outstanding_argument,p.create_by, p.create_time,
-               p.update_by, p.update_time, p.remark,u.is_agree as isAgree
+               p.update_by, p.update_time, p.remark,u.is_agree as isAgree,u.type as dwType
         from proposal_info p
         left join proposal_user u on p.proposal_id = u.proposal_id
         where u.user_id = #{proposalUserId} and u.type = '2'
@@ -152,6 +154,53 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         order by p.update_time desc
     </select>
 
+    <select id="selectProposalInfoListByUnit" resultMap="ProposalInfoResult">
+        select p.proposal_id, p.proposal_user_id, p.proposal_number, p.title, p.proposal_name, p.proposal_phone, p.boundary, p.party_affiliation,
+        p.contact_address, p.category_id, p.category_name, p.proposal_type, p.proposal_content, p.is_jointly, p.is_publicity, p.content_publicity,
+        p.is_survey, p.is_first, p.is_person, p.is_record, p.negotiate_type, p.proposed_contractor, p.proposal_progress, p.rolling_process, p.complex_type,
+        p.is_cases_together, p.unite_proposal_id, p.satisfaction, p.members_opinion,p.cbdwdfwy,
+        p.zx_satisfaction,p.zx_opinion,p.is_key_point,p.key_point_argument,p.is_outstanding,p.outstanding_argument,p.create_by, p.create_time,
+        p.update_by, p.update_time, p.remark,u.is_agree as isAgree
+        from proposal_info p
+        left join proposal_unit_reply u on p.proposal_id = u.proposal_id
+        where u.dept_id = #{deptId}
+        <if test="type != null  and type != ''"> and u.type = #{dwType}</if>
+        <if test="proposalNumber != null  and proposalNumber != ''"> and p.proposal_number = #{proposalNumber}</if>
+        <if test="title != null  and title != ''"> and p.title = #{title}</if>
+        <if test="proposalName != null  and proposalName != ''"> and p.proposal_name like concat('%', #{proposalName}, '%')</if>
+        <if test="proposalPhone != null  and proposalPhone != ''"> and p.proposal_phone = #{proposalPhone}</if>
+        <if test="boundary != null  and boundary != ''"> and p.boundary = #{boundary}</if>
+        <if test="partyAffiliation != null  and partyAffiliation != ''"> and p.party_affiliation = #{partyAffiliation}</if>
+        <if test="contactAddress != null  and contactAddress != ''"> and p.contact_address = #{contactAddress}</if>
+        <if test="categoryId != null "> and p.category_id = #{categoryId}</if>
+        <if test="categoryName != null  and categoryName != ''"> and p.category_name like concat('%', #{categoryName}, '%')</if>
+        <if test="proposalType != null  and proposalType != ''"> and p.proposal_type = #{proposalType}</if>
+        <if test="proposalContent != null  and proposalContent != ''"> and p.proposal_content = #{proposalContent}</if>
+        <if test="isJointly != null  and isJointly != ''"> and p.is_jointly = #{isJointly}</if>
+        <if test="isPublicity != null  and isPublicity != ''"> and p.is_publicity = #{isPublicity}</if>
+        <if test="contentPublicity != null  and contentPublicity != ''"> and p.content_publicity = #{contentPublicity}</if>
+        <if test="isSurvey != null  and isSurvey != ''"> and p.is_survey = #{isSurvey}</if>
+        <if test="isFirst != null  and isFirst != ''"> and p.is_first = #{isFirst}</if>
+        <if test="isPerson != null  and isPerson != ''"> and p.is_person = #{isPerson}</if>
+        <if test="isRecord != null  and isRecord != ''"> and p.is_record = #{isRecord}</if>
+        <if test="negotiateType != null  and negotiateType != ''"> and p.negotiate_type = #{negotiateType}</if>
+        <if test="proposedContractor != null  and proposedContractor != ''"> and p.proposed_contractor = #{proposedContractor}</if>
+        <if test="proposalProgress != null  and proposalProgress != ''"> and p.proposal_progress = #{proposalProgress}</if>
+        <if test="rollingProcess != null  and rollingProcess != ''"> and p.rolling_process = #{rollingProcess}</if>
+        <if test="complexType != null  and complexType != ''"> and p.complex_type = #{complexType}</if>
+        <if test="isCasesTogether != null  and isCasesTogether != ''"> and p.is_cases_together = #{isCasesTogether}</if>
+        <if test="uniteProposalId != null "> and p.unite_proposal_id = #{uniteProposalId}</if>
+        <if test="satisfaction != null  and satisfaction != ''"> and p.satisfaction = #{satisfaction}</if>
+        <if test="membersOpinion != null  and membersOpinion != ''"> and p.members_opinion = #{membersOpinion}</if>
+        <if test="zxSatisfaction != null  and zxSatisfaction != ''"> and p.zx_satisfaction = #{zxSatisfaction}</if>
+        <if test="zxOpinion != null  and zxOpinion != ''"> and p.zx_opinion = #{zxOpinion}</if>
+        <if test="isKeyPoint != null  and isKeyPoint != ''"> and p.is_key_point = #{isKeyPoint}</if>
+        <if test="keyPointArgument != null  and keyPointArgument != ''"> and p.key_point_argument = #{keyPointArgument}</if>
+        <if test="isOutstanding != null  and isOutstanding != ''"> and p.is_outstanding = #{isOutstanding}</if>
+        <if test="outstandingArgument != null  and outstandingArgument != ''"> and p.outstanding_argument = #{outstandingArgument}</if>
+        order by p.update_time desc
+    </select>
+
     <insert id="insertProposalInfo" parameterType="ProposalInfo" useGeneratedKeys="true" keyProperty="proposalId">
         insert into proposal_info
         <trim prefix="(" suffix=")" suffixOverrides=",">

+ 19 - 1
ruoyi-system/src/main/resources/mapper/system/ProposalUnitReplyMapper.xml

@@ -12,11 +12,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="isReply"    column="is_reply"    />
         <result property="content"    column="content"    />
         <result property="type"    column="type"    />
+
+        <result property="startTime"    column="start_time"    />
+        <result property="endTime"    column="end_time"    />
+        <result property="handling"    column="handling"    />
+        <result property="degree"    column="degree"    />
+
         <result property="remark"    column="remark"    />
     </resultMap>
 
     <sql id="selectProposalUnitReplyVo">
-        select id, dept_id,dept_name, proposal_id,is_reply, content, type, remark from proposal_unit_reply
+        select id, dept_id,dept_name, proposal_id,is_reply, content, type,start_time,end_time,handling,degree, remark from proposal_unit_reply
     </sql>
 
     <select id="selectProposalUnitReplyList" parameterType="ProposalUnitReply" resultMap="ProposalUnitReplyResult">
@@ -44,6 +50,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isReply != null  ">is_reply ,</if>
             <if test="content != null and content != ''">content,</if>
             <if test="type != null">type,</if>
+            <if test="startTime != null">start_time,</if>
+            <if test="endTime != null">end_time,</if>
+            <if test="handling != null">handling,</if>
+            <if test="degree != null">degree,</if>
             <if test="remark != null">remark,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
@@ -53,6 +63,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isReply != null  ">#{isReply},</if>
             <if test="content != null and content != ''">#{content},</if>
             <if test="type != null">#{type},</if>
+            <if test="startTime != null">#{startTime},</if>
+            <if test="endTime != null">#{endTime},</if>
+            <if test="handling != null">#{handling},</if>
+            <if test="degree != null">#{degree},</if>
             <if test="remark != null">#{remark},</if>
          </trim>
     </insert>
@@ -66,6 +80,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isReply != null  "> is_reply = #{isReply},</if>
             <if test="content != null and content != ''">content = #{content},</if>
             <if test="type != null">type = #{type},</if>
+            <if test="startTime != null">start_time= #{startTime},</if>
+            <if test="endTime != null">end_time= #{endTime},</if>
+            <if test="handling != null">handling= #{handling},</if>
+            <if test="degree != null">degree= #{degree},</if>
             <if test="remark != null">remark = #{remark},</if>
         </trim>
         where id = #{id}