Exemplo n.º 1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            txtDepartmentHeadsRemarks.Visible = true;
            txtDivisionHeadsRemarks.Visible   = true;
            txtDepartmentHeadsRemarks.Enabled = false;
            txtDivisionHeadsRemarks.Enabled   = false;

            txtDepartmentHeadsRemarks.Text = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "1");
            txtDivisionHeadsRemarks.Text   = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "2");

            lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + ")";
            this.MakeCart();
            if (EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "1").ToString() == Request.Cookies["Speedo"]["UserName"].ToString())
            {
                txtDepartmentHeadsRemarks.Enabled = true;
                btnApprove.Text = "Approved";
            }
            if (EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "2").ToString() == Request.Cookies["Speedo"]["UserName"].ToString())
            {
                txtDivisionHeadsRemarks.Enabled = true;
                btnApprove.Text = "Read and Commented";
            }
        }
    }
Exemplo n.º 2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + ")";
         this.MakeCart();
         this.LoadDSLs();
     }
 }
Exemplo n.º 3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + ")";
     this.MakeCart();
     lblDeptApprover.Text           = "(" + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") + ")";
     lblDepartmentHeadsRemarks.Text = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "1");
     lblDivApprover.Text            = "(" + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") + ")";
     lblDivisionHeadsRemarks.Text   = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "2");
 }
Exemplo n.º 4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        clsSpeedo.Authenticate();
        if (!Page.IsPostBack)
        {
            string strDeptDetails = "", strDivDetails = "";
            string strDeptStatus = "", strDivStatus = "";
            lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + ")";
            this.MakeCart();
            this.LoadContent();
            //lblDeptApprover.Text = "(" + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") + ")";
            try
            {
                lblDepartmentHeadsRemarks.Text = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "1");

                if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") == "F")
                {
                    strDeptStatus = "For Review";
                }
                else if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") == "A")
                {
                    strDeptStatus = "Reviewed";
                }
                else if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") == "F")
                {
                    strDeptStatus = "Disapproved";
                }
                strDeptDetails = "Reviewer: " + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") + "<br />" +
                                 "Status: " + strDeptStatus + "<br />" +
                                 "Remarks: <br />" + EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "1");
                lblDepartmentHeadsRemarks.Text = strDeptDetails;
            }
            catch { }

            //if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") == "F")
            //{
            //    strDivStatus = "For Approval";
            //}
            //else if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") == "A")
            //{
            //    strDivStatus = "Approved";
            //}
            //else if (EmployeeJournalApproval.GetApproverAStatus(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") == "F")
            //{
            //    strDivStatus = "Disapproved";
            //}
            //strDivDetails = "Approver: " + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") + "<br />" +
            //    "Status: " + strDivStatus + "<br />" +
            //    "Remarks: <br />" + EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "2");
            //lblDivisionHeadsRemarks.Text = strDivDetails;
        }
    }
Exemplo n.º 5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + ")";
            this.MakeCart();

            lblDeptApprover.Text     = "(" + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "1") + ")";
            lblDeptRemarks.Text      = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "1");
            lblDivApprover.Text      = "(" + EmployeeJournalApproval.GetApprover(Convert.ToInt16(Request.QueryString["JournalCode"]), "2") + ")";
            lblDivRemarks.Text       = EmployeeJournalApproval.GetRemarks(Convert.ToInt16(Request.QueryString["JournalCode"]), "2");
            ViewState["JournalCode"] = Request.QueryString["JournalCode"].ToString();
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        //DateTime firstDayOfWeek = clsDateTime.FirstDateOfWeek(DateTime.Now.Year, _intThisWeekCode, CultureInfo.CurrentCulture);
        //lblWeekDates.Text = firstDayOfWeek.ToString("MM/dd/yyyy") + " - " + firstDayOfWeek.AddDays(6).ToString("MM/dd/yyyy");

        lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + ")";

        //if (EmployeeJournal.HasExistingJournal(Request.Cookies["Speedo"]["UserName"].ToString(), _intThisWeekCode))
        //{
        //    using (EmployeeJournal objEmployeeJouurnal = new EmployeeJournal())
        //    {
        //        objEmployeeJouurnal.WeekCode = _intThisWeekCode;
        //        objEmployeeJouurnal.WeekYear = DateTime.Now.Year.ToString();
        //        objEmployeeJouurnal.CreatedBy = Request.Cookies["Speedo"]["UserName"].ToString();
        //        objEmployeeJouurnal.Fill();
        //        ckeContents.Text = objEmployeeJouurnal.Contents;

        //    }
        //}
    }
Exemplo n.º 7
0
    protected void Page_Load(object sender, EventArgs e)
    {
        clsSpeedo.Authenticate();
        this.LoadDueValidation();
        if (!Page.IsPostBack)
        {
            //lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(WeekYear.GetActiveWeekCode())).ToString("MMM dd, yyyy") + ")";
            lblWeekDates.Text = WeekYear.GetWeekName(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString() + " (" + WeekYear.GetDateStart(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + " - " + WeekYear.GetDateEnd(Convert.ToInt16(EmployeeJournal.GetWeekCode(Convert.ToInt16(Request.QueryString["JournalCode"])))).ToString("MMM dd, yyyy") + ")";
            this.MakeCart();
            this.LoadDSLs();
            this.LoadContents();

            if (EmployeeReviewer.GetReviewer(Request.Cookies["Speedo"]["UserName"].ToString()).Length > 0)
            {
                lblReviewer.ForeColor = Color.Black;
                lblReviewer.Text      = EmployeeReviewer.GetReviewer(Request.Cookies["Speedo"]["UserName"].ToString());
            }
            else
            {
                lblReviewer.ForeColor = Color.Red;
                lblReviewer.Text      = "No assigned reviewer.";
            }
        }
    }