Ejemplo n.º 1
0
        public async Task <IActionResult> ApiSecretDelete(ApiSecretsDto apiSecret)
        {
            await _apiResourceService.DeleteApiSecretAsync(apiSecret);


            return(Success(new { Id = apiSecret.ApiResourceId }));
        }
        public async Task <IActionResult> ApiSecretDelete(ApiSecretsDto apiSecret)
        {
            await _apiResourceService.DeleteApiSecretAsync(apiSecret);

            SuccessNotification(_localizer["SuccessDeleteApiSecret"], _localizer["SuccessTitle"]);

            return(RedirectToAction(nameof(ApiSecrets), new { Id = apiSecret.ApiResourceId }));
        }
Ejemplo n.º 3
0
        public async Task <IActionResult> DeleteSecret(int secretId)
        {
            var apiSecret = new ApiSecretsDto {
                ApiSecretId = secretId
            };

            await _apiResourceService.GetApiSecretAsync(apiSecret.ApiSecretId);

            await _apiResourceService.DeleteApiSecretAsync(apiSecret);

            return(Ok());
        }