Beispiel #1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();

            ZWL.BLL.ERPKaoQinSetting MyModel = new ZWL.BLL.ERPKaoQinSetting();
            MyModel.GetModel(int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting")));

            string GuiDingTime1 = MyModel.GuiDingTime1;
            this.DropDownList1.SelectedValue = GuiDingTime1.Split(':')[0];
            this.DropDownList2.SelectedValue = GuiDingTime1.Split(':')[1];
            string GuiDingTime2 = MyModel.GuiDingTime2;
            this.DropDownList3.SelectedValue = GuiDingTime2.Split(':')[0];
            this.DropDownList4.SelectedValue = GuiDingTime2.Split(':')[1];
            string GuiDingTime3 = MyModel.GuiDingTime3;
            this.DropDownList5.SelectedValue = GuiDingTime3.Split(':')[0];
            this.DropDownList6.SelectedValue = GuiDingTime3.Split(':')[1];
            string GuiDingTime4 = MyModel.GuiDingTime4;
            this.DropDownList7.SelectedValue = GuiDingTime4.Split(':')[0];
            this.DropDownList8.SelectedValue = GuiDingTime4.Split(':')[1];
            string GuiDingTime5 = MyModel.GuiDingTime5;
            this.DropDownList9.SelectedValue  = GuiDingTime5.Split(':')[0];
            this.DropDownList10.SelectedValue = GuiDingTime5.Split(':')[1];
            string GuiDingTime6 = MyModel.GuiDingTime6;
            this.DropDownList11.SelectedValue = GuiDingTime6.Split(':')[0];
            this.DropDownList12.SelectedValue = GuiDingTime6.Split(':')[1];

            //设定按钮权限
            ImageButton1.Visible = ZWL.Common.PublicMethod.StrIFIn("|106M|", ZWL.Common.PublicMethod.GetSessionValue("QuanXian"));
        }
    }
Beispiel #2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();

            ZWL.BLL.ERPKaoQinSetting MyModel = new ZWL.BLL.ERPKaoQinSetting();
            MyModel.GetModel(int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting")));

            string GuiDingTime1 = MyModel.GuiDingTime1;
            this.DropDownList1.SelectedValue = GuiDingTime1.Split(':')[0];
            this.DropDownList2.SelectedValue = GuiDingTime1.Split(':')[1];
            string GuiDingTime2 = MyModel.GuiDingTime2;
            this.DropDownList3.SelectedValue = GuiDingTime2.Split(':')[0];
            this.DropDownList4.SelectedValue = GuiDingTime2.Split(':')[1];
            string GuiDingTime3 = MyModel.GuiDingTime3;
            this.DropDownList5.SelectedValue = GuiDingTime3.Split(':')[0];
            this.DropDownList6.SelectedValue = GuiDingTime3.Split(':')[1];
            string GuiDingTime4 = MyModel.GuiDingTime4;
            this.DropDownList7.SelectedValue = GuiDingTime4.Split(':')[0];
            this.DropDownList8.SelectedValue = GuiDingTime4.Split(':')[1];
            string GuiDingTime5 = MyModel.GuiDingTime5;
            this.DropDownList9.SelectedValue = GuiDingTime5.Split(':')[0];
            this.DropDownList10.SelectedValue = GuiDingTime5.Split(':')[1];
            string GuiDingTime6 = MyModel.GuiDingTime6;
            this.DropDownList11.SelectedValue = GuiDingTime6.Split(':')[0];
            this.DropDownList12.SelectedValue = GuiDingTime6.Split(':')[1];

            //设定按钮权限
            ImageButton1.Visible = ZWL.Common.PublicMethod.StrIFIn("|106M|", ZWL.Common.PublicMethod.GetSessionValue("QuanXian"));
        }
    }
Beispiel #3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();

            ZWL.BLL.ERPKaoQinSetting MyModel = new ZWL.BLL.ERPKaoQinSetting();
            MyModel.GetModel(int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting")));

            this.Label3.Text = MyModel.GuiDingTime1;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label3.Text) == true)
            {
                this.Label3.Text = "未设置    ";
            }
            this.Label7.Text = MyModel.GuiDingTime2;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label7.Text) == true)
            {
                this.Label7.Text = "未设置    ";
            }
            this.Label11.Text = MyModel.GuiDingTime3;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label11.Text) == true)
            {
                this.Label11.Text = "未设置    ";
            }
            this.Label15.Text = MyModel.GuiDingTime4;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label15.Text) == true)
            {
                this.Label15.Text = "未设置    ";
            }
            this.Label19.Text = MyModel.GuiDingTime5;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label19.Text) == true)
            {
                this.Label19.Text = "未设置    ";
            }
            this.Label23.Text = MyModel.GuiDingTime6;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label23.Text) == true)
            {
                this.Label23.Text = "未设置    ";
            }

            //获取当前已经打了卡的考勤时钟,今日没考勤数据时生成空记录
            GetKaoQin();
        }
    }
Beispiel #4
0
    protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
    {
        ZWL.BLL.ERPKaoQinSetting Model = new ZWL.BLL.ERPKaoQinSetting();
        Model.ID           = int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting"));
        Model.GuiDingTime1 = this.DropDownList1.SelectedItem.Text + ":" + this.DropDownList2.SelectedItem.Text + ":00";
        Model.GuiDingTime2 = this.DropDownList3.SelectedItem.Text + ":" + this.DropDownList4.SelectedItem.Text + ":00";
        Model.GuiDingTime3 = this.DropDownList5.SelectedItem.Text + ":" + this.DropDownList6.SelectedItem.Text + ":00";
        Model.GuiDingTime4 = this.DropDownList7.SelectedItem.Text + ":" + this.DropDownList8.SelectedItem.Text + ":00";
        Model.GuiDingTime5 = this.DropDownList9.SelectedItem.Text + ":" + this.DropDownList10.SelectedItem.Text + ":00";
        Model.GuiDingTime6 = this.DropDownList11.SelectedItem.Text + ":" + this.DropDownList12.SelectedItem.Text + ":00";
        Model.Update();

        //写系统日志
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "用户修改考勤时间设置";
        MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();
        ZWL.Common.MessageBox.ShowAndRedirect(this, "考勤时间设置成功!", "KaoQinSetting.aspx");
    }
Beispiel #5
0
    protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
    {
        ZWL.BLL.ERPKaoQinSetting Model = new ZWL.BLL.ERPKaoQinSetting();
        Model.ID = int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting"));
        Model.GuiDingTime1 = this.DropDownList1.SelectedItem.Text + ":" + this.DropDownList2.SelectedItem.Text + ":00";
        Model.GuiDingTime2 = this.DropDownList3.SelectedItem.Text + ":" + this.DropDownList4.SelectedItem.Text + ":00";
        Model.GuiDingTime3 = this.DropDownList5.SelectedItem.Text + ":" + this.DropDownList6.SelectedItem.Text + ":00";
        Model.GuiDingTime4 = this.DropDownList7.SelectedItem.Text + ":" + this.DropDownList8.SelectedItem.Text + ":00";
        Model.GuiDingTime5 = this.DropDownList9.SelectedItem.Text + ":" + this.DropDownList10.SelectedItem.Text + ":00";
        Model.GuiDingTime6 = this.DropDownList11.SelectedItem.Text + ":" + this.DropDownList12.SelectedItem.Text + ":00";
        Model.Update();

        //写系统日志
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "用户修改考勤时间设置";
        MyRiZhi.IpStr = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();
        ZWL.Common.MessageBox.ShowAndRedirect(this, "考勤时间设置成功!", "KaoQinSetting.aspx");
    }
Beispiel #6
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();

            ZWL.BLL.ERPKaoQinSetting MyModel = new ZWL.BLL.ERPKaoQinSetting();
            MyModel.GetModel(int.Parse(ZWL.DBUtility.DbHelperSQL.GetSHSLInt("select top 1 [ID] FROM ERPKaoQinSetting")));

            this.Label3.Text = MyModel.GuiDingTime1;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label3.Text) == true)
            {
                this.Label3.Text = "未设置    ";
            }
            this.Label7.Text = MyModel.GuiDingTime2;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label7.Text) == true)
            {
                this.Label7.Text = "未设置    ";
            }
            this.Label11.Text = MyModel.GuiDingTime3;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label11.Text) == true)
            {
                this.Label11.Text = "未设置    ";
            }
            this.Label15.Text = MyModel.GuiDingTime4;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label15.Text) == true)
            {
                this.Label15.Text = "未设置    ";
            }
            this.Label19.Text = MyModel.GuiDingTime5;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label19.Text) == true)
            {
                this.Label19.Text = "未设置    ";
            }
            this.Label23.Text = MyModel.GuiDingTime6;
            if (ZWL.Common.PublicMethod.StrIFIn("未设置", this.Label23.Text) == true)
            {
                this.Label23.Text = "未设置    ";
            }

            //获取当前已经打了卡的考勤时钟,今日没考勤数据时生成空记录
            GetKaoQin();
        }
    }