public void TestInitialize()
        {
            string conn = "Database=agile_config_test;Data Source=localhost;User Id=root;Password=dev@123;port=3306";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.MySql, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            freeSqlContext = new FreeSqlContext(fsq);
            service        = new AppService(freeSqlContext);
            fsq.Delete <App>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
Beispiel #2
0
        public void TestInitialize()
        {
            string conn = "Data Source=agile_config.db";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.Sqlite, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            freeSqlContext = new FreeSqlContext(fsq);
            service        = new AppService(freeSqlContext);
            fsq.Delete <App>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
Beispiel #3
0
        public void TestInitialize()
        {
            string conn = "Host=127.0.0.1;Database=agile_config;Username=postgres;Password=dev@123";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.PostgreSQL, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            FluentApi.Config(fsq);
            freeSqlContext = new FreeSqlContext(fsq);
            service        = new AppService(freeSqlContext);
            fsq.Delete <App>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
        public void TestInitialize()
        {
            string conn = "user id=CLINIC;password=CLINIC;data source=192.168.0.91/orcl";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.Oracle, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            FluentApi.Config(fsq);
            freeSqlContext = new FreeSqlContext(fsq);
            service        = new AppService(freeSqlContext);
            fsq.Delete <App>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
Beispiel #5
0
        public void TestInitialize()
        {
            string conn = "Persist Security Info = False; User ID =dev; Password =dev@123,; Initial Catalog =agile_config_test; Server =xxxxx";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.SqlServer, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            FluentApi.Config(fsq);
            freeSqlContext = new FreeSqlContext(fsq);
            service        = new AppService(freeSqlContext);
            fsq.Delete <App>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
Beispiel #6
0
        public void TestInitialize()
        {
            string conn = "Data Source=agile_config.db";

            fsq = new FreeSqlBuilder()
                  .UseConnectionString(FreeSql.DataType.Sqlite, conn)
                  .UseAutoSyncStructure(true)
                  .Build();
            freeSqlContext = new FreeSqlContext(fsq);

            var cache  = new Mock <IMemoryCache>();
            var config = new Config();

            service = new ConfigService(freeSqlContext, cache.Object, new AppService(freeSqlContext));
            fsq.Delete <Config>().Where("1=1");

            Console.WriteLine("TestInitialize");
        }
Beispiel #7
0
 public ConfigService(FreeSqlContext context, IMemoryCache memoryCache, IAppService appService)
 {
     _dbContext   = context;
     _memoryCache = memoryCache;
     _appService  = appService;
 }
 public AppService(FreeSqlContext context)
 {
     _dbContext = context;
 }
Beispiel #9
0
 public SysLogService(FreeSqlContext context)
 {
     _dbContext = context;
 }
 public SettingService(FreeSqlContext context)
 {
     _dbContext = context;
 }
Beispiel #11
0
 public ModifyLogService(FreeSqlContext context)
 {
     _dbContext = context;
 }
 public QzRunLogService(FreeSqlContext context, IMongoRepository <QzRunLogMoEntity> mongoRepository)
 {
     _dbContext       = context;
     _mongoRepository = mongoRepository;
 }
Beispiel #13
0
 public QzRunLogService(FreeSqlContext context)
 {
     _dbContext = context;
 }
 public ServerNodeService(FreeSqlContext context)
 {
     _dbContext = context;
 }
Beispiel #15
0
 public PermissionService(FreeSqlContext freeSql)
 {
     _dbContext = freeSql;
 }
Beispiel #16
0
 public ConfigService(FreeSqlContext context, IMemoryCache memoryCache)
 {
     _dbContext   = context;
     _memoryCache = memoryCache;
 }
Beispiel #17
0
 public TasksQzService(FreeSqlContext context)
 {
     _dbContext = context;
 }
Beispiel #18
0
 public UserService(FreeSqlContext context)
 {
     _dbContext = context;
 }