public void Clone <T>(T obj) where T : class, IModel { T_TranSalesBill objdata = obj as T_TranSalesBill; this.TranSalesBillId = objdata.TranSalesBillId; this.SalesBillNo = objdata.SalesBillNo; this.CompanyId = objdata.CompanyId; this.VoucherDate = objdata.VoucherDate; this.ToMSPartyId = objdata.ToMSPartyId; this.TransportId = objdata.TransportId; this.CheckerId = objdata.CheckerId; this.LRNo = objdata.LRNo; this.LRDate = objdata.LRDate; this.BrokerId = objdata.BrokerId; this.Station = objdata.Station; this.LUT = objdata.LUT; }
public T Copy <T>() where T : class, IModel, new() { T obj = new T(); T_TranSalesBill objdata = obj as T_TranSalesBill; objdata.TranSalesBillId = this.TranSalesBillId; objdata.SalesBillNo = this.SalesBillNo; objdata.CompanyId = this.CompanyId; objdata.VoucherDate = this.VoucherDate; objdata.ToMSPartyId = this.ToMSPartyId; objdata.TransportId = this.TransportId; objdata.CheckerId = this.CheckerId; objdata.LRNo = this.LRNo; objdata.LRDate = this.LRDate; objdata.BrokerId = this.BrokerId; objdata.Station = this.Station; objdata.LUT = this.LUT; return(obj); }