合并到develope后,修改绑定名称

This commit is contained in:
hanqiangqiang 2023-05-31 13:30:41 +08:00
parent 8231c28777
commit ce402674a0
2 changed files with 8 additions and 8 deletions

View File

@ -23,18 +23,18 @@ namespace MECF.Framework.UI.Client.TrayThickness.HistoryData
public List<CoatingData> QueryUpdateAll() public List<CoatingData> QueryUpdateAll()
{ {
string cmd = $"select * from tray_thickness_main order by creat_time desc "; string cmd = $"select * from tray_thickness_main order by creat_time desc ";
return NewMethod1(cmd); return QueryBase(cmd);
} }
public List<CoatingData> QueryUpdateTime(string starTime, string endTime) public List<CoatingData> QueryUpdateTime(string starTime, string endTime)
{ {
string cmd = $"select * from tray_thickness_main where creat_time between '{starTime}' and '{endTime}' order by creat_time desc"; string cmd = $"select * from tray_thickness_main where creat_time between '{starTime}' and '{endTime}' order by creat_time desc";
return NewMethod1(cmd); return QueryBase(cmd);
} }
public List<CoatingData> QueryUnitName(string name, string starTime="", string endTime="") public List<CoatingData> QueryUnitName(string name, string starTime="", string endTime="")
{ {
string time = $"and creat_time between '{starTime}' and '{endTime}'"; string time = $"and creat_time between '{starTime}' and '{endTime}'";
string cmd = $"select * from tray_thickness_main where tray_number = '{name}' {time} order by creat_time desc"; string cmd = $"select * from tray_thickness_main where tray_number = '{name}' {time} order by creat_time desc";
return NewMethod1(cmd, true); return QueryBase(cmd, true);
} }
public List<CoatingData> QueryEntirety(string name, string starTime = "", string endTime = "") public List<CoatingData> QueryEntirety(string name, string starTime = "", string endTime = "")
@ -72,10 +72,10 @@ namespace MECF.Framework.UI.Client.TrayThickness.HistoryData
} }
string time = $"and creat_time between '{starTime}' and '{endTime}'"; string time = $"and creat_time between '{starTime}' and '{endTime}'";
string cmdName = $"select * from tray_thickness_main where {cmdName1} {time} order by creat_time desc"; string cmdName = $"select * from tray_thickness_main where {cmdName1} {time} order by creat_time desc";
listCoatingData = NewMethod1(cmdName,true); listCoatingData = QueryBase(cmdName,true);
return listCoatingData; return listCoatingData;
} }
private List<CoatingData> NewMethod1(string cmd, bool isNum = false) private List<CoatingData> QueryBase(string cmd, bool isNum = false)
{ {
List<CoatingData> coatingDataList = new List<CoatingData>(); List<CoatingData> coatingDataList = new List<CoatingData>();
try try

View File

@ -167,7 +167,7 @@
<GridViewColumn Width="120" Header="Label"> <GridViewColumn Width="120" Header="Label">
<GridViewColumn.CellTemplate> <GridViewColumn.CellTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Label}" /> <TextBlock Text="{Binding Caption}" />
</DataTemplate> </DataTemplate>
</GridViewColumn.CellTemplate> </GridViewColumn.CellTemplate>
</GridViewColumn> </GridViewColumn>
@ -176,7 +176,7 @@
<GridViewColumn Width="200" Header="Name"> <GridViewColumn Width="200" Header="Name">
<GridViewColumn.CellTemplate> <GridViewColumn.CellTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Number}" /> <TextBlock Text="{Binding SerialNumber}" />
</DataTemplate> </DataTemplate>
</GridViewColumn.CellTemplate> </GridViewColumn.CellTemplate>
</GridViewColumn> </GridViewColumn>
@ -190,7 +190,7 @@
<GridViewColumn Width="100" Header="Current(um)"> <GridViewColumn Width="100" Header="Current(um)">
<GridViewColumn.CellTemplate> <GridViewColumn.CellTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Current,StringFormat=N1}" > <TextBlock Text="{Binding Current,StringFormat=N2}" >
<TextBlock.Foreground> <TextBlock.Foreground>
<MultiBinding Converter="{StaticResource ColorConverter_Current}" StringFormat="{}{0}:{1}"> <MultiBinding Converter="{StaticResource ColorConverter_Current}" StringFormat="{}{0}:{1}">
<Binding Path="Current" /> <Binding Path="Current" />