步骤编辑修改
This commit is contained in:
commit
fa836593f5
5 files changed
+192
-163
No files matched your search
@@ -16,59 +16,61 @@ namespace DyeingComputer.ConvertMoels
|
|||||||
switch (value)
|
switch (value)
|
||||||
{
|
{
|
||||||
case "001":
|
case "001":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID001.png", UriKind.Relative));//功能模块001温度控制
|
return new BitmapImage(new Uri("/Lmage/ID001.png", UriKind.Relative));//功能模块001温度控制
|
||||||
case "007":
|
case "007":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID007.png", UriKind.Relative));//液位入水
|
return new BitmapImage(new Uri("/Lmage/ID007.png", UriKind.Relative));//液位入水
|
||||||
case "008":
|
case "008":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID008.png", UriKind.Relative));//流量入水
|
return new BitmapImage(new Uri("/Lmage/ID008.png", UriKind.Relative));//流量入水
|
||||||
case "013":
|
case "013":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID013.png", UriKind.Relative));//批次水位水洗
|
return new BitmapImage(new Uri("/Lmage/ID013.png", UriKind.Relative));//批次水位水洗
|
||||||
case "015":
|
case "015":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID015.png", UriKind.Relative));//溢流水洗
|
return new BitmapImage(new Uri("/Lmage/ID015.png", UriKind.Relative));//溢流水洗
|
||||||
case "017":
|
case "017":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID017.png", UriKind.Relative));//降温水洗
|
return new BitmapImage(new Uri("/Lmage/ID017.png", UriKind.Relative));//降温水洗
|
||||||
case "020":
|
case "020":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID020.png", UriKind.Relative));//排水
|
return new BitmapImage(new Uri("/Lmage/ID020.png", UriKind.Relative));//排水
|
||||||
case "022":
|
case "022":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID022.png", UriKind.Relative));//动力排水
|
return new BitmapImage(new Uri("/Lmage/ID022.png", UriKind.Relative));//动力排水
|
||||||
case "031":
|
case "031":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID031.png", UriKind.Relative));//运转时间
|
return new BitmapImage(new Uri("/Lmage/ID031.png", UriKind.Relative));//运转时间
|
||||||
case "035":
|
case "035":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID035.png", UriKind.Relative));//准备入布
|
return new BitmapImage(new Uri("/Lmage/ID035.png", UriKind.Relative));//准备入布
|
||||||
case "036":
|
case "036":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID036.png", UriKind.Relative));//准备出布
|
return new BitmapImage(new Uri("/Lmage/ID036.png", UriKind.Relative));//准备出布
|
||||||
case "039":
|
case "039":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID039.png", UriKind.Relative));//呼叫人工
|
return new BitmapImage(new Uri("/Lmage/ID039.png", UriKind.Relative));//呼叫人工
|
||||||
case "040":
|
case "040":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID040.png", UriKind.Relative));//取样
|
return new BitmapImage(new Uri("/Lmage/ID040.png", UriKind.Relative));//取样
|
||||||
case "041":
|
case "041":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID041.png", UriKind.Relative));//结束
|
return new BitmapImage(new Uri("/Lmage/ID041.png", UriKind.Relative));//结束
|
||||||
case "049":
|
case "049":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID049.png", UriKind.Relative));//等待
|
return new BitmapImage(new Uri("/Lmage/ID049.png", UriKind.Relative));//等待
|
||||||
case "050":
|
case "050":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID050.png", UriKind.Relative));//主缸加压
|
return new BitmapImage(new Uri("/Lmage/ID050.png", UriKind.Relative));//主缸加压
|
||||||
case "051":
|
case "051":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID051.png", UriKind.Relative));//主缸减压
|
return new BitmapImage(new Uri("/Lmage/ID051.png", UriKind.Relative));//主缸减压
|
||||||
case "054":
|
case "054":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID054.png", UriKind.Relative));//主泵/风机速度
|
return new BitmapImage(new Uri("/Lmage/ID054.png", UriKind.Relative));//主泵/风机速度
|
||||||
case "055":
|
case "055":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID055.png", UriKind.Relative));//主泵启动
|
return new BitmapImage(new Uri("/Lmage/ID055.png", UriKind.Relative));//主泵启动
|
||||||
case "056":
|
case "056":
|
||||||
|
return new BitmapImage(new Uri("/Lmage/ID056.png", UriKind.Relative));//
|
||||||
case "064":
|
case "064":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID064.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID064.png", UriKind.Relative));//
|
||||||
case "065":
|
case "065":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID065.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID065.png", UriKind.Relative));//
|
||||||
case "067":
|
case "067":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID067.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID067.png", UriKind.Relative));//
|
||||||
|
case "068":
|
||||||
|
return new BitmapImage(new Uri("/Lmage/ID068.png", UriKind.Relative));//
|
||||||
case "090":
|
case "090":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID090.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID090.png", UriKind.Relative));//
|
||||||
case "091":
|
case "091":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID091.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID091.png", UriKind.Relative));//
|
||||||
case "094":
|
case "094":
|
||||||
return new BitmapImage(new Uri("/Lmage/ID094.png", UriKind.Relative));//
|
return new BitmapImage(new Uri("/Lmage/ID094.png", UriKind.Relative));//
|
||||||
default:
|
default:
|
||||||
return new BitmapImage(new Uri("",UriKind.Relative));
|
return new BitmapImage(new Uri("", UriKind.Relative));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
using DyeingComputer.UserClass;
|
using DyeingComputer.UserClass;
|
||||||
|
using DyeingComputer.ViewModel;
|
||||||
using DyeingComputer.Windows;
|
using DyeingComputer.Windows;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@@ -127,12 +128,12 @@ namespace DyeingComputer.View
|
|||||||
}
|
}
|
||||||
return child;
|
return child;
|
||||||
}
|
}
|
||||||
|
/***********/
|
||||||
private void ProgramgroupView_edit_Click(object sender, RoutedEventArgs e)//编辑
|
private void ProgramgroupView_edit_Click(object sender, RoutedEventArgs e)//编辑
|
||||||
{
|
{
|
||||||
if (string.IsNullOrEmpty(Numder)) { Numder = null; P1 = "0";P2 = "0";P3 = "0";P4 = "0";P5 = "0"; }
|
if (string.IsNullOrEmpty(Numder)) { Numder = null; P1 = "0";P2 = "0";P3 = "0";P4 = "0";P5 = "0"; }
|
||||||
if (ID == null) ID = sql.Tables[0].Rows.Count.ToString();
|
if (ID == null) ID = sql.Tables[0].Rows.Count.ToString();
|
||||||
ViewStep viewstop = new ViewStep(Numder, P1, P2, P3, P4, P5);
|
ViewStep viewstop = new ViewStep(Numder, sql.Tables[0].Select("STEP = " + ID).First());
|
||||||
viewstop.AddressUpdated += new ViewStep.AddressUpdateHandler(Address_ButtonClicked);
|
viewstop.AddressUpdated += new ViewStep.AddressUpdateHandler(Address_ButtonClicked);
|
||||||
viewstop.data = ID;
|
viewstop.data = ID;
|
||||||
viewstop.ShowDialog();
|
viewstop.ShowDialog();
|
||||||
|
|||||||
+131
-121
@@ -15,8 +15,7 @@
|
|||||||
<ConvertMoels:StatenToImageConvert x:Key="StatenToImageConvert"/>
|
<ConvertMoels:StatenToImageConvert x:Key="StatenToImageConvert"/>
|
||||||
</UserControl.Resources>
|
</UserControl.Resources>
|
||||||
<Grid>
|
<Grid>
|
||||||
<ScrollViewer PanningMode="VerticalOnly" VerticalScrollBarVisibility="Auto">
|
<DataGrid x:Name="GridSTEP" AlternationCount="2" IsReadOnly="True" SelectionChanged="Grid_SelectionChanged"
|
||||||
<DataGrid x:Name="GridSTEP" AlternationCount="2" IsReadOnly="True" SelectionChanged="Grid_SelectionChanged"
|
|
||||||
Margin="630,40,0,0" d:ItemsSource="{d:SampleData ItemCount=90}" AutoGenerateColumns="False" MinColumnWidth="30"
|
Margin="630,40,0,0" d:ItemsSource="{d:SampleData ItemCount=90}" AutoGenerateColumns="False" MinColumnWidth="30"
|
||||||
ItemsSource="{Binding Path=TechnologicalProcess_View,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
ItemsSource="{Binding Path=TechnologicalProcess_View,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||||
HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="{x:Null}"
|
HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="{x:Null}"
|
||||||
@@ -24,134 +23,145 @@
|
|||||||
CanUserReorderColumns="False" CanUserSortColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False"
|
CanUserReorderColumns="False" CanUserSortColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False"
|
||||||
CanUserAddRows="True" CanUserDeleteRows="False" HeadersVisibility ="Column"
|
CanUserAddRows="True" CanUserDeleteRows="False" HeadersVisibility ="Column"
|
||||||
Background="White" SelectionMode="Single" FontSize="15" MinHeight="632" TabIndex="1" Focusable="True" >
|
Background="White" SelectionMode="Single" FontSize="15" MinHeight="632" TabIndex="1" Focusable="True" >
|
||||||
<DataGrid.Resources>
|
<DataGrid.Resources>
|
||||||
<Style TargetType="ScrollViewer">
|
<Style TargetType="ScrollViewer">
|
||||||
<Setter Property="PanningMode" Value="VerticalOnly"/>
|
<Setter Property="PanningMode" Value="VerticalOnly"/>
|
||||||
</Style>
|
</Style>
|
||||||
</DataGrid.Resources>
|
</DataGrid.Resources>
|
||||||
<DataGrid.RowStyle >
|
<DataGrid.RowStyle >
|
||||||
<Style TargetType="{x:Type DataGridRow}">
|
<Style TargetType="{x:Type DataGridRow}">
|
||||||
<Setter Property="IsHitTestVisible" Value="{Binding DataContext.IsInteractive,
|
<Setter Property="IsHitTestVisible" Value="{Binding DataContext.IsInteractive,
|
||||||
RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
|
RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
|
||||||
<Setter Property="Height" Value="100" />
|
<Setter Property="Height" Value="100" />
|
||||||
<Setter Property="FontSize" Value="25" />
|
<Setter Property="FontSize" Value="25" />
|
||||||
<Style.Triggers>
|
<Style.Triggers>
|
||||||
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
||||||
<Setter Property="Background" Value="#FFFFFFFF" />
|
<Setter Property="Background" Value="#FFFFFFFF" />
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
||||||
<Setter Property="Background" Value="#FFF0F0F0" />
|
<Setter Property="Background" Value="#FFF0F0F0" />
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="IsMouseOver" Value="False"/>
|
<Trigger Property="IsMouseOver" Value="False"/>
|
||||||
<DataTrigger Binding="{Binding RUN}" Value="1">
|
<DataTrigger Binding="{Binding RUN}" Value="1">
|
||||||
<Setter Property="Background" Value="#FF00D6FF"/>
|
<Setter Property="Background" Value="#FF00D6FF"/>
|
||||||
</DataTrigger>
|
</DataTrigger>
|
||||||
<DataTrigger Binding="{Binding RUN}" Value="2">
|
<DataTrigger Binding="{Binding RUN}" Value="2">
|
||||||
<Setter Property="Background" Value="Yellow"/>
|
<Setter Property="Background" Value="Yellow"/>
|
||||||
</DataTrigger>
|
</DataTrigger>
|
||||||
<DataTrigger Binding="{Binding RUN}" Value="9">
|
<DataTrigger Binding="{Binding RUN}" Value="9">
|
||||||
<Setter Property="Background" Value="Red"/>
|
<Setter Property="Background" Value="Red"/>
|
||||||
</DataTrigger>
|
</DataTrigger>
|
||||||
</Style.Triggers>
|
</Style.Triggers>
|
||||||
</Style>
|
</Style>
|
||||||
</DataGrid.RowStyle>
|
</DataGrid.RowStyle>
|
||||||
<DataGrid.CellStyle>
|
<DataGrid.CellStyle>
|
||||||
<Style TargetType="DataGridCell">
|
<Style TargetType="DataGridCell">
|
||||||
<Setter Property="BorderThickness" Value="0"/>
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
<Setter Property="MinWidth" Value="20"/>
|
<Setter Property="MinWidth" Value="20"/>
|
||||||
<Style.Triggers>
|
<Style.Triggers>
|
||||||
<Trigger Property="IsSelected" Value="True">
|
<Trigger Property="IsSelected" Value="True">
|
||||||
<Setter Property="Background" Value="#FFC0C0C0"/>
|
<Setter Property="Background" Value="#FFC0C0C0"/>
|
||||||
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
||||||
<Setter Property="Foreground" Value="Black"/>
|
<Setter Property="Foreground" Value="Black"/>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
</Style.Triggers>
|
</Style.Triggers>
|
||||||
</Style>
|
</Style>
|
||||||
</DataGrid.CellStyle>
|
</DataGrid.CellStyle>
|
||||||
<DataGrid.Columns>
|
<DataGrid.Columns>
|
||||||
<!--列信息绑定-->
|
<!--列信息绑定-->
|
||||||
<DataGridTextColumn Binding="{Binding ProgramID}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding ProgramID}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Program}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Program}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Header="{x:Static lang:Resources.Step}" Binding="{Binding Step}" Width="60" IsReadOnly="True">
|
<DataGridTextColumn Header="{x:Static lang:Resources.Step}" Binding="{Binding Step}" Width="60" IsReadOnly="True">
|
||||||
<DataGridTextColumn.ElementStyle>
|
<DataGridTextColumn.ElementStyle>
|
||||||
<Style TargetType="TextBlock">
|
<Style TargetType="TextBlock">
|
||||||
<Setter Property="VerticalAlignment" Value="Center"/>
|
<Setter Property="VerticalAlignment" Value="Center"/>
|
||||||
<Setter Property="HorizontalAlignment" Value="Center"/>
|
<Setter Property="HorizontalAlignment" Value="Center"/>
|
||||||
</Style>
|
</Style>
|
||||||
</DataGridTextColumn.ElementStyle>
|
</DataGridTextColumn.ElementStyle>
|
||||||
</DataGridTextColumn>
|
</DataGridTextColumn>
|
||||||
<DataGridTextColumn Header="{x:Static lang:Resources.Code}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding StepID}" IsReadOnly="True"/>
|
<DataGridTextColumn Header="{x:Static lang:Resources.Code}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding StepID}" IsReadOnly="True"/>
|
||||||
<DataGridTextColumn Header="{x:Static lang:Resources.Directives}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding StepName}" IsReadOnly="True"/>
|
<DataGridTextColumn Header="{x:Static lang:Resources.Directives}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding StepName}" IsReadOnly="True"/>
|
||||||
<DataGridTextColumn Header="{x:Static lang:Resources.ParameterSet}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding ParameterName}" IsReadOnly="True"/>
|
<DataGridTextColumn Header="{x:Static lang:Resources.ParameterSet}" Width="0" MinWidth="0" MaxWidth="0" Binding="{Binding ParameterName}" IsReadOnly="True"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter4}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter4}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter5}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter5}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter6}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter6}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter7}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter7}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter8}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter8}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter9}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter9}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding Parameter10}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter10}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTextColumn Binding="{Binding DYELOT}" Width="0" MinWidth="0" MaxWidth="0"/>
|
<DataGridTextColumn Binding="{Binding Parameter1_S1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
|
<DataGridTextColumn Binding="{Binding Parameter2_S1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
<DataGridTextColumn Binding="{Binding Parameter3_S1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTemplateColumn.CellTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter4_S1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter5_S1}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<Image Source="{Binding Path=StepID,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
<DataGridTextColumn Binding="{Binding Parameter1_S2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
</DataTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter2_S2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
</DataGridTemplateColumn.CellTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter3_S2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
</DataGridTemplateColumn>
|
<DataGridTextColumn Binding="{Binding Parameter4_S2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="600" IsReadOnly="True">
|
<DataGridTextColumn Binding="{Binding Parameter5_S2}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataGridTemplateColumn.CellTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter1_S3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<DataTemplate>
|
<DataGridTextColumn Binding="{Binding Parameter2_S3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<StackPanel>
|
<DataGridTextColumn Binding="{Binding Parameter3_S3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<Border BorderBrush="#FFC9C9C9" BorderThickness="0,0,0,0.5">
|
<DataGridTextColumn Binding="{Binding Parameter4_S3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
<TextBlock Height="50" >
|
<DataGridTextColumn Binding="{Binding Parameter5_S3}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||||
|
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
||||||
|
<DataGridTemplateColumn.CellTemplate>
|
||||||
|
<DataTemplate>
|
||||||
|
<Image Source="{Binding Path=StepID,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
||||||
|
</DataTemplate>
|
||||||
|
</DataGridTemplateColumn.CellTemplate>
|
||||||
|
</DataGridTemplateColumn>
|
||||||
|
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="600" IsReadOnly="True">
|
||||||
|
<DataGridTemplateColumn.CellTemplate>
|
||||||
|
<DataTemplate>
|
||||||
|
<StackPanel>
|
||||||
|
<Border BorderBrush="#FFC9C9C9" BorderThickness="0,0,0,0.5">
|
||||||
|
<TextBlock Height="50" >
|
||||||
<Run Text="{x:Static lang:Resources.Function}"/>
|
<Run Text="{x:Static lang:Resources.Function}"/>
|
||||||
<Run Text=":"/>
|
<Run Text=":"/>
|
||||||
<Run Text="{Binding StepName}"/>
|
<Run Text="{Binding StepName}"/>
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
</Border>
|
</Border>
|
||||||
<Border BorderBrush="#FFC9C9C9" BorderThickness="0,0.5,0,0">
|
<Border BorderBrush="#FFC9C9C9" BorderThickness="0,0.5,0,0">
|
||||||
<TextBlock Height="50" >
|
<TextBlock Height="50" >
|
||||||
<Run Text="{x:Static lang:Resources.ParameterSet}"/>
|
<Run Text="{x:Static lang:Resources.ParameterSet}"/>
|
||||||
<Run Text=":"/>
|
<Run Text=":"/>
|
||||||
<Run Text="{Binding ParameterName}"/>
|
<Run Text="{Binding ParameterName}"/>
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
</Border>
|
</Border>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</DataGridTemplateColumn.CellTemplate>
|
</DataGridTemplateColumn.CellTemplate>
|
||||||
</DataGridTemplateColumn>
|
</DataGridTemplateColumn>
|
||||||
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
||||||
<DataGridTemplateColumn.CellTemplate>
|
<DataGridTemplateColumn.CellTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<Image Source="{Binding Path=StepID_S1,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
<Image Source="{Binding Path=StepID_S1,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</DataGridTemplateColumn.CellTemplate>
|
</DataGridTemplateColumn.CellTemplate>
|
||||||
</DataGridTemplateColumn>
|
</DataGridTemplateColumn>
|
||||||
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
||||||
<DataGridTemplateColumn.CellTemplate>
|
<DataGridTemplateColumn.CellTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<Image Source="{Binding Path=StepID_S2,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
<Image Source="{Binding Path=StepID_S2,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</DataGridTemplateColumn.CellTemplate>
|
</DataGridTemplateColumn.CellTemplate>
|
||||||
</DataGridTemplateColumn>
|
</DataGridTemplateColumn>
|
||||||
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
<DataGridTemplateColumn Header="{x:Static lang:Resources.Directives}" Width="100" IsReadOnly="True">
|
||||||
<DataGridTemplateColumn.CellTemplate>
|
<DataGridTemplateColumn.CellTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<Image Source="{Binding Path=StepID_S3 ,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
<Image Source="{Binding Path=StepID_S3 ,Converter={StaticResource StatenToImageConvert}}" Height="100" Width="100"/>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</DataGridTemplateColumn.CellTemplate>
|
</DataGridTemplateColumn.CellTemplate>
|
||||||
</DataGridTemplateColumn>
|
</DataGridTemplateColumn>
|
||||||
</DataGrid.Columns>
|
</DataGrid.Columns>
|
||||||
</DataGrid>
|
</DataGrid>
|
||||||
</ScrollViewer>
|
|
||||||
<Grid Width="600" Margin="0,40,0,0" HorizontalAlignment="Left" >
|
<Grid Width="600" Margin="0,40,0,0" HorizontalAlignment="Left" >
|
||||||
<ScrollViewer VerticalScrollBarVisibility="Auto" PanningMode="VerticalOnly">
|
<ScrollViewer VerticalScrollBarVisibility="Auto" PanningMode="VerticalOnly">
|
||||||
<TextBlock x:Name="log" FontSize="25" Background="White"
|
<TextBlock x:Name="log" FontSize="25" Background="White" Text="{Binding Sys_log}" />
|
||||||
Text="{Binding Sys_log}" />
|
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
<DataGrid x:Name="Receip" IsHitTestVisible="False" Visibility="Collapsed"
|
<DataGrid x:Name="Receip" IsHitTestVisible="False" Visibility="Collapsed"
|
||||||
AutoGenerateColumns="False" FontSize="15" AlternationCount="2"
|
AutoGenerateColumns="False" FontSize="15" AlternationCount="2"
|
||||||
|
|||||||
@@ -272,6 +272,8 @@ namespace DyeingComputer.View
|
|||||||
string Numder = null;
|
string Numder = null;
|
||||||
string ID = null;
|
string ID = null;
|
||||||
string P1 = "0", P2 = "0", P3 = "0", P4 = "0", P5 = "0";
|
string P1 = "0", P2 = "0", P3 = "0", P4 = "0", P5 = "0";
|
||||||
|
object P1_S1, P2_S1, P3_S1, P4_S1, P5_S1, P1_S2, P2_S2, P3_S2, P4_S2, P5_S2, P1_S3, P2_S3, P3_S3, P4_S3, P5_S3;
|
||||||
|
|
||||||
private void TechnologicalProcess_Import()
|
private void TechnologicalProcess_Import()
|
||||||
{
|
{
|
||||||
SQLiteHelpers = new SQLiteHelper(DBAddress); //数据库连接路径
|
SQLiteHelpers = new SQLiteHelper(DBAddress); //数据库连接路径
|
||||||
@@ -323,13 +325,12 @@ namespace DyeingComputer.View
|
|||||||
// FocusManager.SetFocusedElement(Grid, Grid);
|
// FocusManager.SetFocusedElement(Grid, Grid);
|
||||||
// Grid.DataContext = new MainWindowViewModel();
|
// Grid.DataContext = new MainWindowViewModel();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ProgramgroupView_edit_Click(object sender, RoutedEventArgs e)//编辑按钮
|
private void ProgramgroupView_edit_Click(object sender, RoutedEventArgs e)//编辑按钮
|
||||||
{
|
{
|
||||||
if (string.IsNullOrEmpty(Numder)) { Numder = null; P1 = "0"; P2 = "0"; P3 = "0"; P4 = "0"; P5 = "0"; }
|
// if (string.IsNullOrEmpty(Numder)) { Numder = null; P1 = "0"; P2 = "0"; P3 = "0"; P4 = "0"; P5 = "0"; }
|
||||||
if (ID == null) ID = sql.Tables[0].Rows.Count.ToString();
|
if (ID == null) return;//ID = sql.Tables[0].Rows.Count.ToString();
|
||||||
APILog.LOGlog(MainWindowViewModel.WorkNumder.ToString(), "UserActions", "Edit", "STEP = " + ID);
|
APILog.LOGlog(MainWindowViewModel.WorkNumder.ToString(), "UserActions", "Edit", "STEP = " + ID);
|
||||||
ViewStep viewstop = new ViewStep(Numder, P1, P2, P3, P4, P5);
|
ViewStep viewstop = new ViewStep(Numder, MainWindowViewModel.dt_TP.Select("STEP = " + ID).First());
|
||||||
viewstop.boxNAME.IsEnabled=false;
|
viewstop.boxNAME.IsEnabled=false;
|
||||||
viewstop.no.IsEnabled = false;
|
viewstop.no.IsEnabled = false;
|
||||||
viewstop.data = ID;
|
viewstop.data = ID;
|
||||||
@@ -443,9 +444,8 @@ namespace DyeingComputer.View
|
|||||||
Dat();
|
Dat();
|
||||||
|
|
||||||
APILog.LOGlog(MainWindowViewModel.WorkNumder.ToString(), "UserActions", "Insert", "STEP = "+ID);
|
APILog.LOGlog(MainWindowViewModel.WorkNumder.ToString(), "UserActions", "Insert", "STEP = "+ID);
|
||||||
if (string.IsNullOrEmpty(Numder)) { Numder = null; P1 = "0"; P2 = "0"; P3 = "0"; P4 = "0"; P5 = "0"; }
|
if (ID == null) return;// ID = MainWindowViewModel.dt_TP.Rows.Count.ToString();
|
||||||
if (ID == null) ID = MainWindowViewModel.dt_TP.Rows.Count.ToString();
|
ViewStep viewstop = new ViewStep(null, MainWindowViewModel.dt_TP.Select("STEP = " + ID).First());
|
||||||
ViewStep viewstop = new ViewStep(null, "0", "0", "0", "0", "0");
|
|
||||||
viewstop.boxNAME.IsEnabled = false;
|
viewstop.boxNAME.IsEnabled = false;
|
||||||
viewstop.no.IsEnabled = false;
|
viewstop.no.IsEnabled = false;
|
||||||
viewstop.data = ID;
|
viewstop.data = ID;
|
||||||
@@ -529,6 +529,22 @@ namespace DyeingComputer.View
|
|||||||
P3 = (GridSTEP.Columns[8].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第8列,
|
P3 = (GridSTEP.Columns[8].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第8列,
|
||||||
P4 = (GridSTEP.Columns[9].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第9列,
|
P4 = (GridSTEP.Columns[9].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第9列,
|
||||||
P5 = (GridSTEP.Columns[10].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第10列,
|
P5 = (GridSTEP.Columns[10].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//定位第10列,
|
||||||
|
|
||||||
|
P1_S1 = (GridSTEP.Columns[16].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;
|
||||||
|
P2_S1 = (GridSTEP.Columns[17].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P3_S1 = (GridSTEP.Columns[18].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P4_S1 = (GridSTEP.Columns[19].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P5_S1 = (GridSTEP.Columns[20].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P1_S2 = (GridSTEP.Columns[21].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;
|
||||||
|
P2_S2 = (GridSTEP.Columns[22].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P3_S2 = (GridSTEP.Columns[23].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P4_S2 = (GridSTEP.Columns[24].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P5_S2 = (GridSTEP.Columns[25].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P1_S3 = (GridSTEP.Columns[26].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P2_S3 = (GridSTEP.Columns[27].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//,
|
||||||
|
P3_S3 = (GridSTEP.Columns[28].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//,
|
||||||
|
P4_S3 = (GridSTEP.Columns[29].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;//
|
||||||
|
P5_S3 = (GridSTEP.Columns[30].GetCellContent(GridSTEP.Items[rownum]) as TextBlock).Text;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ namespace DyeingComputer.Windows
|
|||||||
//声明一个更新Address的事件
|
//声明一个更新Address的事件
|
||||||
public event AddressUpdateHandler AddressUpdated;
|
public event AddressUpdateHandler AddressUpdated;
|
||||||
|
|
||||||
public ViewStep(string Numder ,string P1D,string P2D,string P3D,string P4D,string P5D)
|
public ViewStep(string Numder ,DataRow DAT)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
this.DataContext = this;
|
this.DataContext = this;
|
||||||
@@ -42,11 +42,11 @@ namespace DyeingComputer.Windows
|
|||||||
boxNAME.Focus();
|
boxNAME.Focus();
|
||||||
boxNAME.Text = Numder;
|
boxNAME.Text = Numder;
|
||||||
|
|
||||||
P1.Text = P1D;
|
P1.Text = DAT.Field<string>("Parameter1");
|
||||||
P2.Text = P2D;
|
P2.Text = DAT.Field<string>("Parameter2");
|
||||||
P3.Text = P3D;
|
P3.Text = DAT.Field<string>("Parameter3");
|
||||||
P4.Text = P4D;
|
P4.Text = DAT.Field<string>("Parameter4");
|
||||||
P5.Text = P5D;
|
P5.Text = DAT.Field<string>("Parameter5");
|
||||||
/* P1.Visibility = Visibility.Collapsed;
|
/* P1.Visibility = Visibility.Collapsed;
|
||||||
P1N.Visibility = Visibility.Collapsed;
|
P1N.Visibility = Visibility.Collapsed;
|
||||||
P2.Visibility = Visibility.Collapsed;
|
P2.Visibility = Visibility.Collapsed;
|
||||||
|
|||||||
Reference in new issue
Block a user