Esempio n. 1
0
        public IEnumerable <GetAllRequestForUserDto> GetMailroomRequestList(GetMailroomRequestDto dto)
        {
            try
            {
                Logger.Info("Just entered GetMailroomRequestList function");

                using (var db = new EOneContext())
                {
                    var list = db.ExecuteQuery <GetAllRequestForUserDto>("select * from Courier_Tracker where Dispatch_Rider_Name is not Null and Dispatch_Rider_Pickup_DateTime is not Null and Central_Mailroom_Officer is Null and Central_Mailroom_Date is Null", new Object[] { }).ToList();
                    return(list);
                }
            }
            catch (Exception ex)
            {
                Logger.Error("GetMailroomRequestList function entered an exception");
                Logger.Error(ex);
                return(null);
            }
        }
Esempio n. 2
0
        public IEnumerable <AllUserDto> GetAllNames()
        {
            try
            {
                Logger.Info("Just entered GetAllNames function");

                using (var db = new EOneContext())
                {
                    var list = db.ExecuteQuery <AllUserDto>("select Courier_Name, Units_Branches, Phone_Numbers, Email_Address,Status, Branch_Code from Dispatch_Riders_Lagos", new Object[] { }).ToList();
                    return(list);
                }
            }
            catch (Exception ex)
            {
                Logger.Error("GetAllNames function entered an exception");
                Logger.Error(ex);
                return(null);
            }
        }
Esempio n. 3
0
        public IEnumerable <GetAllRequestForUserDto> GetRiderRequestList(GetRiderRequestDto dto)
        {
            try
            {
                Logger.Info("Just entered GetRiderRequestList function" + dto.RiderEmail);

                using (var db = new EOneContext())
                {
                    var list = db.ExecuteQuery <GetAllRequestForUserDto>("select * from Courier_Tracker where PickUp_Branch ='" + dto.BranchCode.Trim() + "' and Dispatch_Rider_Name is Null and Dispatch_Rider_Pickup_DateTime is Null ", new Object[] { }).ToList();
                    return(list);
                }
            }
            catch (Exception ex)
            {
                Logger.Error("GetRiderRequestList function entered an exception" + dto.RiderEmail);
                Logger.Error(ex);
                return(null);
            }
        }