Exemplo n.º 1
0
        public async Task <IActionResult> DeleteRiskPassword([FromBody] Api.RiskPasswordDelete riskPasswordDelete)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            var ids = new List <string>();

            foreach (var passwordSha1Hash in riskPasswordDelete.PasswordSha1Hashs)
            {
                ids.Add(await RiskPassword.IdFormat(passwordSha1Hash));
            }

            await masterRepository.DeleteBulkAsync <RiskPassword>(ids);

            return(NoContent());
        }