Add preview url to json

This commit is contained in:
Kuba Orlik 2022-07-09 21:36:21 +02:00
parent f9b61e35ae
commit e1291673ea

View File

@ -64,6 +64,7 @@ export default class ScreenshotRequest {
elapsed_time_s: number; elapsed_time_s: number;
zip_url: string | null; zip_url: string | null;
current_action: string; current_action: string;
preview: string;
}> { }> {
return { return {
url: this.url, url: this.url,
@ -89,6 +90,7 @@ export default class ScreenshotRequest {
this.status === "finished" this.status === "finished"
? `/api/requests/${this.id}/all-screenshots` ? `/api/requests/${this.id}/all-screenshots`
: null, : null,
preview: `/static/${this.id}/preview.png`,
}; };
} }