style check
This commit is contained in:
parent
752c40657d
commit
32da0fa891
3 changed files with 15 additions and 25 deletions
|
@ -1,11 +1,9 @@
|
|||
class SIADE::API
|
||||
|
||||
class << self
|
||||
attr_accessor :token
|
||||
end
|
||||
|
||||
def initialize
|
||||
|
||||
end
|
||||
|
||||
def self.entreprise(siren)
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
class SIADE::EntrepriseAdapter
|
||||
|
||||
def initialize(siren)
|
||||
@siren = siren
|
||||
end
|
||||
|
@ -13,10 +12,8 @@ class SIADE::EntrepriseAdapter
|
|||
def to_params
|
||||
params = {}
|
||||
|
||||
data_source[:entreprise].each do |k,v|
|
||||
if attr_to_fetch.include?(k)
|
||||
params[k] = v
|
||||
end
|
||||
data_source[:entreprise].each do |k, v|
|
||||
params[k] = v if attr_to_fetch.include?(k)
|
||||
end
|
||||
params
|
||||
rescue
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
class SIADE::EtablissementAdapter
|
||||
|
||||
def initialize(siret)
|
||||
@siret = siret
|
||||
end
|
||||
|
@ -11,16 +10,12 @@ class SIADE::EtablissementAdapter
|
|||
def to_params
|
||||
params = {}
|
||||
|
||||
data_source[:etablissement].each do |k,v|
|
||||
if attr_to_fetch.include?(k)
|
||||
params[k] = v
|
||||
end
|
||||
data_source[:etablissement].each do |k, v|
|
||||
params[k] = v if attr_to_fetch.include?(k)
|
||||
end
|
||||
params[:adresse] = adresse
|
||||
data_source[:etablissement][:adresse].each do |k,v|
|
||||
if address_attribut_to_fetch.include?(k)
|
||||
params[k] = v
|
||||
end
|
||||
data_source[:etablissement][:adresse].each do |k, v|
|
||||
params[k] = v if address_attribut_to_fetch.include?(k)
|
||||
end
|
||||
params
|
||||
end
|
||||
|
@ -29,7 +24,7 @@ class SIADE::EtablissementAdapter
|
|||
[:siret,
|
||||
:siege_social,
|
||||
:naf,
|
||||
:libelle_naf,
|
||||
:libelle_naf
|
||||
]
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue