Skip to content

Commit 8984cfe

Browse files
committed
Fix: shelterluv link
1 parent 7708d71 commit 8984cfe

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

src/client/src/pages/DataView360/View/View360.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ class View360 extends Component {
8686
});
8787
})
8888
}
89-
debugger;
89+
9090
this.setState({
9191
participantData: response.result,
9292
animalData: animalInfo,
@@ -164,12 +164,13 @@ class View360 extends Component {
164164
<AnimalInfo pets={_.get(this.state, 'animalData')}
165165
events={_.get(this.state, 'adoptionEvents')}
166166
headerText={"Adoption Records"}
167-
adoption_person_id=
167+
shelterluv_id={_.get(this.state, 'participantData.shelterluv_id')}
168168

169169
/>
170170
<AnimalInfo pets={_.get(this.state, 'animalData')}
171171
events={_.get(this.state, 'fosterEvents')}
172172
headerText={"Foster Records"}
173+
shelterluv_id={_.get(this.state, 'participantData.shelterluv_id')}
173174
/>
174175
<VolunteerActivity volunteer={this.extractVolunteerActivity()} />
175176
<VolunteerHistory volunteerShifts={_.get(this.state, 'participantData.shifts')} />

src/client/src/pages/DataView360/View/components/AnimalInfo.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,15 +57,15 @@ class AnimalInfo extends Component {
5757
const latestPets = this.getLatestPets(this.props.pets, events);
5858
const headerText = this.props.headerText;
5959
const headerAddition = (numOfPets > PET_COUNT) ? " (Showing " + PET_COUNT + " Pets out of " + numOfPets + ")" : ""
60-
const shelterLuvPersonURL = `https://www.shelterluv.com/phlp-p-${this.props.adoption_person_id}`
60+
const shelterLuvPersonURL = `https://www.shelterluv.com/phlp-p-${this.props.shelterluv_id}`;
6161

6262
return (
6363
<Container component={Paper} style={{ "marginTop": "1em" }}>
6464
<DataTableHeader headerText={headerText + headerAddition}
6565
emojiIcon={<PetsIcon color='primary' fontSize='inherit'/>}
6666
>
6767
<Grid item>
68-
<IconButton style={{ 'padding': 0, 'paddingLeft': 5 }} color="primary" aria-label="link" href={shelterLuvPersonURL}>
68+
<IconButton style={{ 'padding': 0, 'paddingLeft': 5 }} color="primary" aria-label="link" href={shelterLuvPersonURL} target="_blank">
6969
<LinkIcon />
7070
</IconButton>
7171
</Grid>

src/server/api/common_api.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,10 @@ def get_360(matching_id):
9898

9999
result['shifts'] = volgisticsshifts_results
100100

101+
if row["source_type"] == "shelterluvpeople":
102+
shelterluv_id = row["source_id"]
103+
result["shelterluv_id"] = shelterluv_id
104+
101105
return jsonify({'result': result})
102106

103107

0 commit comments

Comments
 (0)