예제 #1
0
        private void RefreshDgvSTOIssues()
        {
            if (dgv_STO.SelectedRows.Count > 0)
            {
                var    obj        = dgv_STO.SelectedRows[0].Cells["Code"].Value;
                string teamcode   = obj == null ? null : obj.ToString();
                var    preplanner = PrePlanner.GetPrePlannerFromTeamCode(teamcode);

                if (preplanner != null)
                {
                    this.Invoke(new deleBindDataSource(BindDataSource), preplanner);
                }

                obj = dgv_STO.SelectedRows[0].Cells["col_STO"].Value;
                if (obj != null)
                {
                    string teamname = obj.ToString();
                    for (int j = 0; j < dgv_FBList.ColumnCount; j++)
                    {
                        if (dgv_FBList.Columns[j].Name == "FB" || dgv_FBList.Columns[j].Name == "Start Date" || dgv_FBList.Columns[j].Name == "End Date")
                        {
                            dgv_FBList.Columns[j].Visible = true;
                        }
                        else if (dgv_FBList.Columns[j].Name.Contains(teamname))
                        {
                            dgv_FBList.Columns[j].Visible = true;
                        }
                        else
                        {
                            dgv_FBList.Columns[j].Visible = false;
                        }
                    }
                }
            }
        }
예제 #2
0
        private void BindDataSource(PrePlanner preplanner)
        {
            dgv_AvailableIssues.DataSource = preplanner.DT_AvailIssues;
            dgv_AvailableIssues.Columns["Start FB"].Visible = false;
            dgv_AvailableIssues.Columns["End FB"].Visible   = false;
            dgv_AvailableIssues.Columns["Ori Eff"].Visible  = false;


            dgv_UntouchableIssues.DataSource = preplanner.DT_UntouchableIssues;
            dgv_UntouchableIssues.Columns["Start FB"].Visible = false;
            dgv_UntouchableIssues.Columns["End FB"].Visible   = false;
            dgv_UntouchableIssues.Columns["Ori Eff"].Visible  = false;
        }
예제 #3
0
        // public DataTable DT_FB;
        // public DataTable DT_Rel;

        private void LoadFB()
        {
            dgv_FBList.DataSource = null; //每次打开清空内容

            /*
             * DataTable dt_xls_dates = FeatureBuild.excelToDataSet("FZM FBP tool.xlsb", "Feature Build,Start Date,End Date", "Dates");                         //调用GetData方发写上Excel文件所在的路径,这样就能获取到Excel表里面的数据了
             * DataTable dt_xls_cap = FeatureBuild.excelToDataSet("FZM FBP tool.xlsb", "Capacities,FT_FZ01_Dev,FT_FZ02_Dev", "cap");                         //调用GetData方发写上Excel文件所在的路径,这样就能获取到Excel表里面的数据了
             *
             * var dt_dates = FeatureBuild.FormatDataTableDates(dt_xls_dates);
             * var dt_cap = FeatureBuild.FormatDataTableCap(dt_xls_cap);
             * DT_Rel = FeatureBuild.FormatDataTableRelease(dt_xls_dates);
             *
             * DT_FB = FeatureBuild.MergeDataTable(dt_dates, dt_cap);
             */
            PrePlanner.load_fb();
            dgv_FBList.DataSource  = PrePlanner.DT_FB;
            dgv_Release.DataSource = PrePlanner.DT_REL;
        }
예제 #4
0
        private void dgv_STO_CellContentClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dgv_STO.Columns[e.ColumnIndex].Name == "col_Preplan")
            {
                if ((STO_RUN_STAT)dgv_STO.Rows[e.RowIndex].Cells["col_runstat"].Value == STO_RUN_STAT.RUNNING)
                {
                    MessageBox.Show("Already Running");
                }
                else if ((STO_RUN_STAT)dgv_STO.Rows[e.RowIndex].Cells["col_runstat"].Value == STO_RUN_STAT.TO_RUN)
                {
                    var sto_name   = dgv_STO.Rows[e.RowIndex].Cells["col_STO"].Value.ToString();
                    var sto        = ScrumTeamOwner.GetSTO(sto_name);
                    var preplanner = PrePlanner.GetPrePlannerFromTeamCode(sto.Code);


                    preplanner.AsyncProcessSTO();
                }
            }
        }
예제 #5
0
        private void RefreshDgvSTOIssues()
        {
            if (dgv_STO.SelectedRows.Count > 0)
            {
                var    obj        = dgv_STO.SelectedRows[0].Cells["Code"].Value;
                string teamcode   = obj == null ? null : obj.ToString();
                var    preplanner = PrePlanner.GetPrePlannerFromTeamCode(teamcode);
                preplanner.get_FB(DT_FB);
                preplanner.get_REL(DT_Rel);
                if (preplanner != null)
                {
                    bsAvail                          = new BindingSource();
                    bsAvail.DataSource               = preplanner.DT_AvailIssues;
                    dgv_AvailableIssues.DataSource   = bsAvail;
                    bsUntouch                        = new BindingSource();
                    bsUntouch.DataSource             = preplanner.DT_UntouchableIssues;
                    dgv_UntouchableIssues.DataSource = bsUntouch;
                }

                obj = dgv_STO.SelectedRows[0].Cells["col_STO"].Value;
                if (obj != null)
                {
                    string teamname = obj.ToString();
                    for (int j = 0; j < dgv_FBList.ColumnCount; j++)
                    {
                        if (dgv_FBList.Columns[j].Name == "FB" || dgv_FBList.Columns[j].Name == "Start Date" || dgv_FBList.Columns[j].Name == "End Date")
                        {
                            dgv_FBList.Columns[j].Visible = true;
                        }
                        else if (dgv_FBList.Columns[j].Name.Contains(teamname))
                        {
                            dgv_FBList.Columns[j].Visible = true;
                        }
                        else
                        {
                            dgv_FBList.Columns[j].Visible = false;
                        }
                    }
                }
            }
        }