示例#1
0
 private void ShowInfo(int _id)
 {
     Model.wx_wq_chexi model = bll.GetModel(_id);
     this.txtCximg.Text        = model.pic;
     this.imgCximg.ImageUrl    = model.pic;
     this.txtJname.Text        = model.jName;
     this.txtName.Text         = model.Name;
     this.txtSort_id.Text      = model.sort_id.ToString();
     this.txtSummary.InnerHtml = model.remark;
     ddlPinpai.SelectedValue   = model.pid.ToString();
 }
示例#2
0
        private bool DoEdit(int _id)
        {
            Model.wx_userweixin weixin = GetWeiXinCode();
            Model.wx_wq_chexi   model  = bll.GetModel(_id);
            bool result = false;

            model.jName   = this.txtJname.Text;
            model.Name    = this.txtName.Text;
            model.pic     = this.txtCximg.Text;
            model.pid     = MyCommFun.Str2Int(this.ddlPinpai.SelectedItem.Value);
            model.remark  = this.txtSummary.InnerText;
            model.sort_id = MyCommFun.Str2Int(this.txtSort_id.Text);
            if (bll.Update(model))
            {
                AddAdminLog(MXEnums.ActionEnum.Edit.ToString(), "修改车系内容id:" + model.Id); //记录日志
                result = true;
            }
            return(result);
        }
示例#3
0
        private bool DoAdd()
        {
            Model.wx_userweixin weixin = GetWeiXinCode();
            Model.wx_wq_chexi   model  = new Model.wx_wq_chexi();
            bool result = false;

            model.jName      = this.txtJname.Text;
            model.Name       = this.txtName.Text;
            model.pic        = this.txtCximg.Text;
            model.pid        = MyCommFun.Str2Int(this.ddlPinpai.SelectedItem.Value);
            model.remark     = this.txtSummary.InnerText;
            model.sort_id    = MyCommFun.Str2Int(this.txtSort_id.Text);
            model.wid        = weixin.id;
            model.createdate = DateTime.Now;
            if (bll.Add(model) > 0)
            {
                AddAdminLog(MXEnums.ActionEnum.Add.ToString(), "添加车系信息:" + model.Name); //记录日志
                result = true;
            }
            return(result);
        }