From 4aa6898ecb13606b66c661a2d37a2d77494f4501 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Tue, 14 Feb 2023 11:58:50 +1100 Subject: [PATCH] Reduce line length for easier reading --- lib/reporting/reports/enterprise_fee_summary/parameters.rb | 5 +++-- lib/reporting/reports/enterprise_fee_summary/scope.rb | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lib/reporting/reports/enterprise_fee_summary/parameters.rb b/lib/reporting/reports/enterprise_fee_summary/parameters.rb index 5163625b7b..de74521af0 100644 --- a/lib/reporting/reports/enterprise_fee_summary/parameters.rb +++ b/lib/reporting/reports/enterprise_fee_summary/parameters.rb @@ -6,8 +6,9 @@ module Reporting class Parameters < Reporting::Reports::EnterpriseFeeSummary::Reports::Parameters::Base include ActiveModel::Validations - attr_accessor :completed_at_gt, :completed_at_lt, :distributor_ids, :producer_ids, :order_cycle_ids, - :enterprise_fee_ids, :shipping_method_ids, :payment_method_ids + attr_accessor :completed_at_gt, :completed_at_lt, :distributor_ids, + :producer_ids, :order_cycle_ids, :enterprise_fee_ids, + :shipping_method_ids, :payment_method_ids before_validation :cleanup_arrays diff --git a/lib/reporting/reports/enterprise_fee_summary/scope.rb b/lib/reporting/reports/enterprise_fee_summary/scope.rb index 0b5cfa8944..651ecbb035 100644 --- a/lib/reporting/reports/enterprise_fee_summary/scope.rb +++ b/lib/reporting/reports/enterprise_fee_summary/scope.rb @@ -317,7 +317,8 @@ module Reporting def filter_by_date(params) filter_scope("spree_orders.completed_at >= ?", params.completed_at_gt) \ if params.completed_at_gt.present? - filter_scope("spree_orders.completed_at <= ?", params.completed_at_lt) if params.completed_at_lt.present? + filter_scope("spree_orders.completed_at <= ?", params.completed_at_lt) \ + if params.completed_at_lt.present? end def filter_by_distribution(params)