Ejemplo n.º 1
0
        /// <summary>
        /// contructor of RentBikeForm
        /// </summary>
        public RentBikeForm() : base()
        {
            rentBikeController = new RentBikeController();

            InitializeComponent("RentBikeForm", "Rent Bike");
            DrawRentBikeForm();
        }
Ejemplo n.º 2
0
        /// <summary>
        /// contructor of CardInformationForm
        /// </summary>
        public CardInformationForm() : base()
        {
            rentBikeController = new RentBikeController();

            InitializeComponent("CardInformationForm", "Card Information");
            DrawCardInformation();
        }
Ejemplo n.º 3
0
        static void Main()
        {
            Application.SetHighDpiMode(HighDpiMode.SystemAware);
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            //connect to database
            connecter = SQLConnecter.GetInstance();

            //init services
            bikeService         = new BikeService(connecter);
            cardService         = new CardService(connecter);
            electricBikeService = new ElectricBikeService(connecter);
            stationService      = new StationService(connecter);
            tandemService       = new TandemService(connecter);
            transactionService  = new TransactionService(connecter);
            userService         = new UserService(connecter);

            //init controllers
            rentBikeController    = new RentBikeController();
            bikeStationController = new BikeStationController();
            returnBikeController  = new ReturnBikeController();

            //init the presentation
            homePageForm               = new HomePageForm();
            stationDetailForm          = new StationDetailForm();
            bikeDetailForm             = new BikeDetailForm();
            cardInformationForm        = new CardInformationForm();
            listBikeForm               = new ListBikeForm();
            rentBikeForm               = new RentBikeForm();
            returnBikeForm             = new ReturnBikeForm();
            transactionInformationForm = new TransactionInformationForm();

            Application.Run(homePageForm);
        }
        /// <summary>
        /// contructor of TransactionInformationForm
        /// </summary>
        public TransactionInformationForm() : base()
        {
            rentBikeController   = new RentBikeController();
            returnBikeController = new ReturnBikeController();
            paymentController    = new PaymentController();

            InitializeComponent("TransactionInformationForm", "Transaction Information");
            DrawTransactionInformationForm();
        }