public async Task <Department> CreateDepartment(Department department)
        {
            await _sampleAppDbContext.Department.AddAsync(department);

            await _sampleAppDbContext.SaveChangesAsync();

            return(department);
        }
Beispiel #2
0
        public async Task <Employee> CreateEmployee(Employee employee)
        {
            await _sampleAppDbContext.Employee.AddAsync(employee);

            await _sampleAppDbContext.SaveChangesAsync();

            return(employee);
        }