Skip to content

Commit

Permalink
Merge pull request #616 from culturecreates/feature/issue-471
Browse files Browse the repository at this point in the history
fix: artsdata links redirection url added
  • Loading branch information
AbhishekPAnil authored Sep 25, 2023
2 parents 53cf96c + fe76669 commit d070646
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 10 deletions.
4 changes: 4 additions & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
REACT_APP_API_URL="https://api.cms.footlight.io"
REACT_APP_ARTS_DATA_URI="https://api.artsdata.ca/"
REACT_APP_ARTS_DATA_PAGE_URI="https://kg.artsdata.ca/resource/"
REACT_APP_DEEPL_URL="https://www.deepl.com/translator#"
REACT_APP_HELP_EN_URL="https://footlight.gitbook.io/footlight-cms-guide"
REACT_APP_HELP_FR_URL="https://footlight.gitbook.io/guide-footlight-cms"
REACT_APP_FEATURE_FLAG_QUICK_CREATE_ORGANIZATION=true
REACT_APP_FEATURE_FLAG_ORG_PERSON_PLACE_VIEW=true
REACT_APP_FEATURE_FLAG_QUICK_CREATE_PEOPLE_PLACE=true
REACT_APP_FEATURE_FLAG_EDIT_SCREEN_PEOPLE_PLACE_ORGANIZATION=false
REACT_APP_FEATURE_FLAG_USERS=false
REACT_APP_FEATURE_FLAG_IMAGE_CROP=false
REACT_APP_ENV="production"
REACT_APP_INVITE_URL=" https://cms.footlight.io/join?invitationId="
Expand Down
1 change: 1 addition & 0 deletions .env.staging
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
REACT_APP_API_URL="https://staging.api.cms.footlight.io"
REACT_APP_ARTS_DATA_URI="https://api.artsdata.ca/"
REACT_APP_ARTS_DATA_PAGE_URI="https://kg.artsdata.ca/resource/"
REACT_APP_DEEPL_URL="https://www.deepl.com/translator#"
REACT_APP_HELP_EN_URL="https://footlight.gitbook.io/footlight-cms-guide"
REACT_APP_HELP_FR_URL="https://footlight.gitbook.io/guide-footlight-cms"
Expand Down
18 changes: 10 additions & 8 deletions src/components/Card/Common/EntityCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,16 @@ const EntityCard = (props) => {
<div className="description">{description}</div>
</div>
<div className="link-container">
<ArtsDataLink
onClick={(e) => {
e.stopPropagation();
window.open(`${artsDataLink}`, '_blank', 'noopener,noreferrer');
}}>
<span style={{ textDecoration: 'underline' }}>{linkText}</span>
<LinkOutlined />
</ArtsDataLink>
{artsDataLink && (
<ArtsDataLink
onClick={(e) => {
e.stopPropagation();
window.open(`${artsDataLink}`, '_blank', 'noopener,noreferrer');
}}>
<span style={{ textDecoration: 'underline' }}>{linkText}</span>
<LinkOutlined />
</ArtsDataLink>
)}
</div>
</div>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ function SearchOrganizations() {
<EntityCard
title={organizer?.name}
description={organizer?.description}
artsDataLink={`${process.env.REACT_APP_ARTS_DATA_URI}${organizer?.id}`}
artsDataLink={`${process.env.REACT_APP_ARTS_DATA_PAGE_URI}${organizer?.id}`}
Logo={organizer.logo ? <img src={organizer?.logo?.thumbnail?.uri} /> : <Logo />}
linkText={t('dashboard.organization.createNew.search.linkText')}
onClick={() => artsDataClickHandler(organizer)}
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Dashboard/SearchPlaces/SearchPlaces.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ function SearchPlaces() {
<EntityCard
title={place?.name}
description={place?.description}
artsDataLink={`${process.env.REACT_APP_ARTS_DATA_URI}${place?.id}`}
artsDataLink={`${process.env.REACT_APP_ARTS_DATA_PAGE_URI}${place?.id}`}
Logo={
place.logo ? (
place.logo?.thumbnail?.uri
Expand Down

0 comments on commit d070646

Please sign in to comment.