public IActionResult DeleteSubCategoryByAdmin([FromBody] int pscid) { IARresponse = BadRequest(); try { if (objadmindb.DeleteSubCategoryByAdmin(pscid) == "") { IARresponse = Ok(new { res = "Category Deleted Successfully" }); } else { IARresponse = BadRequest(new { res = "Category not Deleted... try again later!.." + objadmindb.DeleteSubCategoryByAdmin(pscid) }); } } catch (Exception ex) { IARresponse = BadRequest(new { res = ex.Message }); } return(IARresponse); }