예제 #1
0
    private void TxrKpiPoolQuestion()
    {
        DataTable rDt = this.GetQuestionDataTable();

        string strIType = "";
        int    intRow   = rDt.Rows.Count;
        int    intRtn   = 0;

        if (intRow > 0)
        {
            MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Pool_Question objBSC = new MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Pool_Question();

            for (int i = 0; i < intRow; i++)
            {
                strIType = rDt.Rows[i]["ITYPE"].ToString();

                // 지표풀 자체가 삭제될 경우 하위 항목들은 모두 삭제
                if (this.IType == "D")
                {
                    if (strIType == "U" || strIType == "D")
                    {
                        strIType = "D";
                    }
                    else
                    {
                        strIType = "X";
                    }
                }

                if (strIType == "A")
                {
                    intRtn += objBSC.InsertData(int.Parse(rDt.Rows[i]["KPI_POOL_REF_ID"].ToString())
                                                , rDt.Rows[i]["ITEM_NAME"].ToString()
                                                , int.Parse(rDt.Rows[i]["WEIGHT"].ToString())
                                                , int.Parse(rDt.Rows[i]["QUESTION_ORDER"].ToString())
                                                , rDt.Rows[i]["USE_YN"].ToString()
                                                , gUserInfo.Emp_Ref_ID);
                }
                else if (strIType == "U")
                {
                    intRtn += objBSC.UpdateData(int.Parse(rDt.Rows[i]["KPI_POOL_REF_ID"].ToString())
                                                , int.Parse(rDt.Rows[i]["QUESTION_REF_ID"].ToString())
                                                , rDt.Rows[i]["ITEM_NAME"].ToString()
                                                , double.Parse(rDt.Rows[i]["WEIGHT"].ToString())
                                                , int.Parse(rDt.Rows[i]["QUESTION_ORDER"].ToString())
                                                , rDt.Rows[i]["USE_YN"].ToString()
                                                , gUserInfo.Emp_Ref_ID);
                }
                else if (strIType == "D")
                {
                    intRtn += objBSC.DeleteData(int.Parse(rDt.Rows[i]["KPI_POOL_REF_ID"].ToString())
                                                , int.Parse(rDt.Rows[i]["QUESTION_REF_ID"].ToString())
                                                , gUserInfo.Emp_Ref_ID);
                }
            }
        }

        //string strMsg  = "총 ["+ intRow.ToString() +"] 건중 [" + intRtn.ToString() +"]건이 처리되었습니다.";
        //ltrScript.Text = JSHelper.GetAlertScript(strMsg , false);
    }
예제 #2
0
    private void GetKpiPoolQuestionList()
    {
        MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Pool_Question objBSC = new MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Pool_Question();
        DataSet rDs = objBSC.GetAllList(this.IKpiPoolRefID);

        TugrdQuestionItem.Clear();
        TugrdQuestionItem.DataSource = rDs;
        TugrdQuestionItem.DataBind();
    }