示例#1
0
        public JsonPatchDocument <ApiTeacherSkillRequestModel> CreatePatch(ApiTeacherSkillRequestModel model)
        {
            var patch = new JsonPatchDocument <ApiTeacherSkillRequestModel>();

            patch.Replace(x => x.Name, model.Name);
            return(patch);
        }
示例#2
0
        public virtual ApiTeacherSkillRequestModel MapResponseToRequest(
            ApiTeacherSkillResponseModel response)
        {
            var request = new ApiTeacherSkillRequestModel();

            request.SetProperties(
                response.Name);
            return(request);
        }
示例#3
0
        public virtual ApiTeacherSkillResponseModel MapRequestToResponse(
            int id,
            ApiTeacherSkillRequestModel request)
        {
            var response = new ApiTeacherSkillResponseModel();

            response.SetProperties(id,
                                   request.Name);
            return(response);
        }