Skip to content

Commit 4a9f810

Browse files
committed
Remove publish link is calendar publishing is disabled
Related: nextcloud/server#34873 Author-Change-Id: IB#1126264 Signed-off-by: Pawel Boguslawski <[email protected]>
1 parent d78a682 commit 4a9f810

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

Diff for: src/components/AppNavigation/EditCalendarModal.vue

+11-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<!--
22
- @copyright Copyright (c) 2022 Richard Steinmetz <richard@steinmetz.cloud>
3+
- @copyright Copyright (c) 2024 Informatyka Boguslawski sp. z o.o. sp.k., https://www.ib.pl/
34
-
45
- @author Richard Steinmetz <[email protected]>
56
-
@@ -49,7 +50,7 @@
4950

5051
<div class="edit-calendar-modal__sharing">
5152
<SharingSearch :calendar="calendar" />
52-
<PublishCalendar :calendar="calendar" />
53+
<PublishCalendar :calendar="calendar" v-if="canBePublished" />
5354
<InternalLink :calendar="calendar" />
5455
<ShareItem v-for="sharee in calendar.shares"
5556
:key="sharee.uri"
@@ -135,6 +136,15 @@ export default {
135136
return this.$store.getters.getCalendarById(id)
136137
},
137138

139+
/**
140+
* Whether to show the publishing action.
141+
*
142+
* @return {boolean}
143+
*/
144+
canBePublished() {
145+
return this.calendar.canBePublished
146+
},
147+
138148
/**
139149
* Whether to show the sharing section
140150
*

0 commit comments

Comments
 (0)