Deactive the remember me function as it does not work anymore
This commit is contained in:
+4
-8
@@ -32,16 +32,11 @@
|
|||||||
namespace UserInterface {
|
namespace UserInterface {
|
||||||
|
|
||||||
Auth::Auth()
|
Auth::Auth()
|
||||||
: Wt::WTemplateFormView()
|
: Wt::WTemplateFormView(Wt::WString::tr("Lms.Auth.template"))
|
||||||
{
|
{
|
||||||
_model = std::make_shared<Wt::Auth::AuthModel>(LmsApp->getDb().getAuthService(), LmsApp->getDb().getUserDatabase());
|
_model = std::make_shared<Wt::Auth::AuthModel>(LmsApp->getDb().getAuthService(), LmsApp->getDb().getUserDatabase());
|
||||||
|
|
||||||
_model->addPasswordAuth(&Database::Handler::getPasswordService());
|
_model->addPasswordAuth(&Database::Handler::getPasswordService());
|
||||||
|
|
||||||
setTemplateText(Wt::WString::tr("Lms.Auth.template"));
|
|
||||||
addFunction("tr", &WTemplate::Functions::tr);
|
|
||||||
addFunction("id", &WTemplate::Functions::id);
|
|
||||||
|
|
||||||
// LoginName
|
// LoginName
|
||||||
setFormWidget(Wt::Auth::AuthModel::LoginNameField, std::make_unique<Wt::WLineEdit>());
|
setFormWidget(Wt::Auth::AuthModel::LoginNameField, std::make_unique<Wt::WLineEdit>());
|
||||||
|
|
||||||
@@ -63,8 +58,9 @@ Auth::Auth()
|
|||||||
this->setHidden(true);
|
this->setHidden(true);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
Wt::Auth::User user = _model->processAuthToken();
|
// Wt::Auth::User user = _model->processAuthToken();
|
||||||
_model->loginUser(LmsApp->getDb().getLogin(), user, Wt::Auth::LoginState::Weak);
|
// if (user.isValid())
|
||||||
|
// _model->loginUser(LmsApp->getDb().getLogin(), user, Wt::Auth::LoginState::Weak);
|
||||||
|
|
||||||
updateView(_model.get());
|
updateView(_model.get());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user