Admin accounts controller cleanup (#1664)
* Remove unused account_params method in admin/accounts controller * Introduce AccountFilter to find accounts * Use AccountFilter in admin/accounts controller * Use more restful routes admin silence and suspension area * Add admin/silences and admin/suspensions controllers
This commit is contained in:
parent
0e39cc6a35
commit
3a9eb81a80
9 changed files with 182 additions and 44 deletions
|
@ -1,3 +1,4 @@
|
|||
|
||||
# frozen_string_literal: true
|
||||
|
||||
require 'sidekiq/web'
|
||||
|
@ -89,12 +90,8 @@ Rails.application.routes.draw do
|
|||
end
|
||||
|
||||
resources :accounts, only: [:index, :show] do
|
||||
member do
|
||||
post :silence
|
||||
post :unsilence
|
||||
post :suspend
|
||||
post :unsuspend
|
||||
end
|
||||
resource :silence, only: [:create, :destroy]
|
||||
resource :suspension, only: [:create, :destroy]
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue