コード例 #1
0
ファイル: ChildController.cs プロジェクト: Brano68/Project2
        public async Task <ActionResult <ChildDTO> > PutChild(
            [FromRoute] Guid personId,
            [FromRoute] Guid childId,
            [FromBody] ChildDTO childDTO)
        {
            var child = await ChildManager.UpdateChild(personId, childId, childDTO).ConfigureAwait(false);

            return(child != null
                ? (ObjectResult)Ok(child)
                : BadRequest(new { ErrorMEssage = "Entity not found" }));
        }