Sha256: 7cbe772c4583b11f3fe164c2cd3f07ea408b71c442853e96b1f42023eb0ab814
Contents?: true
Size: 1.1 KB
Versions: 4
Compression:
Stored size: 1.1 KB
Contents
require 'deprecation' module Hydra::ReleaseProcessHelperBehavior extend Deprecation self.deprecation_horizon = 'hydra-head 5.x' def display_release_status_notice(document) readiness = document.test_release_readiness if readiness == true flash[:notice] ||= [] if document.submitted_for_release? flash[:notice] << "This item has been released for library circulation." else flash[:notice] << "This item is ready to be released for library circulation." end else flash[:error] ||= [] flash[:error] = flash[:error] | readiness[:failures] end end deprecation_deprecate :display_release_status_notice def check_embargo_date_format if params.keys.include? [:embargo, :embargo_release_date] em_date = params[[:embargo, :embargo_release_date]]["0"] unless em_date.blank? begin !Date.parse(em_date) rescue params[[:embargo,:embargo_release_date]]["0"] = "" raise "Unacceptable date format" end end end end #deprecation_deprecate :check_embargo_date_format end
Version data entries
4 entries across 4 versions & 1 rubygems