◆ doFinally()
void org.turro.signin.SignInComposer.doFinally |
( |
| ) |
throws Exception |
Definition at line 163 of file SignInComposer.java.
165 IUser userIn = ZkossElephant.getUser();
166 redir = Executions.getCurrent().getParameter(
"redir");
168 siginform.setVisible(
true);
169 if(
"true".equals(ZkossElephant.getCookieValue(
"xp_storepass"))) {
170 storepass.setChecked(
true);
171 String xppass = ZkossElephant.decryptCookieValue(
"xp_pass");
172 if(!Strings.isBlank(xppass)) {
173 password.setValue(xppass);
175 user.setValue(ZkossElephant.getCookieValue(
"xp_login"));
176 personain.setVisible(Strings.isBlank(user.getValue()));
179 sigoutform.setVisible(
true);
180 IConstructor cons = Application.getApplication().getConstructor();
181 Boolean isInternalSignIn = (Boolean) cons.getSessionAttribute(IUser.INTERNAL_SIGNIN);
182 if(isInternalSignIn !=
null && isInternalSignIn) {
183 personaout.setVisible(
false);
185 profile.setVisible(
false);
186 signout.setVisible(
false);
188 if(cons.canWebAdminister()) {
189 wadmin.setVisible(
true);
190 wadmin.setChecked(cons.isWebAdministering());
192 wadmin.setVisible(
false);
195 String[] langs = ElephantContext.getSiteLocales().split(
" *, *");
196 String currentLang = org.turro.elephant.zkoss.ZkossElephant.getCookieValue(
"lang");
197 lang.appendItem(I_.get(
"Browser's default"),
null);
198 for(String l : langs) {
199 Listitem li = lang.appendItem(I_.byKey(l), l);
200 if(l.equals(currentLang)) {
201 li.setSelected(
true);
204 signup.setVisible(
new File(ElephantContext.getRealPath(
"/user/signup")).isDirectory());
◆ onChangingUser()
void org.turro.signin.SignInComposer.onChangingUser |
( |
InputEvent |
evt | ) |
throws IOException |
Definition at line 98 of file SignInComposer.java.
99 personain.setVisible(Strings.isBlank(evt.getValue()));
◆ onLang()
void org.turro.signin.SignInComposer.onLang |
( |
Event |
event | ) |
|
Definition at line 152 of file SignInComposer.java.
153 String sel = lang.getSelectedItem().getValue();
155 ZkossElephant.deleteCookie(
"lang",
"/");
157 ZkossElephant.setCookie(
"lang", sel,
"/", 365*24*60*60);
159 Executions.getCurrent().sendRedirect(
"");
◆ onProfile()
void org.turro.signin.SignInComposer.onProfile |
( |
Event |
event | ) |
throws IOException, InterruptedException |
Definition at line 146 of file SignInComposer.java.
147 SystemLogger.getInstance().doLog(SystemLogType.LOG_INFO,
"/log/profile",
null,
null);
148 Modal.doModal(
"/WEB-INF/_zul/www/profile.zul", (Command)
null);
◆ onRemind()
void org.turro.signin.SignInComposer.onRemind |
( |
Event |
event | ) |
throws IOException |
Definition at line 129 of file SignInComposer.java.
130 if(org.turro.elephant.zkoss.ZkossElephant.doSendReminder(user.getText())) {
131 Clients.showNotification(I_.get(
"A reminder has been sent"));
◆ onSigIn()
void org.turro.signin.SignInComposer.onSigIn |
( |
| ) |
|
Definition at line 108 of file SignInComposer.java.
109 if(storepass.isChecked()) {
110 ZkossElephant.encryptCookie(
"xp_pass", password.getText(),
"/", 365*24*60*60);
111 ZkossElephant.setCookie(
"xp_storepass",
"true",
"/", 365*24*60*60);
112 ZkossElephant.setCookie(
"xp_login", user.getText(),
"/", 365*24*60*60);
113 ZkossElephant.setCookie(
"xp_remember",
"true",
"/", 365*24*60*60);
115 ZkossElephant.deleteCookie(
"xp_pass",
"/");
116 ZkossElephant.deleteCookie(
"xp_storepass",
"/");
117 ZkossElephant.deleteCookie(
"xp_login",
"/");
118 ZkossElephant.deleteCookie(
"xp_remember",
"/");
121 Authentication.doLogin(user.getText(), password.getText(), redir,
null);
123 }
catch (IOException ex) {
124 Logger.getLogger(SignInComposer.class.getName()).log(Level.SEVERE, ElephantContext.logMsg(
null), ex);
◆ onSigOut()
void org.turro.signin.SignInComposer.onSigOut |
( |
| ) |
|
Definition at line 136 of file SignInComposer.java.
138 Authentication.doLogout(redir);
140 }
catch (IOException ex) {
141 Logger.getLogger(SignInComposer.class.getName()).log(Level.SEVERE, ElephantContext.logMsg(
null), ex);
◆ webAdminister()
void org.turro.signin.SignInComposer.webAdminister |
( |
| ) |
throws IOException |
Definition at line 103 of file SignInComposer.java.
104 org.turro.elephant.zkoss.ZkossElephant.doWebAdmin(wadmin.isChecked(), redir);
The documentation for this class was generated from the following file: