Skip to content

Commit

Permalink
[GUI] Update reviewData when switching between reports
Browse files Browse the repository at this point in the history
There was a bug when the report was loaded. The value of the review status dropdown menu did not change when switching to a report with a different status.
Now every time when the report changes, the reviewData is updated as a computed property.
  • Loading branch information
cservakt committed Nov 14, 2023
1 parent 482804c commit ef537ab
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions web/server/vue-cli/src/components/Report/Report.vue
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,6 @@ export default {
step: null,
editor: null,
sourceFile: null,
reviewData: new ReviewData(),
jsPlumbInstance: null,
lineMarks: [],
lineWidgets: [],
Expand Down Expand Up @@ -386,6 +385,12 @@ export default {
return this.showComments
? maxCols - this.commentCols
: maxCols;
},
reviewData() {
return this.report && this.report.reviewData
? this.report.reviewData
: new ReviewData();
}
},
Expand Down Expand Up @@ -531,8 +536,6 @@ export default {
this.report = report;
this.reviewData = report.reviewData;
await this.setSourceFileData(report.fileId);
await this.drawBugPath();
Expand Down

0 comments on commit ef537ab

Please sign in to comment.