예제 #1
0
        public static bool IsAdmin(this IStaffeUser stafferRequest)
        {
            if (stafferRequest == null)
            {
                throw new LogicException("未登錄");
            }

            return(string.Equals(stafferRequest.Role, "Admin", System.StringComparison.CurrentCultureIgnoreCase));
        }
예제 #2
0
 public CalculationService(ProjectRepository repository, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository = repository;
 }
예제 #3
0
 public BasicDataService(IRepository <BasicData> repository, ResourceService resourceService, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository      = repository;
     this.resourceService = resourceService;
 }
예제 #4
0
 public StandingbookService(ProjectRepository repository, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository = repository;
 }
예제 #5
0
 public ProjectProcurementService(ProjectRepository repository, FileStorageServie fileStorageServie, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository        = repository;
     this.fileStorageServie = fileStorageServie;
 }
예제 #6
0
 public SupplierService(IRepository <Supplier> repository, ResourceService resourceService, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository      = repository;
     this.resourceService = resourceService;
 }
예제 #7
0
 public BaseService(IBoundedContext bounded, IStaffeUser user)
 {
     this.Bounded = bounded;
     this.User    = user;
 }
예제 #8
0
 public ProjectMasterService(ProjectRepository repository, ISerialNumberProvider serialNumberProvider, FileStorageServie fileStorageServie, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository           = repository;
     this.serialNumberProvider = serialNumberProvider;
     this.fileStorageServie    = fileStorageServie;
 }
예제 #9
0
 public SettingService(SettingRepository repository, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository = repository;
 }
예제 #10
0
 public TargetCostService(TargetCostRepository repository, ISerialNumberProvider serialNumberProvider, IBoundedContext bounded, IStaffeUser user) : base(bounded, user)
 {
     this.repository           = repository;
     this.serialNumberProvider = serialNumberProvider;
 }