Skip to content

[shots] Add bulk shot generation to the Create shots modal#2070

Open
mxatmx wants to merge 1 commit into
cgwire:mainfrom
mxatmx:feat/bulk-shot-generation-upstream
Open

[shots] Add bulk shot generation to the Create shots modal#2070
mxatmx wants to merge 1 commit into
cgwire:mainfrom
mxatmx:feat/bulk-shot-generation-upstream

Conversation

@mxatmx

@mxatmx mxatmx commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Add a "Bulk" tab to the Create shots modal that generates a range of shot names from a start name, count and step (e.g. SH010, SH020, ...), previews them, and creates them in one pass via the existing CSV import. Adds a generateBulkShotNames string helper and a bulkCreateShots store action.

Add a "Bulk" tab to the Create shots modal that generates a range of shot
names from a start name, count and step (e.g. SH010, SH020, ...), previews
them, and creates them in one pass via the existing CSV import. Adds a
`generateBulkShotNames` string helper and a `bulkCreateShots` store action.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
this.newShot(shot).then(callback).catch(console.error)
},

addShotsBulk(payload, callback) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please don't use callback. Use only promises.

@frankrousseau

Copy link
Copy Markdown
Contributor

Two small guards worth adding to the bulk tab:

  1. TV show with no episode selected → empty Episode cell in the CSV. isBulkGenerateAllowed only requires selectedSequenceId; on a TV show with selectedEpisodeId null, episodeName ?? null ends up as "" in the generated CSV and the result depends on how zou handles an empty episode column. Adding (!isTVShow || selectedEpisodeId) to the condition closes it.

  2. Negative step is not blocked. min="1" on the input doesn't prevent typing -10, and the !bulk.step guard only catches 0. Result: preview names like SH-10, SH-20, creatable if there is no collision. A bulk.step < 1 check in the bulkPreviewNames guard is enough.

Minor, non-blocking: on import failure the modal only does console.error + spinner reset — with up to 500 shots at stake, surfacing an error message in the modal would help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants