protected void btnSave_Click(object sender, EventArgs e) { string strErr = ""; if (this.txtF_Key.Text.Trim().Length == 0) { strErr += "应用字段关键字不能为空!\\n"; } if (this.txtF_CName.Text.Trim().Length == 0) { strErr += "应用字段中文说明不能为空!\\n"; } if (this.txtF_Remark.Text.Trim().Length == 0) { strErr += "描述说明不能为空!\\n"; } if (strErr != "") { MessageBox.Show(this, strErr); return; } string F_Key = this.txtF_Key.Text; string F_CName = this.txtF_CName.Text; string F_Remark = this.txtF_Remark.Text; Maticsoft.Model.sys_Field model = new Maticsoft.Model.sys_Field(); model.F_Key = F_Key; model.F_CName = F_CName; model.F_Remark = F_Remark; Maticsoft.BLL.sys_Field bll = new Maticsoft.BLL.sys_Field(); bll.Add(model); Maticsoft.Common.MessageBox.ShowAndRedirect(this, "保存成功!", "add.aspx"); }
protected void btnSave_Click(object sender, EventArgs e) { string strErr=""; if(this.txtF_Key.Text.Trim().Length==0) { strErr+="应用字段关键字不能为空!\\n"; } if(this.txtF_CName.Text.Trim().Length==0) { strErr+="应用字段中文说明不能为空!\\n"; } if(this.txtF_Remark.Text.Trim().Length==0) { strErr+="描述说明不能为空!\\n"; } if(strErr!="") { MessageBox.Show(this,strErr); return; } string F_Key=this.txtF_Key.Text; string F_CName=this.txtF_CName.Text; string F_Remark=this.txtF_Remark.Text; Maticsoft.Model.sys_Field model=new Maticsoft.Model.sys_Field(); model.F_Key=F_Key; model.F_CName=F_CName; model.F_Remark=F_Remark; Maticsoft.BLL.sys_Field bll=new Maticsoft.BLL.sys_Field(); bll.Add(model); Maticsoft.Common.MessageBox.ShowAndRedirect(this,"保存成功!","add.aspx"); }
private void ShowInfo(int FieldID) { Maticsoft.BLL.sys_Field bll=new Maticsoft.BLL.sys_Field(); Maticsoft.Model.sys_Field model=bll.GetModel(FieldID); this.lblFieldID.Text=model.FieldID.ToString(); this.lblF_Key.Text=model.F_Key; this.lblF_CName.Text=model.F_CName; this.lblF_Remark.Text=model.F_Remark; }
private void ShowInfo(int FieldID) { Maticsoft.BLL.sys_Field bll = new Maticsoft.BLL.sys_Field(); Maticsoft.Model.sys_Field model = bll.GetModel(FieldID); this.lblFieldID.Text = model.FieldID.ToString(); this.lblF_Key.Text = model.F_Key; this.lblF_CName.Text = model.F_CName; this.lblF_Remark.Text = model.F_Remark; }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { Maticsoft.BLL.sys_Field bll = new Maticsoft.BLL.sys_Field(); if (Request.Params["id"] != null && Request.Params["id"].Trim() != "") { int FieldID = (Convert.ToInt32(Request.Params["id"])); bll.Delete(FieldID); Response.Redirect("list.aspx"); } } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { Maticsoft.BLL.sys_Field bll=new Maticsoft.BLL.sys_Field(); if (Request.Params["id"] != null && Request.Params["id"].Trim() != "") { int FieldID=(Convert.ToInt32(Request.Params["id"])); bll.Delete(FieldID); Response.Redirect("list.aspx"); } } }