/// <summary> /// 保存明细 /// </summary> private void UpdateMaterialInDtl() { List <MaterialInDtlModel> Models = GetScreenDtl(); RmsPM.BFL.MaterialInBFL bfl = new RmsPM.BFL.MaterialInBFL(); bfl.UpdateMaterialInDtlList(Models, RmsPM.BLL.ConvertRule.ToInt(this.MaterialInCode.Text)); }
protected void FormView1_DataBound(object sender, EventArgs e) { if (FormView1.CurrentMode == FormViewMode.ReadOnly) { Button btnDelete = ((Button)this.FormView1.Row.FindControl("btnDelete")); if (btnDelete != null) { btnDelete.Attributes["OnClick"] = "javascript:return confirm('确实要删除当前材料吗?')"; } ButtonStatusCtrl(); } else { if (FormView1.CurrentMode == FormViewMode.Insert) { ((RmsPM.Web.UserControls.InputUser) this.FormView1.Row.FindControl("InPersonBox")).Value = user.UserCode; } DataGrid dgDtl = (DataGrid)this.FormView1.Row.FindControl("dgDtl"); if (dgDtl != null) { RmsPM.BFL.MaterialInBFL bfl = new RmsPM.BFL.MaterialInBFL(); List <MaterialInDtlModel> Models = bfl.GetMaterialInDtlList(RmsPM.BLL.ConvertRule.ToInt(this.MaterialInCode.Text)); ViewState["Models"] = Models; BindDtl(Models); } } }