Exemple #1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();
            ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
            Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
            this.lblTaskTitle.Text=Model.TaskTitle.ToString();
            this.lblTaskContent.Text=Model.TaskContent.ToString();
            this.lblFromUser.Text=Model.FromUser.ToString();
            this.lblToUserList.Text=Model.ToUserList.ToString();
            this.lblXinXiGouTong.Text=Model.XinXiGouTong.ToString();
            this.lblJinDu.Text=Model.JinDu.ToString()+"%";
            this.lblWanCheng.Text=Model.WanCheng.ToString();
            this.lblNowState.Text=Model.NowState.ToString();
            this.Label1.Text = Model.KSSJ.ToString();
            this.Label2.Text = Model.JSSJ.ToString();
            this.Label3.Text = Model.SFFK.ToString();
            this.Label4.Text = Model.FKSJ.ToString();
            //дϵͳ��־
            ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
            MyRiZhi.UserName = ZWL.Common.PublicMethod.GetSessionValue("UserName");
            MyRiZhi.DoSomething = "�û��鿴���������Ϣ(" + this.lblTaskTitle.Text + ")";
            MyRiZhi.IpStr = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
            MyRiZhi.Add();

        }
    }
Exemple #2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         ZWL.Common.PublicMethod.CheckSession();
         ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
         Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
         this.lblTaskTitle.Text    = Model.TaskTitle.ToString();
         this.lblTaskContent.Text  = Model.TaskContent.ToString();
         this.lblFromUser.Text     = Model.FromUser.ToString();
         this.lblToUserList.Text   = Model.ToUserList.ToString();
         this.lblXinXiGouTong.Text = Model.XinXiGouTong.ToString();
         this.lblJinDu.Text        = Model.JinDu.ToString() + "%";
         this.lblWanCheng.Text     = Model.WanCheng.ToString();
         this.lblNowState.Text     = Model.NowState.ToString();
         this.Label1.Text          = Model.KSSJ.ToString();
         this.Label2.Text          = Model.JSSJ.ToString();
         this.Label3.Text          = Model.SFFK.ToString();
         this.Label4.Text          = Model.FKSJ.ToString();
         //写系统日志
         ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
         MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
         MyRiZhi.DoSomething = "用户查看任务分配信息(" + this.lblTaskTitle.Text + ")";
         MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
         MyRiZhi.Add();
     }
 }
Exemple #3
0
    protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
    {
        ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();

        Model.ID           = int.Parse(Request.QueryString["ID"].ToString());
        Model.TaskTitle    = this.txtTaskTitle.Text.ToString();
        Model.TaskContent  = this.txtTaskContent.Text.ToString();
        Model.FromUser     = this.txtFromUser.Text.ToString();
        Model.ToUserList   = this.txtToUserList.Text.ToString();
        Model.XinXiGouTong = this.txtXinXiGouTong.Text.ToString();
        Model.JinDu        = decimal.Parse(this.txtJinDu.Text);
        Model.WanCheng     = this.txtWanCheng.Text.ToString();
        Model.NowState     = this.DropDownList1.SelectedValue.ToString();
        Model.KSSJ         = DateTime.Parse(this.TextBox3.Text.Trim() + " " + this.DropDownList2.SelectedItem.Text + ":" + this.DropDownList3.SelectedItem.Text + ":00");
        Model.JSSJ         = DateTime.Parse(this.TextBox2.Text.Trim() + " " + this.DropDownList4.SelectedItem.Text + ":" + this.DropDownList5.SelectedItem.Text + ":00");
        Model.FKSJ         = DateTime.Parse(this.TextBox4.Text.Trim() + " " + this.DropDownList6.SelectedItem.Text + ":" + this.DropDownList7.SelectedItem.Text + ":00");
        Model.SFFK         = this.TX.Value;
        Model.Update();

        //发送短信
        SendMainAndSms.SendMessage(CHKSMS, CHKMOB, "您有新的任务需要执行!(" + this.txtTaskTitle.Text + ")", this.txtToUserList.Text.Trim());

        //写系统日志
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "用户修改任务分配信息(" + this.txtTaskTitle.Text + ")";
        MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();

        ZWL.Common.MessageBox.ShowAndRedirect(this, "任务分配信息修改成功!", "TaskFP.aspx");
    }
Exemple #4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();
            ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
            Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
            this.txtTaskTitle.Text=Model.TaskTitle.ToString();
            this.txtTaskContent.Text=Model.TaskContent.ToString();
            this.txtFromUser.Text=Model.FromUser.ToString();
            this.txtToUserList.Text=Model.ToUserList.ToString();
            this.txtXinXiGouTong.Text=Model.XinXiGouTong.ToString();
            this.txtJinDu.Text=Model.JinDu.ToString();
            this.txtWanCheng.Text=Model.WanCheng.ToString();
            this.DropDownList1.SelectedValue=Model.NowState.ToString();
            this.TextBox2.Text = Model.KSSJ.ToString().Split(' ')[0];
            this.DropDownList2.SelectedValue = DateTime.Parse(Model.KSSJ.ToString()).Hour.ToString("D2");
            this.DropDownList3.SelectedValue = DateTime.Parse(Model.KSSJ.ToString()).Minute.ToString("D2");

            this.TextBox3.Text = Model.JSSJ.ToString().Split(' ')[0];
            this.DropDownList4.SelectedValue = DateTime.Parse(Model.JSSJ.ToString()).Hour.ToString("D2");
            this.DropDownList5.SelectedValue = DateTime.Parse(Model.JSSJ.ToString()).Minute.ToString("D2");

            this.TextBox4.Text = Model.FKSJ.ToString().Split(' ')[0];
            this.DropDownList6.SelectedValue = DateTime.Parse(Model.FKSJ.ToString()).Hour.ToString("D2");
            this.DropDownList7.SelectedValue = DateTime.Parse(Model.FKSJ.ToString()).Minute.ToString("D2");
            this.TX.Value = Model.SFFK;
        }
    }
Exemple #5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();
            ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
            Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
            this.txtTaskTitle.Text           = Model.TaskTitle.ToString();
            this.txtTaskContent.Text         = Model.TaskContent.ToString();
            this.txtFromUser.Text            = Model.FromUser.ToString();
            this.txtToUserList.Text          = Model.ToUserList.ToString();
            this.txtXinXiGouTong.Text        = Model.XinXiGouTong.ToString();
            this.txtJinDu.Text               = Model.JinDu.ToString();
            this.txtWanCheng.Text            = Model.WanCheng.ToString();
            this.DropDownList1.SelectedValue = Model.NowState.ToString();
            this.TextBox2.Text               = Model.KSSJ.ToString().Split(' ')[0];
            this.DropDownList2.SelectedValue = DateTime.Parse(Model.KSSJ.ToString()).Hour.ToString("D2");
            this.DropDownList3.SelectedValue = DateTime.Parse(Model.KSSJ.ToString()).Minute.ToString("D2");

            this.TextBox3.Text = Model.JSSJ.ToString().Split(' ')[0];
            this.DropDownList4.SelectedValue = DateTime.Parse(Model.JSSJ.ToString()).Hour.ToString("D2");
            this.DropDownList5.SelectedValue = DateTime.Parse(Model.JSSJ.ToString()).Minute.ToString("D2");

            this.TextBox4.Text = Model.FKSJ.ToString().Split(' ')[0];
            this.DropDownList6.SelectedValue = DateTime.Parse(Model.FKSJ.ToString()).Hour.ToString("D2");
            this.DropDownList7.SelectedValue = DateTime.Parse(Model.FKSJ.ToString()).Minute.ToString("D2");
            this.TX.Value = Model.SFFK;
        }
    }
Exemple #6
0
    protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
    {
        ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();

        Model.ID = int.Parse(Request.QueryString["ID"].ToString());
        Model.TaskTitle=this.txtTaskTitle.Text.ToString();
        Model.TaskContent=this.txtTaskContent.Text.ToString();
        Model.FromUser=this.txtFromUser.Text.ToString();
        Model.ToUserList=this.txtToUserList.Text.ToString();
        Model.XinXiGouTong=this.txtXinXiGouTong.Text.ToString();
        Model.JinDu=decimal.Parse(this.txtJinDu.Text);
        Model.WanCheng=this.txtWanCheng.Text.ToString();
        Model.NowState = this.DropDownList1.SelectedValue.ToString();
        Model.KSSJ = DateTime.Parse(this.TextBox3.Text.Trim() + " " + this.DropDownList2.SelectedItem.Text + ":" + this.DropDownList3.SelectedItem.Text + ":00");
        Model.JSSJ = DateTime.Parse(this.TextBox2.Text.Trim() + " " + this.DropDownList4.SelectedItem.Text + ":" + this.DropDownList5.SelectedItem.Text + ":00");
        Model.FKSJ = DateTime.Parse(this.TextBox4.Text.Trim() + " " + this.DropDownList6.SelectedItem.Text + ":" + this.DropDownList7.SelectedItem.Text + ":00");
        Model.SFFK = this.TX.Value;
        Model.Update();

        //���Ͷ���
        SendMainAndSms.SendMessage(CHKSMS, CHKMOB, "�����µ�������Ҫִ�У�(" + this.txtTaskTitle.Text + ")", this.txtToUserList.Text.Trim());

        //дϵͳ��־
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "�û��޸����������Ϣ(" + this.txtTaskTitle.Text + ")";
        MyRiZhi.IpStr = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();

        ZWL.Common.MessageBox.ShowAndRedirect(this, "���������Ϣ�޸ijɹ���", "TaskFP.aspx");
    }
Exemple #7
0
    protected void ImageButton1_Click(object sender, EventArgs e)
    {
        ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();

        Model.TaskTitle    = this.txtTaskTitle.Text.ToString();
        Model.TaskContent  = this.txtTaskContent.Text.ToString();
        Model.FromUser     = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        Model.ToUserList   = this.txtToUserList.Text.ToString();
        Model.XinXiGouTong = "";
        Model.JinDu        = decimal.Parse("0");
        Model.WanCheng     = "暂无";
        Model.NowState     = "任务添加";
        Model.KSSJ         = DateTime.Parse(this.TextBox3.Value.Trim());
        Model.JSSJ         = DateTime.Parse(this.TextBox2.Value.Trim());
        Model.FKSJ         = DateTime.Parse(this.TextBox4.Value.Trim());
        Model.SFFK         = this.TX.Value;
        Model.Add();

        //发送短信
        SendMainAndSms.SendMessage(CHKSMS, CHKMOB, "您有新的任务需要执行!(" + this.txtTaskTitle.Text + ")", this.txtToUserList.Text.Trim());

        //写系统日志
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "用户添加任务分配信息(" + this.txtTaskTitle.Text + ")";
        MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();

        ZWL.Common.MessageBox.ShowAndRedirect(this, "任务分配信息添加成功!", "TaskFP.aspx");
    }
Exemple #8
0
    protected void ImageButton1_Click(object sender, EventArgs e)
    {
        ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();

        Model.TaskTitle = this.txtTaskTitle.Text.ToString();
        Model.TaskContent = this.txtTaskContent.Text.ToString();
        Model.FromUser = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        Model.ToUserList = this.txtToUserList.Text.ToString();
        Model.XinXiGouTong = "";
        Model.JinDu = decimal.Parse("0");
        Model.WanCheng = "����";
        Model.NowState = "�������";
        Model.KSSJ = DateTime.Parse(this.TextBox3.Value.Trim());
        Model.JSSJ = DateTime.Parse(this.TextBox2.Value.Trim());
        Model.FKSJ = DateTime.Parse(this.TextBox4.Value.Trim());
        Model.SFFK = this.TX.Value;
        Model.Add();

        //���Ͷ���
        SendMainAndSms.SendMessage(CHKSMS, CHKMOB, "�����µ�������Ҫִ�У�(" + this.txtTaskTitle.Text + ")", this.txtToUserList.Text.Trim());

        //дϵͳ��־
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "�û�������������Ϣ(" + this.txtTaskTitle.Text + ")";
        MyRiZhi.IpStr = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();

        ZWL.Common.MessageBox.ShowAndRedirect(this, "���������Ϣ��ӳɹ���", "TaskFP.aspx");
    }
Exemple #9
0
 public void DataBindToGridview(string IDList)
 {
     DataEntityDataContext context = new DataEntityDataContext();
     ZWL.BLL.ERPTaskFP MyModel = new ZWL.BLL.ERPTaskFP();
     var T = context.ERPTaskFP.Where(p => p.ID > 0);
     if (IDList.Trim().Length > 0)
     {
         T = T.Where(p => p.ToUserList.Contains(',' + ZWL.Common.PublicMethod.GetSessionValue("UserName") + ',') && IDList.Contains(p.ID.ToString())).OrderByDescending(p => p.ID);
     }
     else
     {
         T = T.Where(p => p.ToUserList.Contains(',' + ZWL.Common.PublicMethod.GetSessionValue("UserName") + ',')).OrderByDescending(p => p.ID);
     }
     EmailList = T.ToList();
 }
Exemple #10
0
 public void DataBindToGridview(string IDList)
 {
     ZWL.BLL.ERPTaskFP MyModel = new ZWL.BLL.ERPTaskFP();
     if (IDList.Trim().Length > 0)
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%' and ID in(" + IDList + ") and FromUser='******' order by ID desc");
     }
     else
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%'  and FromUser='******'  order by ID desc");
     }
     GVData.DataBind();
     LabPageSum.Text     = Convert.ToString(GVData.PageCount);
     LabCurrentPage.Text = Convert.ToString(((int)GVData.PageIndex + 1));
     this.GoPage.Text    = LabCurrentPage.Text.ToString();
 }
Exemple #11
0
 public void DataBindToGridview(string IDList)
 {
     ZWL.BLL.ERPTaskFP MyModel = new ZWL.BLL.ERPTaskFP();
     if (IDList.Trim().Length > 0)
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%' and ID in(" + IDList + ") and ','+ToUserList+',' like '%," + ZWL.Common.PublicMethod.GetSessionValue("UserName") + ",%' order by ID desc");
     }
     else
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%'  and ','+ToUserList+',' like '%," + ZWL.Common.PublicMethod.GetSessionValue("UserName") + ",%'  order by ID desc");
     }
     GVData.DataBind();
     LabPageSum.Text = Convert.ToString(GVData.PageCount);
     LabCurrentPage.Text = Convert.ToString(((int)GVData.PageIndex + 1));
     this.GoPage.Text = LabCurrentPage.Text.ToString();
 }
Exemple #12
0
    public void DataBindToGridview(string IDList)
    {
        DataEntityDataContext context = new DataEntityDataContext();

        ZWL.BLL.ERPTaskFP MyModel = new ZWL.BLL.ERPTaskFP();
        var T = context.ERPTaskFP.Where(p => p.ID > 0);

        if (IDList.Trim().Length > 0)
        {
            T = T.Where(p => p.ToUserList.Contains(',' + ZWL.Common.PublicMethod.GetSessionValue("UserName") + ',') && IDList.Contains(p.ID.ToString())).OrderByDescending(p => p.ID);
        }
        else
        {
            T = T.Where(p => p.FromUser == ZWL.Common.PublicMethod.GetSessionValue("UserName")).OrderByDescending(p => p.ID);
        }
        EmailList = T.ToList();
    }
Exemple #13
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         ZWL.Common.PublicMethod.CheckSession();
         ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
         Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
         this.lblTaskTitle.Text    = Model.TaskTitle.ToString();
         this.lblTaskContent.Text  = Model.TaskContent.ToString();
         this.lblFromUser.Text     = Model.FromUser.ToString();
         this.lblToUserList.Text   = Model.ToUserList.ToString();
         this.lblXinXiGouTong.Text = Model.XinXiGouTong.ToString();
         this.lblJinDu.Text        = Model.JinDu.ToString() + "%";
         this.lblWanCheng.Text     = Model.WanCheng.ToString();
         this.lblNowState.Text     = Model.NowState.ToString();
     }
 }
Exemple #14
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         ZWL.Common.PublicMethod.CheckSession();
         ZWL.BLL.ERPTaskFP Model = new ZWL.BLL.ERPTaskFP();
         Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
         this.lblTaskTitle.Text = Model.TaskTitle.ToString();
         this.lblTaskContent.Text = Model.TaskContent.ToString();
         this.lblFromUser.Text = Model.FromUser.ToString();
         this.lblToUserList.Text = Model.ToUserList.ToString();
         this.lblXinXiGouTong.Text = Model.XinXiGouTong.ToString();
         this.lblJinDu.Text = Model.JinDu.ToString() + "%";
         this.lblWanCheng.Text = Model.WanCheng.ToString();
         this.lblNowState.Text = Model.NowState.ToString();
     }
 }