Пояснительная записка. Трач РВ (1228539), страница 8
Текст из файла (страница 8)
public class Statistics
{
private readonly MAO2Context db = new MAO2Context();
public string Name { get; set; }
public int Kol { get; set; }
public int KolInc(string Zone)
{
Kol = (from i in db.инциденты where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone && i.ИНФРАСТРУКТУРНЫЙ != null select i).Count();
return (Kol);
}
public int KolIncInf(string Zone)
{
Kol = (from i in db.инциденты where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone && i.ИНФРАСТРУКТУРНЫЙ =="t" select i).Count();
return (Kol);
}
public int KolIncTeh(string Zone)
{
Kol = (from i in db.инциденты where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone && i.ИНФРАСТРУКТУРНЫЙ == "f" select i).Count();
return (Kol);
}
public int KolProb(string Zone)
{
Kol = (from i in db.проблемы where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolIzm(string Zone)
{
Kol = (from i in db.изменения where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolObr(string Zone)
{
Kol = (from i in db.инциденты where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone && i.ИНФРАСТРУКТУРНЫЙ == null select i).Count();
return (Kol);
}
public int KolRegWorks(string Zone)
{
Kol = (from i in db.расписания_регламентных_работ where i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolIstochnicChanges(string Criterion, string Zone)
{
Kol = (from i in db.изменения where i.ИСТОЧНИК == Criterion && i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolIstochnicProblem(string Criterion, string Zone)
{
Kol = (from i in db.проблемы where i.НАПРАВЛЕНИЕ == Criterion && i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolIncEK(string Criterion, string Zone)
{
Kol = (from i in db.инциденты where i.ЭК == Criterion && i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolProbEK(string Criterion, string Zone)
{
Kol = (from i in db.проблемы where i.ЭК == Criterion && i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
public int KolChangeEK(string Criterion, string Zone)
{
Kol = (from i in db.изменения where i.ЭК == Criterion && i.ЗОНА_ОТВЕТСТВЕННОСТИ == Zone select i).Count();
return (Kol);
}
}
}















