Merge branch 'master' of http://www.scserverddns.top:13000/sc/DyeingComputer
This commit is contained in:
commit
aa827e30c1
2 files changed
+15
-8
No files matched your search
@@ -62,6 +62,7 @@
|
||||
<DataGridTextColumn Binding="{Binding Parameter8}" 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 DYELOT}" Width="0" MinWidth="0" MaxWidth="0"/>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
<TextBlock x:Name="log" HorizontalAlignment="Left" Margin="0,40,0,0" TextWrapping="Wrap" Width="600" FontSize="20" Background="White"/>
|
||||
|
||||
@@ -30,6 +30,15 @@ namespace DyeingComputer.View
|
||||
public TechnologicalProcessView()
|
||||
{
|
||||
InitializeComponent();
|
||||
FocusManager.SetFocusedElement(Grid, Grid);
|
||||
if (workName != null)
|
||||
{
|
||||
TechnologicalProcess_Import();
|
||||
}
|
||||
else
|
||||
{
|
||||
TechnologicalProcess_sql();
|
||||
}
|
||||
}
|
||||
|
||||
public static object workName;
|
||||
@@ -77,6 +86,7 @@ namespace DyeingComputer.View
|
||||
if (sql != null) sql.Clear(); //清空缓存
|
||||
sql = SQLiteHelpers.ExecuteDataSet(sql_script, null); //读取表写入缓存
|
||||
name.Text = SQLiteHelpers.ExecuteScalar("select Program from RUN where Step = '1'", null).ToString();
|
||||
MainWindowViewModel.WorkNumder = SQLiteHelpers.ExecuteScalar("select DYELOT from RUN where Step = '1'", null).ToString();
|
||||
SQLiteHelpers.Close(); //关闭连接
|
||||
|
||||
if (sql != null) Grid.ItemsSource = sql.Tables[0].DefaultView; //转换显示计划表
|
||||
@@ -84,20 +94,15 @@ namespace DyeingComputer.View
|
||||
|
||||
private void UserControl_Loaded(object sender, RoutedEventArgs e)
|
||||
{
|
||||
FocusManager.SetFocusedElement(Grid, Grid);
|
||||
// FocusManager.SetFocusedElement(Grid, Grid);
|
||||
if (workName != null)
|
||||
{
|
||||
TechnologicalProcess_Import();
|
||||
//Grid.SelectedIndex = 0;
|
||||
//MainWindowViewModel.Process_step = 0;
|
||||
Grid.SelectedIndex = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
TechnologicalProcess_sql();
|
||||
// Grid.SelectedIndex = Convert.ToInt16(MainWindowViewModel.Process_step);
|
||||
if (MainWindowViewModel.WORK_RUN != 0) Grid.SelectedIndex = MainWindowViewModel.RUN_STEPID - 1;//设定图表显示
|
||||
}
|
||||
|
||||
if(MainWindowViewModel.WORK_RUN !=0)Grid.SelectedIndex = MainWindowViewModel.RUN_STEPID-1;//设定图表显示
|
||||
}
|
||||
|
||||
private void UserControl_KeyDown(object sender, KeyEventArgs e) //键盘监控
|
||||
@@ -222,6 +227,7 @@ namespace DyeingComputer.View
|
||||
string P1 = "0", P2 = "0", P3 = "0", P4 = "0", P5 = "0";
|
||||
private void Grid_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||
{
|
||||
if (MainWindowViewModel.WORK_RUN ==2) Grid.SelectedIndex = MainWindowViewModel.RUN_STEPID - 1;//设定图表显示
|
||||
int rownum = Grid.SelectedIndex;//获取鼠标选中行并定义变量
|
||||
if (rownum != -1)//判断鼠标定位是否有效
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user