Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Riina Antikainen
/
Moya
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 15e88c37
authored
Mar 21, 2010
by
Juho Juopperi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dunno what
1 parent
2126e11a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
7 deletions
code/LanBortalBeans/ejbModule/fi/insomnia/bortal/beans/UserBean.java
code/LanBortalDatabase/.classpath
code/LanBortalDatabase/src/fi/insomnia/bortal/model/User.java
code/LanBortalBeans/ejbModule/fi/insomnia/bortal/beans/UserBean.java
View file @
15e88c3
...
@@ -60,5 +60,4 @@ public class UserBean implements UserBeanLocal {
...
@@ -60,5 +60,4 @@ public class UserBean implements UserBeanLocal {
public
User
getUser
(
String
nick
)
{
public
User
getUser
(
String
nick
)
{
return
userFacade
.
findByLogin
(
nick
);
return
userFacade
.
findByLogin
(
nick
);
}
}
}
}
code/LanBortalDatabase/.classpath
View file @
15e88c3
...
@@ -12,5 +12,6 @@
...
@@ -12,5 +12,6 @@
<attribute
name=
"owner.project.facets"
value=
"jst.java"
/>
<attribute
name=
"owner.project.facets"
value=
"jst.java"
/>
</attributes>
</attributes>
</classpathentry>
</classpathentry>
<classpathentry
combineaccessrules=
"false"
kind=
"src"
path=
"/LanBortalUtilities"
/>
<classpathentry
kind=
"output"
path=
"build/classes"
/>
<classpathentry
kind=
"output"
path=
"build/classes"
/>
</classpath>
</classpath>
code/LanBortalDatabase/src/fi/insomnia/bortal/model/User.java
View file @
15e88c3
...
@@ -26,6 +26,8 @@ import javax.persistence.Version;
...
@@ -26,6 +26,8 @@ import javax.persistence.Version;
import
org.slf4j.Logger
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.slf4j.LoggerFactory
;
import
fi.insomnia.bortal.utilities.PasswordFunctions
;
import
sun.reflect.generics.reflectiveObjects.NotImplementedException
;
import
sun.reflect.generics.reflectiveObjects.NotImplementedException
;
/**
/**
...
@@ -61,10 +63,10 @@ public class User implements ModelInterface<Integer> {
...
@@ -61,10 +63,10 @@ public class User implements ModelInterface<Integer> {
@Column
(
name
=
"created"
,
nullable
=
false
,
columnDefinition
=
"timestamptz default now()"
)
@Column
(
name
=
"created"
,
nullable
=
false
,
columnDefinition
=
"timestamptz default now()"
)
@Temporal
(
TemporalType
.
TIMESTAMP
)
@Temporal
(
TemporalType
.
TIMESTAMP
)
private
Calendar
created
;
private
Calendar
created
=
Calendar
.
getInstance
()
;
@Column
(
name
=
"active"
,
nullable
=
false
,
columnDefinition
=
"boolean default true"
)
@Column
(
name
=
"active"
,
nullable
=
false
,
columnDefinition
=
"boolean default true"
)
private
boolean
active
;
private
boolean
active
=
true
;
@Column
(
name
=
"password"
)
@Column
(
name
=
"password"
)
private
String
password
;
private
String
password
;
...
@@ -534,11 +536,12 @@ public class User implements ModelInterface<Integer> {
...
@@ -534,11 +536,12 @@ public class User implements ModelInterface<Integer> {
}
}
public
void
resetPassword
(
String
password
)
{
public
void
resetPassword
(
String
password
)
{
// XXX: Couldn't reference utility project
String
newEncryptedPassword
=
PasswordFunctions
.
getEncryptedPassword
(
password
);
th
row
new
NotImplementedException
();
th
is
.
password
=
newEncryptedPassword
;
// Bypass setter
}
}
public
boolean
checkPassword
(
String
password
)
{
public
boolean
checkPassword
(
String
plainPassword
)
{
throw
new
NotImplementedException
();
boolean
matches
=
PasswordFunctions
.
checkPlainPassword
(
plainPassword
,
this
.
password
);
return
matches
;
}
}
}
}
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment