Browse Source

Just move some ode

pull/998/head 7.6.1
Sebastian 3 years ago
parent
commit
5567c7cb83
  1. 34
      backend/src/Squidex/Areas/Api/Controllers/Rules/RulesController.cs

34
backend/src/Squidex/Areas/Api/Controllers/Rules/RulesController.cs

@ -384,23 +384,6 @@ public sealed class RulesController : ApiController
return NoContent();
}
/// <summary>
/// Cancels all events.
/// </summary>
/// <param name="app">The name of the app.</param>
/// <response code="204">Events cancelled.</response>.
[HttpDelete]
[Route("apps/{app}/rules/events/")]
[ProducesResponseType(StatusCodes.Status204NoContent)]
[ApiPermissionOrAnonymous(PermissionIds.AppRulesEventsDelete)]
[ApiCosts(1)]
public async Task<IActionResult> DeleteEvents(string app)
{
await ruleEventsRepository.CancelByAppAsync(App.Id, HttpContext.RequestAborted);
return NoContent();
}
/// <summary>
/// Cancels an event.
/// </summary>
@ -427,6 +410,23 @@ public sealed class RulesController : ApiController
return NoContent();
}
/// <summary>
/// Cancels all events.
/// </summary>
/// <param name="app">The name of the app.</param>
/// <response code="204">Events cancelled.</response>.
[HttpDelete]
[Route("apps/{app}/rules/events/")]
[ProducesResponseType(StatusCodes.Status204NoContent)]
[ApiPermissionOrAnonymous(PermissionIds.AppRulesEventsDelete)]
[ApiCosts(1)]
public async Task<IActionResult> DeleteEvents(string app)
{
await ruleEventsRepository.CancelByAppAsync(App.Id, HttpContext.RequestAborted);
return NoContent();
}
/// <summary>
/// Provide a list of all event types that are used in rules.
/// </summary>

Loading…
Cancel
Save