Exemple #1
0
        public static void RefreshDateTimeRestricitons()
        {
            AvalonDBDataContext dbcontext = AvalonDbDataContextProvider.DbContextInstance;

            DefaultMinDateTime = dbcontext.Games.Select(x => x.GameTime).Min().Date;
            DefaultMaxDateTime = dbcontext.Games.Select(x => x.GameTime).Max().Date;
            ResetMinDateTime();
            ResetMaxDateTime();
        }
Exemple #2
0
        static QueryRestrictions()
        {
            AvalonDBDataContext dbcontext = AvalonDbDataContextProvider.DbContextInstance;

            DefaultMinDateTime     = dbcontext.Games.Select(x => x.GameTime).Min();
            DefaultMaxDateTime     = dbcontext.Games.Select(x => x.GameTime).Max();
            DefaultGroupSize       = null;
            DefaultContainedPlayer = null;
            DefaultContainedRole   = null;

            ResetMinDateTime();
            ResetMaxDateTime();
            ResetGroupSize();
            ResetContainedPlayer();
            ResetContainedRole();
        }
Exemple #3
0
 public static void RefreshInstance() => _dbcontextInstance = new AvalonDBDataContext();
 public static IEnumerable <GameView> GetFilteredGameViews(this AvalonDBDataContext dbcontext)
 {
     return(QueryRestrictions.FilterGameViews(dbcontext.GameViews));
 }