autoselect first work order type when only 1

deepsource-autofix-76c6eb20
Dan Gowans 2022-12-14 15:30:12 -05:00
parent e995c156b3
commit 9917a11cfb
1 changed files with 1 additions and 1 deletions

View File

@ -110,7 +110,7 @@
<div class="control"> <div class="control">
<div class="select is-fullwidth"> <div class="select is-fullwidth">
<select id="workOrderEdit--workOrderTypeId" name="workOrderTypeId" required <%= (isCreate ? " autofocus" : "") %>> <select id="workOrderEdit--workOrderTypeId" name="workOrderTypeId" required <%= (isCreate ? " autofocus" : "") %>>
<% if (isCreate) { %> <% if (isCreate && workOrderTypes.length > 1) { %>
<option value="">(Select Type)</option> <option value="">(Select Type)</option>
<% } %> <% } %>
<% for (const workOrderType of workOrderTypes) { %> <% for (const workOrderType of workOrderTypes) { %>