lib/proquest/metadata.rb
def transformed_start_date
      return if attributes[:DISS_accept_date].blank?

      date = Date.parse(attributes[:DISS_accept_date])

      return date unless date.month == 1 && date.day == 1

      Date.parse("#{date.year}-12-31")
    end
# The embargo release date for ETDs must be calculated based
# on the DISS_accept_date element.  Unfortunately, according
# to the ProQuest Reference Guide "ProQuest only tracks the
# year that a submission was accepted but for internal
# reasons this variable includes both month and day.  Every
# submission will have January 1st for this variable."
# Therefore, all DISS_accept_date with a value of 01/01/YYYY
# for ETDs should be interpreted as 12/31/YYYY for purposes
# of calculating the embargo release date.
#
# @return [Date, Nil]
The embargo release date for ETDs must be calculated based
on the DISS_accept_date element.  Unfortunately, according
to the ProQuest Reference Guide "ProQuest only tracks the
year that a submission was accepted but for internal
reasons this variable includes both month and day.  Every
submission will have January 1st for this variable."
Therefore, all DISS_accept_date with a value of 01/01/YYYY
for ETDs should be interpreted as 12/31/YYYY for purposes
of calculating the embargo release date.
The embargo release date for ETDs must be calculated based on the DISS_accept_date element . Unfortunately according to the ProQuest Reference Guide " ProQuest only tracks the year that a submission was accepted but for internal reasons this variable includes both month and day . Every submission will have January 1st for this variable . " Therefore all DISS_accept_date with a value of 01 / 01 / YYYY for ETDs should be interpreted as 12 / 31 / YYYY for purposes of calculating the embargo release date .
def transformed_start_date
      return if attributes[:DISS_accept_date].blank?
      date = Date.parse(attributes[:DISS_accept_date])
      return date unless date.month == 1 && date.day == 1
      Date.parse("#{date.year}-12-31")
    end
def transformed_start_date return if attributes [ :DISS_accept_date ] . blank? date = Date . parse ( attributes [ :DISS_accept_date ] ) return date unless date . month == 1 && date . day == 1 Date . parse ( "#{date.year}-12-31" ) end
The embargo release date for ETDs must be calculated based
on the DISS_accept_date element.
The embargo release date for ETDs must be calculated based on the DISS_accept_date element .
None
Date, Nil