陈清红
2025-04-14 880f3c0257eeb8c37761d484258fdd102a369a19
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
Quintiq file version 2.0
#parent: #root
Method RefreshData () id:Method_FormKpiSnapshots_RefreshData
{
  #keys: '[136398.1.792567524]'
  Body:
  [*
    // Refreshes all the data loaded on the form based on the current configuration.
    // This method is also called when the user clicks the Refresh button.
    
    maxitems       := this.GetMaxResults();
    timespanoption := this.RadioButtonGroupTimespan().BoundValue();
    
    set := GlobalStateKpiTracker.QueryDataFromServer( maxitems,
                                                      timespanoption,
                                                      DateTimeSelectorFrom.DateTime(),
                                                      DateTimeSelectorTo.DateTime(),
                                                      RadioButtonGroupTimeType.BoundValue() );
    
    DataHolderSnapshotSetData.Data( &set );
    
    // Refresh the UI timestamp
    Form.RefreshTimeType();
    
    // Refresh the UI label
    Form.RefreshSeries();
    
    // Refresh SnapshotData.Value.Is_Last()
    Form.RefreshUIIsLastAttribute();
    
    // Refresh FixedFilter for List 
    Form.FilterDataOnSelectedKpis();
    
    Form.AutoSelectAllSnapshots();
  *]
}