diff --git a/src/Bundle/ChillMainBundle/Entity/SavedExport.php b/src/Bundle/ChillMainBundle/Entity/SavedExport.php index 08f866cb6..56143efdd 100644 --- a/src/Bundle/ChillMainBundle/Entity/SavedExport.php +++ b/src/Bundle/ChillMainBundle/Entity/SavedExport.php @@ -176,6 +176,14 @@ class SavedExport implements TrackCreationInterface, TrackUpdateInterface ]); } + /** + * Return true if shared with at least one user or one group + */ + public function isShared(): bool + { + return $this->sharedWithUsers->count() > 0 || $this->sharedWithGroups->count() > 0; + } + /** * Determines if the user is shared with either directly or through a group. * diff --git a/src/Bundle/ChillMainBundle/Resources/views/SavedExport/index.html.twig b/src/Bundle/ChillMainBundle/Resources/views/SavedExport/index.html.twig index 49bfda9e8..6ccadbcdf 100644 --- a/src/Bundle/ChillMainBundle/Resources/views/SavedExport/index.html.twig +++ b/src/Bundle/ChillMainBundle/Resources/views/SavedExport/index.html.twig @@ -30,6 +30,7 @@ {% if app.user is same as saved.user %}
{% else %}