derat/yambs

Allow seeding the web frontend

Closed this issue · 3 comments

For recurring submissions of similar data I currently store the contents of "Values to set on all entities" and "Input fields" in a text file next to the spreadsheet with data which is updated with new entries from time to time. While copying these two blurbs of text into the form each time I need them isn't a great deal, I've just had an idea how this workflow could be improved... (trying not to sound greedy after you've already realized #10 so quickly 😁)

It would be very comfortable if I could "seed the seeder" with this data via query parameters, then I could simply store a bookmark for each artist/label/series/whatever for which I plan to regularly seed releases/recordings/works. Seeding would probably make sense for all form elements except for the main input for which you can already load a file (and which may contain too much data).

Bonus points if the frontend provides a button to copy a permalink for the current settings.

(As an alternative I could probably try to finally use the command line version's arguments and create a few simple shell scripts instead of bookmarks, but I really like the UX of the web interface.)

derat commented

Thanks, that's a great idea!

Just to check, do you tend to want the same "set" and "fields" values that you used last time, or do you sometimes need to alternate between multiple combinations? The web UI currently saves and restores the state of the select elements (i.e. source, format, type) in the browser (using localStorage), and it'd be easy to do the same with the "set" and "fields" textareas if that'd fit your use case.

From the mention of artists/labels/series/etc., I'm guessing that you need to manage multiple combinations, though. The approach that you suggested with query parameters and a permalink sounds like a good way to accomplish that; I just want to make sure it's needed since it may be a bit more complicated and hard-to-discover for users. :-)

From the mention of artists/labels/series/etc., I'm guessing that you need to manage multiple combinations, though.

Yeah, that's what I had in mind. I've already used yambs to seed a series of 173 releases by one artist (which is likely complete and won't be expanded) and I'm currently preparing spreadsheets for a few series with dozens/hundreds of works for which I will probably continue to add new works as they are published in the future. So even without using it to add standalone recordings (I've just checked that I only added 11 of these on MB over the years), I definitely have to swap between a dozen different combinations of yambs parameters for which persisting the form in localStorage wouldn't help as much as if I was using the same basic parameters every time.

I can even imagine that I would probably create presets for all of the recurrent additions/editing which I'm currently doing by hand (or using a userscript to clone the latest release by an artist/label/series as a template). Maybe it would be even worth adding such a permalink to the annotation of MB series to help other editors to add missing parts?

derat commented

That makes sense; thanks for the detailed explanation. Let me know if the stuff that I just deployed works for what you're doing.