¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | Method IsInUnit ( |
| | | StockingPoint_MP sp, |
| | | String unitname |
| | | ) as Boolean |
| | | { |
| | | Description: 'æ¯å¦å±äºæä¸ªçº¿' |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Aug-5-2024 (created) |
| | | unit := sp.Unit(); |
| | | parentunits := unit.GetAllParent(); |
| | | return unit.ID() = unitname or exists( parentunits, Elements, punit, punit.ID() = unitname ); |
| | | *] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | StaticMethod GetDefaultAllUnit () const declarative as String |
| | | { |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-25-2024 (created) |
| | | return '<All>'; |
| | | *] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | StaticMethod GetDefaultCCUnit () const as String |
| | | { |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-25-2024 (created) |
| | | return 'é¿æ¥å·¥å'; |
| | | //return 'Assembly Plant (France)'; |
| | | *] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | StaticMethod GetDefaultDLUnit () const as String |
| | | { |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-25-2024 (created) |
| | | return '大è¿å·¥å'; |
| | | //return 'Assembly Plant (Spain)'; |
| | | *] |
| | | } |
| | |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-28-2024 (created) |
| | | return 'é¿æ¥è£
é
线边åº'; |
| | | //return 'é¿æ¥è£
é
线边åº'; |
| | | return 'é¿æ¥è£
é
线'; |
| | | *] |
| | | } |
| | |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-28-2024 (created) |
| | | return '大è¿è£
é
线边åº'; |
| | | //return '大è¿è£
é
线边åº'; |
| | | return '大è¿è£
é
线'; |
| | | *] |
| | | } |
| | |
| | | #parent: #root |
| | | Method Initialize ( |
| | | FinancialSalesColumn column, |
| | | Real quantity |
| | | Number quantity |
| | | ) |
| | | { |
| | | TextBody: |
| | |
| | | // çå
°é¸½ Jun-24-2024 (created) |
| | | cell := selectobject( this, FinancialSalesCell, cell, cell.FinancialSalesColumn() = column ); |
| | | |
| | | value := [Real]cell.Value() + quantity; |
| | | value := [Number]cell.Value() + quantity; |
| | | cell.Value( [String]value ); |
| | | *] |
| | | } |
| | |
| | | // çå
°é¸½ Jun-24-2024 (created) |
| | | owner.FinancialSalesSource( relflush ); |
| | | products := construct( Product_MPs ); |
| | | allsalessegment := FinancialSalesReport::GetSalesSegmentAll(); |
| | | allunit := FinancialSalesReport::GetDefaultAllUnit(); |
| | | ccunit := FinancialSalesReport::GetDefaultCCUnit(); |
| | | dlunit := FinancialSalesReport::GetDefaultDLUnit(); |
| | | ccsalessegment := FinancialSalesReport::GetSalesSegmentCC(); |
| | | dlsalessegment := FinancialSalesReport::GetSalesSegmentDL(); |
| | | tjsalessegment := FinancialSalesReport::GetSalesSegmentTJ(); |
| | | fssalessegment := FinancialSalesReport::GetSalesSegmentFS(); |
| | | ccspline := FinancialSalesReport::GetStockingPointCCLine(); |
| | |
| | | source := owner.FinancialSalesSource( relnew, IsImport := false, Name := FinancialSalesReport::GetDefaultName() ); |
| | | table := source.FinancialSalesReport( relnew, ID := source.Name(), Name := source.Name(), IsImport := false ); |
| | | showtable := source.FinancialSalesReport( relnew, ID := source.Name() + 'Show', Name := source.Name(), IsImport := false, IsShow := true ); |
| | | startofplanning := owner.StartOfPlanning(); |
| | | startofplanning := owner.StartOfPlanning().Date(); |
| | | //startofyear := startofplanning.StartOfYear(); |
| | | startofnextyear := startofplanning.StartOfNextYear(); |
| | | |
| | | search := source.FinancialSalesSearch( relnew, Unit := allsalessegment, Generation := allsalessegment, MqbMlb := allsalessegment, Power := allsalessegment ); |
| | | search := source.FinancialSalesSearch( relnew, Unit := allunit, Generation := allunit, MqbMlb := allunit, Power := allunit ); |
| | | |
| | | table.GenerateColumn( owner ); |
| | | |
| | | //ä»Forecastæ¥è¯¢ |
| | | traverse( owner, SalesDemand.astype( Forecast ), forecast, forecast.StartDate() < startofnextyear.Date() and ( ( forecast.SalesSegmentName() = ccsalessegment and forecast.Product_MP().MQBMLB() = 'MLB' ) |
| | | or forecast.SalesSegmentName() = tjsalessegment or forecast.SalesSegmentName() = fssalessegment ) ){ |
| | | //é¦å
å¨forecastç颿¥æ¾sales segmentä¸ºé¿æ¥çææéæ±ï¼è¯å«åºMLBçææäº§åï¼æ¯ä¸ªäº§åæææ±æ»éæ±æ°é |
| | | traverse( owner, SalesDemand.astype( Forecast ), forecast, forecast.StartDate() < startofnextyear ){ |
| | | salessegment := forecast.SalesSegment_MP(); |
| | | parentsalessegments := salessegment.GetAllParent(); |
| | | //æ¯å¦å±äºé¿æ¥ |
| | | iscc := salessegment.Name() = ccsalessegment or exists( parentsalessegments, Elements, psalessegment, psalessegment.Name() = ccsalessegment ); |
| | | //æ¯å¦å±äºå¤§è¿, å³å¤©æ´¥åä½å±± |
| | | isdl := salessegment.Name() = tjsalessegment or salessegment.Name() = fssalessegment |
| | | or exists( parentsalessegments, Elements, psalessegment, psalessegment.Name() = tjsalessegment ) |
| | | or exists( parentsalessegments, Elements, psalessegment, psalessegment.Name() = fssalessegment ); |
| | | //ForecastçSales Segmentä¸ºé¿æ¥ï¼è¯å«åºMLBçææäº§åæ±æ» |
| | | //大è¿è´¢å¡ééï¼é¦å
å¨forecastç颿¥æ¾Sales Segmentæ¯å¤©æ´¥åä½å±±çææéæ±ï¼æ¯ä¸ªäº§åæææ±æ»éæ±æ°é |
| | | if( ( iscc and forecast.Product_MP().MQBMLB() = 'MLB' ) or isdl ){ |
| | | product := forecast.Product_MP(); |
| | | allrow := table.GetRow( allsalessegment, product.ID() ); |
| | | periodtime := forecast.StartDate().StartOfMonth(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | //è·ååè®¡è¡ |
| | | allrow := table.GetRow( allunit, product.ID() ); |
| | | //è·åå·¥åè¡ |
| | | factoryrow := table.GetRow( ifexpr( iscc and forecast.Product_MP().MQBMLB() = 'MLB', ccunit, dlunit ), product.ID() ); |
| | | |
| | | if( products.Find( product ) < 0 ){ |
| | | products.Add( product ); |
| | | } |
| | | // info( '------------------------', periodname, periodtime ); |
| | | traverse( forecast, PlanningSalesDemandInPeriod, psdip ){ |
| | | periodtime := psdip.StartDate().StartOfMonth(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | // info( '-------------------------', periodname, periodtime ); |
| | | column := selectobject( table, FinancialSalesColumn, column, column.Name() = periodname and column.Period() = periodtime ); |
| | | // info( '------------------------', column.Name() ); |
| | | //ForecastçSales Segmentä¸ºé¿æ¥ï¼è¯å«åºMLBçææäº§åæ±æ» |
| | | if( forecast.SalesSegmentName() = ccsalessegment and product.MQBMLB() = 'MLB' ){ |
| | | // info( '------------------------', column.Name() ); |
| | | ccrow := table.GetRow( ccsalessegment, product.ID() ); |
| | | // info( '------------------------', ccrow.FinancialSalesCell( relsize ), column.FinancialSalesCell( relsize ) ); |
| | | ccrow.Initialize( column, forecast.Quantity() ); |
| | | }else if( forecast.SalesSegmentName() = tjsalessegment or forecast.SalesSegmentName() = fssalessegment ){ |
| | | //大è¿è´¢å¡ééï¼é¦å
å¨forecastç颿¥æ¾Sales Segmentæ¯å¤©æ´¥åä½å±±çææéæ±ï¼æ¯ä¸ªäº§åæææ±æ»éæ±æ°é |
| | | // info( '------------------------', column.Name() ); |
| | | dlrow := table.GetRow( dlsalessegment, product.ID() ); |
| | | // info( '------------------------', dlrow.FinancialSalesCell( relsize ), column.FinancialSalesCell( relsize ) ); |
| | | dlrow.Initialize( column, forecast.Quantity() ); |
| | | // info( '-------------------------', column.Name() ); |
| | | quantity := ceil( psdip.Quantity() );//åä¸åæ´ |
| | | |
| | | factoryrow.Initialize( column, quantity ); |
| | | allrow.Initialize( column, quantity ); |
| | | } |
| | | allrow.Initialize( column, forecast.Quantity() ); |
| | | } |
| | | } |
| | | //ä»Product planningæ¥æ¾åºåç¹ä¸ºé¿æ¥è£
é
线边åºçææMQB产åï¼åTotal Demandåæ®µæææ±æ»éæ±æ°é |
| | | traverse( owner, Product_MP, product, product.IsLeaf() and product.MQBMLB() = 'MQB' ){//产å为MQB |
| | | traverse( product, ProductInStockingPoint_MP, pisp, pisp.StockingPointID() = ccspline ){//åºåç¹ä¸ºé¿æ¥è£
é
çº¿è¾¹åº |
| | | traverse( pisp, ProductInStockingPointInPeriod, pispip, pispip.Start() >= startofplanning |
| | | and pispip.Start() < startofnextyear and pispip.Period_MP().TimeUnit() = Translations::MP_GlobalParameters_Month() ){ |
| | | traverse( owner, StockingPoint_MP, stockingpoint ){ |
| | | // unit := stockingpoint.Unit(); |
| | | // parentunits := unit.GetAllParent(); |
| | | //æ¯å¦å±äºé¿æ¥è£
é
线 |
| | | // iscc := unit.ID() = ccspline or exists( parentunits, Elements, punit, punit.ID() = ccspline ); |
| | | if( table.IsInUnit( stockingpoint, ccspline ) ){ |
| | | traverse( stockingpoint, ProductInStockingPoint_MP, pisp, pisp.Product_MP().IsLeaf() and pisp.Product_MP().MQBMLB() = 'MQB' ){//产å为MQB |
| | | allrow := table.GetRow( allunit, pisp.ProductID() ); |
| | | ccrow := table.GetRow( ccunit, pisp.ProductID() ); |
| | | traverse( pisp, ProductInStockingPointInPeriod, pispip, not pispip.Period_MP().IsHistorical() and pispip.Period_MP().StartDate() < startofnextyear ){ |
| | | periodtime := pispip.Start().StartOfMonth().Date(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | column := selectobject( table, FinancialSalesColumn, column, column.Name() = periodname and column.Period() = periodtime ); |
| | | ccrow := table.GetRow( ccsalessegment, product.ID() ); |
| | | ccrow.Initialize( column, pispip.DependentDemandAndSalesDemandQuantity() );//åTotal Demandåæ®µæææ±æ»éæ±æ°é |
| | | quantity := ceil( pispip.DependentDemandAndSalesDemandQuantity() );//åä¸åæ´ |
| | | |
| | | allrow := table.GetRow( allsalessegment, product.ID() ); |
| | | allrow.Initialize( column, pispip.DependentDemandAndSalesDemandQuantity() ); |
| | | ccrow.Initialize( column, quantity );//åTotal Demandåæ®µæææ±æ»éæ±æ°é |
| | | allrow.Initialize( column, quantity ); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | startofnextyearlead := startofplanning.StartOfNextYear() + FinancialSalesReport::GetDefaultTripLeadingTime(); |
| | | //大è¿è´¢å¡ééï¼é¿æ¥çéæ±éè¦å¨trip plané颿¾å°èµ·å§åºåç¹ä¸ºå¤§è¿è£
é
线边åºï¼ç®çå°ä¸ºé¿æ¥å¤ç§åºç产åï¼ç±äºéè¦èè产åè¿è¾lead timeï¼æ¯ä¸ªæçæ±æ»æ°æ®éè¦æ¨è¿ä¸¤å¤©è¿è¡è®¡ç® |
| | | traverse( owner, Unit.Lane.LaneLeg, laneleg, laneleg.OriginStockingPointID() = dlspline and laneleg.DestinationStockingPointID() = ccrent ){ |
| | | traverse( owner, Unit.Lane.LaneLeg, laneleg ){ |
| | | //èµ·å§åºåç¹æ¯å¦æ¯å¤§è¿è£
é
çº¿è¾¹åº |
| | | originsp := selectobject( owner, StockingPoint_MP, sp, sp.ID() = laneleg.OriginStockingPointID() ); |
| | | isdlspline := table.IsInUnit( originsp, dlspline ); |
| | | //ç®çå°æ¯å¦æ¯é¿æ¥å¤ç§åº |
| | | destisp := selectobject( owner, StockingPoint_MP, sp, sp.ID() = laneleg.DestinationStockingPointID() ); |
| | | isccrent := table.IsInUnit( destisp, ccrent ); |
| | | if( isdlspline and isccrent ){ |
| | | traverse( laneleg, Trip, trip, trip.Arrival() < startofnextyearlead ){ |
| | | periodtime := ( trip.Arrival() - FinancialSalesReport::GetDefaultTripLeadingTime() ).StartOfMonth().Date(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | |
| | | column := selectobject( table, FinancialSalesColumn, column, column.Name() = periodname and column.Period() = periodtime ); |
| | | traverse( trip, ProductInTrip, pit ){ |
| | | dlrow := table.GetRow( dlsalessegment, pit.ProductID() ); |
| | | dlrow.Initialize( column, pit.Quantity() );//åTotal Demandåæ®µæææ±æ»éæ±æ°é |
| | | quantity := ceil( pit.Quantity() );//åä¸åæ´ |
| | | dlrow := table.GetRow( dlunit, pit.ProductID() ); |
| | | dlrow.Initialize( column, quantity );//æ±æ»æ°é |
| | | |
| | | allrow := table.GetRow( allsalessegment, pit.ProductID() ); |
| | | allrow.Initialize( column, pit.Quantity() ); |
| | | allrow := table.GetRow( allunit, pit.ProductID() ); |
| | | allrow.Initialize( column, quantity ); |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | { |
| | | #keys: '3[415136.0.865305024][415136.0.865305023][415136.0.865305025]' |
| | | Description: 'è¯ä»·åºå' |
| | | ValueType: Real |
| | | ValueType: Number |
| | | } |
| | |
| | | { |
| | | #keys: '3[415136.0.865304924][415136.0.865304923][415136.0.865304925]' |
| | | Description: 'ææ«åºå' |
| | | ValueType: Real |
| | | ValueType: Number |
| | | } |
| | |
| | | { |
| | | #keys: '3[415136.0.865304944][415136.0.865304943][415136.0.865304945]' |
| | | Description: 'æå¤§åºå' |
| | | ValueType: Real |
| | | ValueType: Number |
| | | } |
| | |
| | | { |
| | | #keys: '3[415136.0.865304934][415136.0.865304933][415136.0.865304935]' |
| | | Description: 'æå°åºå' |
| | | ValueType: Real |
| | | ValueType: Number |
| | | } |
| | |
| | | alldetails := selectset( selections, Elements.InventoryInterfaceDataDetail, detail, detail.PartNumber() = productid and detail.Date() >= start and detail.Date() <= end ); |
| | | if( alldetails.Size() > 0 ){ |
| | | allrow := table.GetRow( allunit, productid ); |
| | | allvalue := sum( alldetails, Elements, e, e.Quantity() ); |
| | | allvalue := sum( alldetails, Elements, e, [Number]e.Quantity() ); |
| | | allrow.SetCellValue( this, allvalue ); |
| | | //é¿æ¥ |
| | | ccdetails := selectset( alldetails, Elements, detail, ccstockingpointids.Find( detail.InventoryPointSelection().StockpoingPoint() ) >= 0 ); |
| | | if( ccdetails.Size() > 0 ){ |
| | | ccrow := table.GetRow( ccunit, productid ); |
| | | value := sum( ccdetails, Elements, e, e.Quantity() ); |
| | | value := sum( ccdetails, Elements, e, [Number]e.Quantity() ); |
| | | ccrow.SetCellValue( this, value ); |
| | | } |
| | | //å¤§è¿ |
| | | dldetails := selectset( alldetails, Elements, detail, dlstockingpointids.Find( detail.InventoryPointSelection().StockpoingPoint() ) >= 0 ); |
| | | if( dldetails.Size() > 0 ){ |
| | | dlrow := table.GetRow( dlunit, productid ); |
| | | value := sum( dldetails, Elements, e, e.Quantity() ); |
| | | value := sum( dldetails, Elements, e, [Number]e.Quantity() ); |
| | | dlrow.SetCellValue( this, value ); |
| | | } |
| | | } |
| | |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Jun-28-2024 (created) |
| | | return 'é¿æ¥å·¥ç¨'; |
| | | return 'é¿æ¥å·¥å'; |
| | | //return 'Assembly Plant (France)'; |
| | | *] |
| | | } |
| | |
| | | table.GenerateColumn( owner, 'All', startofyear, startofnextyear ); |
| | | //info( '-----------------------------------', table.InventorySummaryColumn( relsize ) ); |
| | | //åºåæ°é为Actual inventorieséé¢çç¹Planned inventoriesåæ®µåºåéå æ» |
| | | traverse( owner, Product_MP.ProductInStockingPoint_MP, pisp, pisp.IsLeaf() and not pisp.IsSystem() and not isnull( pisp.StockingPoint_MP() ) and ( pisp.StockingPoint_MP().UnitID() = ccunit or pisp.StockingPoint_MP().UnitID() = dlunit ) ){ |
| | | unit := pisp.StockingPoint_MP().UnitID(); |
| | | product := pisp.Product_MP(); |
| | | // info( '-----------------------------------', unit, product.ID() ); |
| | | traverse( owner, StockingPoint_MP, stockingpoint ){ |
| | | unit := stockingpoint.Unit(); |
| | | parentunits := unit.GetAllParent(); |
| | | //æ¯å¦å±äºé¿æ¥å·¥å |
| | | iscc := unit.ID() = ccunit or exists( parentunits, Elements, punit, punit.ID() = ccunit ); |
| | | //æ¯å¦å±äºå¤§è¿å·¥å |
| | | isdl := unit.ID() = dlunit or exists( parentunits, Elements, punit, punit.ID() = dlunit ); |
| | | if( iscc or isdl ){ |
| | | traverse( stockingpoint, ProductInStockingPoint_MP, pisp, pisp.Product_MP().IsLeaf() ){ |
| | | //è·åå·¥åè¡ |
| | | factoryrow := table.GetRow( ifexpr( iscc, ccunit, dlunit ), pisp.ProductID() ); |
| | | //è·ååè®¡è¡ |
| | | allrow := table.GetRow( allunit, pisp.ProductID() ); |
| | | //å¨åº¦çæ°æ® |
| | | weekpispips := construct( ProductInStockingPointInPeriods ); |
| | | //æåº¦çæ°æ® |
| | | monthpispips := construct( ProductInStockingPointInPeriods ); |
| | | nextweek := startofplanning.StartOfNextWeek(); |
| | | nextmonth := startofplanning.StartOfNextMonth(); |
| | | |
| | | unitrow := table.GetRow( unit, product.ID() ); |
| | | allrow := table.GetRow( allunit, product.ID() ); |
| | | pispips := selectsortedset( pisp, ProductInStockingPointInPeriod, pispip, pispip.Start() >= startofplanning and pispip.Start() < startofnextyear and pispip.Period_MP().TimeUnit() = Translations::MP_GlobalParameters_Day(), pispip.Start() ); |
| | | // info( '-----------------------------------', isnull( allrow ), pispips.Size() ); |
| | | traverse( pispips, Elements, pispip, pispip.Start() = startofplanning ){ |
| | | // info( '-----------------------------------', pispip.Start() ); |
| | | pispips := selectsortedset( pisp, ProductInStockingPointInPeriod, pispip, not pispip.Period_MP().IsHistorical() |
| | | and pispip.Start() < startofnextyear |
| | | and pispip.Period_MP().TimeUnit() = Translations::MP_GlobalParameters_Day(), pispip.Start() ); |
| | | |
| | | traverse( pispips, Elements, pispip ){ |
| | | period := pispip.Period_MP(); |
| | | periodtime := period.Start().Date(); |
| | | periodname := periodtime.Format( "M2/D2/Y" ); |
| | | |
| | | //天ï¼éæ©æ¥é¢ç²åº¦æ¶ï¼ææ«åºåï¼æå°åºåï¼æå¤§åºååå¹³ååºåçæ°å¼ä¿æä¸è´ |
| | | daycolumn := selectobject( table, InventorySummaryColumn, column, column.Name() = periodname, column.Period() = periodtime, column.TimeUnit() = Translations::MP_GlobalParameters_Day() ); |
| | | info( daycolumn.Name(), daycolumn.Period(), daycolumn.TimeUnit() ); |
| | | unitrow.SetCellValue( daycolumn, pispip.PlannedInventoryLevelEnd() ); |
| | | allrow.SetCellValue( daycolumn, pispip.PlannedInventoryLevelEnd() ); |
| | | factoryrow.SetCellValue( daycolumn, [Number]pispip.PlannedInventoryLevelEnd() ); |
| | | allrow.SetCellValue( daycolumn, [Number]pispip.PlannedInventoryLevelEnd() ); |
| | | |
| | | //å¨ï¼éæ©å¨æ¶ï¼ææ«åºå为æ¯ä¸å¨æåä¸å¤©çæ±æ»åºåä¿¡æ¯ï¼æå°åºå为è¿ä¸å¨åºåéæå°çä¸å¤©çæ°å¼ï¼æå¤§åºå为è¿ä¸å¨åºåéæå¤§çä¸å¤©çæ°å¼ï¼å¹³ååºå为该å¨çå¹³åå¼ |
| | | if( period.Start() < nextweek ){ |
| | |
| | | if( period.Start() = weekend ){ |
| | | weekcolumn := selectobject( table, InventorySummaryColumn, column, column.Name() = periodname, column.Period() = periodtime, column.TimeUnit() = Translations::MP_GlobalParameters_Week() ); |
| | | |
| | | maxinventory := max( weekpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | mininventory := min( weekpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | aveinventory := average( weekpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | unitrow.SetCellValue( weekcolumn, pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, aveinventory ); |
| | | allrow.SetCellValue( weekcolumn, pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, aveinventory ); |
| | | maxinventory := max( weekpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | mininventory := min( weekpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | aveinventory := average( weekpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | factoryrow.SetCellValue( weekcolumn, [Number]pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, [Number]aveinventory ); |
| | | allrow.SetCellValue( weekcolumn, [Number]pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, [Number]aveinventory ); |
| | | } |
| | | }else{ |
| | | weekpispips.Flush(); |
| | |
| | | if( period.Start() = monthend ){ |
| | | monthcolumn := selectobject( table, InventorySummaryColumn, column, column.Name() = periodname, column.Period() = periodtime, column.TimeUnit() = Translations::MP_GlobalParameters_Month() ); |
| | | |
| | | maxinventory := max( monthpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | mininventory := min( monthpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | aveinventory := average( monthpispips, Elements, e, e.PlannedInventoryLevelEnd() ); |
| | | unitrow.SetCellValue( monthcolumn, pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, aveinventory ); |
| | | allrow.SetCellValue( monthcolumn, pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, aveinventory ); |
| | | maxinventory := max( monthpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | mininventory := min( monthpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | aveinventory := average( monthpispips, Elements, e, [Number]e.PlannedInventoryLevelEnd() ); |
| | | factoryrow.SetCellValue( monthcolumn, [Number]pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, [Number]aveinventory ); |
| | | allrow.SetCellValue( monthcolumn, [Number]pispip.PlannedInventoryLevelEnd(), mininventory, maxinventory, [Number]aveinventory ); |
| | | } |
| | | }else{ |
| | | monthpispips.Flush(); |
| | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | //é¦å
å¨Entitieséè¯å«ç¶çº§Unitä¸ºé¿æ¥/大è¿çææåºåç¹ |
| | | //é¿æ¥åºåç¹ |
| | | ccsps := construct( Strings ); |
| | |
| | | #parent: #root |
| | | Method SetCellValue ( |
| | | InventorySummaryColumn column, |
| | | Real quantity |
| | | Number quantity |
| | | ) |
| | | { |
| | | TextBody: |
| | |
| | | #parent: #root |
| | | Method SetCellValue ( |
| | | InventorySummaryColumn column, |
| | | Real endinginventory, |
| | | Real minimuminventory, |
| | | Real maximuminventory, |
| | | Real averageinventory |
| | | Number endinginventory, |
| | | Number minimuminventory, |
| | | Number maximuminventory, |
| | | Number averageinventory |
| | | ) |
| | | { |
| | | TextBody: |
| | |
| | | Properties: |
| | | [ |
| | | Image: 'EXPORT1' |
| | | Taborder: 1 |
| | | ] |
| | | } |
| | | Component ButtonSearch |
| | | { |
| | | #keys: '[415136.0.972170614]' |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'VIEW' |
| | | Taborder: 0 |
| | | ] |
| | | } |
| | |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'EXPORT1' |
| | | Image: 'IMPORT1' |
| | | Taborder: 1 |
| | | ] |
| | | } |
| | |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'IMPORT1' |
| | | Image: 'EXPORT1' |
| | | Taborder: 2 |
| | | ] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: PanelExport/ButtonSearch |
| | | Response OnClick () id:Response_PanelExport_ButtonSearch_OnClick |
| | | { |
| | | #keys: '[415136.0.972170823]' |
| | | CanBindMultiple: false |
| | | DefinitionID: 'Responsedef_WebButton_OnClick' |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | *] |
| | | GroupServerCalls: false |
| | | } |
| | | } |
| | |
| | | [* |
| | | if( dhSearch.Data().Generation() <> selection ){ |
| | | dhSearch.Data().Generation( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | [* |
| | | if( dhSearch.Data().MqbMlb() <> selection ){ |
| | | dhSearch.Data().MqbMlb( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | [* |
| | | if( dhSearch.Data().Power() <> selection ){ |
| | | dhSearch.Data().Power( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | [* |
| | | if( dhSearch.Data().Unit() <> selection ){ |
| | | dhSearch.Data().Unit( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | Properties: |
| | | [ |
| | | Image: 'EXPORT1' |
| | | Taborder: 1 |
| | | ] |
| | | } |
| | | Component ButtonSearch id:ButtonSearch_75 |
| | | { |
| | | #keys: '[415136.0.972100211]' |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'VIEW' |
| | | Taborder: 0 |
| | | ] |
| | | } |
| | |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'EXPORT1' |
| | | Image: 'IMPORT1' |
| | | Taborder: 1 |
| | | ] |
| | | } |
| | |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'IMPORT1' |
| | | Image: 'EXPORT1' |
| | | Taborder: 2 |
| | | ] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: PanelExport_545/ButtonSearch_75 |
| | | Response OnClick () id:Response_PanelExport_ButtonSearch_OnClick_118 |
| | | { |
| | | #keys: '[415136.0.972100210]' |
| | | CanBindMultiple: false |
| | | DefinitionID: 'Responsedef_WebButton_OnClick' |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | *] |
| | | GroupServerCalls: false |
| | | } |
| | | } |
| | |
| | | //ä»£æ°æ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().Generation() <> selection ){ |
| | | dhSearch.Data().Generation( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | //æ¨ªçºµå¶æ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().MqbMlb() <> selection ){ |
| | | dhSearch.Data().MqbMlb( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | //åçæ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().Power() <> selection ){ |
| | | dhSearch.Data().Power( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | Body: |
| | | [* |
| | | |
| | | valueString := "<All>;" + FinancialSalesReport::GetSalesSegmentCC() + ";" + FinancialSalesReport::GetSalesSegmentDL(); |
| | | valueString := FinancialSalesReport::GetDefaultAllUnit() + ";" + FinancialSalesReport::GetDefaultCCUnit() + ";" + FinancialSalesReport::GetDefaultDLUnit(); |
| | | |
| | | this.Strings( valueString ); |
| | | *] |
| | |
| | | //Unitæ´æ°åçææ°çæ¾ç¤º |
| | | if( dhSearch.Data().Unit() <> selection ){ |
| | | dhSearch.Data().Unit( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'IMPORT1' |
| | | Image: 'EXPORT1' |
| | | Taborder: 1 |
| | | ] |
| | | } |
| | | Component ButtonSearch id:ButtonSearch_612 |
| | | { |
| | | #keys: '[415136.0.972100788]' |
| | | BaseType: 'WebButton' |
| | | Properties: |
| | | [ |
| | | Image: 'VIEW' |
| | | Taborder: 0 |
| | | ] |
| | | } |
| | |
| | | //åºé´æ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().Category() <> this.BoundValue() ){ |
| | | dhSearch.Data().Category( this.BoundValue() ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: PanelExport/ButtonSearch_612 |
| | | Response OnClick () id:Response_PanelExport_ButtonSearch_OnClick_290 |
| | | { |
| | | #keys: '[415136.0.972100787]' |
| | | CanBindMultiple: false |
| | | DefinitionID: 'Responsedef_WebButton_OnClick' |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | *] |
| | | GroupServerCalls: false |
| | | } |
| | | } |
| | |
| | | //ä»£æ°æ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().Generation() <> selection ){ |
| | | dhSearch.Data().Generation( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | //æ¨ªçºµå¶æ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().MqbMlb() <> selection ){ |
| | | dhSearch.Data().MqbMlb( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | }else{ |
| | | if( dhSearch.Data().EndDate() <> this.Date() ){ |
| | | dhSearch.Data().EndDate( this.Date() ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | } |
| | | *] |
| | |
| | | }else{ |
| | | if( dhSearch.Data().StartDate() <> this.Date() ){ |
| | | dhSearch.Data().StartDate( this.Date() ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | } |
| | | *] |
| | |
| | | //åçæ¹ååå·æ°æ¾ç¤º |
| | | if( dhSearch.Data().Power() <> selection ){ |
| | | dhSearch.Data().Power( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | |
| | | //Unitæ´æ°åçææ°çæ¾ç¤º |
| | | if( dhSearch.Data().Unit() <> selection ){ |
| | | dhSearch.Data().Unit( selection ); |
| | | DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | // DataHolderTable.Data().Generate( dhSearch.Data(), DataHolderProduct.Data() ); |
| | | } |
| | | *] |
| | | GroupServerCalls: false |