| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
 | | Quintiq file version 2.0 |  | #parent: #root |  | Function CalcMEIO_PeriodNumber |  | { |  |   TextBody: |  |   [* |  |     value := 0;  |  |     if ( not this.IsHistorical() and this.IsPlanning()  )  |  |     { |  |       if ( not isnull( this.PreviousPlanningPeriod() ) )  |  |       { |  |         value := 1 + this.PreviousPlanningPeriod().MEIO_PeriodNumber() |  |       } |  |       else |  |       { |  |         value := 1; // we start at one |  |       } |  |     } |  |     this.MEIO_PeriodNumber( value ); |  |   *] |  | } | 
 |