rails up to 7.0and ruby to 2.7.2
mv lib to app/lib due to upgrade removing concerns from autoload path resolve zeitwerk issues make foodsoft run for dev on rails 7 and ruby 2.7 fix mail file permission bug fix database_config fix articles controller test ActiveModell::Error bump Gemfile.lock
This commit is contained in:
parent
d7591d46b9
commit
fb8ccfea4a
53 changed files with 583 additions and 594 deletions
30
app/lib/bank_account_connector_external.rb
Normal file
30
app/lib/bank_account_connector_external.rb
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
class BankAccountConnectorExternal < BankAccountConnector
|
||||
def load(data)
|
||||
@connector = create_connector
|
||||
@connector.load data
|
||||
end
|
||||
|
||||
def dump
|
||||
@connector.dump
|
||||
end
|
||||
|
||||
def connector_import
|
||||
set_balance @connector.balance iban
|
||||
cp = @connector.transactions iban, continuation_point do |t|
|
||||
update_or_create_transaction t[:id], map_transaction(t)
|
||||
end
|
||||
set_continuation_point cp if cp
|
||||
end
|
||||
|
||||
def connector_logout
|
||||
@connector.logout
|
||||
end
|
||||
|
||||
def import(data)
|
||||
return false unless connector_login(data)
|
||||
|
||||
connector_import
|
||||
connector_logout
|
||||
true
|
||||
end
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue