Skip to content

Commit

Permalink
Not reading from redux store was the issue
Browse files Browse the repository at this point in the history
  • Loading branch information
EdwinGuzman committed Sep 20, 2024
1 parent b2c9395 commit b8fc88e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ jobs:
aws ecs update-service --cluster discovery-ui-edd --service discovery-ui-edd --force-new-deployment
publish_production:
# needs: test
if: github.ref == 'refs/heads/production'
if: github.ref == 'refs/heads/TGR-50/remediation-update'
name: Publish image to ECR and update ECS stack
runs-on: ubuntu-latest
permissions:
Expand Down
5 changes: 2 additions & 3 deletions src/app/components/Item/RequestButtons.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@ import React from 'react';
import { Link } from 'react-router';
import { aeonUrl } from '../../utils/utils';
import { MediaContext } from '../Application/Application';
import { useSelector } from 'react-redux';

const RequestButtons = ({ item, bibId, searchKeywords, appConfig, page }) => {
const features = useSelector(state => state.features);
const media = React.useContext(MediaContext);

const ifAvailableHandler = (handler, available) => (available ? handler : (e) => { e.preventDefault() })
Expand All @@ -12,15 +14,12 @@ const RequestButtons = ({ item, bibId, searchKeywords, appConfig, page }) => {
closedLocations,
recapClosedLocations,
nonRecapClosedLocations,
features,
} = appConfig;
const isRecap = item.isRecap;
const allClosed = closedLocations
.concat(isRecap ? recapClosedLocations : nonRecapClosedLocations)
.includes('');
console.log({closedLocations, recapClosedLocations, nonRecapClosedLocations, allClosed})
const isAeon = item.aeonUrl && features.includes('aeon-links');
console.log(item.aeonUrl, features, isAeon)

const physRequestButton = () => {
if (isAeon || allClosed || !item.physRequestable) {
Expand Down

0 comments on commit b8fc88e

Please sign in to comment.