Exemplo n.º 1
0
        /// <summary>
        /// Eduardo Colon
        /// Created: 2019/03/20
        ///
        /// constructor  to create shuttleReservation with  one parameter.
        /// </summary>
        public ShuttleReservationDetail(IShuttleReservationManager shuttleReservationManager = null, IEmployeeManager employeeManager = null, IGuestManager guestManager = null)
        {
            if (shuttleReservationManager == null)
            {
                shuttleReservationManager = new ShuttleReservationManager();
            }

            if (employeeManager == null)
            {
                employeeManager = new EmployeeManager();
            }
            if (guestManager == null)
            {
                guestManager = new GuestManager();
            }

            _shuttleReservationManager = shuttleReservationManager;
            _employeeManager           = employeeManager;
            _guestManager = guestManager;

            _isUpdate = false;


            InitializeComponent();
            btnDropoffSubmit.Visibility = Visibility.Collapsed;
        }
Exemplo n.º 2
0
 public void testSetup()
 {
     _shuttleReservationMock    = new ShuttleReservationAccessorMock();
     _shuttleReservationManager = new ShuttleReservationManager(_shuttleReservationMock);
     _shuttleReservations       = new List <ShuttleReservation>();
     _shuttleReservations       = _shuttleReservationManager.RetrieveAllShuttleReservations();
 }
Exemplo n.º 3
0
        /// <summary>
        /// Eduardo Colon
        /// Created: 2019/03/20
        ///
        /// constructor: BrowseShuttleReservation with one parameter.
        /// </summary>
        public BrowseShuttleReservation(IShuttleReservationManager shuttleReservationManager = null)
        {
            if (shuttleReservationManager == null)
            {
                _shuttleReservationManager = new ShuttleReservationManager();
            }

            _shuttleReservationManager = shuttleReservationManager;


            InitializeComponent();
        }
Exemplo n.º 4
0
        /// <summary>
        /// Eduardo Colon
        /// Created: 2019/03/10
        ///
        /// constructor  to create shuttleReservation with  three parameters.
        /// </summary>
        public ShuttleReservationDetail(ShuttleReservation selectedShuttleReservation, IShuttleReservationManager shuttleReservationManager = null, IEmployeeManager employeeManager = null, IGuestManager guestManager = null)
        {
            _selectedShuttleReservation = selectedShuttleReservation;

            if (shuttleReservationManager == null)
            {
                shuttleReservationManager = new ShuttleReservationManager();
            }
            if (employeeManager == null)
            {
                employeeManager = new EmployeeManager();
            }
            if (guestManager == null)
            {
                guestManager = new GuestManager();
            }

            _shuttleReservationManager = shuttleReservationManager;
            _employeeManager           = employeeManager;
            _guestManager = guestManager;

            InitializeComponent();


            txtPickupLocation.Text     = _selectedShuttleReservation.PickupLocation;
            txtDropoffDestination.Text = _selectedShuttleReservation.DropoffDestination;


            this.Title                    = "Update Shuttle Reservatiion";
            cboGuestLast.IsEnabled        = false;
            cboGuestFirst.IsEnabled       = false;
            cboGuestPhoneNumber.IsEnabled = false;
            cboEmployeeLast.IsEnabled     = false;
            cboEmployeeFirst.IsEnabled    = false;
            if (_selectedShuttleReservation.DropoffDateTime != null)
            {
                btnDropoffSubmit.IsEnabled = false;
            }

            _isUpdate = true;
        }
Exemplo n.º 5
0
        //private List<Guest> _guestList;


        /// <summary>
        /// Eduardo Colon
        /// Created: 2019/03/20
        ///
        /// Default constructor:  BrowseshuttleReservation.
        /// </summary>
        public BrowseShuttleReservation()
        {
            _shuttleReservationManager = new ShuttleReservationManager();

            InitializeComponent();
        }