public IHttpActionResult Delete(OrgRoleDTO roleDTO) { AppLogger.Instance.LogBegin(this.GetType().Name, System.Reflection.MethodInfo.GetCurrentMethod().Name); iRoleRepository = new OrgRoleRepository(this.Request.GetOwinContext().Get <AppDBContext>()); ActionResult <string> actionResult = iRoleRepository.Delete(roleDTO.Id); AppLogger.Instance.LogEnd(this.GetType().Name, System.Reflection.MethodInfo.GetCurrentMethod().Name); return(Ok(actionResult)); }
public IHttpActionResult GetById(int id) { AppLogger.Instance.LogBegin(this.GetType().Name, System.Reflection.MethodInfo.GetCurrentMethod().Name); iRoleRepository = new OrgRoleRepository(this.Request.GetOwinContext().Get <AppDBContext>()); ActionResult <OrgRoleDTO> actionResult = iRoleRepository.Get(id); AppLogger.Instance.LogEnd(this.GetType().Name, System.Reflection.MethodInfo.GetCurrentMethod().Name); return(Ok(actionResult)); }
public PermissionService(IPermissionRepository permissionRepository, IOrgRoleRepository roleRepository, IUnitOfWork unitOfWork, IMapper mapper, IBus bus, IMemoryCache memoryCache) { _permissionRepository = permissionRepository; _roleRepository = roleRepository; _unitOfWork = unitOfWork; _mapper = mapper; _bus = bus; _memoryCache = memoryCache; }