change-移交最新版

main
liuwf 8 months ago
parent 4d06fbe2aa
commit 186bd68690

1
.gitignore vendored

@ -36,3 +36,4 @@ bld/
/.vs/Admin.Core/v17/.futdcache.v2 /.vs/Admin.Core/v17/.futdcache.v2
/Admin.Core.Repository/Repository_New/SysUserInfoRepository.cs /Admin.Core.Repository/Repository_New/SysUserInfoRepository.cs
/Aucma.Core.SheetMetal/ViewModels/IndexPageViewModel.cs /Aucma.Core.SheetMetal/ViewModels/IndexPageViewModel.cs
/Admin.Core.sln

@ -0,0 +1,42 @@
2024-03-07 10:36:08,730| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 10:36:53,475| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 10:45:22,426| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 10:46:20,485| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:09:35,983| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:10:01,077| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:10:30,297| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:15:12,333| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:20:20,077| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:24:00,889| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:24:42,049| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 11:42:57,108| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 14:38:34,853| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-07 14:39:00,779| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------

@ -0,0 +1,15 @@
2024-03-08 09:24:52,719| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-08 09:36:12,548| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-08 09:37:05,954| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-08 09:37:32,121| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-08 09:38:01,807| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------

@ -0,0 +1,12 @@
2024-03-14 15:16:45,691| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-14 15:19:17,058| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-14 15:43:11,019| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------
2024-03-14 15:43:45,071| INFO Aucma.Core.HwPLc.MelsecPlc
HslCommunication激活成功!
--------------------------------

@ -66,7 +66,7 @@
<ColumnDefinition Width="0.5*"/>--> <ColumnDefinition Width="0.5*"/>-->
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<Border Grid.Row="0" Grid.ColumnSpan="4" Background="#1157b9"> <Border Grid.Row="0" Grid.ColumnSpan="4" Background="#1157b9">
<TextBlock Text="发泡线()" Foreground="White" FontSize="18" FontWeight="Bold"/> <TextBlock Text="发泡线()" Foreground="White" FontSize="18" FontWeight="Bold"/>
</Border> </Border>
<Border Grid.Row="1" Grid.Column="0" Background="#1157b9"> <Border Grid.Row="1" Grid.Column="0" Background="#1157b9">
<TextBlock Text="夹具号" Foreground="White" FontSize="18" FontWeight="Bold"/> <TextBlock Text="夹具号" Foreground="White" FontSize="18" FontWeight="Bold"/>
@ -231,7 +231,7 @@
</Border> </Border>
<Border Grid.Row="0" Grid.Column="8" Grid.ColumnSpan="5" Background="#1157b9"> <Border Grid.Row="0" Grid.Column="8" Grid.ColumnSpan="5" Background="#1157b9">
<TextBlock Text="发泡线()" Foreground="White" FontSize="18" FontWeight="Bold"/> <TextBlock Text="发泡线()" Foreground="White" FontSize="18" FontWeight="Bold"/>
</Border> </Border>
<Border Grid.Row="1" Grid.Column="5" Background="#1157b9"> <Border Grid.Row="1" Grid.Column="5" Background="#1157b9">

@ -27,7 +27,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,6 +17,15 @@ namespace Aucma.Core.BoxFoam.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件s
}
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
} }
} }
} }

@ -219,7 +219,7 @@
"PlcType": "Siemens", "PlcType": "Siemens",
"Enabled": true, "Enabled": true,
// "IP": "127.0.0.1", // "IP": "127.0.0.1",
"IP": "10.10.93.21", "IP": "10.10.93.1",
"Port": 102 "Port": 102
}, },
{ {
@ -228,7 +228,7 @@
"PlcType": "Siemens", "PlcType": "Siemens",
"Enabled": true, "Enabled": true,
// "IP": "127.0.0.1", // "IP": "127.0.0.1",
"IP": "10.10.93.1", "IP": "10.10.93.21",
"Port": 102 "Port": 102
}, },
{ {

@ -623,6 +623,7 @@ namespace Aucma.Core.CodeBinding.ViewModels
if (string.IsNullOrEmpty(appConfig.TeamName)) if (string.IsNullOrEmpty(appConfig.TeamName))
{ {
log.Error($"条码{code1}未登录不做处理,禁止放行"); log.Error($"条码{code1}未登录不做处理,禁止放行");
SendPlcStop();
speechStr.SpeakAsync("请登录以后在使用,请登录"); speechStr.SpeakAsync("请登录以后在使用,请登录");
return; return;
} }

@ -25,7 +25,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2" > <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2" >
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,6 +17,15 @@ namespace Aucma.Core.CodeBinding.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
}
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
} }
} }
} }

@ -9,7 +9,7 @@
d:DesignHeight="1080" d:DesignHeight="1080"
d:DesignWidth="1920" d:DesignWidth="1920"
MinHeight="1080" MinHeight="1080"
MinWidth="1920" MinWidth="1920" WindowStyle="None"
WindowState="Maximized" WindowState="Maximized"
WindowStartupLocation="CenterScreen" > WindowStartupLocation="CenterScreen" >
@ -29,9 +29,9 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<StackPanel Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Center"> <StackPanel Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Center">

@ -17,6 +17,15 @@ namespace Aucma.Core.DoorFoam.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
} }
} }

@ -27,7 +27,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,6 +17,16 @@ namespace Aucma.Core.OldBoxFoam.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
} }
} }

@ -0,0 +1,12 @@
2023-11-27 08:57:46,721| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-27 08:57:46,865| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------
2023-11-27 09:02:12,789| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-27 09:02:12,930| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------

@ -0,0 +1,12 @@
2023-11-29 13:11:31,986| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-29 13:11:32,166| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------
2023-11-29 13:13:17,129| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-29 13:13:17,273| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------

@ -474,7 +474,7 @@ namespace Aucma.Core.Palletiz.ViewModels
{ {
System.Windows.Application.Current.Dispatcher.Invoke((Action)(() => System.Windows.Application.Current.Dispatcher.Invoke((Action)(() =>
{ {
TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account} 条码系统: {appConfig.BarCodeAccount}"; TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account}";
CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
})); }));

@ -26,7 +26,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,6 +17,16 @@ namespace Aucma.Core.Palletiz.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
} }
} }

@ -0,0 +1,12 @@
2023-11-27 08:57:46,721| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-27 08:57:46,865| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------
2023-11-27 09:02:12,789| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-27 09:02:12,930| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------

@ -0,0 +1,12 @@
2023-11-29 13:11:31,986| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-29 13:11:32,166| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------
2023-11-29 13:13:17,129| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器设备列表,进入DeviceListAcq()方法
--------------------------------
2023-11-29 13:13:17,273| INFO Aucma.Core.Scanner.MvCodeHelper
获取扫码器数量为0请检查扫码器连接:
--------------------------------

@ -475,7 +475,7 @@ namespace Aucma.Core.PalletizCX1.ViewModels
{ {
System.Windows.Application.Current.Dispatcher.Invoke((Action)(() => System.Windows.Application.Current.Dispatcher.Invoke((Action)(() =>
{ {
TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account} 条码系统: {appConfig.BarCodeAccount}"; TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account}";
CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
})); }));

@ -26,7 +26,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,6 +17,16 @@ namespace Aucma.Core.PalletizCX1.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
}
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
} }
} }
} }

@ -268,7 +268,7 @@ namespace Aucma.Core.PrintTo.ViewModels
{ {
System.Windows.Application.Current.Dispatcher.Invoke((Action)(() => System.Windows.Application.Current.Dispatcher.Invoke((Action)(() =>
{ {
TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account} 条码系统: {appConfig.BarCodeAccount}"; TeamName = $"班组:{appConfig.TeamName} 用户:{appConfig.Account}";
CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); CurrentDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
})); }));

@ -33,7 +33,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -19,9 +19,17 @@ namespace Aucma.Core.PrintTo.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
} }

@ -38,6 +38,7 @@ namespace Aucma.Core.ProductOffLine.Views
Closing += LoginPageView_Closing; // 订阅窗口关闭事件 Closing += LoginPageView_Closing; // 订阅窗口关闭事件
} }
private void LoginPageView_Closing(object sender, System.ComponentModel.CancelEventArgs e) private void LoginPageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{ {

@ -5,10 +5,10 @@
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
mc:Ignorable="d" mc:Ignorable="d"
Name="window" Name="window"
Title="SCADA" Height="1080" Width="1920" Icon="/Assets/images/Icon.png" FontFamily="Microsoft YaHei" Title="SCADA" Height="1080" Width="1920" Icon="/Assets/images/Icon.png" FontFamily="Microsoft YaHei"
WindowStartupLocation="CenterScreen" WindowStartupLocation="CenterScreen"
WindowState="Maximized" WindowStyle="SingleBorderWindow" ResizeMode="CanResize"> WindowState="Maximized" WindowStyle="None" ResizeMode="CanResize">
<Window.Background> <Window.Background>
<ImageBrush ImageSource="/Assets/images/background.jpg" /> <ImageBrush ImageSource="/Assets/images/background.jpg" />
</Window.Background> </Window.Background>
@ -29,7 +29,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2,2,2" Height="100" Grid.ColumnSpan="2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2,2,2" Height="100" Grid.ColumnSpan="2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -20,8 +20,19 @@ namespace Aucma.Core.ProductOffLine.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
} }
} }

@ -7,7 +7,7 @@
mc:Ignorable="d" Name="window" mc:Ignorable="d" Name="window"
Title="SCADA" Height="1080" Width="1920" Icon="/Assets/images/Icon.png" FontFamily="Microsoft YaHei" Title="SCADA" Height="1080" Width="1920" Icon="/Assets/images/Icon.png" FontFamily="Microsoft YaHei"
WindowStartupLocation="CenterScreen" WindowStartupLocation="CenterScreen"
WindowState="Maximized" WindowStyle="SingleBorderWindow" ResizeMode="CanResize"> WindowState="Maximized" WindowStyle="None" ResizeMode="CanResize">
<Window.Background> <Window.Background>
<ImageBrush ImageSource="/Assets/images/background.jpg" /> <ImageBrush ImageSource="/Assets/images/background.jpg" />
</Window.Background> </Window.Background>
@ -28,7 +28,7 @@
<Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2,2,2" Height="100" Grid.ColumnSpan="2"> <Border Grid.Row="0" BorderBrush="Red" BorderThickness="0" CornerRadius="5" Background="Transparent" Margin="2,2,2,2" Height="100" Grid.ColumnSpan="2">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/> <ColumnDefinition Width="3*"/>
<ColumnDefinition Width="7*"/> <ColumnDefinition Width="7*"/>
<ColumnDefinition Width="3*"/> <ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>

@ -17,9 +17,17 @@ namespace Aucma.Core.ProductOffLineCX1.Views
{ {
InitializeComponent(); InitializeComponent();
this.DataContext = new MainWindowViewModel(); this.DataContext = new MainWindowViewModel();
Closing += PageView_Closing; // 订阅窗口关闭事件
} }
private void PageView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
this.Hide();
//跳转到登录页
LoginPageView login = LoginPageView.Instance;
login.Show();
}
private void Minimized_Click(object sender, RoutedEventArgs e) private void Minimized_Click(object sender, RoutedEventArgs e)
{ {

Loading…
Cancel
Save