Scenario:
You want to hide the save button from the report viewer in JasperServer so that users cannot re-save the report. How to do that?
Solution:
to remove the save buttons you can do the following:
Edit the /jasperserver-pro/WEB-INF/jsp/modules/viewReport/viewReport.jsp
Find the following block:
<li class="node"> <ul class="list buttonSet"> <c:if test="${isPro}"> <li class="leaf"><button id="fileOptions" class="button capsule mutton up first" aria-label="<spring:message code="button.save"/>" data-title="true" disabled="true"><span class="wrap"><span class="icon"></span><span class="indicator"></span></span></button></li> </c:if> <c:if test="${!isPro}"> <li class="leaf"><button id="fileOptions" class="button capsule mutton up first" aria-label="<spring:message code="button.save"/> - <spring:message code="feature.pro.only"/>" data-title="true" disabled="true"><span class="wrap"><span class="icon"></span><span class="indicator"></span></span></button></li> </c:if> <li class="leaf"><button id="export" class="button capsule mutton up last" disabled="disabled" aria-label="<spring:message code="button.export"/>" data-title="true"><span class="wrap"><span class="icon"></span><span class="indicator"></span></span></button></li> </ul> </li>
Comment out the following:
<li class="leaf"><button id="fileOptions" class="button capsule mutton up first" aria-label="<spring:message code="button.save"/>" data-title="true" disabled="true"><span class="wrap"><span class="icon"></span><span class="indicator"></span></span></button></li> <li class="leaf"><button id="fileOptions" class="button capsule mutton up first" aria-label="<spring:message code="button.save"/> - <spring:message code="feature.pro.only"/>" data-title="true" disabled="true"><span class="wrap"><span class="icon"></span><span class="indicator"></span></span></button></li>
- Save and restart.
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now