Explorar el Código

Удалён TitleList

Вадим Королёв hace 1 año
padre
commit
6edf11b708
Se han modificado 2 ficheros con 3 adiciones y 19 borrados
  1. 0 18
      InvestTracker/Models/TitleList.cs
  2. 3 1
      InvestTracker/VM/EmployeeBrowseVM.cs

+ 0 - 18
InvestTracker/Models/TitleList.cs

@@ -1,18 +0,0 @@
-using System.Collections.ObjectModel;
-using InvestTracker.Entities;
-using System.Collections.Generic;
-using Microsoft.EntityFrameworkCore;
-using System.Linq;
-
-namespace InvestTracker.Models
-{
-    class TitleList : ObservableCollection<Title>
-    {
-        public TitleList() 
-        {
-            var dbContext = new InvestContext();
-            List<Title> allTitles = dbContext.Titles.Select(t => t).ToList();
-            this.AddRange(allTitles);
-        }
-    }
-}

+ 3 - 1
InvestTracker/VM/EmployeeBrowseVM.cs

@@ -72,7 +72,9 @@ namespace InvestTracker.VM
 
         private void New_Executed()
         {
-            MessageBox.Show("Adding...");
+            Employee newEmployee = _dbContext.Employee.Create();
+            
+            GridBlocked = false;
             isDirty = true;
         }