Skip to content
Snippets Groups Projects
Commit 10557804 authored by Ndèye Anna Ndiaye's avatar Ndèye Anna Ndiaye Committed by Adrien Béraud
Browse files

Recherche firstname-lastname

Change-Id: I906b903e4ba350841faaa8cea9c80abb09bd49fc

Review changes for name search

Change-Id: Ib24062a178eb383bc6fc77253c6d00feaadad030
parent f40611fd
No related branches found
No related tags found
No related merge requests found
......@@ -77,8 +77,14 @@ public class DataStore implements AuthenticationSource {
if (!queryString.equals("*")) {
StatementList statementList = new StatementList();
StatementElement statementElement = new StatementElement("username","=",queryString,"");
statementList.addStatement(statementElement);
if(field.equals("LOGON_NAME")){
statementList.addStatement(new StatementElement("username","LIKE", queryString,""));
}
else{
String startQueryString = queryString.concat("%");
statementList.addStatement(new StatementElement("firstName","LIKE", startQueryString,"OR"));
statementList.addStatement(new StatementElement("lastName","LIKE", startQueryString, ""));
}
userList = userProfileDao.getObjects(statementList);
} else
userList = userProfileDao.getObjects(null);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment