commit
7130e75913
3 changed files with 9 additions and 2 deletions
|
@ -817,7 +817,7 @@ class Dossier < ApplicationRecord
|
|||
|
||||
columns += [
|
||||
['Archivé', :archived],
|
||||
['État du dossier', I18n.t(state, scope: [:activerecord, :attributes, :dossier, :state])],
|
||||
['État du dossier', Dossier.human_attribute_name("state.#{state}")],
|
||||
['Dernière mise à jour le', :updated_at],
|
||||
['Déposé le', :en_construction_at],
|
||||
['Passé en instruction le', :en_instruction_at],
|
||||
|
|
|
@ -15,6 +15,7 @@ RSpec.describe APIEntreprise::ExercicesJob, type: :job do
|
|||
|
||||
it 'updates etablissement' do
|
||||
subject
|
||||
expect(Etablissement.find(etablissement.id).exercices[0].ca).to eq('21009417')
|
||||
ca_list = Etablissement.find(etablissement.id).exercices.map(&:ca)
|
||||
expect(ca_list).to contain_exactly('21009417', '18968298', '17768838')
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1430,4 +1430,10 @@ describe Dossier do
|
|||
expect(dossier.destroy).to be_truthy
|
||||
end
|
||||
end
|
||||
|
||||
describe "#spreadsheet_columns" do
|
||||
let(:dossier) { create(:dossier) }
|
||||
|
||||
it { expect(dossier.spreadsheet_columns(types_de_champ: [], types_de_champ_private: [])).to include(["État du dossier", "Brouillon"]) }
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue