材料管理修改(打印修改,出库单已审核已完成不计算匹配率)材料匹配修改,焊接任务单修改

This commit is contained in:
2024-12-06 22:17:50 +08:00
parent 77fbdb946d
commit f4f7f93835
24 changed files with 850 additions and 323 deletions
+30 -17
View File
@@ -102,28 +102,41 @@ namespace FineUIPro.Web.CLGL
}
private void BindDetailRelationGrid(string inOutPlanMasterId)
{
/* Model.Tw_InOutPlanDetail_Relation table = new Model.Tw_InOutPlanDetail_Relation();
table.InOutPlanMasterId = inOutPlanMasterId;
var tb = BLL.TwInoutplandetailRelationService.GetListData(table, Grid3);
Grid3.DataSource = tb;
Grid3.DataBind();
*/
var inOutPlanMasterModel = TwInOutplanmasterService.GetById(inOutPlanMasterId);
var tb = BLL.TwArrivalStatisticsService.GetMatMatchByOutPlanMasterId(inOutPlanMasterId);
Grid3.DataSource = tb;
Grid3.DataBind();
//if (tb!= null && tb.Count > 0)
//{
// string Rate = Math.Round((decimal)tb.Average(item => item.MatchRate) * 100, 2).ToString() + "%";
// JObject summary = new JObject();
// //summary.Add("Major", "全部合计");
// summary.Add("MatchRateString", Rate);
if (inOutPlanMasterModel != null)
{
if (inOutPlanMasterModel.State== (int)TwConst.State.|| inOutPlanMasterModel.State == (int)TwConst.State.)
{
TabStrip2.Hidden = true;
TabStrip3.Hidden = false;
Grid4.DataSource = tb;
Grid4.DataBind();
// Grid3.SummaryData = summary;
//}
}
else
{
TabStrip2.Hidden = false;
TabStrip3.Hidden = true;
Grid3.DataSource = tb;
Grid3.DataBind();
for (int i = 0; i < Grid3.Rows.Count; i++)
{
var model = Grid3.Rows[i].DataItem as Tw_PipeMatMatchOutput;
if (model?.MatchRate < 1 || model?.MatchRate == null)
{
Grid3.Rows[i].RowCssClass = "red";
}
}
}
}
}
#endregion