Skip to content

Commit b1ef838

Browse files
SSHVersionControlroot
authored andcommitted
Show edit button for project only if master of project
1 parent 641c669 commit b1ef838

File tree

1 file changed

+3
-1
lines changed
  • src/VersionControl/GitControlBundle/Resources/views/Default

1 file changed

+3
-1
lines changed

src/VersionControl/GitControlBundle/Resources/views/Default/list.html.twig

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@
5959
<td><span class="label label-success">{{userProject.roles}}</label></td>
6060
<td style="width:180px">
6161
<a href="{{ path('project', { 'id': userProject.project.id }) }}" class="btn btn-primary btn-flat">Open</a>
62-
<a href="{{ path('project_edit', { 'id': userProject.project.id }) }}" class="btn btn-info btn-flat">Edit</a>
62+
{% if (is_granted('MASTER', userProject.project)) %}
63+
<a href="{{ path('project_edit', { 'id': userProject.project.id }) }}" class="btn btn-info btn-flat">Edit</a>
64+
{% endif %}
6365
</td>
6466
</tr>
6567
{% endfor %}

0 commit comments

Comments
 (0)