!提交代码
This commit is contained in:
69
货架标准上位机/Views/InInventoryView.xaml.cs
Normal file
69
货架标准上位机/Views/InInventoryView.xaml.cs
Normal file
@ -0,0 +1,69 @@
|
||||
using Ping9719.WpfEx;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Documents;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Media.Imaging;
|
||||
using System.Windows.Shapes;
|
||||
using 货架标准上位机.ViewModel;
|
||||
using 货架标准上位机.Views.Controls;
|
||||
|
||||
namespace 货架标准上位机
|
||||
{
|
||||
/// <summary>
|
||||
/// InInventoryView.xaml 的交互逻辑
|
||||
/// </summary>
|
||||
public partial class InInventoryView : UserControlBase
|
||||
{
|
||||
public InInventoryViewModel viewModel = new InInventoryViewModel();
|
||||
public InInventoryView()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.DataContext = viewModel;
|
||||
|
||||
|
||||
var scanners = ScannerManager.Scanners.Select(t => t).ToList();
|
||||
scanners.ForEach(t =>
|
||||
{
|
||||
var control = new ScannerDisplayControl(t.COM);
|
||||
t.ScannerDisplayControl = control;
|
||||
scannersWrapPanel.Children.Add(control);
|
||||
});
|
||||
}
|
||||
|
||||
private void DataGrid_SelectedCellsChanged(object sender, SelectedCellsChangedEventArgs e)
|
||||
{
|
||||
DataGrid datagrid = sender as DataGrid;
|
||||
datagrid.UnselectAllCells();
|
||||
}
|
||||
|
||||
private void UserControlBase_Loaded(object sender, RoutedEventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void Border_MouseUp(object sender, MouseButtonEventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void UserControlBase_LoadedVisibleFirst(object sender, EventArgs e)
|
||||
{
|
||||
if (IsInDesignMode)
|
||||
return;
|
||||
//viewModel.NewMethod();
|
||||
}
|
||||
|
||||
private void UserControlBase_LoadedVisible(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user