|
|
@ -45,6 +45,8 @@ namespace Mesnac.Action.ChemicalWeighing.LjReport.DayWhiteEmbryo
|
|
|
|
List<ManualLogEntity> list;
|
|
|
|
List<ManualLogEntity> list;
|
|
|
|
|
|
|
|
|
|
|
|
List<ManualLogEntity> listMore;
|
|
|
|
List<ManualLogEntity> listMore;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<ManualLogEntity> listSet;
|
|
|
|
public void Run(RuntimeParameter runtime)
|
|
|
|
public void Run(RuntimeParameter runtime)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
base.RunIni(runtime); //必须调用
|
|
|
|
base.RunIni(runtime); //必须调用
|
|
|
@ -75,7 +77,8 @@ namespace Mesnac.Action.ChemicalWeighing.LjReport.DayWhiteEmbryo
|
|
|
|
dt.Columns.Add("总量", typeof(string));
|
|
|
|
dt.Columns.Add("总量", typeof(string));
|
|
|
|
|
|
|
|
|
|
|
|
MoreDataTable = new DataTable();
|
|
|
|
MoreDataTable = new DataTable();
|
|
|
|
MoreDataTable.Columns.Add("重量", typeof(string));
|
|
|
|
MoreDataTable.Columns.Add("设定重量", typeof(string));
|
|
|
|
|
|
|
|
MoreDataTable.Columns.Add("实际重量", typeof(string));
|
|
|
|
MoreDataTable.Columns.Add("时间", typeof(string));
|
|
|
|
MoreDataTable.Columns.Add("时间", typeof(string));
|
|
|
|
|
|
|
|
|
|
|
|
btnOk.Click += BtnOk_Click;
|
|
|
|
btnOk.Click += BtnOk_Click;
|
|
|
@ -120,12 +123,17 @@ namespace Mesnac.Action.ChemicalWeighing.LjReport.DayWhiteEmbryo
|
|
|
|
}
|
|
|
|
}
|
|
|
|
int num = int.Parse(chr.ToString());
|
|
|
|
int num = int.Parse(chr.ToString());
|
|
|
|
listMore = list.Where(x => x.deviceno == num).ToList();
|
|
|
|
listMore = list.Where(x => x.deviceno == num).ToList();
|
|
|
|
|
|
|
|
listSet = FreeSqlUnit.Instance.Select<ManualLogEntity>().Where(x => x.valuekind == 3 && x.devicekind == 2 && x.deviceno == num).ToList();
|
|
|
|
for (int i = 0; i < listMore.Count; i++)
|
|
|
|
for (int i = 0; i < listMore.Count; i++)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
var dr = MoreDataTable.NewRow();
|
|
|
|
var dr = MoreDataTable.NewRow();
|
|
|
|
dr[0] = listMore[i].value;
|
|
|
|
var val = listSet.Where(x => x.logtime <= listMore[i].logtime);
|
|
|
|
dr[1] = listMore[i].logtime;
|
|
|
|
if (val.Count() != 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
dr[0] = val.LastOrDefault().value;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
dr[1] = listMore[i].value;
|
|
|
|
|
|
|
|
dr[2] = listMore[i].logtime;
|
|
|
|
MoreDataTable.Rows.Add(dr);
|
|
|
|
MoreDataTable.Rows.Add(dr);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|