Add last login attempt field

This commit is contained in:
emeric
2018-09-28 13:42:02 +02:00
parent 995be9470d
commit 1a6b218c77
3 changed files with 16 additions and 0 deletions
+5
View File
@@ -274,6 +274,11 @@ UserView::refreshView()
auto authUser = LmsApp->getDb().getUserDatabase().findWithId( std::to_string(*userId) );
auto name = authUser.identity(Wt::Auth::Identity::LoginName);
t->bindString("title", Wt::WString::tr("Lms.Admin.User.user-edit").arg(name), Wt::TextFormat::Plain);
t->setCondition("if-has-last-login-attempt", true);
Wt::WLineEdit *lastLoginAttempt = t->bindNew<Wt::WLineEdit>("last-login-attempt");
lastLoginAttempt->setText(authUser.lastLoginAttempt().toString());
lastLoginAttempt->setEnabled(false);
}
else
{