more polish

This commit is contained in:
Keith Donald
2007-08-21 05:11:58 +00:00
parent df0675b20c
commit b5f03191bb
3 changed files with 20 additions and 21 deletions

View File

@@ -1,5 +1,4 @@
insert into Customer (username, password, name) values ('springer', 'springrocks', 'Spring User')
insert into Customer (username, password, name) values ('demo', 'demo', 'Demo User')
insert into Customer (username, password, name) values ('springer', 'springrocks', 'Springer')
insert into Hotel (id, price, name, address, city, state, zip, country) values (1, 199, 'Westin Diplomat', '3555 S. Ocean Drive', 'Hollywood', 'FL', '33019', 'USA')
insert into Hotel (id, price, name, address, city, state, zip, country) values (2, 120, 'Marriott Courtyard', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
insert into Hotel (id, price, name, address, city, state, zip, country) values (3, 180, 'Doubletree', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')

View File

@@ -18,26 +18,10 @@ public class User implements Serializable {
public User() {
}
public User(String name, String password, String username) {
this.name = name;
this.password = password;
public User(String username, String password, String name) {
this.username = username;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
this.name = name;
}
@Id
@@ -49,6 +33,22 @@ public class User implements Serializable {
this.username = username;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
@Override
public String toString() {
return "User(" + username + ")";

View File

@@ -20,7 +20,7 @@ public class MainActions extends MultiAction {
}
public Event initCurrentUser(RequestContext context) {
User user = new User("Springer", "springrocks", "Spring User");
User user = new User("springer", "springrocks", "Springer");
context.getConversationScope().put("user", user);
return success();
}