Merge branch 'master' of https://gitee.com/frane-yang/SGGL_CWCEC
This commit is contained in:
commit
8660f76ba5
|
@ -71,14 +71,15 @@ namespace WebAPI.Controllers
|
||||||
/// 根据projectId获取各状态风险数
|
/// 根据projectId获取各状态风险数
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="projectId"></param>
|
/// <param name="projectId"></param>
|
||||||
|
/// <param name="type">0 日常巡检 1 常规巡检</param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public Model.ResponeData getHazardRegisterCount(string projectId)
|
public Model.ResponeData getHazardRegisterCount(string projectId,int type )
|
||||||
{
|
{
|
||||||
var responeData = new Model.ResponeData();
|
var responeData = new Model.ResponeData();
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
//总数
|
//总数
|
||||||
var getDataList = Funs.DB.HSSE_Hazard_HazardRegister.Where(x => x.ProjectId == projectId);
|
var getDataList = Funs.DB.HSSE_Hazard_HazardRegister.Where(x => x.ProjectId == projectId && x.Type==type);
|
||||||
int tatalCount = getDataList.Count();
|
int tatalCount = getDataList.Count();
|
||||||
//待整改
|
//待整改
|
||||||
int count1 = getDataList.Where(x => x.States == "1").Count();
|
int count1 = getDataList.Where(x => x.States == "1").Count();
|
||||||
|
|
Loading…
Reference in New Issue