예제 #1
0
        private void DetailsButton_Click(object sender, EventArgs e)
        {
            Sections grp = new Sections();
            Topics   top = new Topics();

            foreach (DataGridViewRow row in dataGridView1.SelectedRows)
            {
                grp.ID        = (int)row.Cells[0].Value;
                grp.GroupSize = (byte)row.Cells[1].Value;
                grp.Status    = row.Cells[2].Value.ToString();
                if (row.Cells[4].Value != null)
                {
                    grp.TopicID = (int)row.Cells[4].Value;
                    top.ID      = (int)row.Cells[4].Value;
                    top.Title   = row.Cells[5].Value.ToString();
                }
                else
                {
                    top.ID      = 0;
                    grp.TopicID = 0;
                }
                grp.SemID = (int)row.Cells[3].Value;
            }
            top = DependencyFacade.GetTopicData(top);
            MoreInfo mri = new MoreInfo(2, grp, top);

            mri.ShowDialog();
        }
예제 #2
0
        private void MySecButton_Click(object sender, EventArgs e)
        {
            Sections grp = new Sections();
            Topics   top = new Topics();

            grp = DependencyFacade.GetMySection(LoginPanel.albumNumber);
            if (grp != null && grp.TopicID != null)
            {
                top.ID = (int)grp.TopicID;
                top    = DependencyFacade.GetTopicData(top);
            }
            MoreInfo mri = new MoreInfo(1, grp, top);

            mri.ShowDialog();
        }
예제 #3
0
        private void InfoButton_Click(object sender, EventArgs e)
        {
            Sections sec = new Sections();
            Topics   top = new Topics();

            foreach (DataGridViewRow row in dataGridView1.SelectedRows)
            {
                if (row.Cells[4].Value != null)
                {
                    top.ID    = (int)row.Cells[4].Value;
                    top.Title = row.Cells[5].Value.ToString();
                }
                sec.ID = (int)row.Cells[0].Value;
            }
            sec = DependencyFacade.GetSection(sec);
            top = DependencyFacade.GetTopicData(top);
            MoreInfo mri = new MoreInfo(0, sec, top);

            mri.ShowDialog();
        }