Created
October 7, 2018 02:30
-
-
Save michaellwest/09dc454441142f9ef4e360050af1d6de to your computer and use it in GitHub Desktop.
Displays a dialog using Sitecore PowerShell Extensions.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Be sure to update this ID to whichever script you want to execute when the link is clicked. | |
$scriptId = "{6EAF681D-5D87-4C43-B279-356A8B9A15CF}" | |
$item = Get-Item -Path "." | |
$script = Get-Item -Path "master:" -ID $scriptId | |
$command = "item:executescript(id=$($item.ID),db=$($item.Database.Name),script=$($script.ID),scriptDb=$($script.Database.Name))" | |
$options = [ordered]@{"Download Sample"=$command;"View Documentation"=$command;} | |
$props = @{ | |
Parameters = @( | |
@{Name="buttons"; Title="Super Userful Links"; Value = "Something interesting going on here."; Options=$options; Editor="link"; } | |
) | |
Title = "Command Dialog Demo" | |
Icon = "OfficeWhite/32x32/fire.png" | |
Description = "Provides an example of how to add links to the dialog." | |
Width = 450 | |
Height = 300 | |
ShowHints = $true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment