Skip to content

Commit

Permalink
remove crossref dois from stats portal. #53
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Oct 9, 2020
1 parent d67ddd6 commit 63bd21c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/concerns/facetable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ def facet_by_registrants(arr)
end

def providers_totals(arr)
providers = Provider.all.pluck(:symbol, :name).to_h
providers = Provider.unscoped.where("allocator.role_name IN ('ROLE_FOR_PROFIT_PROVIDER', 'ROLE_CONTRACTUAL_PROVIDER', 'ROLE_CONSORTIUM' , 'ROLE_CONSORTIUM_ORGANIZATION', 'ROLE_ALLOCATOR')").where(deleted_at: nil).pluck(:symbol, :name).to_h

arr.map do |hsh|
{ "id" => hsh["key"],
Expand Down
1 change: 1 addition & 0 deletions spec/requests/providers_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@

describe 'GET /providers/totals' do
let(:provider) { create(:provider) }
let(:ra) { create(:provider, role_name: "ROLE_REGISTRATION_AGENCY") }
let(:client) { create(:client, provider: provider) }
let!(:prefixes) { create_list(:prefix, 10) }
let!(:dois) { create_list(:doi, 3, client: client, aasm_state: "findable") }
Expand Down

0 comments on commit 63bd21c

Please sign in to comment.