mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-20 21:33:15 -07:00
!wip
This commit is contained in:
parent
806cf7c0ff
commit
9d2fc81a0c
4 changed files with 9 additions and 4 deletions
|
@ -4,7 +4,7 @@ export interface IFailedRequestsViewModel {
|
||||||
title: string;
|
title: string;
|
||||||
releaseYear: Date;
|
releaseYear: Date;
|
||||||
requestId: number;
|
requestId: number;
|
||||||
requestType: RequestType;
|
type: RequestType;
|
||||||
dts: Date;
|
dts: Date;
|
||||||
error: string;
|
error: string;
|
||||||
retryCount: number;
|
retryCount: number;
|
||||||
|
|
|
@ -15,4 +15,7 @@ export class RequestRetryService extends ServiceHelpers {
|
||||||
public getFailedRequests(): Observable<IFailedRequestsViewModel[]> {
|
public getFailedRequests(): Observable<IFailedRequestsViewModel[]> {
|
||||||
return this.http.get<IFailedRequestsViewModel[]>(this.url, {headers: this.headers});
|
return this.http.get<IFailedRequestsViewModel[]>(this.url, {headers: this.headers});
|
||||||
}
|
}
|
||||||
|
public deleteFailedRequest(failedId: number): Observable<IFailedRequestsViewModel[]> {
|
||||||
|
return this.http.delete<IFailedRequestsViewModel[]>(`${this.url}/${failedId}`, {headers: this.headers});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
<td>Type</td>
|
<td>Type</td>
|
||||||
<td>Retry Count</td>
|
<td>Retry Count</td>
|
||||||
<td>Error Description</td>
|
<td>Error Description</td>
|
||||||
<td>Retry</td>
|
|
||||||
<td>Delete</td>
|
<td>Delete</td>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
@ -21,8 +20,7 @@
|
||||||
<td>{{RequestType[v.type] | humanize}}</td>
|
<td>{{RequestType[v.type] | humanize}}</td>
|
||||||
<td class="vcenter">{{v.retryCount}}</td>
|
<td class="vcenter">{{v.retryCount}}</td>
|
||||||
<td class="vcenter"> <i [pTooltip]="v.error" class="fa fa-info-circle"></i></td>
|
<td class="vcenter"> <i [pTooltip]="v.error" class="fa fa-info-circle"></i></td>
|
||||||
<td class="vcenter"><button></button></td>
|
<td class="vcenter"><button class="btn btn-primary" (click)="remove(v.failedId)">Remove</button></td>
|
||||||
<td class="vcenter"><button></button></td>
|
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
|
@ -15,4 +15,8 @@ export class FailedRequestsComponent implements OnInit {
|
||||||
public ngOnInit() {
|
public ngOnInit() {
|
||||||
this.retry.getFailedRequests().subscribe(x => this.vm = x);
|
this.retry.getFailedRequests().subscribe(x => this.vm = x);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public remove(failedId: number) {
|
||||||
|
this.retry.deleteFailedRequest(failedId).subscribe();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue