Merge pull request #8928 from tchak/feat-api-public-stats
ETQ citoyen, je voudrais avoir accès aux statistiques des démarches closes
This commit is contained in:
commit
39ba03783a
2 changed files with 2 additions and 2 deletions
|
@ -14,7 +14,7 @@ class API::Public::V1::StatsController < API::Public::V1::BaseController
|
|||
private
|
||||
|
||||
def retrieve_procedure
|
||||
@procedure = Procedure.publiees_ou_brouillons.opendata.find_by(id: params[:id])
|
||||
@procedure = Procedure.opendata.find_by(id: params[:id])
|
||||
render_not_found("procedure", params[:id]) if @procedure.blank?
|
||||
end
|
||||
end
|
||||
|
|
|
@ -62,7 +62,7 @@ RSpec.describe API::Public::V1::StatsController, type: :controller do
|
|||
end
|
||||
|
||||
context 'when the procedure is not publiee and not brouillon' do
|
||||
it_behaves_like 'the procedure is not found' do
|
||||
it_behaves_like 'the procedure is found' do
|
||||
let(:procedure) { create(:procedure, :closed) }
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue