I'm struggling to find the Password Date field that @PGriffith pointed out to me in this post:
Can someone please help me find this class via the GatewayContext variable?
EDIT:
This is what I have so far
import com.inductiveautomation.ignition.common.user.User;
import com.inductiveautomation.ignition.gateway.localdb.persistence.LongField;
import com.inductiveautomation.ignition.gateway.localdb.persistence.PersistenceSession;
import com.inductiveautomation.ignition.gateway.model.GatewayContext;
import com.inductiveautomation.ignition.gateway.user.UserSourceProfile;
import java.util.Optional;
public class GatewayScriptModule extends AbstractScriptModule {
private GatewayContext gc;
public GatewayScriptModule(GatewayContext gc){
this.gc = gc;
}
@Override
protected LongField getUserPasswordDate(String userSource, String userName){
UserSourceProfile userSourceProfile = gc.getUserSourceManager().getProfile(userSource);
gc.getUserSourceManager().findUserProperty()
try {
User user = userSourceProfile.getUser(userName);
user.
}
catch(Exception e){
return null;
}
}
}
Thanks,
Brandon