public IHttpActionResult AddProductCategory([FromBody] ProductCateogory productCategory) { try { return(Ok(ProductCateogoryManager.AddProductCategory(productCategory))); } catch (Exception exception) { return(InternalServerError(exception)); } }
public IHttpActionResult GetProductCategoryList([FromBody] SearchViewModel viewModel) { try { return(Ok(ProductCateogoryManager.GetProductCategoryList(viewModel))); } catch (Exception exception) { return(InternalServerError(exception)); } }
public IHttpActionResult GetProductCategoryById([FromBody] IdViewModel idViewModel) { try { return(Ok(ProductCateogoryManager.GetProductCategoryById(idViewModel.Id))); } catch (Exception exception) { return(InternalServerError(exception)); } }
public IHttpActionResult GetProductCategories() { try { return(Ok(ProductCateogoryManager.GetProductCategories())); } catch (Exception exception) { return(InternalServerError(exception)); } }
public IHttpActionResult DeleteProductCategory([FromBody] IdViewModel idViewModel) { try { ProductCateogoryManager.DeleteProductCategory(idViewModel.Id); return(Ok()); } catch (Exception exception) { return(InternalServerError(exception)); } }