Skip to content

Commit

Permalink
fix (inf331): lab progress listing unnecessary cases
Browse files Browse the repository at this point in the history
  • Loading branch information
HeitorMatt committed Sep 11, 2023
1 parent 739b3db commit 57c74a3
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,14 @@
let prognosisList = {}
await axios(config)
.then(function (endpointResponse) {
// for (let c of endpointResponse.data.cases){}
labList = endpointResponse.data.cases
})
.catch(function (error) {
console.log(error)
})
for (let lab of labList) {
if (lab.username == sessionStorage.getItem('harena-user-username')){
let propsLab = await this.getCaseProperties(lab.id)
let extendPeriod = null
let property = null
Expand All @@ -95,7 +97,7 @@
labProgressManager.i.lab[lab.title.substring(lab.title.length-1)] = {'id':lab.id,'desc':lab.description,'keywords':lab.keywords,'property':property, 'extendPeriod':extendPeriod}
}else if (lab.description == lab.keywords){
labProgressManager.i.lab[lab.description.substring(lab.description.length-1)] = {'id':lab.id,'desc':lab.description,'keywords':lab.keywords,'property':property, 'extendPeriod':extendPeriod}
}
}}
}
MessageBus.i.publish('data/lab.info/ready')
}
Expand Down
3 changes: 3 additions & 0 deletions src/adonisjs/public/infra/token-validator-mc.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class TokenController {
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down Expand Up @@ -119,6 +120,8 @@ class TokenController {
sessionStorage.setItem('harena-user-grade', endpointResponse.data.grade)
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down
3 changes: 3 additions & 0 deletions src/adonisjs/public/infra/token-validator-swe.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class TokenController {
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down Expand Up @@ -119,6 +120,8 @@ class TokenController {
sessionStorage.setItem('harena-user-grade', endpointResponse.data.grade)
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down
3 changes: 3 additions & 0 deletions src/adonisjs/public/infra/token-validator.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class TokenController {
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down Expand Up @@ -119,6 +120,8 @@ class TokenController {
sessionStorage.setItem('harena-user-grade', endpointResponse.data.grade)
sessionStorage.setItem('harena-user-institution', endpointResponse.data.institution)
sessionStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
sessionStorage.setItem('harena-user-id', endpointResponse.data.userId)
sessionStorage.setItem('harena-user-username', endpointResponse.data.username)
// localStorage.setItem('harena-user-grade', endpointResponse.data.grade)
// localStorage.setItem('harena-user-institution', endpointResponse.data.institution)
// localStorage.setItem('harena-user-institution-id', endpointResponse.data.institutionId)
Expand Down

0 comments on commit 57c74a3

Please sign in to comment.