From 4c190a035604503c13a5ed10ab325612d5f7a971 Mon Sep 17 00:00:00 2001 From: Artur Beljajev Date: Thu, 8 Mar 2018 13:41:35 +0200 Subject: [PATCH 1/3] Remove unused date/time formats --- config/locales/en.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/config/locales/en.yml b/config/locales/en.yml index 00923faf2..9e00196fc 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -19,7 +19,6 @@ en: time: formats: default: "%Y-%m-%d %H:%M" - longer: "%a, %e. %b %Y, %H:%M" long: "%A, %e. %B %Y, %H:%M" short: "%d.%m.%y, %H:%M" date: "%Y-%m-%d" @@ -28,7 +27,6 @@ en: date: formats: default: "%Y-%m-%d" - year_and_month: "%Y %B" activerecord: errors: From f7301c3aeab76623ab3bf8d5b05bc5bf877f77bc Mon Sep 17 00:00:00 2001 From: Artur Beljajev Date: Thu, 8 Mar 2018 14:36:19 +0200 Subject: [PATCH 2/3] Remove unused attribute Closes #747 --- app/controllers/admin/registrars_controller.rb | 1 - app/views/admin/registrars/show.html.erb | 6 ------ config/locales/en.yml | 1 - .../20180308123240_remove_registrar_billing_address.rb | 5 +++++ db/structure.sql | 3 ++- doc/models_complete.svg | 1 - lib/tasks/import.rake | 1 - 7 files changed, 7 insertions(+), 11 deletions(-) create mode 100644 db/migrate/20180308123240_remove_registrar_billing_address.rb diff --git a/app/controllers/admin/registrars_controller.rb b/app/controllers/admin/registrars_controller.rb index 119abf85b..8d020787b 100644 --- a/app/controllers/admin/registrars_controller.rb +++ b/app/controllers/admin/registrars_controller.rb @@ -70,7 +70,6 @@ module Admin :city, :state, :zip, - :billing_address, :country_code, :email, :phone, diff --git a/app/views/admin/registrars/show.html.erb b/app/views/admin/registrars/show.html.erb index c09602985..a6f2240a9 100644 --- a/app/views/admin/registrars/show.html.erb +++ b/app/views/admin/registrars/show.html.erb @@ -114,12 +114,6 @@
<%= @registrar.email %>
-
- <%= t(:billing_address) %> -
-
- <%= @registrar.billing_address %> -
<%= t(:billing_email) %>
diff --git a/config/locales/en.yml b/config/locales/en.yml index 00923faf2..a02ac1d26 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -395,7 +395,6 @@ en: choose: 'Choose...' created_before: 'Created before' created_after: 'Created after' - billing_address: 'Billing address' billing_email: 'Billing e-mail' contact_phone: 'Contact phone' contact_email: 'Contact e-mail' diff --git a/db/migrate/20180308123240_remove_registrar_billing_address.rb b/db/migrate/20180308123240_remove_registrar_billing_address.rb new file mode 100644 index 000000000..dbbbf2557 --- /dev/null +++ b/db/migrate/20180308123240_remove_registrar_billing_address.rb @@ -0,0 +1,5 @@ +class RemoveRegistrarBillingAddress < ActiveRecord::Migration + def change + remove_column :registrars, :billing_address + end +end diff --git a/db/structure.sql b/db/structure.sql index b303afbe7..a9257ffa3 100644 --- a/db/structure.sql +++ b/db/structure.sql @@ -2139,7 +2139,6 @@ CREATE TABLE registrars ( name character varying, reg_no character varying, vat_no character varying, - billing_address character varying, created_at timestamp without time zone, updated_at timestamp without time zone, creator_str character varying, @@ -4678,3 +4677,5 @@ INSERT INTO schema_migrations (version) VALUES ('20180306183540'); INSERT INTO schema_migrations (version) VALUES ('20180306183549'); +INSERT INTO schema_migrations (version) VALUES ('20180308123240'); + diff --git a/doc/models_complete.svg b/doc/models_complete.svg index 9e5d6f4e5..296d20c67 100644 --- a/doc/models_complete.svg +++ b/doc/models_complete.svg @@ -1475,7 +1475,6 @@ name :string reg_no :string vat_no :string -billing_address :string created_at :datetime updated_at :datetime creator_str :string diff --git a/lib/tasks/import.rake b/lib/tasks/import.rake index c3b67ba88..f26ad252f 100644 --- a/lib/tasks/import.rake +++ b/lib/tasks/import.rake @@ -77,7 +77,6 @@ namespace :import do name: x.organization.try(:strip).presence || x.name.try(:strip).presence || x.handle.try(:strip).presence, reg_no: x.ico.try(:strip), vat_no: x.dic.try(:strip), - billing_address: nil, phone: x.telephone.try(:strip), email: x.email.try(:strip), billing_email: x.billing_address.try(:strip), From a338c294f71b30e96e3c9a589641d73f015f052e Mon Sep 17 00:00:00 2001 From: Artur Beljajev Date: Thu, 8 Mar 2018 17:32:37 +0200 Subject: [PATCH 3/3] Update rack, rack-protection gems #768 --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index ed1d7be26..ed559f465 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -301,12 +301,12 @@ GEM erubis que (~> 0.8) sinatra - rack (1.6.8) + rack (1.6.9) rack-accept (0.4.5) rack (>= 0.4) rack-mount (0.8.3) rack (>= 1.0.0) - rack-protection (1.5.3) + rack-protection (1.5.5) rack rack-test (0.6.3) rack (>= 1.0)