示例#1
0
        public async Task <ActionResult> PostAsync([FromBody] WorkTask task)
        {
            WorkTask fullTask = task.ToDbForm();

            _context.Tasks.Add(fullTask);
            await _context.SaveChangesAsync();

            return(CreatedAtAction("Get", fullTask));
        }