public HttpResponseMessage UpdatePlanType(PlanTypeUpdateRequest model)
        {
            if (!ModelState.IsValid)
            {
                return Request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState);
            }

            _plansService.UpdatePlanType(model);
            SuccessResponse response = new SuccessResponse();

            return Request.CreateResponse(HttpStatusCode.OK, response);
        }
Ejemplo n.º 2
0
        public void UpdatePlanType(PlanTypeUpdateRequest model)
        {
            DataProvider.ExecuteNonQuery(GetConnection, "dbo.PlanTypes_Update"
              , inputParamMapper: delegate(SqlParameterCollection paramCollection)
              {
                  paramCollection.AddWithValue("@Name", model.Name);
                  paramCollection.AddWithValue("@Id", model.Id);

              });
        }