fix red score bug + display score again
This commit is contained in:
@@ -11,7 +11,7 @@
|
|||||||
<div class="recommendation" *ngFor="let r of recommendations.concat(discouragements)">
|
<div class="recommendation" *ngFor="let r of recommendations.concat(discouragements)">
|
||||||
<div class="treatment" [style.border-color]="computeScoreColor(r.score)"
|
<div class="treatment" [style.border-color]="computeScoreColor(r.score)"
|
||||||
[style.color]="computeScoreColor(r.score)"
|
[style.color]="computeScoreColor(r.score)"
|
||||||
(click)="openTreatmentDetails(r.treatment.code)">{{r.treatment.label}}</div>
|
(click)="openTreatmentDetails(r.treatment.code)">{{r.treatment.label}} ({{ r.score }})</div>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-container *ngIf="!hasResults()">
|
<ng-container *ngIf="!hasResults()">
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export class ResultsComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
computeScoreColor = (score: number) => {
|
computeScoreColor = (score: number) => {
|
||||||
if(score < 0.5){
|
if(score < 0){
|
||||||
return "#d3274f";
|
return "#d3274f";
|
||||||
}else if (score < 1){
|
}else if (score < 1){
|
||||||
return "#e8bb02";
|
return "#e8bb02";
|
||||||
|
|||||||
Reference in New Issue
Block a user