Esempio n. 1
0
 public RegisterHandler(ProposeContext context, ICache cache, Lazy <IAuthConfiguration> lazyAuthConfiguration, IMediator mediator)
 {
     _context         = context;
     _cache           = cache;
     _mediator        = mediator;
     _jwtWriterFormat = new JwtWriterFormat(lazyAuthConfiguration, new OAuthOptions(lazyAuthConfiguration, mediator));
 }
Esempio n. 2
0
 public SendRegistrationConfirmationHandler(ProposeContext context, ICache cache, INotificationService notificationService, IEncryptionService encryptionService)
 {
     _context             = context;
     _cache               = cache;
     _notificationService = notificationService;
     _encryptionService   = encryptionService;
 }
        public static void Seed(ProposeContext context)
        {
            context.Tenants.AddOrUpdate(x => x.Name, new Tenant()
            {
                Name = "Default"
            });

            context.SaveChanges();
        }
Esempio n. 4
0
        public static void Seed(ProposeContext context)
        {
            var systemRole = context.Roles.First(x => x.Name == Roles.SYSTEM);
            var roles      = new List <Role>();
            var tenant     = context.Tenants.Single(x => x.Name == "Default");

            roles.Add(systemRole);
            context.Users.AddOrUpdate(x => x.Username, new User()
            {
                Username = "******",
                Password = new EncryptionService().TransformPassword("system"),
                Roles    = roles,
                TenantId = tenant.Id
            });

            context.SaveChanges();
        }
        public static void Seed(ProposeContext context)
        {
            context.Roles.AddOrUpdate(x => x.Name, new Role()
            {
                Name = Roles.SYSTEM
            });

            context.Roles.AddOrUpdate(x => x.Name, new Role()
            {
                Name = Roles.PRODUCT
            });

            context.Roles.AddOrUpdate(x => x.Name, new Role()
            {
                Name = Roles.DEVELOPMENT
            });

            context.SaveChanges();
        }
Esempio n. 6
0
 public GetIdeaCommentsHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 7
0
 public GetTeamByIdHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 8
0
 public RemoveTeamHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
 public ConfirmRegistrationHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 10
0
 public GetUsersHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 11
0
 public AddOrUpdateIdeaCommentHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 12
0
 public RemoveIdeaCommentHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 13
0
 public GetDigitalAssetByUniqueIdHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
 public GetTeamMembersByUserIdHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
 public GetIdeationByIdHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 16
0
 public AddOrUpdateUserHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }
Esempio n. 17
0
 public VoteIdeaHandler(ProposeContext context, ICache cache)
 {
     _context = context;
     _cache   = cache;
 }