Skip to content

Commit fcdb3e4

Browse files
committed
fix: paid users shouldn't see a link to an estimation page when they are on someone else collection page
Fix #1511
1 parent eceaea0 commit fcdb3e4

File tree

1 file changed

+1
-1
lines changed
  • src/main/webapp/WEB-INF/views/collection

1 file changed

+1
-1
lines changed

src/main/webapp/WEB-INF/views/collection/info.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ <h4 class="panel-title" th:text="#{t_in_collection}">In this collection</h4>
9999
<p th:text="|#{t_series_amount}: ${seriesCounter}|">Amount of series: 3</p>
100100
<p th:text="|#{t_stamps_amount}: ${stampsCounter}|">Amount of stamps: 34</p>
101101
<!--/* @todo #892 Add integration tests for showing a link to collection estimation page */-->
102-
<p sec:authorize="hasAuthority('ADD_SERIES_PRICE')">
102+
<p sec:authorize="(hasAuthority('ADD_SERIES_PRICE') and #authentication?.principal?.userCollectionSlug == #vars.slug) or hasAuthority('VIEW_ANY_ESTIMATION')">
103103
<span th:text="#{t_cost}">The cost</span>:
104104
<a href="estimation.html"
105105
th:href="@{${ESTIMATION_COLLECTION_PAGE}(slug=${slug})}"

0 commit comments

Comments
 (0)