@Named(value="userController") @ViewScoped public class UserController extends Object implements Serializable
| Constructor and Description |
|---|
UserController() |
| Modifier and Type | Method and Description |
|---|---|
void |
doChangePassword()
Action method for the Save Changes button in ths change password modal
|
void |
doSaveUserChanges()
Action method for the Save User Changes buttont, which stores the changes in
the properties of the current user entity
|
void |
doSaveUserPlayerChanges()
Action method for the Save Profile Changes button, which creates a new
player entity or stores the changes in the properties of the current player
entity
|
javax.servlet.http.Part |
getAvatarFile()
Gets the user's avatar Part object after being uploaded
|
String |
getNewPassword1()
Gets the input field content for the new password in the change password
modal
|
String |
getNewPassword2()
Gets the input field content for the repeated new password in the change
password modal
|
String |
getOldPassword()
Gets the input field content for the old password in the change password
modal
|
es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.Player |
getPlayer()
Gets the current player profile under edit
|
es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.User |
getUser()
Gets the current user under edit
|
boolean |
isPlayerProfileEnabled()
Gets whether the current player profile is enabled
|
void |
onEnablePlayerProfileChange()
Event listener for b:selectBooleanCheckbox component controlling the enabled
state of current player profile
|
void |
readAvatarContent()
Event listener for o:inputFile component from Omnifaces, responsible of
uploading avatar file contents.
|
void |
setAvatarFile(javax.servlet.http.Part avatarFile)
Sets the user's avatar Part object after being uploaded
|
void |
setNewPassword1(String newPassword1)
Sets the input field content for the new password in the change password
modal
|
void |
setNewPassword2(String newPassword2)
Sets the input field content for the repeated new password in the change
password modal
|
void |
setOldPassword(String oldPassword)
Sets the input field content for the old password in the change password
modal
|
void |
setPlayer(es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.Player player)
Sets the current player under edit
|
void |
setPlayerProfileEnabled(boolean playerProfileEnabled)
Sets the playerProfileEnabled boolean property
|
void |
setUser(es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.User user)
Sets the current user under edit
|
public es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.User getUser()
public void setUser(es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.User user)
user - user being editedpublic es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.Player getPlayer()
public void setPlayer(es.uvigo.esei.dgss.teamd.ligaaas.domain.entities.Player player)
player - player being editedpublic boolean isPlayerProfileEnabled()
public void setPlayerProfileEnabled(boolean playerProfileEnabled)
playerProfileEnabled - property valuepublic javax.servlet.http.Part getAvatarFile()
public void setAvatarFile(javax.servlet.http.Part avatarFile)
avatarFile - Part object with the uploaded filepublic String getOldPassword()
public void setOldPassword(String oldPassword)
oldPassword - old password valuepublic String getNewPassword1()
public void setNewPassword1(String newPassword1)
newPassword1 - new password valuepublic String getNewPassword2()
public void setNewPassword2(String newPassword2)
newPassword2 - repreated new password valuepublic void readAvatarContent()
See http://showcase.omnifaces.org/components/inputFile for details.
public void doSaveUserChanges()
public void doSaveUserPlayerChanges()
public void onEnablePlayerProfileChange()
public void doChangePassword()
Copyright © 2018. All rights reserved.