25 lines
652 B
C#
25 lines
652 B
C#
using System;
|
|
using System.Windows;
|
|
using System.Windows.Input;
|
|
|
|
namespace BodyshopUploader.ViewModels
|
|
{
|
|
public partial class LoginViewModel : BaseViewModel
|
|
{
|
|
private ICommand _loginCommand;
|
|
public ICommand LoginCommand
|
|
{
|
|
get
|
|
{
|
|
if (_loginCommand == null)
|
|
{
|
|
_loginCommand = new RelayCommand(
|
|
p => !string.IsNullOrEmpty(UserName) && UserPassword?.Length > 6,
|
|
async p => { await LoginAsync(p as Window); });
|
|
}
|
|
return _loginCommand;
|
|
}
|
|
}
|
|
}
|
|
}
|