/Platform/Internal/List View/Ribbon/Item/where Platform is the module and Item is a script library. Let's take a look at the script here
$selectedDatais provided to the script automatically by SPE in context of the content of the results on
$selectedData– the selected objects in the list view (the same will be passed to the
$resultSetvariable for compatibility with older scripts)
$allData– all objects passed to the list view using the
$filteredData– all objects displayed after filtering is performed with the search criteria entered by the user in the ribbon.
$exportData– same as
$filteredData, however in this case the objects will have additional properties to support easy display with properties processed as text.
$actionData– any object that was passed to
-ActionDataparameter. Useful when you need additional context that the
Show-ListViewcommand does not explicitly know about. It’s your custom data.
$formatProperty– the content of the
–Propertyparameter when running the command.
$title– window title of the list view.
$infoTitle– info title of the list view.
$infoDescription– info title of the list view.
/Internal/List View/Ribbon/[Object type]. The
[Object type]is the name of the .Net class for which the action is valid. For example, if you want your action to be visible for
Sitecore.Data.Items.Itemthen save the script at the path
Show-ListViewthat are of the type based on location. Rules will provide more granular control and allow for rule-based conditions that determine action visibility.
Itemthat are of template
-ViewNameparameter. Running the script below will produce a report with the action not shown:
Update-ListViewcommand. Consider the following script:
Read-Variablecommand or Show alert using the
Show-Alertcommand or do just about anything possible otherwise from the context menu, ribbon or other interactive integration points.
Show-ListViewcommand has one more useful parameter named
-ActionDatawhich I mentioned above but is worth mentioning again. Anything passed using this parameter will be set as the
$actionDatavariable – this means your report and actions can pass custom data in them it can be as simple as an object or as complex as a hashtable so there is really no hard limit on what can progress from a report to report. Any object that was passed to
-ActionDataparameter will be available to your action.
Show-ListViewcommand provides the Hide parameter to control visibility of the UI elements.
-Hidewith one or more of the following options:
AllExport- hides all export scripts (left-most ribbon panel)
NonSpecificExport- hides export filters that are not specific to this view as specified by
-ViewName(left-most ribbon panel)
Filter- hides filter panel
PagingWhenNotNeeded- hides paging when list is shorter than the page specified
AllActions- hides all actions (right-most ribbon panel)
NonSpecificActions- hides actions that are not specific to this view as specified by
-ViewName(right-most ribbon panel)
StatusBar- hides status bar.