예제 #1
0
파일: REPO.cs 프로젝트: imp908/fileshare
        public static void ReadRepoCheck()
        {
            SQL_entity         ent     = new SQL_entity();
            ReadRepo <T_ACQ_D> readRep = new ReadRepo <T_ACQ_D>(ent);
            MerchantFilterRepo <KEY_CLIENTS, REFMERCHANTS> filtRep = new MerchantFilterRepo <KEY_CLIENTS, REFMERCHANTS>(ent);
            DateFilterRepo <T_ACQ_D>  dateFilter = new DateFilterRepo <T_ACQ_D>(ent);
            ChainingRepo <TEMP_ACQ_D> chainRep   = new ChainingRepo <TEMP_ACQ_D>(ent);

            DateTime stDt = new DateTime(2016, 08, 21, 00, 00, 00);
            DateTime fnDt = new DateTime(2016, 08, 22, 00, 00, 00);

            DateTime st = new DateTime(2016, 02, 01, 00, 00, 00);
            DateTime fn = new DateTime(2016, 06, 01, 00, 00, 00);

            //48
            int cnt_1 = readRep.GetByFilter <T_ACQ_D>(s => s.MERCHANT == 9294109921).Count();

            //50830
            int cnt_2 = dateFilter.GetByDate(stDt, fnDt).Count();
            //128
            int cnt_3 = filtRep.GetByMerchantFilter <T_ACQ_D>().Count();

            //2042
            int cnt_4 = chainRep.FilterByDate(st, fn)._result.Count();
            //597
            int cnt_5 = chainRep.FilterByMerchants <REFMERCHANTS>()._result.Count();
        }
예제 #2
0
파일: REPO.cs 프로젝트: imp908/fileshare
        public int MerchantListCount()
        {
            int _result = 0;
            MerchantFilterRepo <REFMERCHANTS, REFMERCHANTS> merchantRepo = new MerchantFilterRepo <REFMERCHANTS, REFMERCHANTS>(ent);

            _result = merchantRepo.GetMerchantFilterAmount <REFMERCHANTS>();
            return(_result);
        }
예제 #3
0
파일: REPO.cs 프로젝트: imp908/fileshare
        public int GetMerchantFilterAmount()
        {
            int result_ = 0;
            MerchantFilterRepo <KEY_CLIENTS, REFMERCHANTS> MerchantFilter = new MerchantFilterRepo <KEY_CLIENTS, REFMERCHANTS>(ent);

            result_ = MerchantFilter.GetMerchantFilterAmount <KEY_CLIENTS>();
            return(result_);
        }
예제 #4
0
파일: REPO.cs 프로젝트: imp908/fileshare
        //bind K of REFMERCHANTS with method
        public IQueryable <T> GetByMerchants <T>() where T : class, IMerchant
        {
            IQueryable <T> _result = null;
            MerchantFilterRepo <T, REFMERCHANTS> merchantRepo = new MerchantFilterRepo <T, REFMERCHANTS>(ent);

            _result = merchantRepo.GetByMerchantFilter <T>();
            return(_result);
        }
예제 #5
0
파일: REPO.cs 프로젝트: imp908/fileshare
        public IQueryable <IMerchant> FilterByMerchant <T>() where T : class, IMerchant
        {
            IQueryable <IMerchant> result_ = null;
            MerchantFilterRepo <T, REFMERCHANTS> MerchantFilter = new MerchantFilterRepo <T, REFMERCHANTS>(ent);

            result_ = MerchantFilter.GetByMerchantFilter <T>();
            return(result_);
        }