Exemple #1
0
        //public static TMSMissingScanTimeCollection Search(SearchFilter SearchKey)
        //{
        //    TMSMissingScanTimeCollection collection = new TMSMissingScanTimeCollection();
        //    using (var reader = SqlHelper.ExecuteReaderService(ModuleConfig.MyConnection, "TMSMissingScanTime_Search", SearchFilterManager.SqlSearchParamNoCompany(SearchKey)))
        //    {
        //        while (reader.Read())
        //        {
        //            TMSMissingScanTime obj = new TMSMissingScanTime();
        //            obj = GetItemFromReader(reader);
        //            collection.Add(obj);
        //        }
        //    }
        //    return collection;
        //}
        public static TMSMissingScanTimeCollection GetbyUser(string CreatedUser)
        {
            TMSMissingScanTimeCollection collection = new TMSMissingScanTimeCollection();
            TMSMissingScanTime           obj;

            using (var reader = SqlHelper.ExecuteReaderService(ModuleConfig.MyConnection, "TMSMissingScanTime_GetAll_byUser", new SqlParameter("@CreatedUser", CreatedUser)))
            {
                while (reader.Read())
                {
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }
Exemple #2
0
        public static TMSMissingScanTimeCollection GetMissingData(int EmployeeCode, DateTime StartDate, DateTime EndDate, int EntityID)
        {
            TMSMissingScanTimeCollection collection = new TMSMissingScanTimeCollection();
            var pars = new SqlParameter[]
            {
                new SqlParameter("@EmployeeCode", EmployeeCode),
                new SqlParameter("@StartDate", StartDate),
                new SqlParameter("@EndDate", EndDate),
                new SqlParameter("@EntityID", EntityID),
            };

            using (var reader = SqlHelper.ExecuteReaderService(ModuleConfig.MyConnection, "USP_TMS_NotFillScanTime_Report", pars))
            {
                TMSMissingScanTime obj;
                while (reader.Read())
                {
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }