Example #1
0
 public int AddServiceCategory(MvServiceCategory serviceCategory)
 {
     serviceCategoryId = 0;
     ActionProcedures.SpServiceCategoryIns(JsonConvert.SerializeObject(serviceCategory, new JsonSerializerSettings {
         ContractResolver = new CamelCasePropertyNamesContractResolver()
     }), ref serviceCategoryId);
     return(serviceCategoryId);
 }
 public IActionResult EditServiceCategory([FromBody] MvServiceCategory serviceCategory)
 {
     try
     {
         serviceCategoryService.EditServiceCategory(serviceCategory);
         return(Ok());
     }
     catch (Exception ex)
     {
         return(BadRequest(ex.Message));
     }
 }
 public IActionResult ServiceCategory([FromBody] MvServiceCategory serviceCategory)
 {
     try
     {
         int serviceCategoryId = serviceCategoryService.AddServiceCategory(serviceCategory);
         return(Ok(serviceCategoryId));
     }
     catch (Exception ex)
     {
         return(BadRequest(ex.Message));
     }
 }
Example #4
0
 public void EditServiceCategory(MvServiceCategory serviceCategory)
 {
     ActionProcedures.SpServiceCategoryUpd(JsonConvert.SerializeObject(serviceCategory, new JsonSerializerSettings {
         ContractResolver = new CamelCasePropertyNamesContractResolver()
     }));
 }