Added showcase flag to batch table.

This commit is contained in:
DebaucheryLibrarian
2023-07-25 03:22:24 +02:00
parent 1082effc17
commit b7a31b7933
3 changed files with 22 additions and 3 deletions

View File

@@ -343,7 +343,7 @@ async function storeMovies(movies, useBatchId) {
}
const { uniqueReleases } = await filterDuplicateReleases(movies);
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ comment: null }).returning('id');
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ showcased: argv.showcased, comment: null }).returning('id');
const curatedMovieEntries = await Promise.all(uniqueReleases.map((release) => curateReleaseEntry(release, batchId, null, 'movie')));
@@ -362,7 +362,7 @@ async function storeSeries(series, useBatchId) {
}
const { uniqueReleases } = await filterDuplicateReleases(series);
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ comment: null }).returning('id');
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ showcased: argv.showcased, comment: null }).returning('id');
const curatedSerieEntries = await Promise.all(uniqueReleases.map((release) => curateReleaseEntry(release, batchId, null, 'serie')));
@@ -380,7 +380,7 @@ async function storeScenes(releases, useBatchId) {
return [];
}
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ comment: null }).returning('id');
const [batchId] = useBatchId ? [useBatchId] : await knex('batches').insert({ showcased: argv.showcased, comment: null }).returning('id');
const releasesWithChannels = await attachChannelEntities(releases);
const releasesWithBaseActors = releasesWithChannels.map((release) => ({ ...release, actors: toBaseActors(release.actors) }));