From ce0c5ab36f8fafb28ad4a7db5147b71e4a1fa23e Mon Sep 17 00:00:00 2001 From: sohitkumar Date: Tue, 22 Oct 2024 12:12:28 +0530 Subject: [PATCH] (update) : added enableAI flag for visibilty of chat button --- src/features/default/src/Components/Resources/ResourceCard.js | 2 ++ src/features/default/src/Views/Resources/ViewResource.js | 1 + 2 files changed, 3 insertions(+) diff --git a/src/features/default/src/Components/Resources/ResourceCard.js b/src/features/default/src/Components/Resources/ResourceCard.js index d9f33bfb..88ba714c 100644 --- a/src/features/default/src/Components/Resources/ResourceCard.js +++ b/src/features/default/src/Components/Resources/ResourceCard.js @@ -39,6 +39,7 @@ import { TbEditCircle } from "react-icons/tb"; import { CgDetailsMore } from "react-icons/cg"; import { IoMdMore } from "react-icons/io"; import UrlConstant from "../../Constants/UrlConstants"; +import globalConfig from "globalConfig"; const cardSx = { maxWidth: 368, @@ -318,6 +319,7 @@ const ResourceCard = ({ {getTokenLocal() && + globalConfig.enableAI && (isLoggedInUserAdmin() || isLoggedInUserCoSteward() || isLoggedInUserParticipant()) ? ( diff --git a/src/features/default/src/Views/Resources/ViewResource.js b/src/features/default/src/Views/Resources/ViewResource.js index d84083f1..d9b9d84f 100644 --- a/src/features/default/src/Views/Resources/ViewResource.js +++ b/src/features/default/src/Views/Resources/ViewResource.js @@ -1699,6 +1699,7 @@ const ViewResource = (props) => { {getTokenLocal() && + globalConfig.enableAI && (isLoggedInUserAdmin() || isLoggedInUserCoSteward() || isLoggedInUserParticipant()) ? (