Commit 1821a882 by Nilu

Should not allow proceeding without selecting the Role Type

parent 42cdf297
......@@ -30,6 +30,7 @@ public class ProcessCultureFP extends SaveFP
HttpServletRequest request = submission.getRequest();
Job job = (Job) process.getAttribute("Job");
boolean fromJobMatch = request.getAttribute("fromJobMatch") != null ? (boolean) request.getAttribute("fromJobMatch"): false;
Debug.assertion(job != null, "No job found . Call from " + getClass().getName());
......@@ -40,5 +41,10 @@ public class ProcessCultureFP extends SaveFP
BusinessObjectParser.assertFieldCondition(criteria.getCultureElementRating() != null, criteria , CultureCriteria.SINGLEREFERENCE_CultureElementRating, "mandatory", exceptions, true, request);
}
}
if(fromJobMatch)
{
BusinessObjectParser.assertFieldCondition(job.getLevel()!= null, job , Job.SINGLEREFERENCE_Level, "mandatory", exceptions, true, request);
}
}
}
\ No newline at end of file
......@@ -13,6 +13,7 @@
String fourthPage = WebUtils.getSamePageInRenderMode(request, WebUtils.ASSESSMENT_CRITERIA);
String fifthPage = WebUtils.getSamePageInRenderMode(request, WebUtils.JOB_REVIEW);
boolean savedJob = job.getStatus() != ObjectStatus.NEW;
boolean fromJobMatch = pageNumber == "2";
%>
<oneit:dynIncluded>
......@@ -20,9 +21,10 @@
<div class="main-tab-form job-main-tabs">
<ul class="nav nav-pills nav-justified">
<li class="<%= pageNumber == "1" ? "active" : CollectionUtils.equals(job.getCompletedDetails(), Boolean.TRUE) || savedJob ? "complate" : ""%>">
<oneit:button value=" " name="gotoPage" skin="link"
<oneit:button value=" " name="processCulture" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", firstPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", fromJobMatch)
.toMap() %>">
<span><%= CollectionUtils.equals(job.getCompletedDetails(), Boolean.TRUE) || savedJob ? "<img src=\"images/right-mark.png\" />" : "1"%></span>
Job Detail
......@@ -32,6 +34,7 @@
<oneit:button value=" " name="processCulture" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", secondPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", fromJobMatch)
.toMap() %>">
<span><%= CollectionUtils.equals(job.getCompletedAssessmentType(), Boolean.TRUE) || savedJob ? "<img src=\"images/right-mark.png\" />" : "2"%></span>
Role
......@@ -41,6 +44,7 @@
<oneit:button value=" " name="processCulture" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", thirdPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", fromJobMatch)
.toMap() %>">
<span><%= CollectionUtils.equals(job.getCompletedCulture(), Boolean.TRUE) || savedJob ? "<img src=\"images/right-mark.png\" />" : "3"%></span>
Culture
......@@ -50,6 +54,7 @@
<oneit:button value=" " name="processCulture" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", fourthPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", fromJobMatch)
.toMap() %>">
<span><%= CollectionUtils.equals(job.getCompletedRequirements(), Boolean.TRUE) || savedJob ? "<img src=\"images/right-mark.png\" />" : "4"%></span>
Requirements
......@@ -59,6 +64,7 @@
<oneit:button value=" " name="processCulture" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", fifthPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", fromJobMatch)
.toMap() %>">
<span>5</span>
Review
......
......@@ -113,9 +113,10 @@
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", jobPage)
.mapEntry(UpdateMappedObjFP.FAIL_VALIDATION_ERRORS, Boolean.FALSE)
.toMap() %>"/>
<oneit:button value="Proceed to Culture" name="gotoPage" cssClass="btn btn-primary top-margin-37 largeBtn"
<oneit:button value="Proceed to Culture" name="processCulture" cssClass="btn btn-primary top-margin-37 largeBtn"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", nextPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).toMap())
.mapEntry("fromJobMatch", true)
.toMap() %>"/>
</div>
</div>
......
......@@ -131,7 +131,6 @@
</div>
</div>
<div class="form-brack-line-sub"></div>
<%
FormTag jobForm = FormTag.getActiveFormTag(request);
......
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