changes to match the summary table addition of the api

This commit is contained in:
Katerina 2023-11-21 15:21:24 +02:00
parent df695da83f
commit e08b72eec2
4 changed files with 10 additions and 10 deletions

View File

@ -1,5 +1,5 @@
export class RulePerJob {
rule_name: string;
ruleName: string;
rule_weight: number;
guidelines: string;
rule_status: Status;

View File

@ -16,10 +16,10 @@
<tr *ngFor="let ruleResult of rules">
<td>
<div>
<span *ngIf="!ruleResult.rule_name">[No title available]</span>
<span *ngIf="ruleResult.rule_name">
<a *ngIf="ruleResult.link" class="custom-external uk-link-text" [href]="ruleResult.link" target="_blank">{{ruleResult.rule_name}}</a>
<span *ngIf="!ruleResult.link">{{ruleResult.rule_name}}</span>
<span *ngIf="!ruleResult.ruleName">[No title available]</span>
<span *ngIf="ruleResult.ruleName">
<a *ngIf="ruleResult.link" class="custom-external uk-link-text" [href]="ruleResult.link" target="_blank">{{ruleResult.ruleName}}</a>
<span *ngIf="!ruleResult.link">{{ruleResult.ruleName}}</span>
</span>
<span *ngIf="ruleResult.requirement_level">
<span> (</span>

View File

@ -160,7 +160,7 @@ export class OaipmhAnalysisComponent implements OnInit {
this.warningsModalOpen = true;
this.warningsModal.cancelButton = false;
this.warningsModal.okButton = false;
this.warningsModal.alertTitle = rule.rule_name;
this.warningsModal.alertTitle = rule.ruleName;
this.warningsModal.open();
}
@ -168,7 +168,7 @@ export class OaipmhAnalysisComponent implements OnInit {
this.errorsModalOpen = true;
this.errorsModal.cancelButton = false;
this.errorsModal.okButton = false;
this.errorsModal.alertTitle = rule.rule_name;
this.errorsModal.alertTitle = rule.ruleName;
this.errorsModal.open();
}
@ -176,7 +176,7 @@ export class OaipmhAnalysisComponent implements OnInit {
this.warnings = [];
this.openWarningsModal(rule);
this.warningsModalOpen = true;
this.subscriptions.push(this.validator.getWarnings(this.jobId, rule.rule_name).subscribe(
this.subscriptions.push(this.validator.getWarnings(this.jobId, rule.ruleName).subscribe(
result => {
this.warnings = result;
console.log(result);
@ -192,7 +192,7 @@ export class OaipmhAnalysisComponent implements OnInit {
this.errorsModalOpen = true;
if(rule.has_errors) {
this.subscriptions.push(this.validator.getErrors(this.jobId, rule.rule_name).subscribe(
this.subscriptions.push(this.validator.getErrors(this.jobId, rule.ruleName).subscribe(
result => {
this.errors = result;
console.log(result);

View File

@ -11,7 +11,7 @@ export class OaipmhValidatorService {
constructor(private http: HttpClient) {}
getAnalysis(jobId: string) {
let url: string = environment.validatorAPI + "reports/getResultsByJobId?jobId="+jobId;
let url: string = environment.validatorAPI + "reports/getSummaryFromDB?jobId="+jobId;
return this.http.get(url);
}