Пример #1
0
        public virtual ApiColumnSameAsFKTableClientRequestModel MapClientResponseToRequest(
            ApiColumnSameAsFKTableClientResponseModel response)
        {
            var request = new ApiColumnSameAsFKTableClientRequestModel();

            request.SetProperties(
                response.Person,
                response.PersonId);
            return(request);
        }
Пример #2
0
        public virtual ApiColumnSameAsFKTableClientResponseModel MapClientRequestToResponse(
            int id,
            ApiColumnSameAsFKTableClientRequestModel request)
        {
            var response = new ApiColumnSameAsFKTableClientResponseModel();

            response.SetProperties(id,
                                   request.Person,
                                   request.PersonId);
            return(response);
        }
Пример #3
0
        public virtual async Task <UpdateResponse <ApiColumnSameAsFKTableClientResponseModel> > ColumnSameAsFKTableUpdateAsync(int id, ApiColumnSameAsFKTableClientRequestModel item, CancellationToken cancellationToken = default(CancellationToken))
        {
            HttpResponseMessage httpResponse = await this.Client.PutAsJsonAsync($"api/ColumnSameAsFKTables/{id}", item, cancellationToken).ConfigureAwait(false);

            this.HandleResponseCode(httpResponse);
            return(JsonConvert.DeserializeObject <UpdateResponse <ApiColumnSameAsFKTableClientResponseModel> >(httpResponse.Content.ContentToString()));
        }