diff --git a/BeWo/View/Detail/AI/AiPromptbausteinFolderView.xaml b/BeWo/View/Detail/AI/AiPromptbausteinFolderView.xaml index f803b8d93..bbb0efecc 100644 --- a/BeWo/View/Detail/AI/AiPromptbausteinFolderView.xaml +++ b/BeWo/View/Detail/AI/AiPromptbausteinFolderView.xaml @@ -46,7 +46,7 @@ @@ -99,13 +99,13 @@ IsEnabled="False" SelectedCompactEmployeeDC="{Binding ViewModel.Creator}" /> - + IsEnabled="{Binding ViewModel.CanShareEdit}" /> ShowPrompt && ShowPromptByTenant; } + public bool CanShareEdit + { + get => BeWoApp.HasLoggedOnUserRight(UserRightType.AiModulePromptbausteinShare) + && Creator?.EmployeeOid is long owner + && owner == BeWoApp.CompactLoggedOnEmployee.EmployeeOid; + } + public string FavoritenHeader => IsFavorite ? "Favorit entfernen" : "Favorit hinzufügen"; protected override void InitByDataContract(AiPromptbausteinPromptDC pDataContract)