Skip to content

Commit 0449b3a

Browse files
committed
removed publish workflow as we still use precreated workflow
1 parent 3d826ff commit 0449b3a

File tree

2 files changed

+2
-25
lines changed

2 files changed

+2
-25
lines changed

launcher-csharp/Maestro/Controllers/TriggerWorkflow.cs

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -49,17 +49,6 @@ public override IActionResult Get()
4949
}
5050

5151
this.RequestItemsService.WorkflowId = this.configuration["DocuSign:WorkflowId"];
52-
var accessToken = this.RequestItemsService.User.AccessToken;
53-
var accountId = this.RequestItemsService.Session.AccountId;
54-
55-
if (!this.RequestItemsService.IsWorkflowPublished)
56-
{
57-
var docuSignClient = new DocuSignClient(this.RequestItemsService.Session.MaestroManageApiBasePath);
58-
docuSignClient.Configuration.DefaultHeader.Add("Authorization", "Bearer " + accessToken);
59-
TriggerWorkflowService.PublishWorkFlow(docuSignClient, accountId, this.RequestItemsService.WorkflowId);
60-
this.RequestItemsService.IsWorkflowPublished = true;
61-
}
62-
6352
this.ViewBag.Config = this.Config;
6453
var workflowTriggerModel = new WorkflowTriggerModel();
6554

launcher-csharp/Maestro/Examples/TriggerWorkflowService.cs

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,15 @@
44

55
namespace DocuSign.WebForms.Examples
66
{
7+
using System;
8+
using System.Web;
79
using DocuSign.CodeExamples.Maestro.Models;
810
using DocuSign.Maestro.Api;
911
using DocuSign.Maestro.Client;
1012
using DocuSign.Maestro.Model;
11-
using System;
12-
using System.Collections.Generic;
13-
using System.Linq;
14-
using System.Web;
15-
using static Microsoft.EntityFrameworkCore.DbLoggerCategory;
1613

1714
public static class TriggerWorkflowService
1815
{
19-
20-
public static void PublishWorkFlow(DocuSignClient docuSignClient, string accountId, string workflowId)
21-
{
22-
var maestroApi = new WorkflowManagementApi(docuSignClient);
23-
maestroApi.PublishOrUnPublishWorkflowDefinition(accountId, workflowId, new DeployRequest());
24-
25-
// add logic for consent url when create workflow feature will be ready to be used
26-
}
27-
2816
public static WorkflowDefinitionWithId GetWorkFlowDefinition(DocuSignClient docuSignClient, string accountId, string workflowId)
2917
{
3018
var maestroApi = new WorkflowManagementApi(docuSignClient);

0 commit comments

Comments
 (0)