Merge branch 'dev_xd' of http://62.234.3.186:3000/jiangyq/YZProjectCloud into dev_xd
# Conflicts: # yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/controller/SmzSspProblemmodifyController.java # yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/service/ISmzSspProblemmodifyService.javadev_xd
commit
4635d42aa4
|
@ -145,6 +145,19 @@ public class SmzSspProblemmodify extends BaseEntity
|
||||||
@Excel(name = "问题类型", readConverterExp = "1=常规问题,2专项问题")
|
@Excel(name = "问题类型", readConverterExp = "1=常规问题,2专项问题")
|
||||||
private String problemType;
|
private String problemType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否最新(1-排序规则(按id降序))
|
||||||
|
*/
|
||||||
|
private Long isNew;
|
||||||
|
|
||||||
|
public Long getIsNew() {
|
||||||
|
return isNew;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIsNew(Long isNew) {
|
||||||
|
this.isNew = isNew;
|
||||||
|
}
|
||||||
|
|
||||||
private String problemTypeName;
|
private String problemTypeName;
|
||||||
private String dangerTypeName;
|
private String dangerTypeName;
|
||||||
private String createUserName;
|
private String createUserName;
|
||||||
|
|
|
@ -58,4 +58,5 @@ public interface SmzSspAuditinfoMapper
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteSmzSspAuditinfoByIds(Long[] ids);
|
public int deleteSmzSspAuditinfoByIds(Long[] ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -81,4 +81,18 @@ public interface SmzSspProblemmodifyMapper
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where);
|
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按检查类型(ssp_proble_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<SmzSspProblemmodify> groupByProblemType(SmzSspProblemmodify where);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按隐患类型(ssp_proble_sub_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<SmzSspProblemmodify> groupByDangerType(SmzSspProblemmodify where);
|
||||||
}
|
}
|
||||||
|
|
|
@ -410,5 +410,66 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
and a.checkState not in (4) and date(nickedTime) <= curdate()
|
and a.checkState not in (4) and date(nickedTime) <= curdate()
|
||||||
</if>
|
</if>
|
||||||
<include refid="countUserWhere"></include>
|
<include refid="countUserWhere"></include>
|
||||||
|
<if test="isNew!=null and isNew!=0">
|
||||||
|
order by a.id desc
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
<select id="groupByProblemType" parameterType="SmzSspProblemmodify" resultMap="SmzSspProblemmodifyResult">
|
||||||
|
select a.dict_value nickedInfo,a.dict_label problemType,b.cnt id
|
||||||
|
from (SELECT * from sys_dict_data dic WHERE dict_type='ssp_proble_type') a
|
||||||
|
left join (
|
||||||
|
SELECT dic.dict_value,count(1) cnt
|
||||||
|
from smz_ssp_problemmodify ssp,sys_dict_data dic
|
||||||
|
where ssp.problemType=dic.dict_value and dic.dict_type='ssp_proble_type'
|
||||||
|
and ssp.isDel=0
|
||||||
|
<if test="comId != null "> and ssp.comId = #{comId}</if>
|
||||||
|
<if test="projectId != null "> and ssp.projectId = #{projectId}</if>
|
||||||
|
<if test="infoType != null "> and ssp.infoType = #{infoType}</if>
|
||||||
|
group by dic.dict_value )b on a.dict_value =b.dict_value
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="groupByDangerType" parameterType="SmzSspProblemmodify" resultMap="SmzSspProblemmodifyResult">
|
||||||
|
SELECT
|
||||||
|
a.cnt id,
|
||||||
|
b.cnt comId,
|
||||||
|
dic.dict_value nickedInfo,
|
||||||
|
dic.dict_label danger_type
|
||||||
|
FROM
|
||||||
|
( SELECT * FROM sys_dict_data dic WHERE dict_type = 'ssp_proble_sub_type' ) dic
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT
|
||||||
|
dic.dict_value,
|
||||||
|
count( 1 ) cnt
|
||||||
|
FROM
|
||||||
|
smz_ssp_problemmodify ssp,
|
||||||
|
sys_dict_data dic
|
||||||
|
WHERE
|
||||||
|
ssp.danger_type = dic.dict_value
|
||||||
|
and ssp.isDel=0
|
||||||
|
<if test="comId != null "> and ssp.comId = #{comId}</if>
|
||||||
|
<if test="projectId != null "> and ssp.projectId = #{projectId}</if>
|
||||||
|
<if test="infoType != null "> and ssp.infoType = #{infoType}</if>
|
||||||
|
AND dic.dict_type = 'ssp_proble_sub_type'
|
||||||
|
GROUP BY
|
||||||
|
dic.dict_value
|
||||||
|
) a ON a.dict_value = dic.dict_value
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT
|
||||||
|
dic.dict_value,
|
||||||
|
count( 1 ) cnt
|
||||||
|
FROM
|
||||||
|
smz_ssp_problemmodify ssp,
|
||||||
|
sys_dict_data dic
|
||||||
|
WHERE
|
||||||
|
ssp.danger_type = dic.dict_value
|
||||||
|
and ssp.isDel=0
|
||||||
|
<if test="comId != null "> and ssp.comId = #{comId}</if>
|
||||||
|
<if test="projectId != null "> and ssp.projectId = #{projectId}</if>
|
||||||
|
<if test="infoType != null "> and ssp.infoType = #{infoType}</if>
|
||||||
|
AND dic.dict_type = 'ssp_proble_sub_type'
|
||||||
|
AND ssp.checkState IN ( 0, 3 )
|
||||||
|
GROUP BY
|
||||||
|
dic.dict_value
|
||||||
|
) b ON b.dict_value = dic.dict_value
|
||||||
</select>
|
</select>
|
||||||
</mapper>
|
</mapper>
|
|
@ -229,6 +229,7 @@ public class SmzSspProblemmodifyController extends BaseController
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
<<<<<<< HEAD
|
||||||
* 查询问题整改详情
|
* 查询问题整改详情
|
||||||
* @param id
|
* @param id
|
||||||
* @return
|
* @return
|
||||||
|
@ -284,4 +285,50 @@ public class SmzSspProblemmodifyController extends BaseController
|
||||||
return success(smzSspAuditinfoService.insertSmzSspAuditinfo(smzSspAuditinfo));
|
return success(smzSspAuditinfoService.insertSmzSspAuditinfo(smzSspAuditinfo));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** 按检查类型(ssp_proble_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("trouble:problemmodify:list")
|
||||||
|
@PostMapping("/groupByProblemType")
|
||||||
|
public AjaxResult groupByProblemType(@RequestBody SmzSspProblemmodify where){
|
||||||
|
return success(smzSspProblemmodifyService.groupByProblemType(where));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按隐患类型(ssp_proble_sub_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("trouble:problemmodify:list")
|
||||||
|
@PostMapping("/groupByDangerType")
|
||||||
|
public AjaxResult groupByDangerType(@RequestBody SmzSspProblemmodify where){
|
||||||
|
return success(smzSspProblemmodifyService.groupByDangerType(where));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分类计数
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("trouble:problemmodify:list")
|
||||||
|
@GetMapping("/listCountForBG")
|
||||||
|
public AjaxResult listCountForBG(SmzSspProblemmodify where){
|
||||||
|
List<SmzSspProblemmodify> result=smzSspProblemmodifyService.getListCount(where);
|
||||||
|
return AjaxResult.success(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询隐患问题列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("trouble:problemmodify:list")
|
||||||
|
@GetMapping("/listForBG")
|
||||||
|
public TableDataInfo listForBG(SmzSspProblemmodify where)
|
||||||
|
{
|
||||||
|
where.setIsNew(1L);
|
||||||
|
startPage();
|
||||||
|
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectList(where);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,4 +85,18 @@ public interface ISmzSspProblemmodifyService
|
||||||
*/
|
*/
|
||||||
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where);
|
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按检查类型(ssp_proble_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<SmzSspProblemmodify> groupByProblemType(SmzSspProblemmodify where);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按隐患类型(ssp_proble_sub_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<SmzSspProblemmodify> groupByDangerType(SmzSspProblemmodify where);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,7 @@
|
||||||
package com.yanzhu.manage.service.impl;
|
package com.yanzhu.manage.service.impl;
|
||||||
|
|
||||||
import com.yanzhu.common.core.enums.IsDelEnums;
|
|
||||||
import com.yanzhu.common.core.text.Convert;
|
|
||||||
import com.yanzhu.common.core.utils.DateUtils;
|
import com.yanzhu.common.core.utils.DateUtils;
|
||||||
import com.yanzhu.common.core.utils.StringUtils;
|
|
||||||
import com.yanzhu.common.security.utils.SecurityUtils;
|
import com.yanzhu.common.security.utils.SecurityUtils;
|
||||||
import com.yanzhu.manage.domain.SmzSspAuditinfo;
|
|
||||||
import com.yanzhu.manage.domain.SmzSspFileinfo;
|
|
||||||
import com.yanzhu.manage.domain.SmzSspProblemmodify;
|
import com.yanzhu.manage.domain.SmzSspProblemmodify;
|
||||||
import com.yanzhu.manage.enums.CheckStateEnums;
|
import com.yanzhu.manage.enums.CheckStateEnums;
|
||||||
import com.yanzhu.manage.mapper.SmzSspAuditinfoMapper;
|
import com.yanzhu.manage.mapper.SmzSspAuditinfoMapper;
|
||||||
|
@ -18,7 +13,6 @@ import com.yanzhu.system.api.model.LoginUser;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
@ -164,4 +158,24 @@ public class SmzSspProblemmodifyServiceImpl implements ISmzSspProblemmodifyServi
|
||||||
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where) {
|
public List<SmzSspProblemmodify> selectList(SmzSspProblemmodify where) {
|
||||||
return smzSspProblemmodifyMapper.selectList(where);
|
return smzSspProblemmodifyMapper.selectList(where);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按检查类型(ssp_proble_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<SmzSspProblemmodify> groupByProblemType(SmzSspProblemmodify where) {
|
||||||
|
return smzSspProblemmodifyMapper.groupByProblemType(where);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 按隐患类型(ssp_proble_sub_type)分组查询
|
||||||
|
* @param where
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<SmzSspProblemmodify> groupByDangerType(SmzSspProblemmodify where) {
|
||||||
|
return smzSspProblemmodifyMapper.groupByDangerType(where);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue