Add amount field to job creation — auto-creates bracket when > 1
Amount > 1 with no bracket selected: auto-creates a bracket named
'{customer} – {file} ×{amount}', assigns all jobs to it, and redirects
to the new bracket page. Amount = 1 behaves as before.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -153,14 +153,26 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label class="form-label text-secondary small">Bracket <span class="text-secondary fw-normal">(optional)</span></label>
|
||||
<select name="bracket_id" class="form-select bg-dark border-secondary text-white">
|
||||
<option value="">— none —</option>
|
||||
{% for b in brackets %}
|
||||
<option value="{{ b.id }}">{{ b.name }}{% if b.customer %} · {{ b.customer }}{% endif %}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<div class="row g-3">
|
||||
<div class="col-md-4">
|
||||
<label class="form-label text-secondary small">Amount</label>
|
||||
<input type="number" name="amount"
|
||||
class="form-control bg-dark border-secondary text-white"
|
||||
value="1" min="1" max="500"
|
||||
title=">1 auto-creates a bracket">
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<label class="form-label text-secondary small">
|
||||
Bracket
|
||||
<span class="text-secondary fw-normal">(auto-created when amount > 1)</span>
|
||||
</label>
|
||||
<select name="bracket_id" class="form-select bg-dark border-secondary text-white">
|
||||
<option value="">— none / auto —</option>
|
||||
{% for b in brackets %}
|
||||
<option value="{{ b.id }}">{{ b.name }}{% if b.customer %} · {{ b.customer }}{% endif %}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
|
||||
Reference in New Issue
Block a user