Ejemplo n.º 1
0
        public async Task UpdateIssueAsync(Issue issue, IssueUpdateOptions options, CancellationToken token = default(CancellationToken))
        {
            var resource = String.Format("rest/api/2/issue/{0}", issue.Key.Value);

            if (options.SuppressEmailNotification)
            {
                resource += "?notifyUsers=false";
            }
            var fieldProvider = issue as IRemoteIssueFieldProvider;
            var remoteFields  = await fieldProvider.GetRemoteFieldValuesAsync(token).ConfigureAwait(false);

            var remoteIssue = await issue.ToRemoteAsync(token).ConfigureAwait(false);

            var fields = await this.BuildFieldsObjectFromIssueAsync(remoteIssue, remoteFields, token).ConfigureAwait(false);

            await _jira.RestClient.ExecuteRequestAsync(Method.PUT, resource, new { fields = fields }, token).ConfigureAwait(false);
        }
Ejemplo n.º 2
0
        public Task UpdateIssueAsync(Issue issue, CancellationToken token = default(CancellationToken))
        {
            var options = new IssueUpdateOptions();

            return(UpdateIssueAsync(issue, options, token));
        }