DataTable GetDetail() { RDFNew.Module.Admin.Pur.Pur_PoD obj = new RDFNew.Module.Admin.Pur.Pur_PoD(); DataTable dt = obj.GetDataByParent(B_Keyword)[1] as DataTable; if (dt.Rows.Count == 0) dt.Rows.Add(dt.NewRow()); return dt; }
protected override void OnInit(EventArgs e) { base.OnInit(e); B_ModuleID = "Pur_PoM"; B_ModuleName = "采购订单"; B_ToolBar1 = this.Toolbar1; B_IDAL = new RDFNew.Module.Admin.Pur.Pur_PoD(); B_DetailSessionKey = "Pur_PoDAdd"; }
public object[] ApplyMaster(DataTable dtM, RDFNew.Module.DALEntity.Sys_Log la) { DataTable dtDetail = null; if (la != null && la.Action.ToUpper() == "DELETE") { dtDetail = new RDFNew.Module.Admin.Pur.Pur_PoD().GetDataByParent( dtM.Rows[0]["PoMID",DataRowVersion.Original].ToString())[1] as DataTable; for (int i = 0; i < dtDetail.Rows.Count; i++) dtDetail.Rows[i].Delete(); } return ApplyMaster(dtM, dtDetail, la); }
protected override void LoadDetail() { DataTable dt; dt = App_Com.Helper.GetSession(B_DetailSessionKey, false) as DataTable; if (dt == null) { RDFNew.Module.Admin.Pur.Pur_PoD da = new RDFNew.Module.Admin.Pur.Pur_PoD(); dt = da.GetDataByParent(B_Keyword)[1] as DataTable; DataColumn dc; dc = new DataColumn("Amt", typeof(decimal), "Qty*Price"); dt.Columns.Add(dc); App_Com.Helper.SetSession(B_DetailSessionKey, dt); } OutputSummaryData(dt); this.Grid1.DataSource = dt; this.Grid1.DataBind(); }