Fix customer email inputs to allow comma-separated addresses
type="email" triggers jQuery Validate's email rule which rejects commas, blocking multi-address input despite the multiple attribute. Switching to type="text" defers validation to the server-side SplitEmails/MailAddress logic in the DTO which already handles comma-separated lists correctly. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -74,7 +74,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<label asp-for="Email" class="form-label">Email <span class="text-danger">*</span> <span class="text-muted fw-normal">(required if no phone number)</span></label>
|
<label asp-for="Email" class="form-label">Email <span class="text-danger">*</span> <span class="text-muted fw-normal">(required if no phone number)</span></label>
|
||||||
<input asp-for="Email" type="email" multiple class="form-control" placeholder="name@example.com (comma-separate multiple)" />
|
<input asp-for="Email" type="text" class="form-control" placeholder="name@example.com (comma-separate multiple)" />
|
||||||
<span asp-validation-for="Email" class="text-danger"></span>
|
<span asp-validation-for="Email" class="text-danger"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
@@ -91,7 +91,7 @@
|
|||||||
<label asp-for="BillingEmail" class="form-label">Billing / Accounting Email
|
<label asp-for="BillingEmail" class="form-label">Billing / Accounting Email
|
||||||
<span class="text-muted fw-normal">(invoices sent here)</span>
|
<span class="text-muted fw-normal">(invoices sent here)</span>
|
||||||
</label>
|
</label>
|
||||||
<input asp-for="BillingEmail" type="email" multiple class="form-control" placeholder="accounting@company.com (comma-separate multiple)" />
|
<input asp-for="BillingEmail" type="text" class="form-control" placeholder="accounting@company.com (comma-separate multiple)" />
|
||||||
<span asp-validation-for="BillingEmail" class="text-danger"></span>
|
<span asp-validation-for="BillingEmail" class="text-danger"></span>
|
||||||
<div class="form-text">When set, invoices are emailed here instead of the contact email.</div>
|
<div class="form-text">When set, invoices are emailed here instead of the contact email.</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -78,7 +78,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<label asp-for="Email" class="form-label">Email</label>
|
<label asp-for="Email" class="form-label">Email</label>
|
||||||
<input asp-for="Email" type="email" multiple class="form-control" placeholder="name@example.com (comma-separate multiple)" />
|
<input asp-for="Email" type="text" class="form-control" placeholder="name@example.com (comma-separate multiple)" />
|
||||||
<span asp-validation-for="Email" class="text-danger"></span>
|
<span asp-validation-for="Email" class="text-danger"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
@@ -95,7 +95,7 @@
|
|||||||
<label asp-for="BillingEmail" class="form-label">Billing / Accounting Email
|
<label asp-for="BillingEmail" class="form-label">Billing / Accounting Email
|
||||||
<span class="text-muted fw-normal">(invoices sent here)</span>
|
<span class="text-muted fw-normal">(invoices sent here)</span>
|
||||||
</label>
|
</label>
|
||||||
<input asp-for="BillingEmail" type="email" multiple class="form-control" placeholder="accounting@company.com (comma-separate multiple)" />
|
<input asp-for="BillingEmail" type="text" class="form-control" placeholder="accounting@company.com (comma-separate multiple)" />
|
||||||
<span asp-validation-for="BillingEmail" class="text-danger"></span>
|
<span asp-validation-for="BillingEmail" class="text-danger"></span>
|
||||||
<div class="form-text">When set, invoices are emailed here instead of the contact email.</div>
|
<div class="form-text">When set, invoices are emailed here instead of the contact email.</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user