Browse Source

refactor: slight cleanup

pull/1675/head
natdeanlewissoftwire 3 years ago
parent
commit
68378d106c
  1. 1
      app/controllers/logs_controller.rb
  2. 1
      app/controllers/organisations_controller.rb
  3. 2
      app/views/logs/_log_filters.erb

1
app/controllers/logs_controller.rb

@ -1,6 +1,5 @@
class LogsController < ApplicationController class LogsController < ApplicationController
include Pagy::Backend include Pagy::Backend
include Modules::LogsFilter
include Modules::SearchFilter include Modules::SearchFilter
skip_before_action :verify_authenticity_token, if: :json_api_request? skip_before_action :verify_authenticity_token, if: :json_api_request?

1
app/controllers/organisations_controller.rb

@ -1,6 +1,5 @@
class OrganisationsController < ApplicationController class OrganisationsController < ApplicationController
include Pagy::Backend include Pagy::Backend
include Modules::LogsFilter
include Modules::SearchFilter include Modules::SearchFilter
before_action :authenticate_user! before_action :authenticate_user!

2
app/views/logs/_log_filters.erb

@ -39,7 +39,6 @@
<%= render partial: "filters/radio_filter", <%= render partial: "filters/radio_filter",
locals: { locals: {
f: f, f: f,
filter_type: @filter_type,
options: all_or_yours, options: all_or_yours,
label: "Logs", label: "Logs",
category: "user", category: "user",
@ -48,7 +47,6 @@
<% if (@current_user.support? || @current_user.organisation.has_managing_agents?) && request.path == "/lettings-logs" %> <% if (@current_user.support? || @current_user.organisation.has_managing_agents?) && request.path == "/lettings-logs" %>
<%= render partial: "filters/radio_filter", locals: { <%= render partial: "filters/radio_filter", locals: {
f: f, f: f,
filter_type: @filter_type,
options: { options: {
"all": { label: "All" }, "all": { label: "All" },
"specific_org": { "specific_org": {

Loading…
Cancel
Save