Commit 64d6469d by Nilu

HT019.5 - HT Owner account is also the 'billing user' and the only team member…

HT019.5 - HT Owner account is also the 'billing user' and the only team member who's authorized to see navigation links for Billing, Plan, Invoices
parent 5c013a57
...@@ -175,4 +175,9 @@ public class CompanyUser extends BaseCompanyUser ...@@ -175,4 +175,9 @@ public class CompanyUser extends BaseCompanyUser
} }
} }
public boolean hasRole(RoleType role)
{
return getRoles() != null && getRoles().contains(role);
}
} }
\ No newline at end of file
...@@ -10,6 +10,9 @@ ...@@ -10,6 +10,9 @@
String secondPage = WebUtils.getSamePageInRenderMode(request, "ManagePlan"); String secondPage = WebUtils.getSamePageInRenderMode(request, "ManagePlan");
String thirdPage = WebUtils.getSamePageInRenderMode(request, "Billing"); String thirdPage = WebUtils.getSamePageInRenderMode(request, "Billing");
String forthPage = WebUtils.getSamePageInRenderMode(request, "Invoices"); String forthPage = WebUtils.getSamePageInRenderMode(request, "Invoices");
SecUser loggedInUser = SecUser.getTXUser(transaction);
CompanyUser companyUser = loggedInUser.getExtension(CompanyUser.REFERENCE_CompanyUser);
%> %>
<oneit:dynIncluded> <oneit:dynIncluded>
...@@ -22,27 +25,34 @@ ...@@ -22,27 +25,34 @@
Hiring Team Details Hiring Team Details
</oneit:button> </oneit:button>
</li> </li>
<li class="<%= tabNumber == "2" ? "active" : ""%>"> <%
<oneit:button value=" " name="gotoPage" skin="link" if(companyUser.hasRole(RoleType.BILLING))
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", secondPage) {
.toMap() %>"> %>
Manage Plan <li class="<%= tabNumber == "2" ? "active" : ""%>">
</oneit:button> <oneit:button value=" " name="gotoPage" skin="link"
</li> requestAttribs="<%= CollectionUtils.mapEntry("nextPage", secondPage)
<li class="<%= tabNumber == "3" ? "active" : ""%>"> .toMap() %>">
<oneit:button value=" " name="gotoPage" skin="link" Manage Plan
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", thirdPage) </oneit:button>
.toMap() %>"> </li>
Billing <li class="<%= tabNumber == "3" ? "active" : ""%>">
</oneit:button> <oneit:button value=" " name="gotoPage" skin="link"
</li> requestAttribs="<%= CollectionUtils.mapEntry("nextPage", thirdPage)
<li class="<%= tabNumber == "4" ? "active" : ""%>"> .toMap() %>">
<oneit:button value=" " name="gotoPage" skin="link" Billing
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", forthPage) </oneit:button>
.toMap() %>"> </li>
Invoices <li class="<%= tabNumber == "4" ? "active" : ""%>">
</oneit:button> <oneit:button value=" " name="gotoPage" skin="link"
</li> requestAttribs="<%= CollectionUtils.mapEntry("nextPage", forthPage)
.toMap() %>">
Invoices
</oneit:button>
</li>
<%
}
%>
</ul> </ul>
</div> </div>
</oneit:dynIncluded> </oneit:dynIncluded>
......
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