| | |
| | | isccrent := table.IsInUnit( destisp, ccrent ); |
| | | if( isdlspline and isccrent ){ |
| | | traverse( laneleg, Trip, trip, trip.Arrival() < startofnextyearlead ){ |
| | | periodtime := ( trip.Arrival() - FinancialSalesReport::GetDefaultTripLeadingTime() ).StartOfMonth().Date(); |
| | | // periodtime := ( trip.Arrival() - FinancialSalesReport::GetDefaultTripLeadingTime() ).StartOfMonth().Date(); |
| | | periodtime := trip.Departure().StartOfMonth().Date(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | |
| | | column := selectobject( table, FinancialSalesColumn, column, column.Name() = periodname and column.Period() = periodtime ); |
| | | traverse( trip, ProductInTrip, pit ){ |
| | | quantity := [Number]pit.Quantity();//四舍五入 |
| | | dlrow := table.GetRow( dlunit, pit.Product_MP() ); |
| | | dlrow.Initialize( column, quantity );//汇总数量 |
| | | |
| | | allrow := table.GetRow( allunit, pit.Product_MP() ); |
| | | allrow.Initialize( column, quantity ); |
| | | if( not isnull( column ) ){ |
| | | traverse( trip, ProductInTrip, pit ){ |
| | | quantity := [Number]pit.Quantity();//四舍五入 |
| | | dlrow := table.GetRow( dlunit, pit.Product_MP() ); |
| | | dlrow.Initialize( column, quantity );//汇总数量 |
| | | |
| | | allrow := table.GetRow( allunit, pit.Product_MP() ); |
| | | allrow.Initialize( column, quantity ); |
| | | } |
| | | } |
| | | } |
| | | } |