예제 #1
0
    protected void iBtnConfirm_Click(object sender, ImageClickEventArgs e)
    {
        int effrctRow = 0;
        Biz_QuestionDeptEmpMaps questionDeptEmpMaps = new Biz_QuestionDeptEmpMaps();
        DataTable dataTable = questionDeptEmpMaps.GetDataTableSchema();

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid2
                                                            , new string[] { "TGT_DEPT_ID", "TGT_EMP_ID" }
                                                            , dataTable);

        foreach (DataRow dataRow in dataTable.Rows)
        {
            effrctRow += new MicroBSC.Integration.BSC.Biz.Biz_Bsc_Kpi_Info().KpiAutoInsert(ESTTERM_REF_ID, view_ref_id, stg_ref_id, poo_ref_id,
                                                                                           int.Parse(dataRow["TGT_DEPT_ID"].ToString()), int.Parse(dataRow["TGT_EMP_ID"].ToString()));
        }

        if (effrctRow > 0)
        {
            ltrScript.Text = JSHelper.GetOpenerControlCallBackScript(POSTBACK_CTRL_NAME, true);
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("추가하실 사원을 선택하세요.");
        }
    }
예제 #2
0
    protected void Save_Custom_Col_Value()
    {
        DataTable DT = new DataTable();

        string[] Cols = new string[] { "PRJ_COL_ID", "PRJ_COL_NAME", "PRJ_COL_VALUE" };

        for (int i = 0; i < Cols.Length; i++)
        {
            DT.Columns.Add(Cols[i]);
        }

        DT = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid3, Cols, DT);

        bool Result;

        Result = bizPmsColInfo.Modify_Custom_Col_Value(DT, PRJ_ID, gUserInfo.Emp_Ref_ID.ToString());

        if (Result)
        {
            this.ltrScript.Text = JSHelper.GetAlertScript("저장되었습니다.");
        }
        else
        {
            this.ltrScript.Text = JSHelper.GetAlertScript("저장에 실패하였습니다.");
        }
    }
예제 #3
0
    protected void iBtnConfirm_Click(object sender, ImageClickEventArgs e)
    {
        Biz_QuestionDeptEmpMaps questionDeptEmpMaps = new Biz_QuestionDeptEmpMaps();
        DataTable dataTable = questionDeptEmpMaps.GetDataTableSchema();

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid2
                                                            , new string[] { "TGT_DEPT_ID", "TGT_EMP_ID" }
                                                            , dataTable);

        foreach (DataRow dataRow in dataTable.Rows)
        {
            dataRow["COMP_ID"]         = COMP_ID;
            dataRow["ESTTERM_REF_ID"]  = ESTTERM_REF_ID;
            dataRow["ESTTERM_SUB_ID"]  = ESTTERM_SUB_ID;
            dataRow["ESTTERM_STEP_ID"] = ESTTERM_STEP_ID;
            dataRow["EST_ID"]          = EST_ID;
            dataRow["Q_OBJ_ID"]        = Q_OBJ_ID;
            dataRow["DATE"]            = DateTime.Now;
            dataRow["USER"]            = EMP_REF_ID;
        }

        bool isOK = questionDeptEmpMaps.AddQuestionDeptEmpMap(dataTable);

        if (isOK)
        {
            ltrScript.Text = JSHelper.GetOpenerControlCallBackScript("lbnEmpReload", true);
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("추가하실 사원을 선택하세요.");
        }
    }
예제 #4
0
    protected void ibnSave_Click(object sender, ImageClickEventArgs e)
    {
        UltraGridRow row;

        Biz_DeptOpinionTgtEmps deptOpinionTgtEmp = new Biz_DeptOpinionTgtEmps();
        DataTable dataTable = deptOpinionTgtEmp.GetDataTableSchema();

        for (int i = 0; i < UltraWebGrid1.Rows.Count; i++)
        {
            row = UltraWebGrid1.Rows[i];
            TemplatedColumn hdf_col     = (TemplatedColumn)row.Band.Columns.FromKey("CTRL_EMP");
            HiddenField     hdfTgtEmpID = (HiddenField)((CellItem)hdf_col.CellItems[row.BandIndex]).FindControl("hdfTgtEmpID");

            TemplatedColumn txt_col       = (TemplatedColumn)row.Band.Columns.FromKey("CTRL_EMP");
            TextBox         txtTgtEmpName = (TextBox)((CellItem)txt_col.CellItems[row.BandIndex]).FindControl("txtTgtEmpName");

            if (hdfTgtEmpID.Value.Equals(""))
            {
                row.Cells.FromKey("TGT_EMP_ID").Value = DBNull.Value;
            }
            else
            {
                row.Cells.FromKey("TGT_EMP_ID").Value = DataTypeUtility.GetToDouble(hdfTgtEmpID.Value);
            }
        }

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid1
                                                            , new string[] { "TGT_DEPT_ID", "TGT_EMP_ID" }
                                                            , dataTable);

        dataTable = DataTypeUtility.FilterSortDataTable(dataTable, "TGT_EMP_ID IS NOT NULL");

        foreach (DataRow dataRow in dataTable.Rows)
        {
            dataRow["COMP_ID"]        = COMP_ID;
            dataRow["EST_ID"]         = EST_ID;
            dataRow["TGT_OPINION_YN"] = "Y";
            dataRow["DATE"]           = DateTime.Now;
            dataRow["USER"]           = EMP_REF_ID;
        }

        bool isOK = deptOpinionTgtEmp.SaveDeptOpinionTgtEmp(dataTable, COMP_ID, EST_ID);

        if (isOK)
        {
            ltrScript.Text = JSHelper.GetAlertScript("정상적으로 의견상신 담당자를 설정하였습니다.");
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("처리 중 오류가 발생하였습니다.");
        }
    }
예제 #5
0
    protected void lbnSavePOS_Click(object sender, EventArgs e)
    {
        Biz_DeptPosScales deptPosScale = new Biz_DeptPosScales();
        Biz_DeptInfos     deptInfo     = new Biz_DeptInfos();
        DataTable         dataTable    = deptPosScale.GetDataTableSchema();
        DataTable         dtDept       = deptInfo.GetDataTableSchema();
        DataRow           drRow        = null;

        string[] dept_values = hdfDeptID.Value.Split(',');

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid3
                                                            , new string[] { "SEQ", "POS_ID", "POS_VALUE", "SCALE_ID" }
                                                            , dataTable);

        foreach (string dept_value in dept_values)
        {
            drRow = dtDept.NewRow();
            drRow["DEPT_REF_ID"] = DataTypeUtility.GetToInt32(dept_value);
            dtDept.Rows.Add(drRow);
        }

        if (dataTable.Rows.Count == 0)
        {
            ltrScript.Text = JSHelper.GetAlertScript("적용하려는 부서별 평가방법이 없습니다.");
            return;
        }

        foreach (DataRow dataRow in dataTable.Rows)
        {
            dataRow["COMP_ID"]        = COMP_ID;
            dataRow["EST_ID"]         = EST_ID;
            dataRow["ESTTERM_REF_ID"] = ESTTERM_REF_ID;
            dataRow["DATE"]           = DateTime.Now;
            dataRow["USER"]           = EMP_REF_ID;
        }

        bool isOK = deptPosScale.SaveDeptPosScaleAll(dtDept, dataTable);

        if (isOK)
        {
            ltrScript.Text = JSHelper.GetAlertScript("선택부서의 평가방법을 일괄 적용하였습니다.");

            GridBinding2(COMP_ID, ESTTERM_REF_ID, EST_ID);
            UltraWebGrid3.Clear();
            hdfDeptID.Value = "";
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("정상적으로 처리 않았습니다.");
        }
    }
예제 #6
0
    protected void ibnUpdateEmpRole_Click(object sender, ImageClickEventArgs e)
    {
        UltraGridRow row;

        Biz_EmpRoleRels        empRoleRel        = new Biz_EmpRoleRels();
        Biz_DeptOpinionTgtEmps deptOpinionTgtEmp = new Biz_DeptOpinionTgtEmps();
        DataTable dataTable = deptOpinionTgtEmp.GetDataTableSchema();

        dataTable.Columns.Add("EMP_REF_ID", typeof(int));
        dataTable.Columns.Add("ROLE_REF_ID", typeof(int));

        for (int i = 0; i < UltraWebGrid1.Rows.Count; i++)
        {
            row = UltraWebGrid1.Rows[i];
            TemplatedColumn hdf_col     = (TemplatedColumn)row.Band.Columns.FromKey("CTRL_EMP");
            HiddenField     hdfTgtEmpID = (HiddenField)((CellItem)hdf_col.CellItems[row.BandIndex]).FindControl("hdfTgtEmpID");

            if (hdfTgtEmpID.Value.Equals(""))
            {
                row.Cells.FromKey("TGT_EMP_ID").Value = DBNull.Value;
            }
            else
            {
                row.Cells.FromKey("TGT_EMP_ID").Value = DataTypeUtility.GetToDouble(hdfTgtEmpID.Value);
            }
        }

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid1
                                                            , new string[] { "TGT_EMP_ID" }
                                                            , dataTable);

        dataTable = DataTypeUtility.FilterSortDataTable(dataTable, "TGT_EMP_ID IS NOT NULL");

        foreach (DataRow dataRow in dataTable.Rows)
        {
            dataRow["EMP_REF_ID"]  = dataRow["TGT_EMP_ID"];
            dataRow["ROLE_REF_ID"] = ROLE_REF_ID;
        }

        bool isOK = empRoleRel.SaveEmpRoleRel(dataTable, ROLE_REF_ID);

        if (isOK)
        {
            ltrScript.Text = JSHelper.GetAlertScript("정상적으로 의견상신 담당자 권한을 부여하였습니다.");
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("부여된 권한이 없습니다.");
        }
    }
예제 #7
0
    protected void ibnSavePosAll_Click(object sender, ImageClickEventArgs e)
    {
        Biz_DeptPosScales deptPosScale = new Biz_DeptPosScales();
        Biz_DeptInfos     deptInfo     = new Biz_DeptInfos();
        DataTable         dataTable    = deptPosScale.GetDataTableSchema();
        DataTable         dtDept       = deptInfo.GetDataTableSchema();

        dataTable = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid3
                                                            , new string[] { "SEQ", "POS_ID", "POS_VALUE", "SCALE_ID" }
                                                            , dataTable);

        dtDept = UltraGridUtility.GetDataTableByAllValue(UltraWebGrid2
                                                         , new string[] { "DEPT_REF_ID" }
                                                         , dtDept);

        if (dataTable.Rows.Count == 0)
        {
            ltrScript.Text = JSHelper.GetAlertScript("적용하려는 부서별 평가방법이 없습니다.");
            return;
        }

        foreach (DataRow dataRow in dataTable.Rows)
        {
            dataRow["COMP_ID"]        = COMP_ID;
            dataRow["EST_ID"]         = EST_ID;
            dataRow["ESTTERM_REF_ID"] = ESTTERM_REF_ID;
            dataRow["DATE"]           = DateTime.Now;
            dataRow["USER"]           = EMP_REF_ID;
        }

        bool isOK = deptPosScale.SaveDeptPosScaleAll(dtDept, dataTable);

        if (isOK)
        {
            ltrScript.Text = JSHelper.GetAlertScript("모든 부서의 평가방법을 일괄 적용하였습니다.");

            GridBinding2(COMP_ID, ESTTERM_REF_ID, EST_ID);
            UltraWebGrid3.Clear();
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("정상적으로 처리 않았습니다.");
        }
    }
예제 #8
0
    protected void iBtnConfirm_Click(object sender, ImageClickEventArgs e)
    {
        _iestterm_ref_id = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo);
        _iymd            = PageUtility.GetByValueDropDownList(ddlEstTermMonth, "");

        Biz_Datas est_data    = new Biz_Datas();
        DataSet   _dataSet    = est_data.GetEvaluationDataScheme();
        DataTable _dataTable  = _dataSet.Tables[0];
        DataTable _dataTable2 = _dataSet.Tables[1];
        DataTable _dataTable3 = est_data.GetEvaluationScoreInfo(_iestterm_ref_id);

        _dataTable = UltraGridUtility.GetDataTableByAllValue(ugrdResultTotal
                                                             , new string[] { "EMP_REF_ID", "EMP_CODE"
                                                                              , "ORGANIZATION_POINT", "ORGANIZATION_WEIGHT"
                                                                              , "APPRAISAL_POINT", "APPRAISAL_WEIGHT"
                                                                              , "OTHERS1_POINT", "OTHERS1_WEIGHT"
                                                                              , "OTHERS2_POINT", "OTHERS2_WEIGHT"
                                                                              , "OTHERS3_POINT", "OTHERS3_WEIGHT"
                                                                              , "WEIGHT_SUM", "POINT_SUM"
                                                                              , "POS_GRP_ID" }
                                                             , _dataTable);
        _dataTable = DataTypeUtility.FilterSortDataTable(_dataTable, "EMP_REF_ID IS NOT NULL", "POS_GRP_ID ASC");

        string _pos_grp_id = "";
        double _sum        = 0.0;
        double _sum2       = 0.0;
        int    _n          = 0;
        double _sumPoint   = 0.0;
        double _mean       = 0.0;
        double _stdv       = 0.0;

        for (int i = 0; i < _dataTable.Rows.Count; i++)
        {
            if (_dataTable.Rows[i]["ORGANIZATION_POINT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["ORGANIZATION_POINT"] = 0;
            }
            if (_dataTable.Rows[i]["ORGANIZATION_WEIGHT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["ORGANIZATION_WEIGHT"] = 0;
            }
            if (_dataTable.Rows[i]["APPRAISAL_POINT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["APPRAISAL_POINT"] = 0;
            }
            if (_dataTable.Rows[i]["APPRAISAL_WEIGHT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["APPRAISAL_WEIGHT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS1_POINT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS1_POINT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS1_WEIGHT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS1_WEIGHT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS2_POINT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS2_POINT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS2_WEIGHT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS2_WEIGHT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS3_POINT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS3_POINT"] = 0;
            }
            if (_dataTable.Rows[i]["OTHERS3_WEIGHT"] == DBNull.Value)
            {
                _dataTable.Rows[i]["OTHERS3_WEIGHT"] = 0;
            }

            _dataTable.Rows[i]["ESTTERM_REF_ID"] = _iestterm_ref_id;
            _dataTable.Rows[i]["YY"]             = _iymd.Substring(0, 4);
            _dataTable.Rows[i]["DD"]             = _iymd.Substring(4, 2);
            _sumPoint  = Convert.ToDouble(_dataTable.Rows[i]["ORGANIZATION_POINT"]) * Convert.ToDouble(_dataTable.Rows[i]["ORGANIZATION_WEIGHT"]) / 100;
            _sumPoint += Convert.ToDouble(_dataTable.Rows[i]["APPRAISAL_POINT"]) * Convert.ToDouble(_dataTable.Rows[i]["APPRAISAL_WEIGHT"]) / 100;
            _sumPoint += Convert.ToDouble(_dataTable.Rows[i]["OTHERS1_POINT"]) * Convert.ToDouble(_dataTable.Rows[i]["OTHERS1_WEIGHT"]) / 100;
            _sumPoint += Convert.ToDouble(_dataTable.Rows[i]["OTHERS2_POINT"]) * Convert.ToDouble(_dataTable.Rows[i]["OTHERS2_WEIGHT"]) / 100;
            _sumPoint += Convert.ToDouble(_dataTable.Rows[i]["OTHERS3_POINT"]) * Convert.ToDouble(_dataTable.Rows[i]["OTHERS3_WEIGHT"]) / 100;
            _dataTable.Rows[i]["POINT_SUM"]   = _sumPoint;
            _dataTable.Rows[i]["CREATE_DATE"] = DateTime.Now;
            _dataTable.Rows[i]["CREATE_USER"] = EMP_REF_ID;
            _dataTable.Rows[i]["UPDATE_DATE"] = DateTime.Now;
            _dataTable.Rows[i]["UPDATE_USER"] = EMP_REF_ID;

            if (i == 0)
            {
                _pos_grp_id = _dataTable.Rows[i]["POS_GRP_ID"].ToString();
                _sum        = DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _sum2       = DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]) * DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _n          = 1;
            }
            else if (_pos_grp_id == _dataTable.Rows[i]["POS_GRP_ID"].ToString())
            {
                _sum  += DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _sum2 += DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]) * DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _n    += 1;
            }
            else if (_pos_grp_id != _dataTable.Rows[i]["POS_GRP_ID"].ToString())
            {
                _stdv = Math.Sqrt(((double)_n * _sum2 - _sum * _sum) / ((double)_n * (double)(_n)));
                _mean = _sum / (double)_n;

                DataRow _newRow = _dataTable2.NewRow();
                _newRow["ESTTERM_REF_ID"]     = _iestterm_ref_id;
                _newRow["YY"]                 = _iymd.Substring(0, 4);
                _newRow["DD"]                 = _iymd.Substring(4, 2);
                _newRow["POS_GRP_ID"]         = _pos_grp_id;
                _newRow["GROUP_MEAN"]         = _mean;
                _newRow["STANDARD_DEVIATION"] = _stdv;
                _newRow["CREATE_DATE"]        = DateTime.Now;
                _newRow["CREATE_USER"]        = EMP_REF_ID;
                _newRow["UPDATE_DATE"]        = DateTime.Now;
                _newRow["UPDATE_USER"]        = EMP_REF_ID;
                _dataTable2.Rows.Add(_newRow);

                _pos_grp_id = _dataTable.Rows[i]["POS_GRP_ID"].ToString();
                _sum        = DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _sum2       = DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]) * DataTypeUtility.GetToDouble(_dataTable.Rows[i]["POINT_SUM"]);
                _n          = 1;
            }
            if (i + 1 == _dataTable.Rows.Count)
            {
                _stdv = Math.Sqrt(((double)_n * _sum2 - _sum * _sum) / ((double)_n * (double)(_n)));
                _mean = _sum / (double)_n;

                DataRow _newRow = _dataTable2.NewRow();
                _newRow["ESTTERM_REF_ID"]     = _iestterm_ref_id;
                _newRow["YY"]                 = _iymd.Substring(0, 4);
                _newRow["DD"]                 = _iymd.Substring(4, 2);
                _newRow["POS_GRP_ID"]         = _pos_grp_id;
                _newRow["GROUP_MEAN"]         = _mean;
                _newRow["STANDARD_DEVIATION"] = _stdv;
                _newRow["CREATE_DATE"]        = DateTime.Now;
                _newRow["CREATE_USER"]        = EMP_REF_ID;
                _newRow["UPDATE_DATE"]        = DateTime.Now;
                _newRow["UPDATE_USER"]        = EMP_REF_ID;
                _dataTable2.Rows.Add(_newRow);
            }
        }

        foreach (DataRow _drv in _dataTable2.Rows)
        {
            DataRow[] _dr = _dataTable.Select("POS_GRP_ID = '" + _drv["POS_GRP_ID"].ToString() + "'");
            if (_dr.Length > 0)
            {
                for (int i = 0; i < _dr.Length; i++)
                {
                    if (DataTypeUtility.GetToDouble(_drv["STANDARD_DEVIATION"]) == 0)
                    {
                        _dr[i]["STANDARD_SCORE"] = 0;
                    }
                    else
                    {
                        _dr[i]["STANDARD_SCORE"] = (DataTypeUtility.GetToDouble(_dr[i]["POINT_SUM"])
                                                    - DataTypeUtility.GetToDouble(_drv["GROUP_MEAN"]))
                                                   / DataTypeUtility.GetToDouble(_drv["STANDARD_DEVIATION"]);
                    }
                    DataRow[] _stdRat =
                        _dataTable3.Select(DataTypeUtility.GetToDouble(_dr[i]["STANDARD_SCORE"]) + " > MIN_VALUE AND "
                                           + DataTypeUtility.GetToDouble(_dr[i]["STANDARD_SCORE"]) + " <= MAX_VALUE");
                    if (_stdRat.Length > 0)
                    {
                        _dr[i]["STANDARD_RATING"] = _stdRat[0]["SCORE_CODE"].ToString();
                    }
                    else
                    {
                        _dr[i]["STANDARD_RATING"] = "U";
                    }
                }
            }
        }

        bool isOK = est_data.SaveDataPersonEvaluation(_dataTable, true);

        if (isOK)
        {
            isOK = est_data.SaveDataGroupEvaluation(_dataTable2, true);
            if (isOK)
            {
                ltrScript.Text = JSHelper.GetAlertScript("정상적으로 저장하였습니다.");
                this.SetResultListGrid();
            }
            else
            {
                ltrScript.Text = JSHelper.GetAlertScript("처리 중 오류가 발생하였습니다.");
            }
        }
        else
        {
            ltrScript.Text = JSHelper.GetAlertScript("처리 중 오류가 발생하였습니다.");
        }
    }
예제 #9
0
    protected void ibtnCalc_Click(object sender, ImageClickEventArgs e)
    {
        string selectQuery = string.Empty;
        string joinQuery   = string.Empty;

        Biz_BiasDatas bizBiasData = new Biz_BiasDatas();
        DataTable     dtPointType = bizBiasData.GetBiasColumns(this.ICOMP_ID, this.IEST_ID, "Y", "Y");

        if (dtPointType.Rows.Count > 0)
        {
            DataRow[] drPointType = dtPointType.Select("COL_TYPE = 'USERKEY'", "COL_ORDER ASC");
            foreach (DataRow dr in drPointType)
            {
                selectQuery += @"
        , " + dr["COL_KEY"].ToString() + ".RTNVALUE AS " + dr["COL_KEY"].ToString();
                joinQuery   += @"
LEFT OUTER JOIN " + dr["PROC_NAME"].ToString() + "(@COMP_ID, @EST_ID, @ESTTERM_REF_ID, @ESTTERM_SUB_ID, @ESTTERM_STEP_ID, @BIAS_GRP_ID)  " + dr["COL_KEY"].ToString()
                               + "          ON  " + dr["COL_KEY"].ToString() + ".TGT_EMP_ID = A.EMP_REF_ID";
            }
        }

        DataTable dtBiasData = bizBiasData.CalcBiasData(this.ICOMP_ID, this.IEST_ID, this.IESTTERM_REF_ID, this.IESTTERM_SUB_ID, this.IESTTERM_STEP_ID, this.IBIAS_GRP_ID, selectQuery, joinQuery);

        ugrdBias.DataSource = dtBiasData;
        ugrdBias.DataBind();


        DoSortColumn();

        if (ugrdBias.Rows.Count == 0)
        {
            ibtnInsert.Visible = false;//ibtnConfirm.Visible =
            ltrScript.Text     = JSHelper.GetAlertScript("계산된 데이터가 없습니다.");
        }
        else
        {
            DataTable dtBank = new DataTable();

            string strUserColumnName = string.Empty;
            for (int i = 1; i < 11; i++)
            {
                if (ugrdBias.Columns.FromKey("COL" + i.ToString()) != null)
                {
                    strUserColumnName += "COL" + i.ToString() + ";";
                }
            }

            string[] strUserColumn = { "TGT_DEPT_ID", "TGT_EMP_ID", "TGT_POS_CLS_ID", "TGT_POS_DUT_ID", "TGT_POS_GRP_ID", "TGT_POS_RNK_ID", "", "", "", "", "", "", "", "", "", "" };
            if (strUserColumnName != string.Empty)
            {
                strUserColumnName = strUserColumnName.Substring(0, strUserColumnName.Length - 1);
                for (int i = 0; i < strUserColumnName.Split(';').Length; i++)
                {
                    strUserColumn.SetValue(strUserColumnName.Split(';').GetValue(i).ToString(), 6 + i);
                }
            }


            int cntUserColumnName;
            if (strUserColumnName.Trim().Length == 0)
            {
                cntUserColumnName = 0;
            }
            else
            {
                cntUserColumnName = strUserColumnName.Split(';').Length;
            }


            string[] strFinalColumn = new string[6 + cntUserColumnName];
            for (int i = 0; i < strFinalColumn.Length; i++)
            {
                if (strUserColumn.GetValue(i).ToString() != "")
                {
                    strFinalColumn.SetValue(strUserColumn.GetValue(i).ToString(), i);
                    dtBank.Columns.Add(strUserColumn.GetValue(i).ToString(), (i < 2 ? typeof(int) : typeof(string)));
                }
            }

            //dtBank.Columns.Add("POINT", typeof(double));

            DataTable dtCalcData = UltraGridUtility.GetDataTableByAllValue(ugrdBias
                                                                           , strFinalColumn
                                                                           , dtBank);

            if (dtCalcData.Rows.Count > 0)
            {
                if (bizBiasData.InsertBiasData(this.ICOMP_ID, this.IEST_ID, this.IESTTERM_REF_ID, this.IESTTERM_SUB_ID, this.IESTTERM_STEP_ID, this.IBIAS_GRP_ID, dtCalcData, gUserInfo.Emp_Ref_ID))
                {
                    DoBindingData();
                    ltrScript.Text = JSHelper.GetAlertScript("정상적으로 Bias 조정점수 계산을 완료하였습니다.");
                }
                else
                {
                    ltrScript.Text = JSHelper.GetAlertScript("데이터 적용이 실패하였습니다.\\n" + bizBiasData.errMSG.Replace("\n", ""));
                }
            }
            else
            {
                ltrScript.Text = JSHelper.GetAlertScript("데이터 적용이 실패하였습니다.");
            }
        }
        lblRowCount.Text = ugrdBias.Rows.Count.ToString();
    }