stuff
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Windows;
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using System.Windows.Input;
|
||||
using CommunityToolkit.Mvvm.Input;
|
||||
using WD7UVN_SzTGUI_2023242.Client.WPF.Windows;
|
||||
|
||||
namespace WD7UVN_SzTGUI_2023242.Client.WPF.ViewModels
|
||||
{
|
||||
@@ -42,7 +43,7 @@ namespace WD7UVN_SzTGUI_2023242.Client.WPF.ViewModels
|
||||
{
|
||||
if (!IsInDesignMode)
|
||||
{
|
||||
Employees = new RestCollection<Employee>("http://localhost:5000/", "api/GetSubordinates", "hub");
|
||||
Employees = new RestCollection<Employee>("http://localhost:5000/", "api/Employee", "hub");
|
||||
|
||||
UpdateEmployeeCommand = new RelayCommand(() =>
|
||||
{
|
||||
@@ -61,6 +62,16 @@ namespace WD7UVN_SzTGUI_2023242.Client.WPF.ViewModels
|
||||
{
|
||||
return SelectedEmployee != null;
|
||||
});
|
||||
|
||||
GetSubordinatesCommand = new RelayCommand(() =>
|
||||
{
|
||||
Window window = new GetSubordinates(SelectedEmployee);
|
||||
window.Show();
|
||||
},
|
||||
() =>
|
||||
{
|
||||
return SelectedEmployee != null;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user