Merge branch 'dev' of http://62.234.3.186:3000/sxyanzhu/jhprjv2 into dev
commit
116cc8a419
|
@ -35,15 +35,15 @@ public class ProblemmodifyController extends BaseController {
|
|||
* @return
|
||||
*/
|
||||
@GetMapping("/safetySummary")
|
||||
public List<SmzSspProblemmodify> safetySummary(int deptId,int roleType)
|
||||
public List<SmzSspProblemmodify> safetySummary(int deptId,int roleType,int projectId)
|
||||
{
|
||||
//3集团//4子公司//5监理单位//6总包//7分包
|
||||
String key="problemmodify_safetySummary-"+deptId+'-'+roleType;
|
||||
String key="problemmodify_safetySummary-"+deptId+"-"+roleType+"_"+projectId;
|
||||
Object obj=redisCache.getCacheObject(key);
|
||||
if(obj!=null){
|
||||
return (List<SmzSspProblemmodify>) obj;
|
||||
}
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummary(deptId,roleType,0);
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummary(deptId,roleType,projectId,0);
|
||||
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
|
||||
return list;
|
||||
}
|
||||
|
@ -56,15 +56,15 @@ public class ProblemmodifyController extends BaseController {
|
|||
* @return
|
||||
*/
|
||||
@GetMapping("/qualitySummary")
|
||||
public List<SmzSspProblemmodify> qualitySummary(int deptId,int roleType)
|
||||
public List<SmzSspProblemmodify> qualitySummary(int deptId,int roleType,int projectId)
|
||||
{
|
||||
//3集团//4子公司//5监理单位//6总包//7分包
|
||||
String key="problemmodify_qualitySummary-"+deptId+'-'+roleType;
|
||||
String key="problemmodify_qualitySummary-"+deptId+"-"+roleType+"_"+projectId;
|
||||
Object obj=redisCache.getCacheObject(key);
|
||||
if(obj!=null){
|
||||
return (List<SmzSspProblemmodify>) obj;
|
||||
}
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummary(deptId,roleType,1);
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummary(deptId,roleType,projectId,1);
|
||||
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
|
||||
return list;
|
||||
}
|
||||
|
@ -77,15 +77,15 @@ public class ProblemmodifyController extends BaseController {
|
|||
* @return
|
||||
*/
|
||||
@GetMapping("/safetySummaryByProject")
|
||||
public List<SmzSspProblemmodify> safetySummaryByProject(int deptId,int roleType)
|
||||
public List<SmzSspProblemmodify> safetySummaryByProject(int deptId,int roleType,int projectId)
|
||||
{
|
||||
//3集团//4子公司//5监理单位//6总包//7分包
|
||||
String key="problemmodify_safetySummaryByProject-"+deptId+'-'+roleType;
|
||||
String key="problemmodify_safetySummaryByProject-"+deptId+"-"+roleType+"_"+projectId;
|
||||
Object obj=redisCache.getCacheObject(key);
|
||||
if(obj!=null){
|
||||
return (List<SmzSspProblemmodify>) obj;
|
||||
}
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummaryByProject(deptId,roleType,0);
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummaryByProject(deptId,roleType,projectId,0);
|
||||
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
|
||||
return list;
|
||||
}
|
||||
|
@ -98,15 +98,15 @@ public class ProblemmodifyController extends BaseController {
|
|||
* @return
|
||||
*/
|
||||
@GetMapping("/qualitySummaryByProject")
|
||||
public List<SmzSspProblemmodify> qualitySummaryByProject(int deptId,int roleType)
|
||||
public List<SmzSspProblemmodify> qualitySummaryByProject(int deptId,int roleType,int projectId)
|
||||
{
|
||||
//3集团//4子公司//5监理单位//6总包//7分包
|
||||
String key="problemmodify_qualitySummaryByProject-"+deptId+'-'+roleType;
|
||||
String key="problemmodify_qualitySummaryByProject-"+deptId+"-"+roleType+"_"+projectId;
|
||||
Object obj=redisCache.getCacheObject(key);
|
||||
if(obj!=null){
|
||||
return (List<SmzSspProblemmodify>) obj;
|
||||
}
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummaryByProject(deptId,roleType,1);
|
||||
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSummaryByProject(deptId,roleType,projectId,1);
|
||||
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
|
||||
return list;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
package com.yanzhu.jh.project.domain.where;
|
||||
|
||||
public class SurProjectBuildNodeDataExport {
|
||||
}
|
|
@ -76,7 +76,7 @@ public interface ISmzSspProblemmodifyService
|
|||
* @param infoType 信息类型(0安全,1质量)
|
||||
* @return
|
||||
*/
|
||||
public List<SmzSspProblemmodify> selectSummary(int deptId, int roleType, int infoType);
|
||||
public List<SmzSspProblemmodify> selectSummary(int deptId, int roleType,int projectId, int infoType);
|
||||
|
||||
/**
|
||||
* 分类汇总(按项目)
|
||||
|
@ -85,7 +85,7 @@ public interface ISmzSspProblemmodifyService
|
|||
* @param infoType 信息类型(0安全,1质量)
|
||||
* @return
|
||||
*/
|
||||
public List<SmzSspProblemmodify> selectSummaryByProject(int deptId, int roleType, int infoType);
|
||||
public List<SmzSspProblemmodify> selectSummaryByProject(int deptId, int roleType,int projectId, int infoType);
|
||||
|
||||
public List<SmzSspProblemmodify> countByDate(SmzSspProblemmodifyWhere where);
|
||||
|
||||
|
|
|
@ -117,18 +117,20 @@ public class SmzSspProblemmodifyServiceImpl implements ISmzSspProblemmodifyServi
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<SmzSspProblemmodify> selectSummary(int deptId, int roleType, int infoType) {
|
||||
public List<SmzSspProblemmodify> selectSummary(int deptId, int roleType,int projectId, int infoType) {
|
||||
SmzSspProblemmodify smzSspProblemmodify=new SmzSspProblemmodify();
|
||||
smzSspProblemmodify.setRoleType(roleType);
|
||||
smzSspProblemmodify.setProjectId((long)projectId);
|
||||
smzSspProblemmodify.setInfoType((long)infoType);
|
||||
smzSspProblemmodify.setId((long)deptId);
|
||||
return smzSspProblemmodifyMapper.selectSummary(smzSspProblemmodify);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SmzSspProblemmodify> selectSummaryByProject(int deptId, int roleType, int infoType) {
|
||||
public List<SmzSspProblemmodify> selectSummaryByProject(int deptId, int roleType,int projectId, int infoType) {
|
||||
SmzSspProblemmodify smzSspProblemmodify=new SmzSspProblemmodify();
|
||||
smzSspProblemmodify.setRoleType(roleType);
|
||||
smzSspProblemmodify.setProjectId((long)projectId);
|
||||
smzSspProblemmodify.setInfoType((long)infoType);
|
||||
smzSspProblemmodify.setId((long)deptId);
|
||||
return smzSspProblemmodifyMapper.selectSummaryByProject(smzSspProblemmodify);
|
||||
|
|
|
@ -256,6 +256,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
LEFT JOIN ( SELECT danger_type,COUNT(1) cnt FROM smz_ssp_problemmodify WHERE projectId IN(
|
||||
SELECT id FROM sur_project
|
||||
where isDel=0
|
||||
<if test="projectId>0">and projectId=#{projectId}</if>
|
||||
<if test="id >0 ">AND deptid = #{id}</if>
|
||||
|
||||
) AND infotype=#{infoType} and isDel=0
|
||||
|
@ -268,6 +269,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
(
|
||||
select projectId,prjName,count(1) proble from vw_smz_ssp_problemmodify_audit
|
||||
where infoType=#{infoType}
|
||||
<if test="projectId>0">and projectId=#{projectId}</if>
|
||||
<if test="id >0 ">AND deptid = #{id}</if>
|
||||
<if test="roleType > 0">AND roletype=#{roleType}</if>
|
||||
group by projectId,prjName
|
||||
|
@ -277,6 +279,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
select projectid,count(1) timoutNoComp from vw_smz_ssp_problemmodify_audit where
|
||||
((updateTime is null and date(nickedTime) < date(now()) ) or date(updateTime )>date(nickedTime))
|
||||
and infoType=#{infoType}
|
||||
<if test="projectId>0">and projectId=#{projectId}</if>
|
||||
<if test="id >0 ">AND deptid = #{id}</if>
|
||||
<if test="roleType > 0">AND roletype=#{roleType}</if>
|
||||
group by projectId
|
||||
|
@ -285,6 +288,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
left join (
|
||||
SELECT projectid,COUNT(1) timoutComp FROM vw_smz_ssp_problemmodify_audit WHERE (updateTime is null and date(nickedTime) < date(now()) )
|
||||
and infoType=#{infoType}
|
||||
<if test="projectId>0">and projectId=#{projectId}</if>
|
||||
<if test="id >0 ">AND deptid = #{id}</if>
|
||||
<if test="roleType > 0">AND roletype=#{roleType}</if>
|
||||
GROUP BY projectid
|
||||
|
|
Loading…
Reference in New Issue