Automatic Mapping between Wizard SDT and WPD variables

Each WebPanel that is a Wizard step, needs to map the WPD Variables that are shown in the user interface, with the “Wizard SDT” for two purposes:
To initialize the Variables with the SDT when the WebPanel is loaded.
To store the data entered by the user in the “Wizard SDT” when the next or finish action is executed.

WPD will try to map each WPD variable with the “Wizard SDT” fields automatically to simplify the developer’s tasks.

The automatic mapping follows these rules:

To ilustrate mapping rules this SDT will be used.

  • Each plain variable in the WPD will be mapped with a field in the “Wizard SDT” which has the same name as the variable.
    In this example the fields InvoiceCode, InvoiceDate and InvoiceExpirationDate will be mapped with the fileds of the SDT with the same name.

    WizardAMVariablesLoad WizardAMVariablesSave
    Automatic load of Wizard Step Variable from SDT Automatic save of Wizard SDT Variables to SDT

  • Each “Attributes”, “Grid” or “FreeStyleGrid” node based on an SDT, will be mapped if they are based in the “Wizard SDT” or on an SDT that is referenced by the “Wizard SDT”.
    Attributes based on the WizardSDT

    WizardAMSDTLoad WizardAMSDTSave
    Automatic load of the SDT from the WizardSDT Automatic save of the Attributes SDT, to the WizardSDT

  • Each Grid with RowSelection, will be mapped with a field collection whose name is the same as the grid. In this case, the items included in the level, will be mapped with the selected fields of the grid
    WebPanelDesigner specification. In this case the name of the grid is taken into account for the mapping

    The rows that are in the &WizardSDT.Products collections will start as selected.

    The &WizardSDT.Products is updated with the selected products.

The developer can change this behaviour or add its own mapping, adding code in the U_OpenPage and U_WizardConfirm subroutines.