//To get roles public IHttpActionResult GetUsersPendingApprovals(string emailID) { try { PendingApprovalsData pendingApprovalsData = new PendingApprovalsData(); var pendingApprovals = pendingApprovalsData.GetPendingApprovals(emailID); return(Ok(pendingApprovals)); } catch (Exception ex) { return(BadRequest("Could not fetch users pending approvals")); } }
//To get roles public IHttpActionResult GetPendingApprovals(int?ownerID) { try { PendingApprovalsData pendingApprovalsData = new PendingApprovalsData(); var pendingApprovals = pendingApprovalsData.GetPendingApprovals(ownerID); return(Ok(pendingApprovals)); } catch (Exception ex) { return(BadRequest("Could not fetch pending approvals")); } }