mirror of
https://github.com/nicotsx/ironmount.git
synced 2025-12-10 12:10:51 +01:00
feat: backup schedule frontend
This commit is contained in:
@@ -7,6 +7,7 @@ import {
|
||||
getRepositoryDto,
|
||||
listRepositoriesDto,
|
||||
listSnapshotsDto,
|
||||
listSnapshotsFilters,
|
||||
type DeleteRepositoryDto,
|
||||
type GetRepositoryDto,
|
||||
type ListRepositoriesDto,
|
||||
@@ -38,9 +39,11 @@ export const repositoriesController = new Hono()
|
||||
|
||||
return c.json<DeleteRepositoryDto>({ message: "Repository deleted" }, 200);
|
||||
})
|
||||
.get("/:name/snapshots", listSnapshotsDto, async (c) => {
|
||||
.get("/:name/snapshots", listSnapshotsDto, validator("query", listSnapshotsFilters), async (c) => {
|
||||
const { name } = c.req.param();
|
||||
const res = await repositoriesService.listSnapshots(name);
|
||||
const { volumeId } = c.req.valid("query");
|
||||
|
||||
const res = await repositoriesService.listSnapshots(name, Number(volumeId));
|
||||
|
||||
const snapshots = res.map((snapshot) => {
|
||||
const { summary } = snapshot;
|
||||
|
||||
Reference in New Issue
Block a user