-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature/1444 - Add ability to unamend an unmodified amendment #2136
Conversation
@@ -107,6 +108,28 @@ export class ReportListComponent extends TableListBaseComponent<Report> implemen | |||
}); | |||
} | |||
|
|||
public confirmUnamend(report: Report): void { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not seeing a confirm dialog in the ticket. I think we need to leave this out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Took out confirm.
.startUnamendment(report) | ||
.pipe(take(1), takeUntil(this.destroy$)) | ||
.subscribe(() => { | ||
this.loadTableItems({}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The ticket references a toast message. Probably need to add:
this.messageService.add({
severity: 'success',
summary: 'Successful',
detail: 'Report Unamended',
life: 3000,
});
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added in toast.
@@ -104,6 +104,10 @@ export class ReportService implements TableListService<Report> { | |||
return this.apiService.post(`${this.apiEndpoint}/${report.id}/amend/`, {}); | |||
} | |||
|
|||
public startUnamendment(report: Report): Observable<string> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see we're following the pattern the amendment implementation set. What do you think of changing these two to promises?
public amend(report:Report): Promise<string> {
return getFirstValueFrom(this.apiService.post(...))
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I just saw this one. Yea promises would make a lot more sense here.
e7de8b8
to
76b74ef
Compare
sier processing
869cfa0
to
57842d9
Compare
Quality Gate passedIssues Measures |
Issue FECFILE-1444
API PR PR1032