1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
| Quintiq file version 2.0
| #parent: #root
| Method IsForUnits (
| structured_Object objects
| ) declarative remote as Boolean
| {
| Description: 'Returns true if this account has any unit accounts tied to the parameters units/ unit nodes. Used in designer as filter.'
| TextBody:
| [*
| // TYG2 Jun-09-2016 (Modified)
|
| value := false;
|
| unit := this.GetUnit();
|
| if( not isnull( unit ) )
| {
| value := exists( objects, Elements.astype( Unit ), u, u = unit or u.IsParent( unit ) or u.ID() = unit.ID() )
| or exists( objects, Elements.astype( UnitNode ).Unit, u, u = unit or u.IsParent( unit ) or u.ID() = unit.ID() );
| }
|
| return value;
| *]
| }
|
|