Esempio n. 1
0
        public JsonPatchDocument <ApiBusinessEntityAddressRequestModel> CreatePatch(ApiBusinessEntityAddressRequestModel model)
        {
            var patch = new JsonPatchDocument <ApiBusinessEntityAddressRequestModel>();

            patch.Replace(x => x.AddressID, model.AddressID);
            patch.Replace(x => x.AddressTypeID, model.AddressTypeID);
            patch.Replace(x => x.ModifiedDate, model.ModifiedDate);
            patch.Replace(x => x.Rowguid, model.Rowguid);
            return(patch);
        }
Esempio n. 2
0
        public virtual ApiBusinessEntityAddressRequestModel MapResponseToRequest(
            ApiBusinessEntityAddressResponseModel response)
        {
            var request = new ApiBusinessEntityAddressRequestModel();

            request.SetProperties(
                response.AddressID,
                response.AddressTypeID,
                response.ModifiedDate,
                response.Rowguid);
            return(request);
        }
Esempio n. 3
0
        public virtual ApiBusinessEntityAddressResponseModel MapRequestToResponse(
            int businessEntityID,
            ApiBusinessEntityAddressRequestModel request)
        {
            var response = new ApiBusinessEntityAddressResponseModel();

            response.SetProperties(businessEntityID,
                                   request.AddressID,
                                   request.AddressTypeID,
                                   request.ModifiedDate,
                                   request.Rowguid);
            return(response);
        }