Skip to content

Commit

Permalink
Remove bank name, bank account number and bank code ui
Browse files Browse the repository at this point in the history
  • Loading branch information
Marc Altmann committed Apr 19, 2016
1 parent f4b0d23 commit 0aa65ed
Show file tree
Hide file tree
Showing 10 changed files with 4 additions and 24 deletions.
2 changes: 1 addition & 1 deletion app/models/user/extended_attributes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module User::ExtendedAttributes
included do
extend Sanitization

auto_sanitize :nickname, :bank_name
auto_sanitize :nickname
auto_sanitize :iban, :bic, remove_all_spaces: true
auto_sanitize :about_me, :terms, :cancellation, :about, method: 'tiny_mce'

Expand Down
7 changes: 3 additions & 4 deletions app/refineries/user_refinery.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,11 @@ def update
permitted = [
:current_password, # <- update specific
:email, :password, :password_confirmation, :remember_me, :type,
:nickname, :legal, :paypal_account,
:banned, :about_me,
:phone, :mobile, :fax,
:nickname, :legal, :paypal_account, :banned,
:about_me, :phone, :mobile, :fax,
:company_name, :max_value_of_goods_cents_bonus,
:fastbill_profile_update, :vacationing, :newsletter, :receive_comments_notification,
:iban, :bic, :bank_name, :bank_account_owner, :direct_debit_confirmation,
:iban, :bic, :bank_account_owner, :direct_debit_confirmation,
:unified_transport_provider, :unified_transport_maximum_articles, :unified_transport_price,
:free_transport_available, :free_transport_at_price,
{ image_attributes: ImageRefinery.new(Image.new, user).default }
Expand Down
4 changes: 0 additions & 4 deletions app/views/articles/form/_common_inputs.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,6 @@
= f.inputs id: 'payment_bank_transfer-checked', class: "payment_bank_transfer" do
= f.semantic_fields_for :seller do |user|
= user.input :bank_account_owner, required: true, input_html: { value: current_user.bank_account_owner, disabled: true}, label: t('formtastic.labels.user.bank_account_owner')
= user.input :bank_code, required: true, input_html: {id: "bank_code", value: current_user.bank_code, disabled: true }, label: t('formtastic.labels.user.bank_code')
= user.input :bank_name, required: true, input_html: {id: "bank_name", value: current_user.bank_name, disabled: true }, label: t('formtastic.labels.user.bank_name')
= user.input :bank_account_number, required: true, input_html: {id: "bank_account_number", value: current_user.bank_account_number, disabled: true }, label: t('formtastic.labels.user.bank_account_number')

= user.input :iban, required: true, input_html: {id: "iban", value: current_user.iban, disabled: true }, label: t('formtastic.labels.user.iban')
= user.input :bic, required: true, input_html: {id: "bic", value: current_user.bic, disabled: true }, label: t('formtastic.labels.user.bic')

Expand Down
2 changes: 0 additions & 2 deletions app/views/devise/registrations/edit.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -159,8 +159,6 @@ h1= t('common.actions.edit_profile')
h3= t('users.form_titles.payment_bank_account')

= f.input :bank_account_owner, required: true, label: t('formtastic.labels.user.bank_account_owner')
= f.input :bank_name, input_html: {id: "bank_name"}, label: t('formtastic.labels.user.bank_name')

= f.input :iban, required: true, input_html: {id: "iban"}, label: t('formtastic.labels.user.iban'), tooltip: true
= f.input :bic, required: true, input_html: {id: "bic"}, label: t('formtastic.labels.user.bic'), tooltip: true

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
= bank_account_line(seller, :bank_account_owner)
= bank_account_line(seller, :iban)
= bank_account_line(seller, :bic)
= bank_account_line(seller, :bank_name)
.line
.heading
= "#{I18n.t("line_item_group.texts.bank_transfer_purpose")}:"
Expand Down
1 change: 0 additions & 1 deletion app/views/line_item_groups/show/_donations.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
= bank_account_line(organisation, :bank_account_owner)
= bank_account_line(organisation, :iban)
= bank_account_line(organisation, :bic)
= bank_account_line(organisation, :bank_name)

- elsif role == 'buyer'
.line
Expand Down
3 changes: 0 additions & 3 deletions config/initializers/rails_admin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -264,9 +264,6 @@
field :slug
field(:type) { read_only true }
field :bank_account_owner
field :bank_account_number
field :bank_code
field :bank_name
field :iban
field :bic
field :paypal_account
Expand Down
3 changes: 0 additions & 3 deletions config/locales/old/gems/formtastic/de.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ de:
about: "Impressum und Kontakt"
alternative_emails: "Normalerweise werden alle Deine E-Mails an %{email} geschickt. Hier kannst du spezielle E-Mail-Adressen eingeben, an die Rechnungen von Fairmondo oder Bestellbestätigungen geschickt werden."
bank_account_notification: "(Beachte, dass sich eine Änderung auf all Deine Artikel auswirkt, bei der Du die Bezahloption \"Überweisung\" gewählt hast.)"
bank_code: "Bankleitzahl"
bank_name: "Name der Bank"
bank_account_number: "Kontonummer"
bank_account_owner: "Kontoinhaber*in"
iban: "IBAN"
bic: "BIC"
Expand Down
3 changes: 0 additions & 3 deletions config/locales/old/transaction/de.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,6 @@ de:
fees: "Deine Gebühren: "
donations: "Das faire Prozent: "
bank_account_owner: "Kontoinhaber*in: "
bank_account_number: "Kontonummer: "
bank_code: "Bankleitzahl: "
bank_name: "Name der Bank: "
iban: "IBAN: "
bic: "BIC: "
custom_seller_identifier: "Artikelnummer: "
Expand Down
2 changes: 0 additions & 2 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@
end

namespace :bank_details do
get 'check', constraints: { format: 'json' }
get 'acquire_bank_name', constraints: { format: 'json' }
get 'check_iban', constraints: { format: 'json' }
get 'check_bic', constraints: { format: 'json' }
end
Expand Down

0 comments on commit 0aa65ed

Please sign in to comment.