Parcourir la source

上报页面展示调整

user5 il y a 4 ans
Parent
commit
c63b1a649e

+ 9 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralProjectRecords.java

@@ -135,6 +135,7 @@ public class RuralProjectRecords extends ActEntity<RuralProjectRecords> {
 	private Integer startCount;    //开始数据
 	private Integer endingCount;   //结束数据
 	private String adventDate;   //超期时间
+	private Date adventDateDate;   //超期时间
 	private String reportedType;   //超期状态(0:未超期;1:已超期)
 	private Date auditPassDate;   //报告审批日期
 
@@ -1370,4 +1371,12 @@ public class RuralProjectRecords extends ActEntity<RuralProjectRecords> {
 	public void setProjectProperties(String projectProperties) {
 		this.projectProperties = projectProperties;
 	}
+
+	public Date getAdventDateDate() {
+		return adventDateDate;
+	}
+
+	public void setAdventDateDate(Date adventDateDate) {
+		this.adventDateDate = adventDateDate;
+	}
 }

+ 14 - 3
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectRecordsService.java

@@ -1577,14 +1577,25 @@ public class RuralProjectRecordsService extends CrudService<RuralProjectRecordsD
 			//获取超期时间天数转int
 			Integer endingCount = Integer.parseInt(adventCount.get(0).getLabel());
 			//设置开始时间为还有3天即将超期
-			projectRecords.setStartCount(endingCount-3);
+			//projectRecords.setStartCount(endingCount-3);
+			//设置开始时间为领取报告号30天未上报得时间节点
+			projectRecords.setStartCount(30);
 			projectRecords.setEndingCount(endingCount);
 		}
 		//获取项目数据(提前三天进行通知 即 获取即将超期的数据)
 		List<RuralProjectRecords> projectRecordsList = dao.getProjectReportedListByAdvent(projectRecords);
 		for (RuralProjectRecords info: projectRecordsList) {
-			String notifyStr = "项目【"+ info.getProjectName()+"】即将上报超期";
-			String titleStr = "项目【"+ info.getProjectName()+"】即将上报超期。超期时间:"+info.getAdventDate();
+			String notifyStr = null;
+			String titleStr = null;
+			//如果当前时间大于过期时间
+			//Date类的一个方法,如果info.getAdventDateDate()早于 new Date() 返回true,否则返回false
+			if(info.getAdventDateDate().before(new Date())){
+				notifyStr = "项目【"+ info.getProjectName()+"】上报已超期";
+				titleStr = "项目【"+ info.getProjectName()+"】上报已超期。超期时间:"+info.getAdventDate() +"。请尽快上报";
+			}else{
+				notifyStr = "项目【"+ info.getProjectName()+"】即将上报超期";
+				titleStr = "项目【"+ info.getProjectName()+"】即将上报超期。超期时间:"+info.getAdventDate();
+			}
 			List<User> projectLeaders = workProjectUserDao.queryProjectUsers(info.getId(), "1");
 			for (User user: projectLeaders) {
 				workProjectNotifyService

+ 1 - 1
src/main/java/com/jeeplus/modules/workcalendar/service/WorkCalendarTaskService.java

@@ -118,4 +118,4 @@ public class WorkCalendarTaskService  {
         projectRecordsService.saveProjectReportedListByAdvent();
         logger.info("------------项目超期未上报定时任务结束------------------");
     }
-}
+}

+ 3 - 2
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml

@@ -1214,6 +1214,7 @@
 		SELECT
 			<include refid="projectRecordsColumns"/>
 			,date_add(date_format(prd.audit_pass_date, '%Y-%m-%d'),interval #{endingCount} day) as adventDate
+			,date_add(date_format(prd.audit_pass_date, '%Y-%m-%d'),interval #{endingCount} day) as adventDateDate
 			,a.project_type as "projectType"
 			FROM rural_project_records a
 			left join work_contract_info wci on a.contract_id = wci.id
@@ -1227,9 +1228,9 @@
 			left join sys_office so on so.id = su.office_id
 		<where>
 			a.del_flag = 0
-			and (a.reported_state!=5 or a.reported_state is null)
+			and (a.reported_state=6 or a.reported_state is null)
 			and prd.status = 5
-			and now() between date_add(prd.audit_pass_date,interval #{startCount} day) and date_add(prd.audit_pass_date,interval #{endingCount} day)
+			and now() > date_add(prd.audit_pass_date,interval #{startCount} day)
 		</where>
 	</select>
 

+ 3 - 3
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReportedForm.jsp

@@ -214,11 +214,11 @@
                     return false;
                 }
 
-                /*var checkedCount = $('input[type=checkbox]:checked').length;
+                var checkedCount = $('input[type=checkbox]:checked').length;
                 if(checkedCount == 0){
                     parent.layer.msg("请选择咨询项目造价包含内容说明!", {icon: 5});
                     return false;
-                }*/
+                }
 
                 var BaoGaoShuQianFaDate = $("#BaoGaoShuQianFaDate").val();
                 var s = BaoGaoShuQianFaDate.replace(/-/g,"/");
@@ -1369,7 +1369,7 @@
             <div class="form-group layui-row first lw9">
                 <div class="form-group-label"><h2>咨询项目造价包含内容说明</h2></div>
                 <div class="layui-item layui-col-sm12">
-                    <label class="layui-form-label double-line">咨询项目造价包含内容说明(勾选):</label>
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>咨询项目造价包含内容说明(勾选):</label>
                     <div class="layui-input-block paddingDiv">
                         <c:forEach items="${fns:getMainDictList('contents_include')}" var="contents">
                             <input type="checkbox" name="contentsIncludeList" class="contents_${contents.value}" value="${contents.value}" title="${contents.label}"/>

+ 12 - 4
src/main/webapp/webpage/modules/ruralprojectrecords/cost/reportedModify.jsp

@@ -215,11 +215,11 @@
                     return false;
                 }
 
-                /*var checkedCount = $('input[type=checkbox]:checked').length;
+                var checkedCount = $('input[type=checkbox]:checked').length;
                 if(checkedCount == 0){
                     parent.layer.msg("请选择咨询项目造价包含内容说明!", {icon: 5});
                     return false;
-                }*/
+                }
 
                 var BaoGaoShuQianFaDate = $("#BaoGaoShuQianFaDate").val();
                 var s = BaoGaoShuQianFaDate.replace(/-/g,"/");
@@ -612,6 +612,11 @@
                 $("#GCGMValueParameter").removeClass("number");
                 $("#GCGMValueParameter").addClass("number");
             }
+            var contents=${ruralProjectRecordsReported.contentsIncludeList}
+            for(var i=0;i<contents.length;i++){
+                var con=contents[i];
+                $(".contents_"+con+"").prop("checked",true)
+            }
         });
 
         function ZiXunBDEChange(){
@@ -1369,9 +1374,12 @@
             <div class="form-group layui-row first lw9">
                 <div class="form-group-label"><h2>咨询项目造价包含内容说明</h2></div>
                 <div class="layui-item layui-col-sm12">
-                    <label class="layui-form-label double-line">咨询项目造价包含内容说明(勾选):</label>
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>咨询项目造价包含内容说明(勾选):</label>
                     <div class="layui-input-block paddingDiv">
-                        <form:checkboxes path="contentsIncludeList" lay-filter="chargeCriterionList" lay-skin="primary" itemLabel="label" itemValue="value" htmlEscape="true" items="${fns:getMainDictList('contents_include')}" />
+                        <c:forEach items="${fns:getMainDictList('contents_include')}" var="contents">
+                            <input type="checkbox" name="contentsIncludeList" class="contents_${contents.value}" value="${contents.value}" title="${contents.label}"/>
+                        </c:forEach>
+                        <%--<form:checkboxes path="contentsIncludeList" lay-filter="chargeCriterionList" lay-skin="primary" itemLabel="label" itemValue="value" htmlEscape="true" items="${fns:getMainDictList('contents_include')}" />--%>
                     </div>
                 </div>
                 <div class="overallProcessDiv" style="display: none">

+ 7 - 1
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedAudit.jsp

@@ -218,6 +218,12 @@
                         return false;
                     }
 
+                    var checkedCount = $('input[type=checkbox]:checked').length;
+                    if(checkedCount == 0){
+                        parent.layer.msg("请选择咨询项目造价包含内容说明!", {icon: 5});
+                        return false;
+                    }
+
                     var BaoGaoShuQianFaDate = $("#BaoGaoShuQianFaDate").val();
                     var s = BaoGaoShuQianFaDate.replace(/-/g,"/");
                     var baogaoDate = new Date(s );
@@ -1383,7 +1389,7 @@
             <div class="form-group layui-row first lw9">
                 <div class="form-group-label"><h2>咨询项目造价包含内容说明</h2></div>
                 <div class="layui-item layui-col-sm12">
-                    <label class="layui-form-label double-line">咨询项目造价包含内容说明(勾选):</label>
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>咨询项目造价包含内容说明(勾选):</label>
                     <div class="layui-input-block paddingDiv">
                         <c:forEach items="${fns:getMainDictList('contents_include')}" var="contents">
                             <input type="checkbox" name="contentsIncludeList" class="contents_${contents.value}" value="${contents.value}" title="${contents.label}"/>

+ 3 - 3
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedForm.jsp

@@ -215,11 +215,11 @@
                     return false;
                 }
 
-                /*var checkedCount = $('input[type=checkbox]:checked').length;
+                var checkedCount = $('input[type=checkbox]:checked').length;
                 if(checkedCount == 0){
                     parent.layer.msg("请选择咨询项目造价包含内容说明!", {icon: 5});
                     return false;
-                }*/
+                }
 
                 var BaoGaoShuQianFaDate = $("#BaoGaoShuQianFaDate").val();
                 var s = BaoGaoShuQianFaDate.replace(/-/g,"/");
@@ -1356,7 +1356,7 @@
             <div class="form-group layui-row first lw9">
                 <div class="form-group-label"><h2>咨询项目造价包含内容说明</h2></div>
                 <div class="layui-item layui-col-sm12">
-                    <label class="layui-form-label double-line">咨询项目造价包含内容说明(勾选):</label>
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>咨询项目造价包含内容说明(勾选):</label>
                     <div class="layui-input-block paddingDiv">
                         <c:forEach items="${fns:getMainDictList('contents_include')}" var="contents">
                             <input type="checkbox" name="contentsIncludeList" class="contents_${contents.value}" value="${contents.value}" title="${contents.label}"/>

+ 3 - 3
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedModify.jsp

@@ -214,11 +214,11 @@
                     return false;
                 }
 
-                /*var checkedCount = $('input[type=checkbox]:checked').length;
+                var checkedCount = $('input[type=checkbox]:checked').length;
                 if(checkedCount == 0){
                     parent.layer.msg("请选择咨询项目造价包含内容说明!", {icon: 5});
                     return false;
-                }*/
+                }
 
                 var BaoGaoShuQianFaDate = $("#BaoGaoShuQianFaDate").val();
                 var s = BaoGaoShuQianFaDate.replace(/-/g,"/");
@@ -1359,7 +1359,7 @@
             <div class="form-group layui-row first lw9">
                 <div class="form-group-label"><h2>咨询项目造价包含内容说明</h2></div>
                 <div class="layui-item layui-col-sm12">
-                    <label class="layui-form-label double-line">咨询项目造价包含内容说明(勾选):</label>
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>明(勾选):</label>
                     <div class="layui-input-block paddingDiv">
                         <c:forEach items="${fns:getMainDictList('contents_include')}" var="contents">
                             <input type="checkbox" name="contentsIncludeList" class="contents_${contents.value}" value="${contents.value}" title="${contents.label}"/>