Commit b455c713 by Nilu Committed by Harsh Shah

hiding order by when there are no applicants. removing expand feature which was…

hiding order by when there are no applicants. removing expand feature which was used earlier in HT005. Fix issue of not showing to shortlist option in all applicant grid view.
parent 686e669a
...@@ -335,11 +335,11 @@ public class Job extends BaseJob ...@@ -335,11 +335,11 @@ public class Job extends BaseJob
return getApplyBy() != null && DateDiff.endOfDay(getApplyBy()).before(DateDiff.getToday()); return getApplyBy() != null && DateDiff.endOfDay(getApplyBy()).before(DateDiff.getToday());
} }
public List<AppProcessOption> getValidProcessOptions(String tabNumber) public List<AppProcessOption> getValidProcessOptions(boolean isShortlist)
{ {
List<AppProcessOption> options = new ArrayList<>(); List<AppProcessOption> options = new ArrayList<>();
if(tabNumber == null || CollectionUtils.equals(tabNumber, "1")) if(!isShortlist)
{ {
options.add(AppProcessOption.TO_SHORTLIST); options.add(AppProcessOption.TO_SHORTLIST);
} }
......
...@@ -3290,7 +3290,7 @@ input.add-note-btn:hover{ ...@@ -3290,7 +3290,7 @@ input.add-note-btn:hover{
width: 19%; width: 19%;
text-align: left; text-align: left;
background: #ffffff none repeat scroll 0 0; background: #ffffff none repeat scroll 0 0;
margin: 0 0.4%; margin: 0.4% 0.4%;
width: 19.05%; width: 19.05%;
} }
.green-back{ .green-back{
...@@ -3939,7 +3939,7 @@ img.alert-icon {float: left;} ...@@ -3939,7 +3939,7 @@ img.alert-icon {float: left;}
.week-states{margin-top: 20px;} .week-states{margin-top: 20px;}
.dash-count {font-size: 48px;} .dash-count {font-size: 48px;}
.welcome-text {font-size: 30px;} .welcome-text {font-size: 30px;}
.appl-c-box{margin: 0 0.3%;} .appl-c-box{margin: 0.3% 0.3%;}
} }
@media screen and (max-width: 1380px){ @media screen and (max-width: 1380px){
...@@ -3952,7 +3952,7 @@ img.alert-icon {float: left;} ...@@ -3952,7 +3952,7 @@ img.alert-icon {float: left;}
.facebook-icon {width: 12.73%;} .facebook-icon {width: 12.73%;}
.shape-icon{width: 13.73%; } .shape-icon{width: 13.73%; }
.more-icon {width: 13.3%;} .more-icon {width: 13.3%;}
.appl-c-box{margin: 0 0.2%;} .appl-c-box{margin: 0.2% 0.2%;}
.over-all.f-60 {font-size: 54px;} .over-all.f-60 {font-size: 54px;}
.appli-list-drop{width: 145px;} .appli-list-drop{width: 145px;}
.appli-view-bar{margin-bottom: 5.5px;} .appli-view-bar{margin-bottom: 5.5px;}
......
...@@ -10,9 +10,8 @@ ...@@ -10,9 +10,8 @@
String currentPage = (String) getData(request, "currentPage"); String currentPage = (String) getData(request, "currentPage");
AppSortOption appSortOpt = (AppSortOption) getData(request, "sortOption"); AppSortOption appSortOpt = (AppSortOption) getData(request, "sortOption");
String tabNumber = (String) getData(request, "tabNumber"); String tabNumber = (String) getData(request, "tabNumber");
Boolean isShortList = getData(request, "isShortList")!=null ? (Boolean) getData(request, "isShortList") : Boolean.FALSE; Boolean isShortList = getData(request, "isShortList")!= null ? (Boolean) getData(request, "isShortList") : Boolean.FALSE;
Boolean expand = getData(request, "expand")!=null ? (Boolean) getData(request, "expand") : Boolean.FALSE; Boolean showOrderBy = getData(request, "showOrderBy")!= null ? (Boolean) getData(request, "showOrderBy") : Boolean.FALSE;
%> %>
<oneit:dynIncluded> <oneit:dynIncluded>
...@@ -45,7 +44,7 @@ ...@@ -45,7 +44,7 @@
<div class="appli-shorting-dropdown appli-left"> <div class="appli-shorting-dropdown appli-left">
<span class="appli-order-label">Bulk Update</span> <span class="appli-order-label">Bulk Update</span>
<oneit:ormEnum obj="<%= job %>" attributeName="AppProcessOption" cssClass="form-control bullk-app-process" id="AppProcessOption" <oneit:ormEnum obj="<%= job %>" attributeName="AppProcessOption" cssClass="form-control bullk-app-process" id="AppProcessOption"
enums="<%= job.getValidProcessOptions(tabNumber) %>"/> enums="<%= job.getValidProcessOptions(isShortList) %>"/>
<oneit:button name="bulkupdate" value=" " cssClass="bulk-update" skin="link" <oneit:button name="bulkupdate" value=" " cssClass="bulk-update" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", currentPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", currentPage)
...@@ -94,6 +93,9 @@ ...@@ -94,6 +93,9 @@
--%> --%>
<% <%
} }
if(showOrderBy)
{
%> %>
<div class="appli-shorting-dropdown"> <div class="appli-shorting-dropdown">
<span class="appli-order-label">order by</span> <span class="appli-order-label">order by</span>
...@@ -101,8 +103,7 @@ ...@@ -101,8 +103,7 @@
<% <%
for (AppSortOption sortOption : AppSortOption.getAppSortOptionArray()) for (AppSortOption sortOption : AppSortOption.getAppSortOptionArray())
{ {
String optionLink = currentPage + "&JobID=" + job.getID() + "&AppSortOption=" + sortOption.getName() String optionLink = currentPage + "&JobID=" + job.getID() + "&AppSortOption=" + sortOption.getName();
+ (expand ? "&Expand=Y" : "");
%> %>
<option <%= (appSortOpt != null && appSortOpt == sortOption ? "selected" : "" )%> value="<%= optionLink %>"> <option <%= (appSortOpt != null && appSortOpt == sortOption ? "selected" : "" )%> value="<%= optionLink %>">
<oneit:toString value="<%= sortOption.getDescription() %>" mode="EscapeHTML"/> <oneit:toString value="<%= sortOption.getDescription() %>" mode="EscapeHTML"/>
...@@ -112,6 +113,9 @@ ...@@ -112,6 +113,9 @@
%> %>
</select> </select>
</div> </div>
<%
}
%>
</div> </div>
</div> </div>
......
...@@ -69,6 +69,7 @@ ...@@ -69,6 +69,7 @@
tabNumber="1" tabNumber="1"
sortOption="<%= appSortOpt %>" sortOption="<%= appSortOpt %>"
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
showOrderBy="<%= sortedApplications.size() > 0 %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
<oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp"
......
...@@ -64,6 +64,7 @@ ...@@ -64,6 +64,7 @@
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
tabNumber="1" tabNumber="1"
isShortList="<%= Boolean.TRUE %>" isShortList="<%= Boolean.TRUE %>"
showOrderBy="<%= sortedApplications.size() > 0 %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
<oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp"
......
...@@ -16,18 +16,6 @@ ...@@ -16,18 +16,6 @@
process.setAttribute("Job", job); process.setAttribute("Job", job);
} }
Boolean isExpand = (Boolean) process.getAttribute("IsExpand");
if(request.getParameter("Expand") != null)
{
isExpand = CollectionUtils.equals((String) request.getParameter("Expand"), "Y");
}
if(isExpand == null)
{
isExpand = Boolean.FALSE;
}
Debug.assertion(job != null, "Job is null in admin portal view applicants"); Debug.assertion(job != null, "Job is null in admin portal view applicants");
String applicationPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICATION); String applicationPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICATION);
...@@ -56,7 +44,6 @@ ...@@ -56,7 +44,6 @@
List<JobApplication> sortedApplications = applications!=null ? Utils.getApplicationsSorted(applications, appSortOpt) : new ArrayList<JobApplication>(); List<JobApplication> sortedApplications = applications!=null ? Utils.getApplicationsSorted(applications, appSortOpt) : new ArrayList<JobApplication>();
process.setAttribute("AppSortOption", appSortOpt); process.setAttribute("AppSortOption", appSortOpt);
process.setAttribute("IsExpand", isExpand);
%> %>
<script type="text/javascript"> <script type="text/javascript">
...@@ -114,7 +101,7 @@ ...@@ -114,7 +101,7 @@
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
tabNumber="2" tabNumber="2"
isShortList="<%= Boolean.TRUE %>" isShortList="<%= Boolean.TRUE %>"
expand="<%= isExpand %>" showOrderBy="<%= sortedApplications.size() > 0 %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
......
...@@ -66,6 +66,7 @@ ...@@ -66,6 +66,7 @@
<oneit:dynInclude page="/extensions/adminportal/inc/application_sorting_bar.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/application_sorting_bar.jsp"
sortOption="<%= appSortOpt %>" sortOption="<%= appSortOpt %>"
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
showOrderBy="<%= sortedApplications.size() > 0 %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
<oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/application_list_data.jsp"
......
...@@ -16,18 +16,6 @@ ...@@ -16,18 +16,6 @@
process.setAttribute("Job", job); process.setAttribute("Job", job);
} }
Boolean isExpand = (Boolean) process.getAttribute("IsExpand");
if(request.getParameter("Expand") != null)
{
isExpand = CollectionUtils.equals((String) request.getParameter("Expand"), "Y");
}
if(isExpand == null)
{
isExpand = Boolean.FALSE;
}
Debug.assertion(job != null, "Job is null in admin portal view applicants"); Debug.assertion(job != null, "Job is null in admin portal view applicants");
String applicationPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICATION); String applicationPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICATION);
...@@ -59,7 +47,6 @@ ...@@ -59,7 +47,6 @@
List<JobApplication> sortedApplications = applications!=null ? Utils.getApplicationsSorted(applications, appSortOpt) : new ArrayList<JobApplication>(); List<JobApplication> sortedApplications = applications!=null ? Utils.getApplicationsSorted(applications, appSortOpt) : new ArrayList<JobApplication>();
process.setAttribute("AppSortOption", appSortOpt); process.setAttribute("AppSortOption", appSortOpt);
process.setAttribute("IsExpand", isExpand);
%> %>
<script type="text/javascript"> <script type="text/javascript">
...@@ -116,7 +103,7 @@ ...@@ -116,7 +103,7 @@
sortOption="<%= appSortOpt %>" sortOption="<%= appSortOpt %>"
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
tabNumber="2" tabNumber="2"
expand="<%= isExpand %>" showOrderBy="<%= sortedApplications.size() > 0 %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
...@@ -126,17 +113,24 @@ ...@@ -126,17 +113,24 @@
for(JobApplication jobApplication : sortedApplications) for(JobApplication jobApplication : sortedApplications)
{ {
String appID = "app-id-" + jobApplication.getID().toString();
%> %>
<div class="appl-c-box application-row"> <div class="appl-c-box application-row">
<oneit:button value=" " name="gotoPage" cssClass="<%= jobApplication.getID() + ""%>" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicationPage)
.mapEntry("procParams", CollectionUtils.mapEntry("JobApplication", jobApplication).toMap())
.toMap() %>">
<!--TODO: need to work on the logic. just added to demonstrate that there are 3 different colors for this--> <!--TODO: need to work on the logic. just added to demonstrate that there are 3 different colors for this-->
<div class="<%= "cb-title " + (index == 0 ? "green-back" : (index < 3 ? "blue-back" : "dark-back" ))%> "> <div class="<%= "cb-title " + (index == 0 ? "green-back" : (index < 3 ? "blue-back" : "dark-back" ))%> ">
<div class="checkbox-list grid-checkbox">
<div class="checkbox-list">
<input type="checkbox" name="IsSelected" value="<%= jobApplication.getObjectID().toString() %>" id="<%= appID %>" class="applicant" >
<label for="<%= appID %>">
<oneit:toString value="<%= jobApplication.getCandidate() %>" mode="EscapeHTML" /> <oneit:toString value="<%= jobApplication.getCandidate() %>" mode="EscapeHTML" />
</label>
</div>
</div>
</div> </div>
<oneit:button value=" " name="gotoPage" cssClass="<%= jobApplication.getID() + ""%>" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicationPage)
.mapEntry("procParams", CollectionUtils.mapEntry("JobApplication", jobApplication).toMap())
.toMap() %>">
<div class="overall-suitablity"> <div class="overall-suitablity">
<div class="<%= "overall " + (index == 0 ? "f-60" : "")%>">overall rank</div> <div class="<%= "overall " + (index == 0 ? "f-60" : "")%>">overall rank</div>
<div class="<%= "over-all " + (index == 0 ? "f-60 green" : (index < 3 ? "blue" : "gray"))%> "> <div class="<%= "over-all " + (index == 0 ? "f-60 green" : (index < 3 ? "blue" : "gray"))%> ">
......
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