Enterprise Edition:Context

From CoPlanner 11
Jump to navigationJump to search

From version 9.3 HF 2.7 it's possible to transfer the context (=current filter settings in masks) other actions.

Description

The context contains the current settings which the user uses in the active mask. Following settings can be used:

  • Filter: The currently selected filter settings
  • Axis: The currently displayed and selcted for display elements on the axis
  • Position: The current position on the axis is taken as filter in the context (only for matrix masks)
matrix mask, context, position

The context will always be set in the source mask The target responds only to the existing context, the reaction depends on the type of the object.

If there are parameter set in the context, which cannot be interpreted by the called component (eg axial are transferred to a detail record) , they will be ignored by the called component.


Hint  The filter/axis matching between the individual elements is based on the filter name in the mask, this corresponds to the Alias at the level of CoPlanner Cube.


The context of the source mask can be forwarded to the following targets:


Set context in source mask

Depending on the type of mask, you can set all or certain settings:

  • Input mask: filter, axis, position
  • Single row mask: filter
  • Single record mask: filter


The configuration of the context can be made at the following positions in the source mask:

Configuration Description
Properties measure settings The context can be configured over the property DetailContext under the properties of measure settings, onto which fall back on the jump of the detail record.
Masks, Properties measure settings, DetailContext
MakroDescriptor-listing-editor The context can be configured over DetailContext at MacroDescriptor-listing-editor when calling a macro.
MacroDescriptor-listing-editor, DetailContext


Contribute context to target macro

The context is supported by sever-side macros, as-well as client-side (NAV-Actions) macros but the behavior is different:

  • Filter settings are accepted and use for the

In server-side macros filter settings are accepted and used for the development of the current instruction/request; Axis settings do not matter here (axis settings are transferred to filter, this will be treated in the same way as filter). The processed data set is limited by the passed filter.

  • In client-side macros will the whole context will be passed to the target of a Nav-action.

A macro is only a destination for settings that are passed in context. However it can pass only settings.

Hint  By passing filter settings for a dimension through the context, no furhter filter settings must be defined for this dimension in the macro; the behavior of the system when both are existing is not defined.


Example: Passed context of an input mask to extinction macro

  • Create an extinguishing macro with a restricted filter on the 'types of revenue':
Input maks, Macro
  • Include this macro in the source mask and configure the shortcut with the following settings:
Object administration, Macro
  • Open the source mask with restriction of the filter 'Types of revenue':
Input mask, Filter settings
  • The execution of the macro in the source mask leads to the conclusion that the dimension 'types of revenue' of the source mask is not passed to the macro, because this has been excluded from the context. Instead the macro runs with the self-defined filter. If this dimension was not excluded in context only those revenues would be deleted with the type of revenue 'merchandise/Handelswaren' by the macro.


If you execute a macro with an active context(e.g. a link) place holder in the format @Context.<filtername>@, for example @Context.COPSYS_ID@ will be replaced with these parameters:

  • Continuation condition

Example: Sql=select COUNT(*) from Tabelle where COPSYS_ID=@Context.COPSYSID@

  • NavAktion/Other/BrowserWindow

Example: http://localhost:8058/@SessionID=@Session_ID@,@RecordID=@Context.COPSYSID@

  • ServerBefehl/DBC Execute Procedure (in parameter)

Example(in Stored-Procedure Parameter): @COPSYS_ID=@Context.COPSYSID@

  • NavAktion/Action which have a parameter window name

Mask for ID @Context.COPSYSID@

Example of a link which creates a context:

cop://name=Name der Aktion & aktion=Makro & p1=MakroKontext & p2= & p3= & p4=ContextFiltersetting:COPSYSID=636172261478600305=0=FilterText=COPSYS_ID & frmlocation=Struktur & bild=__PARAM_NOT_FOUND__ & info=__PARAM_NOT_FOUND__ & styledefinition=Blau Verlauf.maskskin & readonly=__PARAM_NOT_FOUND__

Hint  Replacement of place holders works just for macros on the client side. That means for example, it does not work if the macro is defined in MacroOnSave.

Context distribution to target import

The filter settings will be applied for an import object. For individual dimensions, analogous to masks, either settings can be configured in the import object, or the values will be taken from the context. The system doesn' support a configuration of both simultaneous for one dimension (the systems behavior is undefined).

An import object is only a destination for settings that are passed in context. However it can pass only settings.


Hint   Settings can only be set for import object with the data source "data definition" but not for the types "SQL" or "text".


Example: To pass the context of an input mask to import

  • Create an extinguishing macro with a restricted filter on the 'types of revenue':


Context distribution to target mask

The context can be passed toInput mask, Row view and Single row mask. Depending on the type of mask only certain values can be assumed from the context:

  • Input mask: filter, axis, position
  • Single row mask: filter
  • Single record mask: filter

The context can be configured under the properties of measure settings


Context distribution to target webpage

Is the target a webpage, the current context can be passed by using an URL and will be set accordingly by a call from the CoPlanner client.

A webpage is only a destination for settings that are passed in context. However it can pass only settings.

The CopLink can be created in CopContextDialog. This will be opened by the shortcut "Ctrl J" of a matrix mask or singel row mask.

CopContextLinkDialog