Merge pull request #11856 from inietov/fixes/purchase_date_not_nullable

Fixed Purchase date "readonly" value makes purchase date unable to be nulled in update form [sc-19540]
This commit is contained in:
snipe 2022-09-26 13:38:24 -07:00 committed by GitHub
commit 091ef62cbe
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -6,6 +6,7 @@
<input type="text" class="form-control" placeholder="{{ trans('general.select_date') }}" name="purchase_date" id="purchase_date" readonly value="{{ old('purchase_date', ($item->purchase_date) ? $item->purchase_date->format('Y-m-d') : '') }}" style="background-color:inherit"> <input type="text" class="form-control" placeholder="{{ trans('general.select_date') }}" name="purchase_date" id="purchase_date" readonly value="{{ old('purchase_date', ($item->purchase_date) ? $item->purchase_date->format('Y-m-d') : '') }}" style="background-color:inherit">
<span class="input-group-addon"><i class="fas fa-calendar" aria-hidden="true"></i></span> <span class="input-group-addon"><i class="fas fa-calendar" aria-hidden="true"></i></span>
</div> </div>
<a style="cursor:pointer" onclick="document.getElementById('purchase_date').value = ''"> Clear </a>
{!! $errors->first('purchase_date', '<span class="alert-msg" aria-hidden="true"><i class="fas fa-times" aria-hidden="true"></i> :message</span>') !!} {!! $errors->first('purchase_date', '<span class="alert-msg" aria-hidden="true"><i class="fas fa-times" aria-hidden="true"></i> :message</span>') !!}
</div> </div>
</div> </div>