Skip to content

Commit 3663bc2

Browse files
authored
Merge pull request #115 from docusign/DEVDOCS-16547-remove-embed-example
[DEVDOCS-16547] Combine Embed Example Into Trigger Workflow
2 parents 0df921f + 3a42c2b commit 3663bc2

File tree

4 files changed

+23
-43
lines changed

4 files changed

+23
-43
lines changed

examples/Maestro/eg001TriggerWorkflow.sh

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,29 @@ echo ""
167167
echo "Use this URL to complete the workflow steps:"
168168
echo $decoded_instance_url
169169

170+
sleep 3
171+
172+
echo ""
173+
echo "Opening a browser with the embedded workflow..."
174+
175+
sleep 5
176+
177+
#ds-snippet-start:Maestro1Step6
178+
# [Optional] Launch local server and embed workflow instance using the instance URL
179+
decoded_instance_url=$(echo "$instance_url" | sed 's/\\u0026/\&/g')
180+
181+
182+
host_url="http://localhost:8080"
183+
if which xdg-open &> /dev/null ; then
184+
xdg-open $host_url
185+
elif which open &> /dev/null ; then
186+
open $host_url
187+
elif which start &> /dev/null ; then
188+
start $host_url
189+
fi
190+
php ./examples/Maestro/lib/startServerForEmbeddedWorkflow.php "$decoded_instance_url"
191+
#ds-snippet-end:Maestro1Step6
192+
170193
# Remove the temporary files
171194
rm "$request_data"
172195
rm "$response"

examples/Maestro/eg002EmbedWorkflow.sh

Lines changed: 0 additions & 35 deletions
This file was deleted.

examples/Maestro/lib/startServerForEmbeddedWorkflow.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,10 @@
3434
</style>
3535
</head>
3636
<body>
37-
#ds-snippet-start:Maestro2Step3
3837
<div>
3938
<iframe src=$triggerUrl width=800 height=600>
4039
</iframe>
4140
</div>
42-
#ds-snippet-end:Maestro2Step3
4341
</body>
4442
</html>
4543

launcher.sh

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -968,21 +968,15 @@ function startMaestro() {
968968
PS3='Select the action : '
969969
select CHOICE in \
970970
"Trigger_Workflow" \
971-
"Embed_Workflow" \
972971
"Home"; do
973972
case "$CHOICE" in
974-
975973
Home)
976974
choices
977975
;;
978976
Trigger_Workflow)
979977
bash examples/Maestro/eg001TriggerWorkflow.sh
980978
startMaestro
981979
;;
982-
Embed_Workflow)
983-
bash examples/Maestro/eg002EmbedWorkflow.sh
984-
startMaestro
985-
;;
986980
*)
987981
echo "Default action..."
988982
startMaestro

0 commit comments

Comments
 (0)