示例#1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            ZWL.Common.PublicMethod.CheckSession();
            ZWL.BLL.ERPCarBaoYang Model = new ZWL.BLL.ERPCarBaoYang();
            Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
            this.lblCarName.Text      = Model.CarName.ToString();
            this.lblBYDate.Text       = Model.BYDate.ToString();
            this.lblJingBanUser.Text  = Model.JingBanUser.ToString();
            this.lblZhuGuanUser.Text  = Model.ZhuGuanUser.ToString();
            this.lblBYQianLCBNum.Text = Model.BYQianLCBNum.ToString();
            this.lblQiYouJinE.Text    = Model.QiYouJinE.ToString();
            this.lblBYJinE.Text       = Model.BYJinE.ToString();
            this.lblWeiXiuJinE.Text   = Model.WeiXiuJinE.ToString();
            this.lblOtherJinE.Text    = Model.OtherJinE.ToString();
            this.lblUserName.Text     = Model.UserName.ToString();
            this.lblTimeStr.Text      = Model.TimeStr.ToString();
            this.lblBackInfo.Text     = Model.BackInfo.ToString();

            //写系统日志
            ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
            MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
            MyRiZhi.DoSomething = "用户查看车辆保养记录信息(" + this.lblCarName.Text + ")";
            MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
            MyRiZhi.Add();
        }
    }
示例#2
0
    protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
    {
        ZWL.BLL.ERPCarBaoYang Model = new ZWL.BLL.ERPCarBaoYang();

        Model.CarName      = this.txtCarName.Text.ToString();
        Model.BYDate       = this.txtBYDate.Text.ToString();
        Model.JingBanUser  = this.txtJingBanUser.Text.ToString();
        Model.ZhuGuanUser  = this.txtZhuGuanUser.Text.ToString();
        Model.BYQianLCBNum = this.txtBYQianLCBNum.Text.ToString();
        Model.QiYouJinE    = this.txtQiYouJinE.Text.ToString();
        Model.BYJinE       = this.txtBYJinE.Text.ToString();
        Model.WeiXiuJinE   = this.txtWeiXiuJinE.Text.ToString();
        Model.OtherJinE    = this.txtOtherJinE.Text.ToString();
        Model.UserName     = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        Model.TimeStr      = DateTime.Now;
        Model.BackInfo     = this.txtBackInfo.Text.ToString();

        Model.Add();

        //写系统日志
        ZWL.BLL.ERPRiZhi MyRiZhi = new ZWL.BLL.ERPRiZhi();
        MyRiZhi.UserName    = ZWL.Common.PublicMethod.GetSessionValue("UserName");
        MyRiZhi.DoSomething = "用户添加车辆保养记录信息(" + this.txtCarName.Text + ")";
        MyRiZhi.IpStr       = System.Web.HttpContext.Current.Request.UserHostAddress.ToString();
        MyRiZhi.Add();

        ZWL.Common.MessageBox.ShowAndRedirect(this, "车辆保养记录信息添加成功!", "CarBaoYang.aspx");
    }
示例#3
0
 public void DataBindToGridview(string IDList)
 {
     ZWL.BLL.ERPCarBaoYang MyModel = new ZWL.BLL.ERPCarBaoYang();
     if (IDList.Trim().Length > 0)
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%' and ID in(" + IDList + ") order by ID desc");
     }
     else
     {
         GVData.DataSource = MyModel.GetList(" " + DropDownList2.SelectedItem.Value.ToString() + " like '%" + this.TextBox3.Text.Trim() + "%' 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();
 }
示例#4
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         ZWL.Common.PublicMethod.CheckSession();
         ZWL.BLL.ERPCarBaoYang Model = new ZWL.BLL.ERPCarBaoYang();
         Model.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
         this.txtCarName.Text      = Model.CarName.ToString();
         this.txtBYDate.Text       = Model.BYDate.ToString();
         this.txtJingBanUser.Text  = Model.JingBanUser.ToString();
         this.txtZhuGuanUser.Text  = Model.ZhuGuanUser.ToString();
         this.txtBYQianLCBNum.Text = Model.BYQianLCBNum.ToString();
         this.txtQiYouJinE.Text    = Model.QiYouJinE.ToString();
         this.txtBYJinE.Text       = Model.BYJinE.ToString();
         this.txtWeiXiuJinE.Text   = Model.WeiXiuJinE.ToString();
         this.txtOtherJinE.Text    = Model.OtherJinE.ToString();
         this.txtUserName.Text     = Model.UserName.ToString();
         this.txtTimeStr.Text      = Model.TimeStr.ToString();
         this.txtBackInfo.Text     = Model.BackInfo.ToString();
     }
 }