Module Settings
This commit is contained in:
@@ -102,6 +102,7 @@ namespace BeWo.ViewModel
|
||||
{(r) => r == UserRightType.SupportConcept_ImportData, BeWoApp.AppSettings.ShowPersehImport},
|
||||
{(r) => r == UserRightType.AiChatInZeiterfassung, BeWoApp.AppSettings.ShowAI},
|
||||
{IsAiModuleRight, BeWoApp.AppSettings.ModuleAiEnabled},
|
||||
{IsAiModuleSettingRight, BeWoApp.AppSettings.ModuleAiSettingsEnabled},
|
||||
};
|
||||
|
||||
public List<UserRightType> PossibleRights
|
||||
@@ -291,7 +292,9 @@ namespace BeWo.ViewModel
|
||||
return false;
|
||||
}
|
||||
private static bool IsAiModuleRight(UserRightType right) =>
|
||||
ContainsRight(right, UserRightType.AiModuleView, UserRightType.AiModuleView2, UserRightType.AiModuleChatAdd, UserRightType.AiModuleChatDelete, UserRightType.AiModuleChatEdit, UserRightType.AiModuleViewSetting, UserRightType.AiModuleChatClone);
|
||||
ContainsRight(right, UserRightType.AiModuleView, UserRightType.AiModuleView2, UserRightType.AiModuleChatAdd, UserRightType.AiModuleChatDelete, UserRightType.AiModuleChatEdit, UserRightType.AiModuleChatClone);
|
||||
private static bool IsAiModuleSettingRight(UserRightType right) =>
|
||||
ContainsRight(right, UserRightType.AiModuleViewSetting);
|
||||
|
||||
private static bool ContainsRight(UserRightType right, params UserRightType[] rightTypes)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user