-
Notifications
You must be signed in to change notification settings - Fork 153
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add verification date cutoff to summary responses (#7141)
* add verification date cutoff to summary responses * update tests * test commit
- Loading branch information
Showing
3 changed files
with
52 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,18 @@ | ||
package org.orcid.core.constants; | ||
|
||
import org.orcid.jaxb.model.v3.release.common.VerificationDate; | ||
|
||
import javax.xml.datatype.DatatypeConfigurationException; | ||
import javax.xml.datatype.DatatypeFactory; | ||
import javax.xml.datatype.XMLGregorianCalendar; | ||
|
||
public class EmailConstants { | ||
|
||
public static final String WILDCARD_VERIFICATION_URL = "${verification_url}"; | ||
|
||
/* | ||
* session attribute that is used to see if we should check and notify the | ||
* user if their primary email ins't verified. | ||
* user if their primary email isn't verified. | ||
*/ | ||
public static String CHECK_EMAIL_VALIDATED = "CHECK_EMAIL_VALIDATED"; | ||
|
||
|
@@ -17,4 +23,25 @@ public class EmailConstants { | |
public static final String DO_NOT_REPLY_NOTIFY_ORCID_ORG = "ORCID - Do not reply <[email protected]>"; | ||
|
||
public static final String DO_NOT_REPLY_VERIFY_ORCID_ORG = "ORCID - Do not reply <[email protected]>"; | ||
|
||
public static final VerificationDate VERIFICATION_DATE_CUTOFF; | ||
|
||
static { | ||
XMLGregorianCalendar gregorianCutoffDate = null; | ||
VerificationDate verificationDate = null; | ||
|
||
try { | ||
gregorianCutoffDate = DatatypeFactory.newInstance().newXMLGregorianCalendar(); | ||
|
||
gregorianCutoffDate.setYear(2024); | ||
gregorianCutoffDate.setMonth(10); | ||
gregorianCutoffDate.setDay(27); | ||
|
||
verificationDate = new VerificationDate(gregorianCutoffDate); | ||
} catch (DatatypeConfigurationException e) { | ||
throw new RuntimeException("Error initializing XMLGregorianCalendar", e); | ||
} | ||
|
||
VERIFICATION_DATE_CUTOFF = verificationDate; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters