Commit 196c016c by Harsh Shah

Job match assessment issue fixes, review changes

parent 0aac3585
...@@ -15,10 +15,13 @@ ...@@ -15,10 +15,13 @@
<column name="factor_number" type="Long" length="11" nullable="true"/> <column name="factor_number" type="Long" length="11" nullable="true"/>
<column name="level_number" type="Long" length="11" nullable="true"/> <column name="level_number" type="Long" length="11" nullable="true"/>
<column name="narrative_id" type="Long" length="11" nullable="true"/> <column name="narrative_id" type="Long" length="11" nullable="true"/>
<column name="candidate_id" type="Long" length="11" nullable="true"/>
</NODE> </NODE>
<NODE name="INDEX" factory="Participant" class="oneit.sql.transfer.DefineIndexOperation" tableName="tl_score" indexName="idx_tl_score_test_analysis_id" isUnique="false"><column name="test_analysis_id"/></NODE> <NODE name="INDEX" factory="Participant" class="oneit.sql.transfer.DefineIndexOperation" tableName="tl_score" indexName="idx_tl_score_test_analysis_id" isUnique="false"><column name="test_analysis_id"/></NODE>
<NODE name="INDEX" factory="Participant" class="oneit.sql.transfer.DefineIndexOperation" tableName="tl_score" indexName="idx_tl_score_narrative_id" isUnique="false"><column name="narrative_id"/></NODE> <NODE name="INDEX" factory="Participant" class="oneit.sql.transfer.DefineIndexOperation" tableName="tl_score" indexName="idx_tl_score_narrative_id" isUnique="false"><column name="narrative_id"/></NODE>
<NODE name="INDEX" factory="Participant" class="oneit.sql.transfer.DefineIndexOperation" tableName="tl_score" indexName="idx_tl_score_candidate_id" isUnique="false"><column name="candidate_id"/></NODE>
</NODE></OBJECTS> </NODE></OBJECTS>
\ No newline at end of file
...@@ -14,7 +14,8 @@ CREATE TABLE tl_score ( ...@@ -14,7 +14,8 @@ CREATE TABLE tl_score (
test_analysis_id numeric(12) NULL, test_analysis_id numeric(12) NULL,
factor_number numeric(12) NULL, factor_number numeric(12) NULL,
level_number numeric(12) NULL, level_number numeric(12) NULL,
narrative_id numeric(12) NULL narrative_id numeric(12) NULL,
candidate_id numeric(12) NULL
); );
...@@ -32,3 +33,6 @@ ALTER TABLE tl_score ADD ...@@ -32,3 +33,6 @@ ALTER TABLE tl_score ADD
CREATE INDEX idx_tl_score_narrative_id CREATE INDEX idx_tl_score_narrative_id
ON tl_score (narrative_id); ON tl_score (narrative_id);
CREATE INDEX idx_tl_score_candidate_id
ON tl_score (candidate_id);
...@@ -15,7 +15,8 @@ CREATE TABLE tl_score ( ...@@ -15,7 +15,8 @@ CREATE TABLE tl_score (
test_analysis_id number(12) NULL, test_analysis_id number(12) NULL,
factor_number number(12) NULL, factor_number number(12) NULL,
level_number number(12) NULL, level_number number(12) NULL,
narrative_id number(12) NULL narrative_id number(12) NULL,
candidate_id number(12) NULL
); );
...@@ -33,3 +34,6 @@ ALTER TABLE tl_score ADD ...@@ -33,3 +34,6 @@ ALTER TABLE tl_score ADD
CREATE INDEX idx_tl_score_narrative_id CREATE INDEX idx_tl_score_narrative_id
ON tl_score (narrative_id); ON tl_score (narrative_id);
CREATE INDEX idx_tl_score_candidate_id
ON tl_score (candidate_id);
...@@ -15,7 +15,8 @@ CREATE TABLE tl_score ( ...@@ -15,7 +15,8 @@ CREATE TABLE tl_score (
test_analysis_id numeric(12) NULL, test_analysis_id numeric(12) NULL,
factor_number numeric(12) NULL, factor_number numeric(12) NULL,
level_number numeric(12) NULL, level_number numeric(12) NULL,
narrative_id numeric(12) NULL narrative_id numeric(12) NULL,
candidate_id numeric(12) NULL
); );
...@@ -33,3 +34,6 @@ ALTER TABLE tl_score ADD ...@@ -33,3 +34,6 @@ ALTER TABLE tl_score ADD
CREATE INDEX idx_tl_score_narrative_id CREATE INDEX idx_tl_score_narrative_id
ON tl_score (narrative_id); ON tl_score (narrative_id);
CREATE INDEX idx_tl_score_candidate_id
ON tl_score (candidate_id);
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
<MULTIPLEREFERENCE name="TestAnalysises" type="TestAnalysis" backreferenceName="Candidate" /> <MULTIPLEREFERENCE name="TestAnalysises" type="TestAnalysis" backreferenceName="Candidate" />
<MULTIPLEREFERENCE name="JobApplications" type="JobApplication" backreferenceName="Candidate" /> <MULTIPLEREFERENCE name="JobApplications" type="JobApplication" backreferenceName="Candidate" />
<MULTIPLEREFERENCE name="FactorScores" type="FactorScore" backreferenceName="Candidate" />
<TABLE name="oneit_sec_user_extension" tablePrefix="object" polymorphic="TRUE"> <TABLE name="oneit_sec_user_extension" tablePrefix="object" polymorphic="TRUE">
......
...@@ -18,6 +18,7 @@ ...@@ -18,6 +18,7 @@
<SINGLEREFERENCE name="Factor" type="Factor" dbcol="factor_number"/> <SINGLEREFERENCE name="Factor" type="Factor" dbcol="factor_number"/>
<SINGLEREFERENCE name="Level" type="Level" dbcol="level_number"/> <SINGLEREFERENCE name="Level" type="Level" dbcol="level_number"/>
<SINGLEREFERENCE name="Narrative" type="Narrative" dbcol="narrative_id" backreferenceName="FactorScores"/> <SINGLEREFERENCE name="Narrative" type="Narrative" dbcol="narrative_id" backreferenceName="FactorScores"/>
<SINGLEREFERENCE name="Candidate" type="Candidate" dbcol="candidate_id" backreferenceName="FactorScores"/>
</TABLE> </TABLE>
......
...@@ -48,7 +48,7 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -48,7 +48,7 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
} }
private String SELECT_COLUMNS = "{PREFIX}tl_score.object_id as id, {PREFIX}tl_score.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_score.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_score.score_number, {PREFIX}tl_score.color_rank, {PREFIX}tl_score.wghtd_score, {PREFIX}tl_score.test_analysis_id, {PREFIX}tl_score.factor_number, {PREFIX}tl_score.level_number, {PREFIX}tl_score.narrative_id, 1 AS commasafe "; private String SELECT_COLUMNS = "{PREFIX}tl_score.object_id as id, {PREFIX}tl_score.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_score.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_score.score_number, {PREFIX}tl_score.color_rank, {PREFIX}tl_score.wghtd_score, {PREFIX}tl_score.test_analysis_id, {PREFIX}tl_score.factor_number, {PREFIX}tl_score.level_number, {PREFIX}tl_score.narrative_id, {PREFIX}tl_score.candidate_id, 1 AS commasafe ";
private String SELECT_JOINS = ""; private String SELECT_JOINS = "";
public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException
...@@ -105,7 +105,8 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -105,7 +105,8 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
!tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_TestAnalysis)|| !tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_TestAnalysis)||
!tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Factor)|| !tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Factor)||
!tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Level)|| !tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Level)||
!tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Narrative)) !tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Narrative)||
!tl_scorePSet.containsAttrib(FactorScore.SINGLEREFERENCE_Candidate))
{ {
// We will need to retrieve it // We will need to retrieve it
idsToFetch.add (id.longValue()); idsToFetch.add (id.longValue());
...@@ -171,6 +172,16 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -171,6 +172,16 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
return results; return results;
} }
else if (refName.equals (FactorScore.SINGLEREFERENCE_Candidate))
{
String query = "SELECT " + SELECT_COLUMNS +
"FROM {PREFIX}tl_score " +
"WHERE " + SELECT_JOINS + "candidate_id = ?";
BaseBusinessClass[] results = loadQuery (allPSets, sqlMgr, context, query, new Object[] { _objectID.longID () }, null, false);
return results;
}
else else
{ {
throw new IllegalArgumentException ("Illegal reference type:" + refName); throw new IllegalArgumentException ("Illegal reference type:" + refName);
...@@ -195,10 +206,10 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -195,10 +206,10 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
{ {
int rowsUpdated = executeStatement (sqlMgr, int rowsUpdated = executeStatement (sqlMgr,
"UPDATE {PREFIX}tl_score " + "UPDATE {PREFIX}tl_score " +
"SET score_number = ?, color_rank = ?, wghtd_score = ?, test_analysis_id = ? , factor_number = ? , level_number = ? , narrative_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " + "SET score_number = ?, color_rank = ?, wghtd_score = ?, test_analysis_id = ? , factor_number = ? , level_number = ? , narrative_id = ? , candidate_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " +
"WHERE tl_score.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ", "WHERE tl_score.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ",
CollectionUtils.listEntry (HELPER_Score.getForSQL(dummyScore, tl_scorePSet.getAttrib (FactorScore.FIELD_Score))).listEntry (HELPER_ColorRank.getForSQL(dummyColorRank, tl_scorePSet.getAttrib (FactorScore.FIELD_ColorRank))).listEntry (HELPER_WghtdScore.getForSQL(dummyWghtdScore, tl_scorePSet.getAttrib (FactorScore.FIELD_WghtdScore))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_TestAnalysis)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Factor)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Narrative)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray()); CollectionUtils.listEntry (HELPER_Score.getForSQL(dummyScore, tl_scorePSet.getAttrib (FactorScore.FIELD_Score))).listEntry (HELPER_ColorRank.getForSQL(dummyColorRank, tl_scorePSet.getAttrib (FactorScore.FIELD_ColorRank))).listEntry (HELPER_WghtdScore.getForSQL(dummyWghtdScore, tl_scorePSet.getAttrib (FactorScore.FIELD_WghtdScore))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_TestAnalysis)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Factor)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Narrative)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Candidate)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray());
if (rowsUpdated != 1) if (rowsUpdated != 1)
{ {
...@@ -462,6 +473,7 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -462,6 +473,7 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Factor, r.getObject ("factor_number")); tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Factor, r.getObject ("factor_number"));
tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Level, r.getObject ("level_number")); tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Level, r.getObject ("level_number"));
tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Narrative, r.getObject ("narrative_id")); tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Narrative, r.getObject ("narrative_id"));
tl_scorePSet.setAttrib(FactorScore.SINGLEREFERENCE_Candidate, r.getObject ("candidate_id"));
} }
...@@ -478,10 +490,10 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr ...@@ -478,10 +490,10 @@ public class FactorScorePersistenceMgr extends ObjectPersistenceMgr
{ {
executeStatement (sqlMgr, executeStatement (sqlMgr,
"INSERT INTO {PREFIX}tl_score " + "INSERT INTO {PREFIX}tl_score " +
" (score_number, color_rank, wghtd_score, test_analysis_id, factor_number, level_number, narrative_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " + " (score_number, color_rank, wghtd_score, test_analysis_id, factor_number, level_number, narrative_id, candidate_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " +
"VALUES " + "VALUES " +
" (?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")", " (?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")",
CollectionUtils.listEntry (HELPER_Score.getForSQL(dummyScore, tl_scorePSet.getAttrib (FactorScore.FIELD_Score))).listEntry (HELPER_ColorRank.getForSQL(dummyColorRank, tl_scorePSet.getAttrib (FactorScore.FIELD_ColorRank))).listEntry (HELPER_WghtdScore.getForSQL(dummyWghtdScore, tl_scorePSet.getAttrib (FactorScore.FIELD_WghtdScore))) .listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_TestAnalysis)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Factor)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Narrative)))) .listEntry (objectID.longID ()).toList().toArray()); CollectionUtils.listEntry (HELPER_Score.getForSQL(dummyScore, tl_scorePSet.getAttrib (FactorScore.FIELD_Score))).listEntry (HELPER_ColorRank.getForSQL(dummyColorRank, tl_scorePSet.getAttrib (FactorScore.FIELD_ColorRank))).listEntry (HELPER_WghtdScore.getForSQL(dummyWghtdScore, tl_scorePSet.getAttrib (FactorScore.FIELD_WghtdScore))) .listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_TestAnalysis)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Factor)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Narrative)))).listEntry (SQLManager.CheckNull((Long)(tl_scorePSet.getAttrib (FactorScore.SINGLEREFERENCE_Candidate)))) .listEntry (objectID.longID ()).toList().toArray());
tl_scorePSet.setStatus (PersistentSetStatus.PROCESSED); tl_scorePSet.setStatus (PersistentSetStatus.PROCESSED);
} }
......
...@@ -9,7 +9,6 @@ import oneit.utils.filter.CollectionFilter; ...@@ -9,7 +9,6 @@ import oneit.utils.filter.CollectionFilter;
import oneit.utils.filter.Filter; import oneit.utils.filter.Filter;
import oneit.utils.parsers.FieldException; import oneit.utils.parsers.FieldException;
import performa.orm.types.CriteriaType; import performa.orm.types.CriteriaType;
import performa.utils.AnalysisEngine;
public class JobApplication extends BaseJobApplication public class JobApplication extends BaseJobApplication
...@@ -90,7 +89,7 @@ public class JobApplication extends BaseJobApplication ...@@ -90,7 +89,7 @@ public class JobApplication extends BaseJobApplication
Answer rightAnswer = Answer.createAnswer(getTransaction()); Answer rightAnswer = Answer.createAnswer(getTransaction());
addToProfileAssessmentAnswers(rightAnswer); addToProfileAssessmentAnswers(rightAnswer);
rightAnswer.setQuestion(question); rightAnswer.setQuestion(question.getRightQuestion());
} }
} }
} }
......
...@@ -93,11 +93,13 @@ public class AnalysisEngine ...@@ -93,11 +93,13 @@ public class AnalysisEngine
factorScore.setFactor(factor); factorScore.setFactor(factor);
factorScore.setLevel(jobApplication.getJob().getLevel()); factorScore.setLevel(jobApplication.getJob().getLevel());
factorScore.setScore(score); factorScore.setScore(score);
factorScore.setWghtdScore(score); //temp fix, to-do change later
factorScore.setColorCode(factorScoreResult.getColorCode()); factorScore.setColorCode(factorScoreResult.getColorCode());
factorScore.setColorRank(factorScoreResult.getColorCode() != null ? factorScoreResult.getColorCode().getWeightage() : 0); factorScore.setColorRank(factorScoreResult.getColorCode() != null ? factorScoreResult.getColorCode().getWeightage() : 0);
factorScore.setNarrative(factorScoreResult.getNarrative()); factorScore.setNarrative(factorScoreResult.getNarrative());
testAnalysis.addToFactorScores(factorScore); testAnalysis.addToFactorScores(factorScore);
jobApplication.getCandidate().addToFactorScores(factorScore);
} }
} }
......
...@@ -1964,8 +1964,8 @@ ul.security-level { ...@@ -1964,8 +1964,8 @@ ul.security-level {
margin-left: -5px; margin-left: -5px;
border-color: #d1d1d1; border-color: #d1d1d1;
color: #4a4a4a; color: #4a4a4a;
padding: 0; padding: 0;
/* padding: 9px 24.12px;*/ /*padding: 9px 24.12px;*/
} }
.pagination.ratting-number>li:first-child>a, .pagination.ratting-number>li:first-child>span{ .pagination.ratting-number>li:first-child>a, .pagination.ratting-number>li:first-child>span{
border-top-left-radius: 100px; border-top-left-radius: 100px;
...@@ -1979,7 +1979,7 @@ ul.security-level { ...@@ -1979,7 +1979,7 @@ ul.security-level {
color: #4a4a4a; color: #4a4a4a;
font-size: 12px; font-size: 12px;
font-weight: 500; font-weight: 500;
padding: 53px 0 0; padding: 53px 0 87px;
text-align: center; text-align: center;
font-weight: bold; font-weight: bold;
} }
...@@ -2025,7 +2025,36 @@ ul.security-level { ...@@ -2025,7 +2025,36 @@ ul.security-level {
border: solid 1px #2a6ebf; border: solid 1px #2a6ebf;
color: #ffffff; color: #ffffff;
} }
span.left-s-label{
float: left;
font-weight: bold;
color: #4a4a4a;
font-size: 12px;
margin-left: 26px;
margin-right: 0;
width: 150px;
text-align: center;
display: table;
}
span.right-s-label{
float: right;
font-weight: bold;
color: #4a4a4a;
font-size: 12px;
margin-right: 26px;
margin-left: 0;
width: 150px;
text-align: center;
display: table;
}
.left-s-label div,.right-s-label div {
display: table-cell;
vertical-align: middle;
height: 40px;
}
.ips-box{
margin-bottom: 26px;
}
/*Selection Criteria Page All Step End*/ /*Selection Criteria Page All Step End*/
/*Complete Page*/ /*Complete Page*/
...@@ -2293,13 +2322,13 @@ a.forgot-pass { ...@@ -2293,13 +2322,13 @@ a.forgot-pass {
height: 41px; height: 41px;
position: relative; position: relative;
} }
.right-mark-img { .right-mark-img {
position: absolute; position: absolute;
top: 16px; top: 16px;
left: 0; left: 0;
right: 0; right: 0;
margin: 0 auto; margin: 0 auto;
bottom: 0; bottom: 0;
} }
.active-states{ .active-states{
width: 16px; width: 16px;
...@@ -3818,6 +3847,8 @@ img.alert-icon {float: left;} ...@@ -3818,6 +3847,8 @@ img.alert-icon {float: left;}
.main-menu li a {padding: 12px 0 12px 12px;} .main-menu li a {padding: 12px 0 12px 12px;}
.form-page-area {padding: 4.89% 8.5%;} .form-page-area {padding: 4.89% 8.5%;}
.main-content-area{padding: 3% 8.56% 0;} .main-content-area{padding: 3% 8.56% 0;}
.auto-save{padding: 45px 0 70px;}
.ips-box {margin-bottom: 15px;}
} }
@media screen and (max-width: 991px){ @media screen and (max-width: 991px){
...@@ -3826,7 +3857,7 @@ img.alert-icon {float: left;} ...@@ -3826,7 +3857,7 @@ img.alert-icon {float: left;}
.main-application-outline {width: 92%;} .main-application-outline {width: 92%;}
.app-block {margin: 45px 0 35px;padding: 43px 14px 15px;} .app-block {margin: 45px 0 35px;padding: 43px 14px 15px;}
.app-out-btn{margin-bottom: 8%;} .app-out-btn{margin-bottom: 8%;}
.ratting-number a label{padding: 7px 15.12px;} .ratting-number a label{padding: 7px 17.12px;}
.ratting-box span{margin: 0 8px;} .ratting-box span{margin: 0 8px;}
.app-complete-text{width: 75%;} .app-complete-text{width: 75%;}
.job-post-complete {min-height: 410px;} .job-post-complete {min-height: 410px;}
...@@ -3882,6 +3913,9 @@ img.alert-icon {float: left;} ...@@ -3882,6 +3913,9 @@ img.alert-icon {float: left;}
.alert-icon {width: 26px;} .alert-icon {width: 26px;}
.close-alert{margin-top: 2px;} .close-alert{margin-top: 2px;}
.message-common{margin: 15px 0;} .message-common{margin: 15px 0;}
.left-s-label div, .right-s-label div{height: 36px;}
span.left-s-label{margin-right: 0;}
span.right-s-label{margin-left: 0;}
} }
@media screen and (max-width: 980px){ @media screen and (max-width: 980px){
...@@ -4032,7 +4066,8 @@ img.alert-icon {float: left;} ...@@ -4032,7 +4066,8 @@ img.alert-icon {float: left;}
.ratting-number {left: 0;margin: 0;padding-left: 0;position: absolute;right: 0;top: 0;width: 100%;} .ratting-number {left: 0;margin: 0;padding-left: 0;position: absolute;right: 0;top: 0;width: 100%;}
.pagination.ratting-number > li > a, .pagination.ratting-number > li > span{float: left;margin-left: 0;width: 14.28%;border-left: 0 none;} .pagination.ratting-number > li > a, .pagination.ratting-number > li > span{float: left;margin-left: 0;width: 14.28%;border-left: 0 none;}
.ratting-number a label{padding: 14px 0;} .ratting-number a label{padding: 14px 0;}
.ratting-number a label{padding: 14px 0;} .pagination.ratting-number > li:first-child > a, .pagination.ratting-number > li:first-child > span{border-bottom-left-radius: 0;border-top-left-radius: 0;border-left: 0;} 3888 .pagination.ratting-number > li:first-child > a, .pagination.ratting-number > li:first-child > span{border-bottom-left-radius: 0;border-top-left-radius: 0;border-left: 0;} .pagination.ratting-number > li:last-child > a, .pagination.ratting-number > li:last-child > span{border-bottom-right-radius: 0;border-top-right-radius: 0;border-right: 0;} .pagination.ratting-number > li:first-child > a, .pagination.ratting-number > li:first-child > span{border-bottom-left-radius: 0;border-top-left-radius: 0;border-left: 0;}
.pagination.ratting-number > li:last-child > a, .pagination.ratting-number > li:last-child > span{border-bottom-right-radius: 0;border-top-right-radius: 0;border-right: 0;}
.ratting-box {border: 0 none;border-radius: 0;padding: 30px 0 33px;top: -2px;float: left;width: 100%;} .ratting-box {border: 0 none;border-radius: 0;padding: 30px 0 33px;top: -2px;float: left;width: 100%;}
.auto-save{padding: 24px 0;float: left;width: 100%;} .auto-save{padding: 24px 0;float: left;width: 100%;}
.ratting-box span:first-child {float: left;margin: 13px 9px;position: relative;top: 25px;width: 50px;text-align: left;} .ratting-box span:first-child {float: left;margin: 13px 9px;position: relative;top: 25px;width: 50px;text-align: left;}
...@@ -4060,6 +4095,11 @@ img.alert-icon {float: left;} ...@@ -4060,6 +4095,11 @@ img.alert-icon {float: left;}
.slider-prev img{position: relative;left: -4px;} .slider-prev img{position: relative;left: -4px;}
.slider-next img {position: relative;right: -4px;} .slider-next img {position: relative;right: -4px;}
.message-common {padding: 15px;width: 93%;} .message-common {padding: 15px;width: 93%;}
.ratting-box span.left-s-label{width: 150px;line-height: normal;margin-right: 0;display: table;}
.ratting-box span.right-s-label{width: 150px;line-height: normal;margin-left: 0;display: table;}
.pagination.ratting-number.ipsative-rating > li > a, .pagination.ratting-number.ipsative-rating > li > span{width: 20%;}
.ips-box {margin-bottom: 0;}
.left-s-label div, .right-s-label div {height: auto;}
} }
@media screen and (max-width: 750px){ @media screen and (max-width: 750px){
...@@ -4182,6 +4222,8 @@ img.alert-icon {float: left;} ...@@ -4182,6 +4222,8 @@ img.alert-icon {float: left;}
} }
@media screen and (max-width: 420px){ @media screen and (max-width: 420px){
.main-pack-type li {width: 74%;} .main-pack-type li {width: 74%;}
.ratting-box span.left-s-label{width: 105px;}
.ratting-box span.right-s-label{width: 105px;}
} }
@media screen and (max-width: 360px){ @media screen and (max-width: 360px){
.payment-title {font-size: 14px;} .payment-title {font-size: 14px;}
......
...@@ -53,9 +53,9 @@ ...@@ -53,9 +53,9 @@
<div class="job-post-name"> <div class="job-post-name">
<oneit:toString value="<%= job.getJobTitle() %>" mode="EscapeHTML" /> <oneit:toString value="<%= job.getJobTitle() %>" mode="EscapeHTML" />
<oneit:button value="EDIT" name="gotoPage" cssClass="<%= job.getID() + " hidden"%>" skin="link" <oneit:button value="EDIT" name="gotoPage" cssClass="<%= job.getID() + " hidden"%>" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", nextPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", nextPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.toMap() %>"/> .toMap() %>"/>
</div> </div>
<div class="job-company-name"> <div class="job-company-name">
<span class="superlaw">SUPERLAW</span> <span class="superlaw">SUPERLAW</span>
...@@ -96,9 +96,9 @@ ...@@ -96,9 +96,9 @@
enums="<%= Arrays.asList(new JobStatus[]{JobStatus.OPEN, JobStatus.COMPLETE}) %>"/> enums="<%= Arrays.asList(new JobStatus[]{JobStatus.OPEN, JobStatus.COMPLETE}) %>"/>
</div> </div>
<oneit:button name="save" value="Save" cssClass="<%= "save-job" + job.getID().toString() + " hidden"%>" <oneit:button name="save" value="Save" cssClass="<%= "save-job" + job.getID().toString() + " hidden"%>"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage+ (jobStatus != null ? "&JobStatus=" + jobStatus : "")) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage+ (jobStatus != null ? "&JobStatus=" + jobStatus : ""))
.mapEntry("Job", job) .mapEntry("Job", job)
.toMap() %>" /> .toMap() %>" />
</div> </div>
<% <%
} }
......
...@@ -16,9 +16,9 @@ ...@@ -16,9 +16,9 @@
jobStatus = JobStatus.forName((String) request.getParameter("JobStatus")); jobStatus = JobStatus.forName((String) request.getParameter("JobStatus"));
} }
Job[] jobs = jobStatus != null ? Job[] jobs = Job.SearchByAll().andJobStatus(new EqualsFilter<>(jobStatus))
Job.SearchByAll().andJobStatus(new EqualsFilter<>(jobStatus)).search(transaction) : .andSecUser(new EqualsFilter(SecUser.getTXUser(transaction)))
Job.SearchByAll().search(transaction); .search(transaction);
process.setAttribute("JobStatus", jobStatus); process.setAttribute("JobStatus", jobStatus);
%> %>
...@@ -36,9 +36,9 @@ ...@@ -36,9 +36,9 @@
<li class="lable-job-shorting">showing</li> <li class="lable-job-shorting">showing</li>
<li class="<%= (jobStatus == null ? "active" : "" )%>"> <li class="<%= (jobStatus == null ? "active" : "" )%>">
<oneit:button value="All Jobs" name="gotoPage" skin="link" <oneit:button value="All Jobs" name="gotoPage" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage)
.mapEntry("procParams", CollectionUtils.mapEntry("JobStatus", null).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("JobStatus", null).toMap())
.toMap() %>"/> .toMap() %>"/>
</li> </li>
<% <%
for (JobStatus status : JobStatus.getJobStatusArray()) for (JobStatus status : JobStatus.getJobStatusArray())
...@@ -46,9 +46,9 @@ ...@@ -46,9 +46,9 @@
%> %>
<li class="<%= (jobStatus != null && jobStatus == status ? "active" : "" )%>"> <li class="<%= (jobStatus != null && jobStatus == status ? "active" : "" )%>">
<oneit:button value="<%= status.getName() %>" name="gotoPage" skin="link" <oneit:button value="<%= status.getName() %>" name="gotoPage" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage ) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", homePage )
.mapEntry("procParams", CollectionUtils.mapEntry("JobStatus", status).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("JobStatus", status).toMap())
.toMap() %>"/> .toMap() %>"/>
</li> </li>
<% <%
} }
......
...@@ -7,7 +7,10 @@ ...@@ -7,7 +7,10 @@
<oneit:dynIncluded> <oneit:dynIncluded>
<% <%
//TODO: filter with Client; //TODO: filter with Client;
Job[] jobs = Job.SearchByAll().andJobStatus(new EqualsFilter<>(JobStatus.OPEN)).search(transaction); Job[] jobs = Job.SearchByAll().andJobStatus(new EqualsFilter<>(JobStatus.OPEN))
.andSecUser(new EqualsFilter(SecUser.getTXUser(transaction)))
.search(transaction);
Article jobsArticle = WebUtils.getArticleByShortCut(transaction, WebUtils.JOBS); Article jobsArticle = WebUtils.getArticleByShortCut(transaction, WebUtils.JOBS);
String nextPage = jobsArticle.getLink(request, CollectionUtils.mapEntry("cms.rm", WebUtils.VIEW_APPLICANTS).toMap()); String nextPage = jobsArticle.getLink(request, CollectionUtils.mapEntry("cms.rm", WebUtils.VIEW_APPLICANTS).toMap());
String homePage = WebUtils.getSamePageInRenderMode(request, "Page"); String homePage = WebUtils.getSamePageInRenderMode(request, "Page");
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
<%@ include file="/inc/stdimports50.jsp" %><%-- This is in cougar --%> <%@ include file="/inc/stdimports50.jsp" %><%-- This is in cougar --%>
<%@ include file="/inc/stdcms.jsp" %><%-- This is in cougar --%> <%@ include file="/inc/stdcms.jsp" %><%-- This is in cougar --%>
<%@ include file="/extensions/performa/inc/stdimports.jsp" %> <%@ include file="/extensions/performa/inc/stdimports.jsp" %>
<%@ page import="oneit.utils.text.FormatUtils" %>
<oneit:dynIncluded> <oneit:dynIncluded>
<% <%
...@@ -80,23 +81,54 @@ ...@@ -80,23 +81,54 @@
if(questionNumber < totNoOfQuestions) if(questionNumber < totNoOfQuestions)
{ {
Answer answer = jobApplication.getAnswerForQuestion(allQuestions.get(questionNumber)); Question question = allQuestions.get(questionNumber);
String optionKey = WebUtils.getInputKey(request, answer, Answer.FIELD_AnswerNo); QuestionType questionType = question.getQuestionType();
String formValue = formBuilder.fieldValue (optionKey, answer.getAnswerNo() == null ? "" : String.valueOf(answer.getAnswerNo())); Answer answer = jobApplication.getAnswerForQuestion(question);
String numberText = (questionNumber + 1) + "/" + totNoOfQuestions; String optionKey = WebUtils.getInputKey(request, answer, Answer.FIELD_AnswerNo);
%> String formValue = formBuilder.fieldValue (optionKey, answer.getAnswerNo() == null ? "" : String.valueOf(answer.getAnswerNo()));
<div class="rateing-title"> String numberText = (questionNumber + 1) + "/" + totNoOfQuestions;
Rate the importance of each item below
<span><oneit:toString value="<%= numberText %>" mode="EscapeHTML"/></span> if(questionType == QuestionType.SCALAR)
</div> {
<div class="rating-box-title"> %>
<oneit:toString value="<%= answer.getQuestion().getDescription() %>" mode="EscapeHTML"/> <div class="rateing-title">
</div> Rate the importance of each item below
<span><oneit:toString value="<%= numberText %>" mode="EscapeHTML"/></span>
</div>
<div class="rating-box-title">
<oneit:toString value="<%= question.getDescription() %>" mode="EscapeHTML"/>
</div>
<%
}
else
{
%>
<div class="rateing-title">
Select your preference on the scale below
<span><oneit:toString value="<%= numberText %>" mode="EscapeHTML"/></span>
</div>
<%
}
%>
<div class="ratting-box"> <div class="ratting-box">
<span>Very little importance</span> <%
if(questionType == QuestionType.SCALAR)
{
%>
<span>Very little importance</span>
<%
}
else
{
%>
<span class="left-s-label"><div><%= FormatUtils.stringify(question.getDescription(), "EscapeHTML") %></div></span> <!-- toString tag not used due to styling issue with additional span tag -->
<%
}
%>
<ul class="pagination ratting-number"> <ul class="pagination ratting-number">
<% <%
for(int index=1; index<=7; index++) for(int index=1; index <= (questionType == QuestionType.SCALAR ? 7 : 5); index++)
{ {
String activeStr = (CollectionUtils.equals(String.valueOf(index), formValue) ? "active" : ""); String activeStr = (CollectionUtils.equals(String.valueOf(index), formValue) ? "active" : "");
String selectedStr = (CollectionUtils.equals(String.valueOf(index), formValue) ? "checked" : ""); String selectedStr = (CollectionUtils.equals(String.valueOf(index), formValue) ? "checked" : "");
...@@ -111,7 +143,20 @@ ...@@ -111,7 +143,20 @@
} }
%> %>
</ul> </ul>
<span>High importance</span> <%
if(questionType == QuestionType.SCALAR)
{
%>
<span>High importance</span>
<%
}
else if(question.getRightQuestion() != null)
{
%>
<span class="right-s-label"><div><%= FormatUtils.stringify(question.getRightQuestion().getDescription(), "EscapeHTML") %></div></span>
<%
}
%>
</div> </div>
<% <%
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment