Пример #1
0
        public async Task <IActionResult> CheckOutDeviceAsync(SelectEmployeeModel model)
        {
            ReturnUrl = HttpContext.Request.Headers["Referer"];

            await _checkouts.CheckOutDevices(model.SelectedEmployeeId, model.DeviceId);

            return(Redirect(ReturnUrl));
        }
Пример #2
0
        // Выбрать сотрудника
        public async Task <IActionResult> SelectEmployeeAsync(int deviceId)
        {
            var employees = await _employees.GetEmployeesAsync();

            var model = new SelectEmployeeModel
            {
                Employees = employees.ToArray(),
                DeviceId  = deviceId
            };

            return(PartialView(model));
        }