to_spotlight 0.2.6 → 0.2.7
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 070111e1947b8dfc8761c5733c4e896f196be0e2e35a2d6705a3966fc03d0ced
|
4
|
+
data.tar.gz: 259d653332a734d74c82fcf49ec532803c39c868bf0217bcaea6a429d9c519aa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1295991e10c234798c3b25d8260af0a5f750b1929103d5a7631b6722134c4a63bbac936f491135ff31b0ef86687e360422fcfce2330b8cf702cc17f3cab9e1d
|
7
|
+
data.tar.gz: 1758daf976e1710b890caf97524744c8643c4dd6bd8e839007fc4e69a80d05c301dc5b41c5a6867a5857a9b7b7fbad655d877781ee06e2d5a10654fcba91eadf
|
data/config/routes.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Rails.application.routes.draw do
|
2
2
|
get '/to_spotlight/api/:request_type' => 'to_spotlight/spotlight_transfer#api', as: 'to_spotlight_api'
|
3
3
|
post '/to_spotlight/receive' => 'to_spotlight/spotlight_transfer#receive'
|
4
|
-
get '/to_spotlight' => 'to_spotlight/spotlight_transfer#index'
|
4
|
+
get '/to_spotlight' => 'to_spotlight/spotlight_transfer#index', as: 'to_spotlight_index'
|
5
5
|
post '/to_spotlight/approve' => 'to_spotlight/spotlight_transfer#approve'
|
6
6
|
end
|
@@ -1,7 +1,21 @@
|
|
1
|
-
class
|
1
|
+
class ToSpotlight::InstallGenerator < Rails::Generators::Base
|
2
2
|
source_root File.expand_path('../templates', __FILE__)
|
3
3
|
|
4
4
|
def inject_content_dm_yml
|
5
5
|
copy_file('config/to_spotlight.yml', 'config/to_spotlight.yml') unless File.file?('config/to_spotlight.yml')
|
6
6
|
end
|
7
|
+
|
8
|
+
def inject_dashboard_link
|
9
|
+
file_path = 'app/views/hyrax/dashboard/sidebar/_tasks.html.erb'
|
10
|
+
if File.file?(file_path)
|
11
|
+
insert_into_file file_path, before: /[ \t]*<% if can\? :manage, User %>/m do
|
12
|
+
" \n<% if can? :review, :submissions %>\n" \
|
13
|
+
" <%= menu.nav_link(main_app.to_spotlight_index_path) do %>\n" \
|
14
|
+
" <span class=\"fa fa-flag\" aria-hidden=\"true\"></span> <span class=\"sidebar-action-text\"><%= t('Spotlight Transfers') %></span>\n" \
|
15
|
+
" <% end %>\n\n"
|
16
|
+
end
|
17
|
+
else
|
18
|
+
copy_file 'sidebar/_tasks.html.erb', 'app/views/hyrax/dashboard/sidebar/_tasks.html.erb'
|
19
|
+
end
|
20
|
+
end
|
7
21
|
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
<li class="h5"><%= t('hyrax.admin.sidebar.tasks') %></li>
|
2
|
+
|
3
|
+
<% if can? :review, :submissions %>
|
4
|
+
<%= menu.nav_link(hyrax.admin_workflows_path) do %>
|
5
|
+
<span class="fa fa-flag" aria-hidden="true"></span>
|
6
|
+
<span class="sidebar-action-text"><%= t('hyrax.admin.sidebar.workflow_review') %></span>
|
7
|
+
<% end %>
|
8
|
+
<% end %>
|
9
|
+
|
10
|
+
<% if can? :review, :submissions %>
|
11
|
+
<%= menu.nav_link(main_app.to_spotlight_index_path) do %>
|
12
|
+
<span class="fa fa-flag" aria-hidden="true"></span>
|
13
|
+
<span class="sidebar-action-text"><%= t('Spotlight Transfers') %></span>
|
14
|
+
<% end %>
|
15
|
+
<% end %>
|
16
|
+
|
17
|
+
<% if can? :manage, User %>
|
18
|
+
<%= menu.nav_link(hyrax.admin_users_path) do %>
|
19
|
+
<span class="fa fa-user" aria-hidden="true"></span>
|
20
|
+
<span class="sidebar-action-text"><%= t('hyrax.admin.sidebar.users') %></span>
|
21
|
+
<% end %>
|
22
|
+
<% end %>
|
23
|
+
|
24
|
+
<% if can? :manage, Hyku::Group %>
|
25
|
+
<%= menu.nav_link(main_app.admin_groups_path) do %>
|
26
|
+
<span class="fa fa-users"></span>
|
27
|
+
<span class="sidebar-action-text"><%= t('hyrax.admin.sidebar.manage_groups') %></span>
|
28
|
+
<% end %>
|
29
|
+
<% end %>
|
30
|
+
|
31
|
+
<% if can? :read, :admin_dashboard %>
|
32
|
+
<%= menu.nav_link(hyrax.embargoes_path) do %>
|
33
|
+
<span class="fa fa-flag" aria-hidden="true"></span>
|
34
|
+
<span class="sidebar-action-text"><%= t('hyrax.embargoes.index.manage_embargoes') %></span>
|
35
|
+
<% end %>
|
36
|
+
|
37
|
+
<%= menu.nav_link(hyrax.leases_path) do %>
|
38
|
+
<span class="fa fa-flag" aria-hidden="true"></span>
|
39
|
+
<span class="sidebar-action-text"><%= t('hyrax.leases.index.manage_leases') %></span>
|
40
|
+
<% end %>
|
41
|
+
<% end %>
|
data/lib/to_spotlight/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: to_spotlight
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sephirothkod
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-05-
|
11
|
+
date: 2020-05-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -71,6 +71,7 @@ files:
|
|
71
71
|
- db/migrate/20200310153953_create_to_spotlight_spotlight_transfers.rb
|
72
72
|
- lib/generators/install/install_generator.rb
|
73
73
|
- lib/generators/install/templates/config/to_spotlight.yml
|
74
|
+
- lib/generators/install/templates/sidebar/_tasks.html.erb
|
74
75
|
- lib/tasks/to_spotlight_tasks.rake
|
75
76
|
- lib/to_spotlight.rb
|
76
77
|
- lib/to_spotlight/engine.rb
|