Skip to content
This repository has been archived by the owner on Jun 27, 2020. It is now read-only.

Commit

Permalink
Merge branch 'release-4.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
dchandekstark committed Oct 7, 2015
2 parents 5befd3d + 2014505 commit f538dbd
Show file tree
Hide file tree
Showing 154 changed files with 2,207 additions and 4,752 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ before_install:
- sudo apt-get install -qq libclamav6 libclamav-dev clamav clamav-data
- sudo apt-get install -qq libvips-dev
rvm:
- 2.1
- 2.1.3
before_script:
- "cp config/log4r.yml.sample config/log4r.yml"
cache: bundler
Expand Down
3 changes: 2 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ source 'http://rubygems.org'
gem 'rails', '~> 4.1.6'
gem 'hydra-head', '~> 7.2.0'
gem 'ddr-alerts', '~> 1.0.0'
gem 'ddr-models', '2.0.1'
gem 'ddr-batch', '1.0.0'
gem 'ddr-models', '2.1.1'
gem 'rubydora', '>= 1.8.1'
gem 'devise'
gem 'deprecation'
Expand Down
71 changes: 40 additions & 31 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
GEM
remote: http://rubygems.org/
specs:
actionmailer (4.1.10)
actionpack (= 4.1.10)
actionview (= 4.1.10)
actionmailer (4.1.13)
actionpack (= 4.1.13)
actionview (= 4.1.13)
mail (~> 2.5, >= 2.5.4)
actionpack (4.1.10)
actionview (= 4.1.10)
activesupport (= 4.1.10)
actionpack (4.1.13)
actionview (= 4.1.13)
activesupport (= 4.1.13)
rack (~> 1.5.2)
rack-test (~> 0.6.2)
actionview (4.1.10)
activesupport (= 4.1.10)
actionview (4.1.13)
activesupport (= 4.1.13)
builder (~> 3.1)
erubis (~> 2.7.0)
active-fedora (7.1.2)
Expand All @@ -29,14 +29,14 @@ GEM
deprecation (~> 0.1)
linkeddata (~> 1.1)
rdf (~> 1.1)
activemodel (4.1.10)
activesupport (= 4.1.10)
activemodel (4.1.13)
activesupport (= 4.1.13)
builder (~> 3.1)
activerecord (4.1.10)
activemodel (= 4.1.10)
activesupport (= 4.1.10)
activerecord (4.1.13)
activemodel (= 4.1.13)
activesupport (= 4.1.13)
arel (~> 5.0.0)
activesupport (4.1.10)
activesupport (4.1.13)
i18n (~> 0.6, >= 0.6.9)
json (~> 1.7, >= 1.7.7)
minitest (~> 5.1)
Expand Down Expand Up @@ -80,12 +80,20 @@ GEM
database_cleaner (1.4.0)
ddr-alerts (1.0.0)
rails (~> 4.1.6)
ddr-antivirus (1.3.3)
activesupport (~> 4.0)
ddr-models (2.0.1)
ddr-antivirus (2.0.0)
ddr-aux-client (1.2.1)
hashie (~> 3.4)
ddr-batch (1.0.0)
ddr-models (~> 2.1.0)
devise (~> 3.4)
log4r
paperclip (~> 4.2.0)
rails (~> 4.1.13)
ddr-models (2.1.1)
active-fedora (~> 7.0)
cancancan (~> 1.12)
ddr-antivirus (~> 1.3.1)
ddr-antivirus (= 2.0.0)
ddr-aux-client (~> 1.2, >= 1.2.1)
devise (~> 3.4)
ezid-client (~> 1.1, >= 1.1.1)
grouper-rest-client
Expand Down Expand Up @@ -198,7 +206,7 @@ GEM
mime-types (>= 1.16, < 3)
mime-types (2.6.1)
mini_portile (0.6.2)
minitest (5.7.0)
minitest (5.8.0)
mono_logger (1.1.0)
multi_json (1.11.0)
mysql2 (0.3.17)
Expand Down Expand Up @@ -235,19 +243,19 @@ GEM
rack
rack-test (0.6.3)
rack (>= 1.0)
rails (4.1.10)
actionmailer (= 4.1.10)
actionpack (= 4.1.10)
actionview (= 4.1.10)
activemodel (= 4.1.10)
activerecord (= 4.1.10)
activesupport (= 4.1.10)
rails (4.1.13)
actionmailer (= 4.1.13)
actionpack (= 4.1.13)
actionview (= 4.1.13)
activemodel (= 4.1.13)
activerecord (= 4.1.13)
activesupport (= 4.1.13)
bundler (>= 1.3.0, < 2.0)
railties (= 4.1.10)
railties (= 4.1.13)
sprockets-rails (~> 2.0)
railties (4.1.10)
actionpack (= 4.1.10)
activesupport (= 4.1.10)
railties (4.1.13)
actionpack (= 4.1.13)
activesupport (= 4.1.13)
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rake (10.4.2)
Expand Down Expand Up @@ -427,7 +435,8 @@ DEPENDENCIES
capybara (~> 2.0)
database_cleaner
ddr-alerts (~> 1.0.0)
ddr-models (= 2.0.1)
ddr-batch (= 1.0.0)
ddr-models (= 2.1.1)
deprecation
devise
equivalent-xml
Expand Down
52 changes: 26 additions & 26 deletions app/assets/stylesheets/dul-hydra.css
Original file line number Diff line number Diff line change
@@ -1,55 +1,55 @@
/* BEGIN Blacklight */
#header-navbar {
padding-top: 8px;
padding-top: 8px;
}
#header-navbar .navbar-brand {
min-height: 42px;
min-width: 200px;
padding-bottom: 0;
min-height: 42px;
min-width: 200px;
padding-bottom: 0;
}
form.bookmark_toggle {
display: inline;
display: inline;
}
/* END Blacklight */

.rights-form legend {
font-size: medium;
font-weight: bold;
font-size: medium;
font-weight: bold;
}
.rights-form fieldset {
margin-bottom: 1em;
margin-bottom: 1em;
}
.rights-form .access-level {
margin-bottom: 1.5em;
margin-bottom: 1.5em;
}
.rights-form .access-level label {
font-weight: bold;
text-transform: uppercase;
font-weight: bold;
text-transform: uppercase;
}
.rights-form .help-block {
font-size: smaller;
font-size: smaller;
}

table.access-controls {
width: auto;
width: auto;
}
table.access-controls .access-level-label {
text-transform: uppercase;
font-weight: bold;
text-transform: uppercase;
font-weight: bold;
}
table.access-controls td ul {
margin: 0;
margin: 0;
}

.field_with_errors {
padding: 2px;
background-color: red;
display: table;
padding: 2px;
background-color: red;
display: table;
}

.table .sub-header {
font-style: italic;
color: #999;
font-style: italic;
color: #999;
}

.table .mappings:empty {
Expand All @@ -61,17 +61,17 @@ table.access-controls td ul {
}

.table .mappings:empty:before {
content: 'will not map';
content: 'will not map';
}

.desc-metadata-form fieldset {
margin: 1em 0;
margin: 1em 0;
}
.desc-metadata-form .field-value {
margin-bottom: 0.5em;
margin-left: 1em;
margin-bottom: 0.5em;
margin-left: 1em;
}

span.label.event-outcome { /* event outcome label */
font-size: medium;
font-size: medium;
}
8 changes: 8 additions & 0 deletions app/controllers/admin/base_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module Admin
class BaseController < ::ApplicationController

devise_group :admin, contains: [:superuser]
before_action :authenticate_admin!

end
end
8 changes: 8 additions & 0 deletions app/controllers/admin/dashboard_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module Admin
class DashboardController < BaseController

def show
end

end
end
19 changes: 19 additions & 0 deletions app/controllers/admin/reports_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
module Admin
class ReportsController < BaseController

respond_to :csv

def show
report = DulHydra::Reports::Report.new
filename = "Duke_Digital_Repository"
case params.require(:type)
when "techmd"
report.filters << DulHydra::Reports::HasContentFilter
report.columns += DulHydra::Reports::Columns::TechnicalMetadata
filename += "__TECHMD"
end
render csv: report, filename: filename
end

end
end
2 changes: 1 addition & 1 deletion app/controllers/batch_objects_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class BatchObjectsController < ApplicationController

load_and_authorize_resource :class => DulHydra::Batch::Models::BatchObject
load_and_authorize_resource :class => Ddr::Batch::BatchObject

def index
end
Expand Down
8 changes: 4 additions & 4 deletions app/controllers/batches_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class BatchesController < ApplicationController

load_and_authorize_resource :class => DulHydra::Batch::Models::Batch
load_and_authorize_resource :class => Ddr::Batch::Batch

include DulHydra::Controller::TabbedViewBehavior
self.tabs = [:tab_pending_batches, :tab_finished_batches]
Expand All @@ -23,7 +23,7 @@ def show

def destroy
case @batch.status
when nil, DulHydra::Batch::Models::Batch::STATUS_READY, DulHydra::Batch::Models::Batch::STATUS_VALIDATED, DulHydra::Batch::Models::Batch::STATUS_INVALID
when nil, Ddr::Batch::Batch::STATUS_READY, Ddr::Batch::Batch::STATUS_VALIDATED, Ddr::Batch::Batch::STATUS_INVALID
@batch.destroy
flash[:notice] = I18n.t('batch.web.batch_deleted', :id => @batch.id)
else
Expand All @@ -33,7 +33,7 @@ def destroy
end

def procezz
Resque.enqueue(DulHydra::Batch::Jobs::BatchProcessorJob, @batch.id, current_user.id)
Resque.enqueue(Ddr::Batch::BatchProcessorJob, @batch.id, current_user.id)
flash[:notice] = I18n.t('batch.web.batch_queued', :id => @batch.id)
redirect_to batches_url
end
Expand All @@ -43,7 +43,7 @@ def validate
@errors = @batch.validate
valid = @errors.empty?
if valid
@batch.status = DulHydra::Batch::Models::Batch::STATUS_VALIDATED
@batch.status = Ddr::Batch::Batch::STATUS_VALIDATED
@batch.save
end
flash[:notice] = "Batch is #{valid ? '' : 'not '}valid"
Expand Down
Loading

0 comments on commit f538dbd

Please sign in to comment.