代码无效引用清理,试压包资料界面看板修改
This commit is contained in:
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Security.Cryptography;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Linq;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
@@ -15,7 +10,7 @@ namespace BLL
|
||||
/// <param name="projectId"></param>
|
||||
/// <param name="type">0总达因,1预制口总达因,2安装口总达因</param>
|
||||
/// <returns></returns>
|
||||
public static decimal GetSumSize(string projectId,int type)
|
||||
public static decimal GetSumSize(string projectId, int type)
|
||||
{
|
||||
decimal result = 0;
|
||||
|
||||
@@ -42,7 +37,7 @@ namespace BLL
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
return result;
|
||||
}
|
||||
/// <summary>
|
||||
@@ -56,7 +51,7 @@ namespace BLL
|
||||
var getWelds = Funs.DB.HJGL_WeldJoint.Where(x => x.ProjectId == projectId);
|
||||
if (getWelds.Count() > 0)
|
||||
{
|
||||
|
||||
|
||||
var getWeldsOk = getWelds.Where(x => x.WeldingDailyId != null);
|
||||
if (getWeldsOk.Count() > 0)
|
||||
{
|
||||
@@ -64,9 +59,9 @@ namespace BLL
|
||||
if (GCModel.Count() > 0)
|
||||
{
|
||||
result = GCModel.Sum(x => x.Size ?? 0);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
return result;
|
||||
@@ -146,23 +141,23 @@ namespace BLL
|
||||
/// </summary>
|
||||
/// <param name="projectId"></param>
|
||||
/// <returns></returns>
|
||||
public static decimal GetWelderEfficacy(string projectId)
|
||||
public static decimal GetWelderEfficacy(string projectId)
|
||||
{
|
||||
decimal result = 0;
|
||||
var db = Funs.DB;
|
||||
var q = (from x in db.HJGL_WeldJoint
|
||||
join y in db.HJGL_WeldingDaily on x.WeldingDailyId equals y.WeldingDailyId
|
||||
where x.ProjectId ==projectId
|
||||
where x.ProjectId == projectId
|
||||
group x by x.ProjectId into g
|
||||
select new
|
||||
select new
|
||||
{
|
||||
TotalDin = g.Sum(x => x.Size),
|
||||
worktime = g.Select(x=>x.WeldingDailyId).Distinct().Count(),
|
||||
}) ;
|
||||
worktime = g.Select(x => x.WeldingDailyId).Distinct().Count(),
|
||||
});
|
||||
foreach (var item in q)
|
||||
{
|
||||
result = decimal.Divide((decimal)item.TotalDin, item.worktime) ;
|
||||
|
||||
result = decimal.Divide((decimal)item.TotalDin, item.worktime);
|
||||
|
||||
}
|
||||
|
||||
return decimal.Truncate(result);
|
||||
@@ -173,7 +168,7 @@ namespace BLL
|
||||
var db = Funs.DB;
|
||||
var q = (from x in db.HJGL_WeldJoint
|
||||
join y in db.HJGL_WeldingDaily on x.WeldingDailyId equals y.WeldingDailyId
|
||||
where x.ProjectId == projectId && x.JointAttribute=="预制口"
|
||||
where x.ProjectId == projectId && x.JointAttribute == "预制口"
|
||||
group x by x.ProjectId into g
|
||||
select new
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user