fix(project): only show create task cta when the user has permission to write to the project

Resolves https://community.vikunja.io/t/create-a-task-link-in-empty-project-for-read-only-share-links/3127
This commit is contained in:
kolaente
2024-12-19 17:08:44 +01:00
parent 9c5f35a0d8
commit bfb7cf9403

View File

@@ -37,14 +37,13 @@
<Nothing v-if="ctaVisible && tasks.length === 0 && !loading">
{{ $t('project.list.empty') }}
<ButtonLink
v-if="project.id > 0"
v-if="project.id > 0 && canWrite"
@click="focusNewTaskInput()"
>
{{ $t('project.list.newTaskCta') }}
</ButtonLink>
</Nothing>
<draggable
v-if="tasks && tasks.length > 0"
v-model="tasks"