public async Task UpdateBusinessNameAsync(BusinessNameUpdateRequest model)
        {
            await _client
            .For <Ntt_breathingspacemoratorium>()
            .Key(model.MoratoriumId)
            .Action("ntt_BSSAPIMABusinessUpdate")
            .Set(model.ToDictionary())
            .ExecuteAsync();

            var contentDict = model.ToDictionary();

            contentDict.Add(nameof(model.MoratoriumId), model.MoratoriumId);
            contentDict.Add("ntt_BSSAPIMABusinessUpdate", true);
            await _auditService.PerformAuditing(_auditContext.ToAuditDetail(contentDict));
        }
Пример #2
0
        public async Task <IStatusCodeActionResult> UpdateBusinessNameAsync([FromRoute] Guid bsid, [FromRoute] Guid bid, BusinessNameUpdateRequest model)
        {
            model.MoratoriumId = bsid;
            model.BusinessId   = bid;

            if (bsid == Guid.Empty)
            {
                throw new NotFoundHttpResponseException();
            }

            if (bid == Guid.Empty)
            {
                throw new NotFoundHttpResponseException();
            }

            await _moneyAdviserGateway.UpdateBusinessNameAsync(model);

            return(Ok());
        }