Rev 19 | Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
18 | moos | 1 | package ch.ffhs.webE.action; |
2 | |||
3 | import com.opensymphony.xwork2.ActionSupport; |
||
4 | |||
5 | public class LoginAction extends ActionSupport { |
||
6 | |||
7 | private static final long serialVersionUID = 1799753056277211344L; |
||
8 | |||
9 | private String userName ; |
||
10 | private String password; |
||
11 | |||
12 | public LoginAction() { |
||
13 | } |
||
14 | |||
15 | public String execute() { |
||
16 | //TODO: DB Abfrage für Login |
||
17 | if("moos".equals(getUserName())) { |
||
18 | return "success"; |
||
19 | } else { |
||
20 | return "failed"; |
||
21 | } |
||
22 | } |
||
23 | |||
24 | public String getUserName() { |
||
25 | return userName; |
||
26 | } |
||
27 | |||
28 | public void setUserName(String userName) { |
||
29 | this.userName = userName; |
||
30 | } |
||
31 | |||
32 | public String getPassword() { |
||
33 | return password; |
||
34 | } |
||
35 | public void setPassword(String password) { |
||
36 | this.password = password; |
||
37 | } |
||
38 | |||
39 | |||
40 | |||
41 | |||
42 | } |