コード例 #1
0
 public CreateConference(PreliminaryPhase parent, int positionX, int positionY)
 {
     InitializeComponent();
     Location              = new Point(positionX, positionY);
     this.parent           = parent;
     preliminaryController = ApplicationFactory.getPreliminaryPhaseController();
     validator             = new ConferenceValidator();
 }
コード例 #2
0
        public Register(Form parentForm)
        {
            InitializeComponent();

            this.parentForm       = parentForm;
            userValidator         = new UserValidator();
            preliminaryController = ApplicationFactory.getPreliminaryPhaseController();
        }
コード例 #3
0
        public PreliminaryPhase(Form parentForm, User loggedUser)
        {
            InitializeComponent();

            this.loggedUser       = loggedUser;
            this.parentForm       = parentForm;
            preliminaryController = ApplicationFactory.getPreliminaryPhaseController();

            updateStatus();
        }
コード例 #4
0
        public ConferenceDetails()
        {
            InitializeComponent();
            PreliminaryPhaseController preliminaryController = ApplicationFactory.getPreliminaryPhaseController();

            activeConference = preliminaryController.ActiveConference();
            if (activeConference == null)
            {
                richTextBox1.Text = "Currently, there is no active conference!";
            }
            else
            {
                richTextBox1.Text  = "Conference details:\n\n";
                richTextBox1.Text += "Conference name: " + activeConference.Name + "\n\n";
                richTextBox1.Text += "Conference fee: " + activeConference.ConferenceFee + "\n\n";
                richTextBox1.Text += "Conference commitee:\n";

                foreach (ConferenceUser confUser in activeConference.Users)
                {
                    User user = preliminaryController.FindUserById(confUser.UserId);
                    richTextBox1.Text += user.LastName + " " + user.FirstName + "\n";
                }

                richTextBox1.Text += "\n\nConference topics:\n";

                foreach (Topic topic in activeConference.Topics)
                {
                    richTextBox1.Text += topic.Name + "\n";
                }

                switch (activeConference.ActivePhase.Name)
                {
                case "PRELIMINARY":
                    richTextBox1.Text += "\nConference is currently in PRELIMINARY phase!";
                    richTextBox1.Text += "\nDeadline for this phase: " + activeConference.ActivePhase.Deadline.ToString() + "\n";
                    break;

                case "PHASEONE":
                    richTextBox1.Text += "\nConference is currently in PHASE ONE!";
                    richTextBox1.Text += "\nDeadline for this phase: " + activeConference.ActivePhase.Deadline.ToString() + "\n";
                    break;

                case "PHASETWO":
                    richTextBox1.Text += "\nConference is currently in PHASE TWO!";
                    richTextBox1.Text += "\nDeadline for this phase: " + activeConference.ActivePhase.Deadline.ToString() + "\n";
                    break;

                case "PHASETHREE":
                    richTextBox1.Text += "\nConference is currently in PHASE THREE!";
                    richTextBox1.Text += "\nDeadline for this phase: " + activeConference.ActivePhase.Deadline.ToString() + "\n";
                    break;
                }
            }
        }