private void CheckPosGrid(int comp_id, string est_id) { Biz_EstInfos estInfo = new Biz_EstInfos(comp_id, est_id); OwnerTypeMode = BizUtility.GetOwnerType(estInfo.Owner_Type); if (OwnerTypeMode == OwnerType.Dept) { uwgRelGrpPosInfo.Visible = false; uwgRelGrpPosData.Visible = false; trRelPos.Visible = false; trRelPosData.Visible = false; } }
private void GridBinding2(int comp_id, int estterm_ref_id, string est_id) { Biz_DeptEstDetails deptEstDetail = new Biz_DeptEstDetails(); _dtEstScale = deptEstDetail.GetDeptEstDetail(comp_id, estterm_ref_id, 0, est_id).Tables[0]; Biz_DeptPosScales deptPosScale = new Biz_DeptPosScales(); _dtPosScale = deptPosScale.GetDeptPosScale(comp_id, estterm_ref_id, 0, est_id).Tables[0]; UltraWebGrid2.Clear(); UltraWebGrid2.DataSource = BizUtility.GetDeptTree(" "); UltraWebGrid2.DataBind(); }
private DataTable GetRelGroupData(int comp_id, string est_id, int estterm_ref_id) { Biz_EmpInfos empInfo = new Biz_EmpInfos(); Biz_RelGroupInfos relGrpInfo = new Biz_RelGroupInfos(); Biz_RelGroupTgtMaps relGrpTgtMap = new Biz_RelGroupTgtMaps(); DataTable dataTable = relGrpTgtMap.GetDataTableSchema(); DataRow dataRow = null; DataTable dtRelGrp = relGrpInfo.GetRelGroupInfo(comp_id, "", est_id, estterm_ref_id).Tables[0]; foreach (DataRow dataRowRelGrp in dtRelGrp.Rows) { DataTable dtTgt = null; string rel_grp_id = dataRowRelGrp["REL_GRP_ID"].ToString(); string where_sentence = ""; where_sentence = BizUtility.GetRelGroupWhereString(COMP_ID , EST_ID , ESTTERM_REF_ID , rel_grp_id , "TM"); if (OwnerTypeMode == OwnerType.Dept) { dtTgt = empInfo.GetRelDeptList("WHERE", where_sentence, "TM").Tables[0]; } else if (OwnerTypeMode == OwnerType.Emp_User) { dtTgt = empInfo.GetRelEmpList("WHERE", where_sentence, "TM").Tables[0]; } foreach (DataRow dataRowTgt in dtTgt.Rows) { dataRow = dataTable.NewRow(); dataRow["COMP_ID"] = comp_id; dataRow["REL_GRP_ID"] = rel_grp_id; dataRow["EST_ID"] = est_id; dataRow["ESTTERM_REF_ID"] = estterm_ref_id; dataRow["TGT_DEPT_ID"] = dataRowTgt["TGT_DEPT_ID"]; dataRow["TGT_EMP_ID"] = dataRowTgt["TGT_EMP_ID"]; dataRow["DATE"] = DateTime.Now; dataRow["USER"] = EMP_REF_ID; dataTable.Rows.Add(dataRow); } } return(dataTable); }
private void InitControlValue() { WebCommon.SetEstTermDropDownList(ddlEstTermInfo); int intEstTermId = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); WebCommon.SetTermMonthDropDownList(ddlEstTermMonth, intEstTermId); WebCommon.SetEstDeptDropDownList(ddlEstDept, intEstTermId, true, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlEstDept, BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID)); Biz_Com_Code_Info objCode = new Biz_Com_Code_Info(); objCode.getResultMethod(ddlResultMethod, "", true, 120); objCode.GetKpiType(ddlKpiGroupRefID, "", true, 120); }
protected void lnkLanguage_Click(object sender, EventArgs e) { try { Session.Timeout = 180; DataSet ds = new DataSet(); ds = Session["IntroDetails"] as DataSet; ds.Tables[0].DefaultView.RowFilter = ""; DataTable dt = ds.Tables[0]; string SortExp = "Language"; if (Session["SortDirec"] == null) { Session["SortDirec"] = "Ascending"; lnkLanguage.Text = "Language ⇓"; } else if (Session["SortDirec"].ToString() == "") { Session["SortDirec"] = "Ascending"; lnkLanguage.Text = "Language ⇓"; } else if (Session["SortDirec"].ToString() == "Ascending") { Session["SortDirec"] = "Descending"; lnkLanguage.Text = "Language ⇑"; } else { Session["SortDirec"] = "Ascending"; lnkLanguage.Text = "Language ⇓"; } lnkMarketSpecialist.Text = "Market Specialist ↓ ↑"; lnkDateSort.Text = "Date ↓ ↑"; lnkStatus.Text = "Status ↓ ↑"; lnkCustomerEmail.Text = "Customer Email ↓ ↑"; if (dt != null) { BizUtility.GridSortForReport(txthdnSortOrder, SortExp, grdIntroInfo, 0, dt, Session["SortDirec"].ToString()); } } catch (Exception ex) { throw ex; } }
protected void grdUsers_Sorting(object sender, GridViewSortEventArgs e) { try { DataTable dt = new DataTable(); dt = Session["AllusersData"] as DataTable; if (dt != null) { BizUtility.GridSort(txthdnSortOrder, e, grdUsers, 0, dt); } } catch (Exception ex) { throw ex; } }
public int VIEWROLE;//임원, 팀장, 사원 구분 #endregion #region --> Page_Load() protected void Page_Load(object sender, EventArgs e) { //좌측메뉴설정 base.SetMenuControl(true, true, true); if (!IsPostBack) { chartMM.Visible = false; chartDal.Visible = false; NotPostBackSetting(); this.IEstTermRefID = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); this.IYmd = PageUtility.GetByValueDropDownList(ddlMonthInfo); this.IisAdmin = (User.IsInRole(ROLE_ADMIN) ? "Y" : "N"); if (this.IisAdmin == "Y") { //WebCommon.SetComDeptDropDownList(ddlDeptList, true, gUserInfo.Emp_Ref_ID); //PageUtility.FindByValueDropDownList(ddlDeptList, this.IDEPT_ID); this.IDeptID = BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID); WebCommon.SetComDeptDropDownList(ddlDeptList, false, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlDeptList, IDeptID); } else { BindDeptList(); } this.IDeptID = BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID); DoBinding(IEstTermRefID, IDeptID); } else { } this.IEstTermRefID = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); this.IYmd = PageUtility.GetByValueDropDownList(ddlMonthInfo); this.IDeptID = PageUtility.GetIntByValueDropDownList(ddlDeptList); this.UltraWebGrid1.Columns.FromKey("CHAMPION_NAME").Header.Caption = this.GetText("LBL_00001", "챔피언"); }
protected void ibnSearch_Click(object sender, ImageClickEventArgs e) { BindingData(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , GraphType , DataType); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, tdImgBox.Controls); BizUtility.SetButtonVisibleByEstJobID(EST_JOB_IDS , tdImgBox.Controls , COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID); }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { EST_JOB_ID = "JOB_18"; DropDownListCommom.BindComp(ddlCompID, lblCompTitle); DropDownListCommom.BindEstTerm(ddlEstTermRefID); DropDownListCommom.BindDefaultValue(ddlEstTermSubID, "----------", ""); DropDownListCommom.BindDefaultValue(ddlEstTermStepID, "----------", ""); UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("DEPT_NAME").Hidden = true; UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("EMP_NAME").Hidden = true; UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("POS_CLS_NAME").Hidden = true; UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("POS_RNK_NAME").Hidden = true; UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("POS_DUT_NAME").Hidden = true; UltraWebGrid2.DisplayLayout.Bands[0].Columns.FromKey("POS_GRP_NAME").Hidden = true; ibnSearch.Attributes.Add("onclick", "return Search();"); iBtnDeptRemove.Attributes.Add("onclick", "return confirm('선택된 부서를 삭제하시겠습니까?');"); iBtnEmpRemove.Attributes.Add("onclick", "return confirm('선택된 사원을 삭제하시겠습니까?');"); ibnConfirm.Attributes.Add("onclick", "return confirm('피평가자 질의매핑을 확정하시겠습니까?')"); ibnConfirmCancel.Attributes.Add("onclick", "return confirm('확정을 취소하시겠습니까?')"); } COMP_ID = WebUtility.GetIntByValueDropDownList(ddlCompID); EST_ID = hdfSearchEstID.Value; ESTTERM_REF_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermRefID); ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); if (ddlEstTermStepID.Visible) { ESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } else { ESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } Q_OBJ_ID = hdfQObjID.Value; ltrScript.Text = ""; }
private void InitControlValue() { WebCommon.SetEstTermDropDownList(ddlEstTermInfo); int intEstTermId = (ddlEstTermInfo.Items.Count > 0) ? int.Parse(ddlEstTermInfo.SelectedValue) : 0; WebCommon.SetComDeptDropDownList(ddlEstDept, true); PageUtility.FindByValueDropDownList(ddlEstDept, BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID)); Biz_Com_Code_Info objCode = new Biz_Com_Code_Info(); objCode.getResultMethod(ddlResultInput, "", true, 0); objCode.GetKpiType(ddlKpiGroupRefID, "", true, 0); //if (User.IsInRole(ROLE_ADMIN)) //{ // iBtnConfirm.Visible = true; // iBtnCancel.Visible = true; //} //else //{ // iBtnConfirm.Visible = false; // iBtnCancel.Visible = false; //} lblCopyText.Style.Add("vertical-align", "middle"); ddlEsttermCopy.Style.Add("vertical-align", "middle"); TermInfos objTerm = new TermInfos(); TermInfos objTermOpen = new TermInfos(objTerm.GetOpenEstTermID()); if (objTermOpen.Estterm_ref_id > 0) { ddlEsttermCopy.Items.Add(new ListItem(objTermOpen.Estterm_name, objTermOpen.Estterm_ref_id.ToString())); } else { lblCopyText.Visible = false; ddlEsttermCopy.Visible = false; iBtnKpiCopy.Visible = false; } }
private void DoInitControl() { WebCommon.SetEstTermDropDownList(ddlEstTermInfo); this.IESTTERM_REF_ID = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); WebCommon.SetTermMonthDropDownList(ddlEstTermMonth, this.IESTTERM_REF_ID); this.IYMD = PageUtility.GetByValueDropDownList(ddlEstTermMonth); WebCommon.SetComDeptDropDownList(ddlEstDept, true, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlEstDept, BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID)); Biz_Com_Code_Info objCode = new Biz_Com_Code_Info(); objCode.GetKpiType(ddlKpiGroupRefID, "", true, 120); WebCommon.SetKpiCategoryTopActiveDropDownList(ddlKpiCategoryTop, true, "Y"); WebCommon.SetKpiCategoryMidActiveDropDownList(ddlKpiCategoryMid, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), "Y"); WebCommon.SetKpiCategoryLowActiveDropDownList(ddlKpiCategoryLow, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), PageUtility.GetIntByValueDropDownList(ddlKpiCategoryMid), "Y"); }
private void InitControlValue() { WebCommon.SetEstTermDropDownList(ddlEstTermInfo); int intEstTermId = (ddlEstTermInfo.Items.Count > 0) ? int.Parse(ddlEstTermInfo.SelectedValue) : 0; WebCommon.SetTermMonthDropDownList(ddlEstTermMonth, intEstTermId); //WebCommon.SetComDeptDropDownList(ddlEstDept, true); //WebCommon.SetEstDeptDropDownList(ddlEstDept, intEstTermId, true, gUserInfo.Emp_Ref_ID); WebCommon.SetComDeptDropDownList(ddlEstDept, true, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlEstDept, BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID)); Biz_Com_Code_Info objCode = new Biz_Com_Code_Info(); objCode.getResultMethod(ddlResultMethod, "", true, 120); objCode.GetKpiType(ddlKpiGroupRefID, "", true, 120); this.IESTTERM_REF_ID = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); this.IYMD = PageUtility.GetByValueDropDownList(ddlEstTermMonth); }
public void SetKpiListExceptMine() { int iTxrUser = gUserInfo.Emp_Ref_ID; int iComDeptId = 0; Biz_Bsc_Mbo_Kpi_Weight objBSC = new Biz_Bsc_Mbo_Kpi_Weight(); // 팀원이 속한 MBO지표 : 구분 -> N 부서코드 -> 로그인사용자 부서 // 나의지표 : 구분 -> N 부서코드 -> 0 // 팀 지표 : 구분 -> Y 부서코드 -> 로그인사용자 부서 // 전체 : 구분 -> '' 부서코드 -> 0 if (PageUtility.GetByValueDropDownList(ddlGubun) == "Y" || PageUtility.GetByValueDropDownList(ddlGubun) == "H") { iComDeptId = BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID); } string gubun = PageUtility.GetByValueDropDownList(ddlGubun); if (gubun.Equals("H")) { gubun = "N"; } DataSet rDs = objBSC.GetKpiListExceptMyKpi (PageUtility.GetIntByValueDropDownList(ddlEstTermInfo) , iTxrUser , "" , txtKpiCode.Text , txtKpiName.Text , "Y" , "" , iComDeptId , "" , gubun , iTxrUser); ugrdKpiList.Clear(); ugrdKpiList.DataSource = rDs; ugrdKpiList.DataBind(); }
private void DoInitControl() { WebCommon.SetEstTermDropDownList(ddlEstTermInfo); this.IESTTERM_REF_ID = PageUtility.GetIntByValueDropDownList(ddlEstTermInfo); MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Group bizBSC = new MicroBSC.BSC.Biz.Biz_Bsc_Kpi_Group(); DataTable dtGroup = bizBSC.GetIssueGroup(this.IESTTERM_REF_ID, 0); ddlGroup.DataValueField = "GROUP_CODE"; ddlGroup.DataTextField = "GROUP_NAME"; ddlGroup.DataSource = dtGroup; ddlGroup.DataBind(); WebCommon.SetComDeptDropDownList(ddlComDept, true); PageUtility.FindByValueDropDownList(ddlComDept, BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID)); MicroBSC.Biz.Common.Biz.Biz_Com_Code_Info objCode = new MicroBSC.Biz.Common.Biz.Biz_Com_Code_Info(); objCode.GetKpiType(ddlKpiGroupRefID, "", true, 120); ugrdGroupList.Columns.FromKey("CHAMPION_NAME").Header.Caption = GetText("LBL_00001", "챔피언"); ugrdKpiList.Columns.FromKey("CHAMPION_EMP_NAME").Header.Caption = GetText("LBL_00001", "챔피언"); }
protected void Page_Load(object sender, EventArgs e) { ESTTERM_REF_ID = WebUtility.GetRequestByInt("ESTTERM_REF_ID"); YMD = WebUtility.GetRequest("YMD"); M_ID = WebUtility.GetRequestByInt("M_ID"); S_ID = WebUtility.GetRequestByInt("S_ID"); AREA_ID = WebUtility.GetRequestByInt("AREA_ID"); //ESTTERM_REF_ID = 1000; //YMD = "201001"; //M_ID = 1; //S_ID = 1; if (!Page.IsPostBack) { BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnEdit); //ibnSave.Visible = true; if (!ibnSave.Visible && !ibnCancel.Visible) { txtContent.Toolbar.Enabled = false; txtContent.ReadOnly = true; txtContent.TabStripDisplay = false; } if (ibnEdit.Visible) { tr01.Height = "35px"; } else { tr01.Height = "10px"; } SetData(); } ltrScript.Text = ""; }
private void DoInitControl() { this.IDEPT_ID = BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID); WebCommon.SetEstTermDropDownList(ddlEstTerm); WebCommon.SetComDeptDropDownList(ddlComDept, true, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlComDept, this.IDEPT_ID); Biz_Com_Code_Info objCom = new Biz_Com_Code_Info(); objCom.GetKpiType(ddlKpiGroup, "", true, 120); DataSet dsCode = objCom.GetCodeListPerCategory("BS0014", "Y"); ddlMboType.DataValueField = "ETC_CODE"; ddlMboType.DataTextField = "CODE_NAME"; ddlMboType.DataSource = dsCode; ddlMboType.DataBind(); ddlMboType.Items.Insert(0, new ListItem(":: 전체 ::", "")); WebCommon.SetKpiCategoryTopActiveDropDownList(ddlKpiCategoryTop, true, "Y"); WebCommon.SetKpiCategoryMidActiveDropDownList(ddlKpiCategoryMid, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), "Y"); WebCommon.SetKpiCategoryLowActiveDropDownList(ddlKpiCategoryLow, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), PageUtility.GetIntByValueDropDownList(ddlKpiCategoryMid), "Y"); if (User.IsInRole(ROLE_ADMIN)) { txtKpiCode.ReadOnly = txtKpiName.ReadOnly = txtChampionName.ReadOnly = false; ddlComDept.Enabled = ddlKpiGroup.Enabled = ddlMboType.Enabled = ddlKpiCategoryTop.Enabled = ddlKpiCategoryMid.Enabled = ddlKpiCategoryLow.Enabled = true; //iBtnDraft.Visible = ImgBtnPrint.Visible = false; } else { txtKpiCode.ReadOnly = txtKpiName.ReadOnly = txtChampionName.ReadOnly = true; ddlComDept.Enabled = ddlKpiGroup.Enabled = ddlMboType.Enabled = ddlKpiCategoryTop.Enabled = ddlKpiCategoryMid.Enabled = ddlKpiCategoryLow.Enabled = false; txtChampionName.Text = gUserInfo.Emp_Name; iBtnDraft.Visible = ImgBtnPrint.Visible = true; } ImgBtnPrint.OnClientClick = "return OpenDraftPrint('" + Biz_Type.app_draft_select + "')"; }
protected void Page_Load(object sender, EventArgs e) { COMP_ID = GetRequestByInt("COMP_ID"); EST_ID = GetRequest("EST_ID"); ESTTERM_REF_ID = GetRequestByInt("ESTTERM_REF_ID"); ESTTERM_SUB_ID = GetRequestByInt("ESTTERM_SUB_ID"); ESTTERM_STEP_ID = GetRequestByInt("ESTTERM_STEP_ID"); EST_JOB_ID = "JOB_32"; YEAR_YN = GetRequest("YEAR_YN"); MERGE_YN = GetRequest("MERGE_YN"); if (!Page.IsPostBack) { bool isOK = CheckValidation(ltrScript); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnSearchAll); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnConfirmAssingPosBiz); if (!isOK) { return; } EST_EMP_ID = EMP_REF_ID; BindingPosBizByTgt(); BindingTgtEmp(EST_EMP_ID); ibnSave.Attributes.Add("onclick", "return confirm('피평가자의 직무를 저장하시겠습니까?');"); ibnConfirmAssingPosBiz.Attributes.Add("onclick", "return confirm('피평가자의 직무를 확정하시겠습니까?');"); } TGT_EMP_ID = DataTypeUtility.GetToInt32(hdfTgtEmpID.Value); TGT_POS_KND_ID = hdfTgtPosKndID.Value; ltrScript.Text = ""; }
private void DoBindingData() { this.IESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); if (MERGE_YN.Equals("Y")) { this.IESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } else { this.IESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } Biz_BiasDatas bizBiasData = new Biz_BiasDatas(); DataTable dtBiasData = bizBiasData.GetBiasData(this.ICOMP_ID, this.IEST_ID, this.IESTTERM_REF_ID, this.IESTTERM_SUB_ID, this.IESTTERM_STEP_ID, this.IBIAS_GRP_ID); ugrdBias.DataSource = dtBiasData; ugrdBias.DataBind(); if (ugrdBias.Rows.Count == 0) { ddlPointType.Visible = ibtnInsert.Visible = ibtnDownload.Visible = false;//ibtnConfirm.Visible = } else { //평가마감되었는지 확인 BizUtility.SetButtonVisibleByEstJobID(this.IEST_JOB_IDS , ibtnCalc , this.ICOMP_ID , this.IEST_ID , this.IESTTERM_REF_ID , this.IESTTERM_SUB_ID , this.IESTTERM_STEP_ID); ibtnInsert.Visible = ddlPointType.Visible = ibtnCalc.Visible;//ibtnConfirm.Visible = ibtnDownload.Visible = true; } lblRowCount.Text = ugrdBias.Rows.Count.ToString(); }
private void BindingGrid(int comp_id , string est_id , int estterm_ref_id , int estterm_sub_id , string q_obj_id) { int tgt_emp_id = 0; Biz_EstInfos estInfo = new Biz_EstInfos(comp_id, est_id); OwnerTypeMode = BizUtility.GetOwnerType(estInfo.Owner_Type); if (OwnerTypeMode == OwnerType.Dept) { UltraWebGrid1.DisplayLayout.Bands[0].Columns.FromKey("TGT_EMP_NAME").Hidden = true; UltraWebGrid1.DisplayLayout.Bands[0].Columns.FromKey("TGT_POS_CLS_NAME").Hidden = true; UltraWebGrid1.DisplayLayout.Bands[0].Columns.FromKey("TGT_POS_DUT_NAME").Hidden = true; UltraWebGrid1.DisplayLayout.Bands[0].Columns.FromKey("TGT_POS_GRP_NAME").Hidden = true; UltraWebGrid1.DisplayLayout.Bands[0].Columns.FromKey("TGT_POS_RNK_NAME").Hidden = true; } Biz_QuestionDeptEmpMaps questionDeptEmpMap = new Biz_QuestionDeptEmpMaps(); DataSet ds = questionDeptEmpMap.GetQuestionEmpMapping(comp_id , estterm_ref_id , estterm_sub_id , 0 , est_id , q_obj_id , 0 , 0 , OwnerTypeMode); UltraWebGrid1.DataSource = ds; UltraWebGrid1.DataBind(); lblRowCount.Text = ds.Tables[0].Rows.Count.ToString(); }
private void DoInitControl() { this.IDEPT_ID = BizUtility.GetDeptID(gUserInfo.Emp_Ref_ID); WebCommon.SetComDeptDropDownList(ddlComDeptRight, true, gUserInfo.Emp_Ref_ID); PageUtility.FindByValueDropDownList(ddlComDeptRight, this.IDEPT_ID); WebCommon.SetEstTermDropDownList(ddlEstTerm); Biz_Com_Code_Info objCom = new Biz_Com_Code_Info(); objCom.GetKpiType(ddlKpiGroup, "", true, 0); WebCommon.SetKpiCategoryTopActiveDropDownList(ddlKpiCategoryTop, true, "Y"); WebCommon.SetKpiCategoryMidActiveDropDownList(ddlKpiCategoryMid, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), "Y"); WebCommon.SetKpiCategoryLowActiveDropDownList(ddlKpiCategoryLow, true, PageUtility.GetIntByValueDropDownList(ddlKpiCategoryTop), PageUtility.GetIntByValueDropDownList(ddlKpiCategoryMid), "Y"); if (!User.IsInRole(ROLE_ADMIN)) { txtChampionNameRight.Text = gUserInfo.Emp_Name; } this.ImageButton1.Visible = false; this.ImageButton2.Visible = false; }
protected void ibnSave_Click(object sender, ImageClickEventArgs e) { UltraGridRow row; Biz_Datas data = new Biz_Datas(); DataTable dataTable = data.GetDataTableSchema(); for (int i = 0; i < UltraWebGrid1.Rows.Count; i++) { row = UltraWebGrid1.Rows[i]; TemplatedColumn ckb_col = (TemplatedColumn)row.Band.Columns.FromKey("selchk"); CheckBox ckbSelect = (CheckBox)((CellItem)ckb_col.CellItems[row.BandIndex]).FindControl("cBox"); TemplatedColumn txt_col = (TemplatedColumn)row.Band.Columns.FromKey("CTRL_POINT"); TextBox txtPoint = (TextBox)((CellItem)txt_col.CellItems[row.BandIndex]).FindControl("txtPoint"); if (ckbSelect.Checked) { if (txtPoint.Text.Trim().Equals("")) { row.Cells.FromKey("POINT").Value = DBNull.Value; } else { row.Cells.FromKey("POINT").Value = DataTypeUtility.GetToDouble(txtPoint.Text); } } } dataTable = UltraGridUtility.GetDataTableByCheckValue(UltraWebGrid1 , "cBox" , "selchk" , new string[] { "TGT_DEPT_ID" , "POINT" } , dataTable); dataTable = DataTypeUtility.FilterSortDataTable(dataTable, "POINT IS NOT NULL"); foreach (DataRow dataRow in dataTable.Rows) { dataRow["COMP_ID"] = COMP_ID; dataRow["EST_ID"] = EST_ID; dataRow["ESTTERM_REF_ID"] = ESTTERM_REF_ID; dataRow["ESTTERM_SUB_ID"] = ESTTERM_SUB_ID; dataRow["ESTTERM_STEP_ID"] = ESTTERM_STEP_ID; dataRow["EST_DEPT_ID"] = BizUtility.GetDeptID(EMP_REF_ID); dataRow["EST_EMP_ID"] = EMP_REF_ID; dataRow["TGT_EMP_ID"] = -1; dataRow["POINT_ORG"] = dataRow["POINT"]; dataRow["DIRECTION_TYPE"] = "SM"; dataRow["POINT_ORG_DATE"] = DateTime.Now; dataRow["POINT_DATE"] = DateTime.Now; dataRow["STATUS_ID"] = "E"; dataRow["STATUS_DATE"] = DateTime.Now; dataRow["DATE"] = DateTime.Now; dataRow["USER"] = EMP_REF_ID; } bool isOK = data.SaveData(dataTable, AllowUpdate); if (isOK) { ltrScript.Text = JSHelper.GetAlertOpenerControlCallBackScript("정상적으로 부서점수를 수기 등록하였습니다.", "lbnReload", true); } else { ltrScript.Text = JSHelper.GetAlertScript("처리 중 오류가 발생하였습니다."); } }
/// <summary> /// 그리드 바인딩 메소드 /// </summary> /// <param name="comp_id"></param> /// <param name="est_id"></param> /// <param name="estterm_ref_id"></param> /// <param name="estterm_sub_id"></param> /// <param name="estterm_step_id"></param> private void GridBidingData(int comp_id , string est_id , int estterm_ref_id , int estterm_sub_id , int estterm_step_id , int est_emp_id , bool isAll) { Biz_EstInfos estInfo = new Biz_EstInfos(comp_id, est_id); if (!estInfo.IsExists(comp_id, est_id)) { ltrScript.Text = JSHelper.GetAlertScript("선택된 회사의 평가정보가 없습니다."); return; } DropDownListCommom.BindEstTermSub(ddlEstTermSubID, comp_id, est_id, ""); DropDownListCommom.BindEstTermStep(ddlEstTermStepID, comp_id, est_id); // 처음 실행될때 if (estterm_sub_id.Equals(0)) { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } // 만약 주기가 년간일 경우 if (YEAR_YN.Equals("Y")) { ESTTERM_SUB_ID = BizUtility.GetEstTermSubIDByYearYN(COMP_ID); } // 만약 차수가 합산일 경우 if (MERGE_YN.Equals("Y")) { ESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } else { // 만약 모든 차수를 보여 줘야하는 경우 if (ESTTERM_STEP_ALL_USE_YN.Equals("Y")) { ESTTERM_STEP_ID = 0; ddlEstTermStepID.Visible = false; } } WebUtility.FindByValueDropDownList(ddlEstTermRefID, estterm_ref_id); if (ddlEstTermSubID.Visible) { WebUtility.FindByValueDropDownList(ddlEstTermSubID, estterm_sub_id); } if (ddlEstTermStepID.Visible) { WebUtility.FindByValueDropDownList(ddlEstTermStepID, estterm_step_id); } // 상태 html HtmlScriptCommon.CreateStatusHtmlTable(tblViewStatus, est_id); Biz_Prj_Data objPrjData = new Biz_Prj_Data(); if (isAll) { est_emp_id = 0; } DataTable dt = objPrjData.GetPrjData(comp_id , est_id , estterm_ref_id , estterm_sub_id , estterm_step_id , 0 , est_emp_id , 0 , YEAR_YN , MERGE_YN).Tables[0]; UltraWebGrid1.Clear(); UltraWebGrid1.DataSource = dt; UltraWebGrid1.DataBind(); lblRowCount.Text = dt.Rows.Count.ToString(); }
protected void Page_Load(object sender, EventArgs e) { EST_JOB_IDS = WebUtility.GetRequest("EST_JOB_IDS"); EST_TGT_TYPE = WebUtility.GetRequest("EST_TGT_TYPE", "EST"); YEAR_YN = WebUtility.GetRequest("YEAR_YN", "N"); MERGE_YN = WebUtility.GetRequest("MERGE_YN", "N"); DEPT_COLUMN_NO_USE_YN = WebUtility.GetRequest("DEPT_COLUMN_NO_USE_YN", "N"); ESTTERM_SUB_ALL_USE_YN = WebUtility.GetRequest("ESTTERM_SUB_ALL_USE_YN", "N"); ESTTERM_STEP_ALL_USE_YN = WebUtility.GetRequest("ESTTERM_STEP_ALL_USE_YN", "N"); if (!Page.IsPostBack) { DropDownListCommom.BindComp(ddlCompID, lblCompTitle); DropDownListCommom.BindEstTerm(ddlEstTermRefID); DropDownListCommom.BindDefaultValue(ddlEstTermSubID, "----------", ""); DropDownListCommom.BindDefaultValue(ddlEstTermStepID, "----------", ""); if (COMP_ID == 0) { COMP_ID = WebUtility.GetIntByValueDropDownList(ddlCompID); } if (ESTTERM_REF_ID == 0) { ESTTERM_REF_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermRefID); } if (ESTTERM_SUB_ID == 0) { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } if (ESTTERM_STEP_ID == 0) { ESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } ibnSearch.Attributes.Add("onclick", "return Search();"); ibnConfirmEstQ.Attributes.Add("onclick", "return confirm('질의평가를 확정하시겠습니까?');"); ibnAggEstTermStep.Attributes.Add("onclick", "return confirm('평가차수 간에 가중치를 반영하여 점수를 집계하시겠습니까?');"); ibnGetPrjPoint.Attributes.Add("onclick", "return confirm('프로젝트 점수를 반영하시겠습니까?');"); ibnProjectToEmpData.Attributes.Add("onclick", "return confirm('사원별 점수로 반영하시겠습니까?');"); if (!WebUtility.GetRequest("EST_ID").Equals("")) { txtSearchEstName.Visible = false; imgEstButton.Visible = false; ibnSearch.Visible = false; hdfSearchEstID.Value = WebUtility.GetRequest("EST_ID"); EST_ID = hdfSearchEstID.Value; GridBidingData(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , EMP_REF_ID , SEARCH_ALL); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, tdImgBox.Controls); BizUtility.SetButtonVisibleByEstJobID(EST_JOB_IDS , tdImgBox.Controls , COMP_ID , hdfSearchEstID.Value , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID); SetConfirmStatusHtml(EST_JOB_IDS); } } COMP_ID = WebUtility.GetIntByValueDropDownList(ddlCompID); EST_ID = hdfSearchEstID.Value; ESTTERM_REF_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermRefID); if (YEAR_YN.Equals("Y")) { ESTTERM_SUB_ID = BizUtility.GetEstTermSubIDByYearYN(COMP_ID); } else { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } if (MERGE_YN.Equals("Y")) { ESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } else { if (ESTTERM_STEP_ALL_USE_YN.Equals("Y")) { ESTTERM_STEP_ID = 0; } else { ESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } } ltrScript.Text = ""; // 상태 html HtmlScriptCommon.CreateStatusHtmlTable(tblViewStatus, EST_ID); }
protected void ibnAggEstTermStep_Click(object sender, ImageClickEventArgs e) { ImageButton ibn = ((ImageButton)sender); string est_job_id = ibn.CommandArgument; bool isJobOK = EstJobUtility.SetConfirmButtonVisible(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , est_job_id , ibnAggEstTermStep , null , "Y" , DateTime.Now , EMP_REF_ID , ltrScript); if (!isJobOK) { return; } Biz_Prj_Data objPrjData = new Biz_Prj_Data(); DataTable dtStatusCheck = objPrjData.GetDataByMergeYN(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , MERGE_YN).Tables[0]; if (dtStatusCheck.Rows.Count != dtStatusCheck.Select("STATUS_ID = 'E'").Length) { ltrScript.Text = JSHelper.GetAlertScript("확정되지 않은 평가정보가 있습니다. 모두 확정된 상태에서 차수별 합산이 가능합니다."); return; } //, BizUtility.GetTotalWeightEstTermStep(COMP_ID, EST_ID) // MERGE_YN 이 N 인 이유는 N인 것만 데이터를 수집해서 집계하기 때문 bool isOK = objPrjData.AggregateEstTermStepEstData(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , BizUtility.GetTotalWeightEstTermStep(COMP_ID, EST_ID) , YEAR_YN , "N"); if (isOK) { ltrScript.Text = JSHelper.GetAlertScript("정상적으로 평가차수에 따른 가중치 집계를 처리하였습니다."); GridBidingData(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , EMP_REF_ID , SEARCH_ALL); SetConfirmStatusHtml(EST_JOB_IDS); } else { //EstJobUtility.SetConfirmButtonVisible(COMP_ID // , EST_ID // , ESTTERM_REF_ID // , ESTTERM_SUB_ID // , ESTTERM_STEP_ID // , est_job_id // , ibn // , null // , "N" // , DateTime.Now // , EMP_REF_ID // , ltrScript); ltrScript.Text = JSHelper.GetAlertScript("가중치 집계 처리 중 오류가 발생하였습니다."); } }
protected internal void UltraWebGrid1_InitializeRow(object sender, RowEventArgs e) { DataRowView drw = (DataRowView)e.Data; BizUtility.SetStatusImage(drw, e.Row.Cells); }
protected void Page_Load(object sender, EventArgs e) { EST_JOB_IDS = WebUtility.GetRequest("EST_JOB_IDS"); EST_TGT_TYPE = WebUtility.GetRequest("EST_TGT_TYPE", "EST"); YEAR_YN = WebUtility.GetRequest("YEAR_YN", "N"); MERGE_YN = WebUtility.GetRequest("MERGE_YN", "N"); DEPT_COLUMN_NO_USE_YN = WebUtility.GetRequest("DEPT_COLUMN_NO_USE_YN", "N"); ESTTERM_SUB_ALL_USE_YN = WebUtility.GetRequest("ESTTERM_SUB_ALL_USE_YN", "N"); ESTTERM_STEP_ALL_USE_YN = WebUtility.GetRequest("ESTTERM_STEP_ALL_USE_YN", "N"); EST_JOB_ID = "JOB_04"; EST_JOB_IDS = "JOB_04"; BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnApplyBiasPoint); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnCalcBiasPoint); if (!Page.IsPostBack) { DropDownListCommom.BindComp(ddlCompID, lblCompTitle); DropDownListCommom.BindEstTerm(ddlEstTermRefID); DropDownListCommom.BindDefaultValue(ddlEstTermSubID, "----------", ""); DropDownListCommom.BindDefaultValue(ddlEstTermStepID, "----------", ""); DropDownListCommom.BindBiasType(ddlBiasTypeID); if (COMP_ID == 0) { COMP_ID = WebUtility.GetIntByValueDropDownList(ddlCompID); } if (ESTTERM_REF_ID == 0) { ESTTERM_REF_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermRefID); } if (ESTTERM_SUB_ID == 0) { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } if (ESTTERM_STEP_ID == 0) { ESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } ibnSearch.Attributes.Add("onclick", "return Search();"); ibnApplyBiasPoint.Attributes.Add("onclick", "return confirm('정말 선택된 조정방식으로 점수를 Bias 조정 하시겠습니까?');"); ibnCalcBiasPoint.Attributes.Add("onclick", "return confirm('Bias 조정점수를 계산 실행하시겠습니까?');"); if (!WebUtility.GetRequest("EST_ID").Equals("")) { txtSearchEstName.Visible = false; imgEstButton.Visible = false; ibnSearch.Visible = false; hdfSearchEstID.Value = WebUtility.GetRequest("EST_ID"); EST_ID = hdfSearchEstID.Value; BindingData(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , GraphType , DataType); //2011.12.27 박효동 : 아래는 없던건데 만들어놓았다..일단은 없이 가자고 함(허성덕과장) //Biz_EstInfos bizEstInfo = new Biz_EstInfos(COMP_ID, EST_ID); //if (bizEstInfo.Bias_Type_ID != "" && bizEstInfo.Bias_YN != "") //{ // PageUtility.FindByValueDropDownList(ddlBiasTypeID, bizEstInfo.Bias_Type_ID); // ddlBiasTypeID.Enabled = false; //} } } COMP_ID = WebUtility.GetIntByValueDropDownList(ddlCompID); EST_ID = hdfSearchEstID.Value; ESTTERM_REF_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermRefID); if (YEAR_YN.Equals("Y")) { ESTTERM_SUB_ID = BizUtility.GetEstTermSubIDByYearYN(COMP_ID); } else { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } if (MERGE_YN.Equals("Y")) { ESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } else { if (ESTTERM_STEP_ALL_USE_YN.Equals("Y")) { ESTTERM_STEP_ID = 0; } else { ESTTERM_STEP_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermStepID); } } DEPT_VALUES = hdfEstDept.Value; ltrScript.Text = ""; }
private void BindingData(int comp_id , string est_id , int estterm_ref_id , int estterm_sub_id , int estterm_step_id , string graphType , BiasType dataType) { Biz_EstInfos estInfo = new Biz_EstInfos(comp_id, est_id); if (!estInfo.IsExists(comp_id, est_id)) { ltrScript.Text = JSHelper.GetAlertScript("선택된 회사의 평가정보가 없습니다."); return; } DropDownListCommom.BindEstTermSub(ddlEstTermSubID, comp_id, est_id, ""); DropDownListCommom.BindEstTermStep(ddlEstTermStepID, comp_id, est_id); // 처음 실행될때 if (estterm_sub_id.Equals(0)) { ESTTERM_SUB_ID = WebUtility.GetIntByValueDropDownList(ddlEstTermSubID); } // 만약 주기가 년간일 경우 if (YEAR_YN.Equals("Y")) { ESTTERM_SUB_ID = BizUtility.GetEstTermSubIDByYearYN(COMP_ID); } // 만약 차수가 합산일 경우 if (MERGE_YN.Equals("Y")) { ESTTERM_STEP_ID = BizUtility.GetEstTermStepIDByMergeYN(COMP_ID); } else { // 만약 모든 차수를 보여 줘야하는 경우 if (ESTTERM_STEP_ALL_USE_YN.Equals("Y")) { ESTTERM_STEP_ID = 0; ddlEstTermStepID.Visible = false; } } WebUtility.FindByValueDropDownList(ddlEstTermRefID, estterm_ref_id); if (ddlEstTermSubID.Visible) { WebUtility.FindByValueDropDownList(ddlEstTermSubID, estterm_sub_id); } if (ddlEstTermStepID.Visible) { WebUtility.FindByValueDropDownList(ddlEstTermStepID, estterm_step_id); } if (estInfo.Owner_Type.Equals("D")) { OwnerTypeMode = OwnerType.Dept; } else { OwnerTypeMode = OwnerType.Emp_User; } ScaleTypeMode = estInfo.Scale_Type; WeightTypeMode = estInfo.Weight_Type; if (estInfo.Bias_YN.Equals("Y")) { BiasYN = YesNo.Yes; } else { BiasYN = YesNo.No; } if (estInfo.Grade_Confirm_YN.Equals("Y")) { GradeConfirmYN = YesNo.Yes; } else { GradeConfirmYN = YesNo.No; } Biz_Datas est_data = new Biz_Datas(); int est_emp_id = 0;; int tgt_dept_id = 0; int tgt_emp_id = 0; if (OwnerTypeMode == OwnerType.Dept) { if (EST_TGT_TYPE.Equals("EST")) { est_emp_id = EMP_REF_ID; tgt_dept_id = 0; tgt_emp_id = 0; } else if (EST_TGT_TYPE.Equals("TGT")) { est_emp_id = 0; tgt_dept_id = BizUtility.GetDeptID(EMP_REF_ID); tgt_emp_id = -1; } } else if (OwnerTypeMode == OwnerType.Emp_User) { if (EST_TGT_TYPE.Equals("EST")) { est_emp_id = EMP_REF_ID; tgt_dept_id = 0; tgt_emp_id = 0; } else if (EST_TGT_TYPE.Equals("TGT")) { est_emp_id = 0; tgt_dept_id = 0; tgt_emp_id = EMP_REF_ID; } } if (OwnerTypeMode == OwnerType.Dept && COL_DEPT_TO_EMP_DATA.Equals("Y")) { OwnerTypeMode = OwnerType.Emp_User; } else if (OwnerTypeMode == OwnerType.Emp_User && COL_DEPT_TO_EMP_DATA.Equals("Y")) { OwnerTypeMode = OwnerType.Dept; } if (estInfo.Bias_Dept_Use_YN.Equals("Y")) { tdBiasDept.Visible = true; } else { tdBiasDept.Visible = false; hdfEstDept.Value = ""; } BindChart(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , GraphType , DataType , DEPT_VALUES); }
private void DataBindingGrid(int comp_id , string est_id , int estterm_ref_id , int estterm_sub_id , int estterm_step_id , string year_yn , string merge_yn , string owner_type) { _eOwnerType = BizUtility.GetOwnerType(owner_type); Biz_Datas data = new Biz_Datas(); DT_EST_DATA = data.GetData(comp_id , est_id , estterm_ref_id , estterm_sub_id , estterm_step_id , 0 , 0 , 0 , 0 , year_yn , merge_yn , _eOwnerType).Tables[0]; Biz_Grades grade = new Biz_Grades(); DT_GRADE = grade.GetEstGrades(comp_id).Tables[0]; DataTable dataDept = BizUtility.GetDeptTree(" "); if (_eOwnerType == OwnerType.Dept) { dataDept.Columns.Add("B_POINT", typeof(double)); dataDept.Columns.Add("A_POINT", typeof(double)); dataDept.Columns.Add("B_GRADE", typeof(string)); dataDept.Columns.Add("A_GRADE", typeof(string)); dataDept.Columns.Add("IS_EST", typeof(string)); foreach (DataRow dataRow in dataDept.Rows) { dataRow["B_POINT"] = "0"; dataRow["A_POINT"] = "0"; dataRow["B_GRADE"] = "-"; dataRow["A_GRADE"] = "-"; dataRow["IS_EST"] = "N"; } foreach (DataRow drDept in dataDept.Rows) { DataRow[] drEstData = DT_EST_DATA.Select(string.Format("TGT_DEPT_ID = {0}", drDept["DEPT_REF_ID"])); foreach (DataRow dataEstData in drEstData) { drDept["A_POINT"] = DataTypeUtility.GetToDouble(dataEstData["POINT"]); drDept["A_GRADE"] = DataTypeUtility.GetValue(dataEstData["GRADE_ID"]);; drDept["IS_EST"] = "Y"; } } } else if (_eOwnerType == OwnerType.Emp_User) { foreach (DataRow drGrade in DT_GRADE.Rows) { dataDept.Columns.Add("B_" + drGrade["GRADE_ID"].ToString(), typeof(string)); dataDept.Columns.Add("A_" + drGrade["GRADE_ID"].ToString(), typeof(string)); } dataDept.Columns.Add("IS_EST", typeof(string)); foreach (DataRow dataRow in dataDept.Rows) { foreach (DataRow drGrade in DT_GRADE.Rows) { dataRow["B_" + drGrade["GRADE_ID"].ToString()] = "0"; dataRow["A_" + drGrade["GRADE_ID"].ToString()] = "0"; dataRow["IS_EST"] = "N"; } } foreach (DataRow drDept in dataDept.Rows) { DataRow[] drEstData = DT_EST_DATA.Select(string.Format("TGT_DEPT_ID = {0}", drDept["DEPT_REF_ID"])); foreach (DataRow dataEstData in drEstData) { if (dataEstData["GRADE_ID"] != DBNull.Value) { drDept["A_" + DataTypeUtility.GetValue(dataEstData["GRADE_ID"])] = DataTypeUtility.GetToInt32(drDept["A_" + DataTypeUtility.GetValue(dataEstData["GRADE_ID"])]) + 1; } drDept["IS_EST"] = "Y"; } } DataRow dr = dataDept.NewRow(); dr["DEPT_REF_ID"] = -9999; dr["DEPT_NAME"] = "<div align='center'><b>합 계</b></center>"; dr["IS_EST"] = "T"; dataDept.Rows.Add(dr); foreach (DataRow drGrade in DT_GRADE.Rows) { foreach (DataRow drEstSum in dataDept.Rows) { if (DataTypeUtility.GetToInt32(drEstSum["DEPT_REF_ID"]) > 0) { dataDept.Rows[dataDept.Rows.Count - 1]["B_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])] = DataTypeUtility.GetToInt32(dataDept.Rows[dataDept.Rows.Count - 1]["B_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])]) + DataTypeUtility.GetToInt32(drEstSum["B_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])]); dataDept.Rows[dataDept.Rows.Count - 1]["A_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])] = DataTypeUtility.GetToInt32(dataDept.Rows[dataDept.Rows.Count - 1]["A_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])]) + DataTypeUtility.GetToInt32(drEstSum["A_" + DataTypeUtility.GetValue(drGrade["GRADE_ID"])]); } } } } UltraWebGrid1.DataSource = dataDept; UltraWebGrid1.DataBind(); //GridView1.DataSource = dataDept; //GridView1.DataBind(); }
private void BindChart(int comp_id , string est_id , int estterm_ref_id , int estterm_sub_id , int estterm_step_id , string graphType , BiasType biasType , string dept_values) { if (tdBiasDept.Visible && hdfEstDept.Value.Trim().Equals("")) { ltrScript.Text = JSHelper.GetAlertScript("Bias 조정을 위한 부서 범위를 선택하세요."); return; } Biz_Datas data = new Biz_Datas(); string query = data.GetBiasQueryScript(comp_id , est_id , estterm_ref_id , estterm_sub_id , estterm_step_id , biasType.ToString() , dept_values); if (graphType.Equals("Radar")) { //try //{ BindRadarChart(Chart1 , query , biasType , ChartImageType.Flash); //} //catch(Exception ex) //{ // ltrScript.Text = JSHelper.GetAlertScript("Bias할 수 있는 데이터가 아닙니다." + ); // return; //} } else if (graphType.Equals("LowHigh")) { //try //{ BindRangeColumnChart(Chart1 , query , biasType , ChartImageType.Flash); //} //catch(Exception ex) //{ // ltrScript.Text = JSHelper.GetAlertScript("Bias할 수 있는 데이터가 아닙니다."); // return; //} } BizUtility.SetButtonVisibleByEstJobID(EST_JOB_IDS , ibnApplyBiasPoint , COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID); BizUtility.SetButtonVisibleByEstJobID(EST_JOB_IDS , ibnCalcBiasPoint , COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID); ddlBiasTypeID.Visible = ibnApplyBiasPoint.Visible; }
protected void Page_Load(object sender, EventArgs e) { COMP_ID = WebUtility.GetRequestByInt("COMP_ID"); EST_ID = WebUtility.GetRequest("EST_ID"); ESTTERM_REF_ID = WebUtility.GetRequestByInt("ESTTERM_REF_ID"); ESTTERM_SUB_ID = WebUtility.GetRequestByInt("ESTTERM_SUB_ID"); ESTTERM_STEP_ID = WebUtility.GetRequestByInt("ESTTERM_STEP_ID"); EST_DEPT_ID = WebUtility.GetRequestByInt("EST_DEPT_ID"); EST_EMP_ID = WebUtility.GetRequestByInt("EST_EMP_ID"); TGT_DEPT_ID = WebUtility.GetRequestByInt("TGT_DEPT_ID"); TGT_EMP_ID = WebUtility.GetRequestByInt("TGT_EMP_ID"); EST_TGT_TYPE = WebUtility.GetRequest("EST_TGT_TYPE", "EST"); READ_ONLY_YN = WebUtility.GetRequest("READ_ONLY_YN", "N"); _estInfos = new Biz_EstInfos(COMP_ID, EST_ID); _q_item_desc_use_yn = _estInfos.Q_Item_Desc_Use_YN; _tgt_opinion_yn = _estInfos.Tgt_Opinion_YN; _feedback_yn = _estInfos.FeedBack_YN; _tgt_send_type = BizUtility.GetTgtSendType(_tgt_opinion_yn, _feedback_yn); _tgt_pos_biz_use_yn = _estInfos.Q_Tgt_Pos_Biz_Use_YN; if (!Page.IsPostBack) { //이전평가차수질의지내용보기가 설정되어있고, 현재차수가 1차수이상일때만 divPreviousControl.Visible = false; Biz_EstInfos bizEstInfo = new Biz_EstInfos(COMP_ID, EST_ID); if (bizEstInfo.Question_Previous_Step_YN.Trim() == "Y" && ESTTERM_STEP_ID > 2) { Biz_TermStepEstMaps bizTermStepEstMap = new Biz_TermStepEstMaps(); DataSet dsTermStepMap = bizTermStepEstMap.GetTermStepEstMap(COMP_ID, EST_ID); if (dsTermStepMap.Tables[0].Rows.Count > 0) { if (dsTermStepMap.Tables[0].Select(string.Format("ESTTERM_STEP_ID > 1 AND ESTTERM_STEP_ID < {0}", ESTTERM_STEP_ID)).Length > 0) { this.IPREVIOUS_STEP_VISIBLE = true; DataRow[] drArr = dsTermStepMap.Tables[0].Select(string.Format("ESTTERM_STEP_ID > 1 AND ESTTERM_STEP_ID < {0}", ESTTERM_STEP_ID), "ESTTERM_STEP_ID ASC"); for (int i = 0; i < drArr.Length; i++) { ddlStep.Items.Insert(i, new ListItem(drArr[i]["ESTTERM_STEP_NAME"].ToString(), drArr[i]["ESTTERM_STEP_ID"].ToString())); } ddlStep.SelectedIndex = ddlStep.Items.Count - 1; //this.IESTTERM_STEP_PREVIOUS_SELECT = WebUtility.GetIntByValueDropDownList(ddlStep); divPreviousControl.Visible = true; } } } } if (READ_ONLY_YN.Equals("N")) { Biz_TermInfos termInfos = new Biz_TermInfos(ESTTERM_REF_ID); Biz_TermSubs termSubs = new Biz_TermSubs(COMP_ID, ESTTERM_SUB_ID); Biz_TermSteps termSteps = new Biz_TermSteps(COMP_ID, ESTTERM_STEP_ID); Biz_EmpInfos estEmpInfos = new Biz_EmpInfos(EST_EMP_ID); Biz_EmpInfos tgtEmpInfos = new Biz_EmpInfos(TGT_EMP_ID); Biz_DeptInfos estDeptInfo = new Biz_DeptInfos(EST_DEPT_ID); Biz_DeptInfos tgtDeptInfo = new Biz_DeptInfos(TGT_DEPT_ID); Biz_Datas data = new Biz_Datas(COMP_ID , EST_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , ESTTERM_STEP_ID , EST_DEPT_ID , EST_EMP_ID , TGT_DEPT_ID , TGT_EMP_ID); _status_style_id = _estInfos.Status_Style_ID; Biz_QuestionDeptEmpMaps questionDeptEmpMaps = new Biz_QuestionDeptEmpMaps(COMP_ID , ESTTERM_REF_ID , ESTTERM_SUB_ID , 0 , EST_ID , "" , TGT_DEPT_ID , TGT_EMP_ID , _estInfos.Owner_Type); if (_tgt_pos_biz_use_yn.Equals("N")) { if (questionDeptEmpMaps.Q_Obj_ID == null) { ltrScript.Text = JSHelper.GetAlertScript("피평가자(부서)에 대한 평가질의서가 매핑되지 않았습니다. 성과평가 관리자에게 문의하세요.", true); return; } } else { } // 의견상신 : X, 피드백 : O if (_tgt_send_type.Equals("FBK")) { if (EST_TGT_TYPE.Equals("EST")) { _status_id = "O"; ibnSaveOpinion.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; // 창을 띄은 사람이 평가자 인지 체크 if (EST_EMP_ID == EMP_REF_ID) { ibnSaveEst.Visible = true; } else { ibnSaveEst.Visible = false; // 롤에 따른 버튼 권한이 있는지 확인 BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnSaveEst); } } else if (EST_TGT_TYPE.Equals("TGT")) { _status_id = "P"; ibnSaveEst.Visible = false; ibnSaveOpinion.Visible = false; // 창을 띄은 사람이 피평가자 인지 체크 if (TGT_EMP_ID == EMP_REF_ID) { ibnFeedbackAgree.Visible = true; ibnFeedbackReject.Visible = true; } else { ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; // 롤에 따른 버튼 권한이 있는지 확인 BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnFeedbackAgree); BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnFeedbackReject); } if (!_status_style_id.Equals("0003")) { ltrScript.Text = JSHelper.GetAlertScript("피드백 5단계 평가으로 설정되어야 합니다.", true); return; } } } else // 그외 사항에서는 { if (EST_TGT_TYPE.Equals("EST")) { _status_id = "P"; ibnSaveOpinion.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; // 창을 띄은 사람이 평가자 인지 체크 if (EST_EMP_ID == EMP_REF_ID) { ibnSaveEst.Visible = true; } else { ibnSaveEst.Visible = false; // 롤에 따른 버튼 권한이 있는지 확인 BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnSaveEst); } } else if (EST_TGT_TYPE.Equals("TGT")) { _status_id = "O"; ibnSaveEst.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; // 창을 띄은 사람이 피평가자 인지 체크 if (TGT_EMP_ID == EMP_REF_ID) { ibnSaveOpinion.Visible = true; } else { ibnSaveOpinion.Visible = false; // 롤에 따른 버튼 권한이 있는지 확인 BizUtility.SetButtonVisibleCommandNameByRolID(EMP_REF_ID, ibnSaveOpinion); } if (!_status_style_id.Equals("0002")) { ltrScript.Text = JSHelper.GetAlertScript("의견상신 5단계 평가으로 설정되어야 합니다.", true); return; } } } if (_tgt_send_type.Equals("FBK")) { if (data.Status_ID.Equals("E")) { ibnSaveEst.Visible = false; ibnSaveOpinion.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; } if (data.Status_ID.Equals("C")) { ibnSaveEst.Visible = false; } } else { if (data.Status_ID.Equals("E")) { ibnSaveEst.Visible = false; ibnSaveOpinion.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; } } Q_OBJ_ID = questionDeptEmpMaps.Q_Obj_ID; EST_NAME = _estInfos.Est_Name; ESTTERM_REF_NAME = termInfos.EstTerm_Name; ESTTERM_SUB_NAME = termSubs.EstTerm_Sub_Name; ESTTERM_STEP_NAME = termSteps.EstTerm_Step_Name; EST_EMP_NAME = estEmpInfos.Emp_Name; TGT_EMP_NAME = tgtEmpInfos.Emp_Name; EST_DEPT_NAME = estDeptInfo.Dept_Name; TGT_DEPT_NAME = tgtDeptInfo.Dept_Name; } else { Q_OBJ_ID = WebUtility.GetRequest("Q_OBJ_ID"); ibnSaveEst.Visible = false; ibnSaveOpinion.Visible = false; ibnFeedbackAgree.Visible = false; ibnFeedbackReject.Visible = false; } if (!Page.IsPostBack) { DataListBinding(); DoBindingPreviousStepQeustion(); ibnSaveEst.Attributes.Add("onclick", "if(confirm('평가내용을 저장하시겠습니까?')) return ConfirmQuesiton();else return false;"); ibnSaveOpinion.Attributes.Add("onclick", "return confirm('평가자에게 의견을 상신하시겠습니까?');"); ibnFeedbackAgree.Attributes.Add("onclick", "return confirm('평가질의에 동의하십니까?');"); ibnFeedbackReject.Attributes.Add("onclick", "return confirm('평가질의에 거절하십니까?');"); } ltrScript.Text = ""; }