Commit 0bbd18bb authored by 潘栩锋's avatar 潘栩锋 🚴

优化 菜单页面

parent 2820048d
......@@ -130,19 +130,10 @@ namespace FLY.Thick.FilmCasting.UI
#endregion
/// <summary>
/// 数据库保存的月数
/// </summary>
public int DBKeepMonth { get; set; }
/// <summary>
/// 数据库路径
/// </summary>
public string DbPath { get; set; }
#endregion
#region Command
public RelayCommand ApplyCmd { get; }
public RelayCommand SelectDbPathCmd { get; }
#endregion
......@@ -151,7 +142,6 @@ namespace FLY.Thick.FilmCasting.UI
public PgInitParamVm()
{
ApplyCmd = new RelayCommand(Apply);
SelectDbPathCmd = new RelayCommand(SelectDbPath);
}
......@@ -179,8 +169,6 @@ namespace FLY.Thick.FilmCasting.UI
Misc.BindingOperations.SetBinding(initParamService, nameof(initParamService.DTime), this, nameof(DTime));
Misc.BindingOperations.SetBinding(initParamService, nameof(initParamService.HVelocity1), this, nameof(HVelocity1));
Misc.BindingOperations.SetBinding(initParamService, nameof(initParamService.HVelocity2), this, nameof(HVelocity2));
Misc.BindingOperations.SetBinding(initParamService, nameof(initParamService.DBKeepMonth), this, nameof(DBKeepMonth));
Misc.BindingOperations.SetBinding(initParamService, nameof(initParamService.DbDirPath), this, nameof(DbPath));
}
private void Apply()
......@@ -208,8 +196,6 @@ namespace FLY.Thick.FilmCasting.UI
initParamService.DTime = this.DTime;
initParamService.HVelocity1 = this.HVelocity1;
initParamService.HVelocity2 = this.HVelocity2;
initParamService.DBKeepMonth = this.DBKeepMonth;
initParamService.DbDirPath = this.DbPath;
initParamService.Apply();
FLY.ControlLibrary.Window_Tip.Show("应用成功",
......@@ -218,17 +204,5 @@ namespace FLY.Thick.FilmCasting.UI
}
private void SelectDbPath()
{
System.Windows.Forms.FolderBrowserDialog open = new System.Windows.Forms.FolderBrowserDialog();
open.SelectedPath = DbPath;
if (open.ShowDialog() == System.Windows.Forms.DialogResult.OK)
{
DbPath = open.SelectedPath;
}
}
}
}
......@@ -49,7 +49,7 @@
</Grid.RowDefinitions>
<WrapPanel Orientation="Vertical" Grid.Column="1">
<WrapPanel.Resources>
<Style TargetType="Button" BasedOn="{StaticResource ResourceKey=ButtonStyle_empty}">
<Style TargetType="Button" BasedOn="{StaticResource Styles.Button.Empty}">
<Setter Property="Background" Value="#FF0083D7"/>
<Setter Property="Width" Value="225"/>
<Setter Property="Height" Value="140"/>
......@@ -105,14 +105,10 @@
</Button>
<Button Click="button_warning_Click" Background="Red" >
<Grid>
<TextBlock Background="DarkRed" Text="报警管理" />
</Grid>
<TextBlock Background="DarkRed" Text="报警管理" />
</Button>
<Button Click="button_scanwarning_Click" Background="DarkRed" >
<Grid>
<TextBlock Text="厚度报警" Background="DarkRed" />
</Grid>
<TextBlock Text="厚度报警" Background="DarkRed" />
</Button>
<Button Click="button_grid_Click" >
<TextBlock Text="机架调试"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment