mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 21:04:37 +03:00
Add gallery scraping (#862)
This commit is contained in:
@@ -218,6 +218,8 @@ export const useScrapePerformer = (
|
||||
|
||||
export const useListSceneScrapers = () => GQL.useListSceneScrapersQuery();
|
||||
|
||||
export const useListGalleryScrapers = () => GQL.useListGalleryScrapersQuery();
|
||||
|
||||
export const useListMovieScrapers = () => GQL.useListMovieScrapersQuery();
|
||||
|
||||
export const useScrapeFreeonesPerformers = (q: string) =>
|
||||
@@ -673,6 +675,15 @@ export const queryScrapeSceneURL = (url: string) =>
|
||||
fetchPolicy: "network-only",
|
||||
});
|
||||
|
||||
export const queryScrapeGalleryURL = (url: string) =>
|
||||
client.query<GQL.ScrapeGalleryUrlQuery>({
|
||||
query: GQL.ScrapeGalleryUrlDocument,
|
||||
variables: {
|
||||
url,
|
||||
},
|
||||
fetchPolicy: "network-only",
|
||||
});
|
||||
|
||||
export const queryScrapeMovieURL = (url: string) =>
|
||||
client.query<GQL.ScrapeMovieUrlQuery>({
|
||||
query: GQL.ScrapeMovieUrlDocument,
|
||||
@@ -706,6 +717,19 @@ export const queryStashBoxScene = (stashBoxIndex: number, sceneID: string) =>
|
||||
},
|
||||
});
|
||||
|
||||
export const queryScrapeGallery = (
|
||||
scraperId: string,
|
||||
scene: GQL.GalleryUpdateInput
|
||||
) =>
|
||||
client.query<GQL.ScrapeGalleryQuery>({
|
||||
query: GQL.ScrapeGalleryDocument,
|
||||
variables: {
|
||||
scraper_id: scraperId,
|
||||
scene,
|
||||
},
|
||||
fetchPolicy: "network-only",
|
||||
});
|
||||
|
||||
export const mutateReloadScrapers = () =>
|
||||
client.mutate<GQL.ReloadScrapersMutation>({
|
||||
mutation: GQL.ReloadScrapersDocument,
|
||||
|
||||
Reference in New Issue
Block a user