留言板

Updating User Lockout

thumbnail
Daniel Breitner,修改在15 年前。

Updating User Lockout

Regular Member 帖子: 105 加入日期: 08-7-16 最近的帖子
Hello all ...

I am trying to un-lock a locked user by clicking on a button.

Everything works fine ... except:

I am calling UserLocalServiceUtil.updateLockout and I get the unlocked user.
But the user is not updated in the database ... do I miss something, or do I have to update him manually ?

With kind regards

Daniel Breitner
Alex Bu,修改在11 年前。

RE: Updating User Lockout

New Member 发布: 1 加入日期: 12-9-18 最近的帖子
Same question!
thumbnail
Bart Simpson,修改在11 年前。

RE: Updating User Lockout

Liferay Master 帖子: 522 加入日期: 11-8-29 最近的帖子
If you digg into the code you'll find that the model is updated but not merged with the current session.
userPersistence.update(user, false);

so you should update the user and merge it as well, using
com.liferay.portal.service.UserLocalServiceUtil.updateUser(User user, boolean merge) 


Hope it helps.