public Response <UserDto> Post(UserDto UserDto) { Response <UserDto> response = new Response <UserDto>(); try { AssetContext assetContext = new AssetContext(); response.Item = assetContext.SaveUser(UserDto); // Configure the Success response. response.Code = OperationCode.ResponseCode.SUCCESS; response.MessageList.Add(MessageResource.GetInstance().GetText("SawDAL_UpdateSuccess", MESSAGE_RESOURCE)); } catch (Exception ex) { response.Code = OperationCode.ResponseCode.ERROR; response.ErrorList.Add(MessageResource.GetInstance().GetText("SawDAL_UpdateInvalid", MESSAGE_RESOURCE)); } return(response); }