Skip to content

Commit

Permalink
log in realms
Browse files Browse the repository at this point in the history
  • Loading branch information
Gemma committed Jun 12, 2024
1 parent 6f76ecd commit 4c06c74
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 23 deletions.
2 changes: 1 addition & 1 deletion frontend/src/components/FilteringTerms/FilteringTerms.css
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ tbody {
width: 57%;
/* height: 100%; */
/* justify-content: center; */

overflow-x: scroll;
margin-bottom: -23px;
padding-left: 30px;
padding-top: 10px;
Expand Down
4 changes: 4 additions & 0 deletions frontend/src/components/Individuals/IndividualsResults.js
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,8 @@ function IndividualsResults (props) {
configData.API_URL + '/individuals',
jsonData1
)
console.log(jsonData1)
console.log(res)
} else {
const headers = { Authorization: `Bearer ${token}` }
console.log('querying with token')
Expand Down Expand Up @@ -861,6 +863,8 @@ function IndividualsResults (props) {
configData.API_URL + '/individuals',
jsonData2
)
console.log(jsonData2)
console.log(res)
} else {
console.log('Querying WITH token')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ function TableResultsIndividuals (props) {

const handleShowCrossQuery = e => {
setShowCrossQuery(true)

setParamCrossQuery(e.target.innerText)
}

Expand Down Expand Up @@ -489,6 +489,7 @@ function TableResultsIndividuals (props) {

useEffect(() => {
setShowDatasets(true)

}, [])

return (
Expand Down Expand Up @@ -600,27 +601,37 @@ function TableResultsIndividuals (props) {
</React.Fragment>
)
})}
{props.results.length === 0 && (
<React.Fragment key={beaconIndex}>
<tr
className='trGranuBeacon'
onClick={() => toggleRow(beaconIndex)}
>
<td className='tdGranuBeaconNoResults'>{result.id}</td>
<td className='tdGranuNoResults'></td>
{props.show === 'boolean' && (
<td
className={`tdGranuNoResults ${'tdNotFoundDataset'}`}
{props.results.length === 0 &&
props.beaconsList.map((beacon, index2) => {
const totalCount = 0
const allTrue = 'No, sorry'

return (
<React.Fragment key={index2}>
<tr
className='trGranuBeacon'
onClick={() => toggleRow(index2)}
>
No, sorry
</td>
)}
{props.show === 'count' && (
<td className={`tdGranu ${'tdNotFound'}`}>0 results</td>
)}
</tr>
</React.Fragment>
)}
<td className='tdGranuBeacon'>
{beacon.id}
{expandedRows.includes(index2) ? (
<ion-icon name='chevron-down-outline'></ion-icon>
) : (
<ion-icon name='chevron-up-outline'></ion-icon>
)}
</td>
<td className='tdGranuBeacon'></td>
<td className='tdGranuBeacon'>
{props.show === 'boolean'
? allTrue
? 'YES'
: 'No, sorry'
: totalCount}
</td>
</tr>
</React.Fragment>
)
})}
</tbody>
</table>
)
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/SignIn/SignInFormNoLS.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export default function SignInFormNoLS () {

const response = await fetch(
configData.KEYCLOAK_URL +
'/auth/realms/Beacon/protocol/openid-connect/token',
`/auth/realms/${process.env.REACT_APP_KEYCLOAK_CLIENT_REALM}/protocol/openid-connect/token`,
{
method: 'POST',
headers: {
Expand Down

0 comments on commit 4c06c74

Please sign in to comment.