/// <summary> /// 打印磅单 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void tsmiPrint_Click(object sender, EventArgs e) { GridRow grid = superGridControl2_BuyFuel.PrimaryGrid.ActiveRow as GridRow; View_BuyFuelTransport entity = grid.DataItem as View_BuyFuelTransport; CmcsBuyFuelTransport transport = commonDAO.SelfDber.Get <CmcsBuyFuelTransport>(entity.Id); FrmPrintWeb frm = new FrmPrintWeb(transport); frm.ShowDialog(); }
private void superGridControl1_DataBindingComplete(object sender, DevComponents.DotNetBar.SuperGrid.GridDataBindingCompleteEventArgs e) { foreach (GridRow gridRow in e.GridPanel.Rows) { View_BuyFuelTransport entity = gridRow.DataItem as View_BuyFuelTransport; if (entity == null) { return; } CmcsBuyFuelTransport entity2 = Dbers.GetInstance().SelfDber.Get <CmcsBuyFuelTransport>(entity.Id); gridRow.Cells["clmKsWeight"].Value = entity2.AutoKsWeight + entity2.KsWeight; } }
/// <summary> /// 打印磅单 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void tsmiPrint_Click(object sender, EventArgs e) { GridRow gridRow = superGridControl2_BuyFuel.PrimaryGrid.ActiveRow as GridRow; if (gridRow == null) { return; } View_BuyFuelTransport entity = gridRow.DataItem as View_BuyFuelTransport; CmcsBuyFuelTransport entity2 = Dbers.GetInstance().SelfDber.Get <CmcsBuyFuelTransport>(entity.Id); FrmPrintWeb frm = new FrmPrintWeb(entity2); frm.ShowDialog(); }