Exemplo n.º 1
0
    public void SetApprovalList()
    {
        Biz_Com_Approval_Prc objApp = new Biz_Com_Approval_Prc();

        string sSDate = base.GetYMDFromDateTime((DateTime)wdcSDate.Value, "-") + " 00:00:00";
        string sEDate = base.GetYMDFromDateTime((DateTime)wdcEDate.Value, "-") + " 23:59:59";

        DateTime dtSDate = Convert.ToDateTime(sSDate);
        DateTime dtEDate = Convert.ToDateTime(sEDate);

        DataSet rDs = objApp.GetToDraftList(gUserInfo.Emp_Ref_ID, PageUtility.GetByValueDropDownList(ddlBizType), PageUtility.GetIntByValueDropDownList(ddlComDept), dtSDate, dtEDate);

        ugrdAppList.Clear();
        ugrdAppPrc.Clear();

        if (rDs.Tables.Count > 0)
        {
            ugrdAppList.DataSource = rDs.Tables[0].DefaultView;
            ugrdAppList.DataBind();
            lblRowCount.Text = rDs.Tables[0].Rows.Count.ToString();
        }
        else
        {
            lblRowCount.Text = "0";
        }
    }
Exemplo n.º 2
0
    /// <summary>
    /// 실적마감율 세팅, 결재할 문서, 커뮤니케이션 문서 존재하는지여부
    /// 공지사항 존재여부
    /// </summary>
    private void SetGlobalStatus()
    {
        MicroBSC.Estimation.Dac.TermInfos    objTermYY = new MicroBSC.Estimation.Dac.TermInfos();
        MicroBSC.BSC.Biz.Biz_Bsc_Term_Detail objTerm   = new MicroBSC.BSC.Biz.Biz_Bsc_Term_Detail();

        int    intEstTerm = objTermYY.GetOpenEstTermID();
        string sFinishMon = objTerm.GetReleasedMonth();

        lblFinishMonth.Text = sFinishMon.Substring(0, 4) + "/" + sFinishMon.Substring(4, 2);

        //실적마감율 세팅
        Biz_lib_MenuControl biz = new Biz_lib_MenuControl();

        lblFinishRate.Text = biz.GetFinishRate(intEstTerm, sFinishMon).ToString();

        // 커뮤니케이션 리스트가 있는지?
        Biz_Bsc_Communication_User objUser = new Biz_Bsc_Communication_User();

        iBtnCommunication.Src = (objUser.GetIsNewListPerUser(this.ILogInUserId)) ? "~/images/NHIT/btn_top_02.gif" : "~/images/NHIT/btn_top_02.gif";//있음:없음

        // 결재할 문서가 있는지?
        //Biz_Bsc_Kpi_Result objBSC = new Biz_Bsc_Kpi_Result();
        //iBtnConfirm.Src = (objBSC.GetIsNewDraftPerUser(intEstTerm, sFinishMon, this.ILogInUserId)) ? "~/images/btn/top_bu_k01_b.gif" : "~/images/btn/top_bu_k01.gif";
        Biz_Com_Approval_Prc objBSC = new Biz_Com_Approval_Prc();
        DataSet rDs = objBSC.GetToDraftList(this.ILogInUserId, "");

        if (rDs.Tables.Count > 0)
        {
            iBtnConfirm.Src = (rDs.Tables[0].Rows.Count > 0) ? "~/images/NHIT/btn_top_01.gif" : "~/images/NHIT/btn_top_01.gif";//있음:없음
        }
        else
        {
            iBtnConfirm.Src = "~/images/NHIT/btn_top_01.gif";
        }


        // 공지사항이 있는지 또는 읽었는지
        Biz_Bsc_Communication_Notice objNot = new Biz_Bsc_Communication_Notice();

        this.IisHaveNoticeYN = (objNot.GetCurrentNotice() ? "Y" : "N");

        string strCookieKey = "NOTICE_" + objNot.Inotice_ref_id.ToString();

        if (Request.Cookies[strCookieKey] != null)
        {
            DateTime dtCookieDate = Convert.ToDateTime(Server.HtmlEncode(Request.Cookies[strCookieKey].Expires.ToShortTimeString()));
            if (dtCookieDate < DateTime.Now)
            {
                this.IisHaveNoticeYN = "N";
            }
        }

        // 회사 이미지로고 세팅
        tblTopMenu.Style.Add(HtmlTextWriterStyle.BackgroundImage, ConfigurationManager.AppSettings["TopMenuLogo.ImageUrl"].ToString());
        imgBottomCopy.ImageUrl = ConfigurationManager.AppSettings["BottomPageCopy.ImageUrl"].ToString();
    }
Exemplo n.º 3
0
    //결제아이콘표시
    private bool isResult()
    {
        // 결재할 문서가 있는지?
        //Biz_Bsc_Kpi_Result objBSC = new Biz_Bsc_Kpi_Result();
        //iBtnConfirm.Src = (objBSC.GetIsNewDraftPerUser(intEstTerm, sFinishMon, this.ILogInUserId)) ? "~/images/btn/top_bu_k01_b.gif" : "~/images/btn/top_bu_k01.gif";
        Biz_Com_Approval_Prc objBSC = new Biz_Com_Approval_Prc();
        DataSet rDs = objBSC.GetToDraftList(this.ILogInUserId, "");

        if (rDs.Tables.Count > 0)
        {
            if (rDs.Tables[0].Rows.Count > 0)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }
        else
        {
            return(false);
        }


        //tmcode 를 가져옵니다.
//        StrategyMapInfos stgMapInfo = new StrategyMapInfos();
//        int tmcode                  = stgMapInfo.GetTMCODE();

//        //해당유저의 부서코드를 가져옵니다.
//        int dept_id = 0;
//        string query = @"
//                SELECT CASE A.DEPT_LEVEL WHEN 4 THEN
//                            (SELECT EST_DEPT_REF_ID
//                                FROM EST_DEPT_INFO
//                                WHERE EST_DEPT_REF_ID = A.UP_EST_DEPT_ID)
//                            ELSE
//                           A.EST_DEPT_REF_ID
//                    END AS EST_DEPT_REF_ID
//                    , UP_EST_DEPT_ID
//                FROM
//                      EST_DEPT_INFO A
//                    , REL_DEPT_EMP B
//                WHERE A.DEPT_REF_ID= B.DEPT_REF_ID
//                AND B.EMP_REF_ID=" + gUserInfo.Emp_Ref_ID.ToString() + @"
//                ORDER BY A.ESTTERM_REF_ID DESC";

//        DataSet ds = gDbAgent.FillDataSet(query, "data0");
//        try
//        {
//            dept_id = int.Parse(ds.Tables[0].Rows[0][0].ToString());
//        }
//        catch
//        {
//            dept_id = 0;
//        }

//        RoleBases rb        = new RoleBases();
//        string sQuery = "";

//        if (Context.User.IsInRole(rb.ROLE_ADMIN))//admin 권한일경우 전부서의 결재를 여부를 가져옴
//        {

//            sQuery = @"
//                    SELECT A.RESULT
//                    FROM   KPI_RESULT A
//	                       ,KPI_INFO B
//                    WHERE A.KPI_REF_ID = B.KPI_REF_ID
//                        AND A.CHECKSTATUS > 0
//                        AND A.CONFIRMSTATUS = 0
//--                    AND A.TMCODE<=" + tmcode.ToString() + @"";
//        }
//        else
//        {
//            sQuery = @"
//                    SELECT A.RESULT
//                    FROM   KPI_RESULT A
//	                       ,KPI_INFO B
//                    WHERE A.KPI_REF_ID=B.KPI_REF_ID
//--                    AND EST_DEPT_ID=" + dept_id.ToString() + @"
//                    AND B.CONFIRM_EMP_ID=" + gUserInfo.Emp_Ref_ID + @"
//                    AND A.CHECKSTATUS>0
//                    AND A.CONFIRMSTATUS=0
//--                    AND A.TMCODE<=" + tmcode.ToString() + @"
//                    ";
//        }

//        ds = gDbAgent.FillDataSet(sQuery, "data0");

//        if (ds.Tables[0].Rows.Count > 0)//결재할것들이 있는지 여부
//        {
//            return true;
//        }
//        else
//        {
//            return false;
//        }
    }
Exemplo n.º 4
0
    private void InitControlValue()
    {
        string pathAndQuery = HttpContext.Current.Request.Url.PathAndQuery;
        string sUrl         = HttpContext.Current.Request.Url.AbsolutePath;

        // ERRORINFO.ASPX는 쿼리스트링이 고정되지 않은 페이지 이므로 예외처리한다. (해당페이지 권한시 FULL_PATH로 처리되므로 무한루프일수 있다.)
        //if (sUrl.Substring(sUrl.LastIndexOf("/") + 1).ToUpper() != "ERRORINFO.ASPX")
        //    sUrl = HttpContext.Current.Request.Url.PathAndQuery;

        lblEmpName.Text = gUserInfo.Emp_Name;
        tblTopMenu.Style.Add(HtmlTextWriterStyle.BackgroundImage, ConfigurationManager.AppSettings["TopMenuLogo.ImageUrl"].ToString());


        MicroBSC.Estimation.Dac.TermInfos    objTermYY = new MicroBSC.Estimation.Dac.TermInfos();
        MicroBSC.BSC.Biz.Biz_Bsc_Term_Detail objTerm   = new MicroBSC.BSC.Biz.Biz_Bsc_Term_Detail();

        int    intEstTerm = objTermYY.GetOpenEstTermID();
        string sFinishMon = objTerm.GetReleasedMonth();


        #region KPI실적 마감월 셋팅
        lblFinishMonth.Text = sFinishMon.Substring(0, 4) + "/" + sFinishMon.Substring(4, 2);
        #endregion

        #region KPI실적 마감율 셋팅
        Biz_lib_MenuControl biz = new Biz_lib_MenuControl();
        lblFinishRate.Text = biz.GetFinishRate(intEstTerm, sFinishMon).ToString();
        #endregion

        #region 커뮤니케이션 리스트가 있는지?
        MicroBSC.BSC.Biz.Biz_Bsc_Communication_User objUser = new MicroBSC.BSC.Biz.Biz_Bsc_Communication_User();
        iBtnCommunication.Src = (objUser.GetIsNewListPerUser(this.ILogInUserId)) ? "~/images/btn/top_bu_k02_b.gif" : "~/images/btn/top_bu_k02.gif";

        // 결재할 문서가 있는지?
        //Biz_Bsc_Kpi_Result objBSC = new Biz_Bsc_Kpi_Result();
        //iBtnConfirm.Src = (objBSC.GetIsNewDraftPerUser(intEstTerm, sFinishMon, this.ILogInUserId)) ? "~/images/btn/top_bu_k01_b.gif" : "~/images/btn/top_bu_k01.gif";
        Biz_Com_Approval_Prc objBSC = new Biz_Com_Approval_Prc();
        DataSet rDs = objBSC.GetToDraftList(this.ILogInUserId, "");
        if (rDs.Tables.Count > 0)
        {
            iBtnConfirm.Src = (rDs.Tables[0].Rows.Count > 0) ? "~/images/btn/top_bu_k01_b.gif" : "~/images/btn/top_bu_k01.gif";
        }
        else
        {
            iBtnConfirm.Src = "~/images/btn/top_bu_k01.gif";
        }


        // 공지사항이 있는지 또는 읽었는지
        MicroBSC.BSC.Biz.Biz_Bsc_Communication_Notice objNot = new MicroBSC.BSC.Biz.Biz_Bsc_Communication_Notice();
        this.IisHaveNoticeYN = (objNot.GetCurrentNotice() ? "Y" : "N");

        string strCookieKey = "NOTICE_" + objNot.Inotice_ref_id.ToString();
        if (Request.Cookies[strCookieKey] != null)
        {
            DateTime dtCookieDate = Convert.ToDateTime(Server.HtmlEncode(Request.Cookies[strCookieKey].Expires.ToShortTimeString()));
            if (dtCookieDate < DateTime.Now)
            {
                this.IisHaveNoticeYN = "N";
            }
        }

        #endregion

        #region 타이틀 셋팅
        if (sUrl.Substring(sUrl.LastIndexOf("/") + 1).ToUpper() != "EST110104.ASPX" &&
            sUrl.Substring(sUrl.LastIndexOf("/") + 1).ToUpper() != "EST110104_01.ASPX")
        {
            lblTitle.Text = biz.GetMenuTitle(pathAndQuery);
        }
        else
        {
            lblTitle.Text = biz.GetMenuTitle(sUrl);
        }

        if (lblTitle.Text.Trim().Equals(""))
        {
            imgTitle.Visible = false;
        }
        #endregion
    }