1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
| Quintiq file version 2.0
| #parent: #root
| StaticMethod CanDecreaseWeight (
| KPIWeights selections,
| output String feedback_o
| ) declarative remote as Boolean
| {
| Description: 'Precondition to block user if reducing weight to 0'
| TextBody:
| [*
| // List - check selection, warn & block user if any active goal has weight lower than 1
| canDecreaseWeight := forall( selections, Elements, e,
| KPIWeight::ValidateInput( feedback_o,
| e.Weight() - 1.0, // -1.0 weight each time
| e.Level() ) );
| return canDecreaseWeight;
| *]
| }
|
|