mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-16 06:23:10 +00:00
[DS-1085] Apply patch (slightly updated) from Jira ticket
This commit is contained in:
@@ -9,6 +9,7 @@ package org.dspace.eperson;
|
||||
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import org.apache.commons.codec.DecoderException;
|
||||
|
||||
@@ -811,7 +812,7 @@ public class EPerson extends DSpaceObject
|
||||
}
|
||||
|
||||
/**
|
||||
* Can the user log in?
|
||||
* Is the user self-registered?
|
||||
*
|
||||
* @return boolean, yes/no (or false if the column is an SQL NULL)
|
||||
*/
|
||||
@@ -954,6 +955,26 @@ public class EPerson extends DSpaceObject
|
||||
return answer;
|
||||
}
|
||||
|
||||
/**
|
||||
* Stamp the EPerson's last-active date.
|
||||
*
|
||||
* @param when latest activity timestamp, or null to clear.
|
||||
*/
|
||||
public void setLastActive(Date when)
|
||||
{
|
||||
myRow.setColumn("last_active", when);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the EPerson's last-active stamp.
|
||||
*
|
||||
* @return date when last logged on, or null.
|
||||
*/
|
||||
public Date getLastActive()
|
||||
{
|
||||
return myRow.getDateColumn("last_active");
|
||||
}
|
||||
|
||||
/**
|
||||
* Update the EPerson
|
||||
*/
|
||||
|
Reference in New Issue
Block a user