using System.Windows.Controls; using System.Windows.Input; using YY.Admin.ViewModels.WeightRecord; namespace YY.Admin.Views.WeightRecord; public partial class CustomerPickerDialogView : UserControl { public CustomerPickerDialogView() { InitializeComponent(); } private void CustomersGrid_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (DataContext is CustomerPickerDialogViewModel vm && vm.ConfirmCommand.CanExecute()) vm.ConfirmCommand.Execute(); } }