admin
2025-01-22 7e31442f0e9b07764e9c6a9680d3d4aeba5fe1de
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Quintiq file version 2.0
#parent: #root
Method ExportRoutings
{
  Description: 'Method to export routings to message via QI'
  TextBody:
  [*
    // Initiate some variables including base NVT
    exportfilename := 'Routings.xml';
    routename := 'QuintiqExportRoutingsFileRoute';
    basenvt := NamedValueTree::Create();
    basenvt.Root( GlobalParameters_MP::GetDatasetMPSync() );
    mp := this.MacroPlan();
    
    operations := selectset( mp, Unit.Operation, op, true );
    this.ExportObjectToNVT( basenvt, operations, typeof( IOOperation ) );
    
    opboms := selectset( operations, Elements.OperationBOM, ob, true );
    this.ExportObjectToNVT( basenvt, opboms, typeof( IOOperationBOM ) );
    
    opinputgrps := selectset( operations, Elements.OperationInputGroup, oig, true );
    this.ExportObjectToNVT( basenvt, opinputgrps, typeof( IOOperationInputGroup ) );
    
    opinputsets := selectset( operations, Elements.OperationInputSet, ois, true );
    this.ExportObjectToNVT( basenvt, opinputsets, typeof( IOOperationInputSet ) );
    
    oplinks := selectset( operations, Elements.SourceOperationLink, oil, true );
    this.ExportObjectToNVT( basenvt, oplinks, typeof( IOOperationLink ) );
    
    routings := selectset( mp, Routing, rt, true );
    this.ExportObjectToNVT( basenvt, routings, typeof( IORouting ) );
    
    rtconfigviews := selectset( mp, ViewBase.astype( RoutingConfiguratorView ), rv, true );
    this.ExportObjectToNVT( basenvt, rtconfigviews, typeof( IORoutingConfiguratorView ) );
    
    rtsteps := selectset( routings, Elements.RoutingStep, rs, true );
    this.ExportObjectToNVT( basenvt, rtsteps, typeof( IORoutingStep ) );
    
    this.ExportNVTToQI( exportfilename, routename, basenvt );
  *]
}