2023-2-14 001

This commit is contained in:
2023-02-14 19:59:12 +08:00
parent c25427af5e
commit 265e9a9f37
20 changed files with 1404 additions and 174 deletions
@@ -7,6 +7,7 @@ using System.Data.SqlClient;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Web;
@@ -230,6 +231,10 @@ namespace FineUIPro.Web.HJGL.WeldingManage
this.BindGrid2(this.tvControlItem.SelectedNodeID);
this.BindGrid3(this.tvControlItem.SelectedNodeID);
}
else
{
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNodeID;
}
}
}
@@ -374,7 +379,46 @@ namespace FineUIPro.Web.HJGL.WeldingManage
//}
#endregion
#endregion
#region
private string GetRateByUnitWork(string unitworkid)
{
var db = Funs.DB;
var q=from x in db.View_HJGL_WeldJoint where x.UnitWorkId == unitworkid select x ;
if (q!=null&&q.Count()>0)
{
var proSum = (from x in q
where x.JointAttribute == "预制口"
group x by x.UnitWorkId into g
select new
{
SizeSum = g.Sum(x => x.Size)
}).FirstOrDefault().SizeSum;
var AllSum = (from x in q
group x by x.UnitWorkId into g
select new
{
SizeSum = g.Sum(x => x.Size)
}).FirstOrDefault().SizeSum;
var a = (decimal)100 * proSum / AllSum;
var rate = Math.Round((decimal)a, 1);
return rate.ToString()+"%";
}
return "";
}
void GetRateByPipelineid(string pipelineid)
{
var db = Funs.DB;
var q = (from x in db.View_HJGL_WeldJoint
group x by x.PipelineId into g
where g.Key == pipelineid
select new
{
SizeSum = g.Sum(x => x.Size)
}).FirstOrDefault().SizeSum;
}
#endregion
#region
/// <summary>
/// Grid双击事件