mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-25 21:54:14 -08:00
Merge remote-tracking branch 'upstream/develop' into develop
This commit is contained in:
commit
72e9360228
|
@ -96,6 +96,14 @@ class AssetImporter extends ItemImporter
|
|||
$item['rtd_location_id'] = $this->item['location_id'];
|
||||
}
|
||||
|
||||
if (isset($this->item['last_audit_date'])) {
|
||||
$item['last_audit_date'] = $this->item['last_audit_date'];
|
||||
}
|
||||
|
||||
if (isset($this->item['next_audit_date'])) {
|
||||
$item['next_audit_date'] = $this->item['next_audit_date'];
|
||||
}
|
||||
|
||||
if ($editingAsset) {
|
||||
$asset->update($item);
|
||||
} else {
|
||||
|
|
|
@ -76,6 +76,17 @@ class ItemImporter extends Importer
|
|||
if ($this->findCsvMatch($row, 'purchase_date') != '') {
|
||||
$this->item['purchase_date'] = date('Y-m-d 00:00:01', strtotime($this->findCsvMatch($row, 'purchase_date')));
|
||||
}
|
||||
|
||||
$this->item['last_audit_date'] = null;
|
||||
if ($this->findCsvMatch($row, 'last_audit_date') != '') {
|
||||
$this->item['last_audit_date'] = date('Y-m-d', strtotime($this->findCsvMatch($row, 'last_audit_date')));
|
||||
}
|
||||
|
||||
$this->item['next_audit_date'] = null;
|
||||
if ($this->findCsvMatch($row, 'next_audit_date') != '') {
|
||||
$this->item['next_audit_date'] = date('Y-m-d', strtotime($this->findCsvMatch($row, 'next_audit_date')));
|
||||
}
|
||||
|
||||
$this->item['qty'] = $this->findCsvMatch($row, 'quantity');
|
||||
$this->item['requestable'] = $this->findCsvMatch($row, 'requestable');
|
||||
$this->item['user_id'] = $this->user_id;
|
||||
|
|
|
@ -154,6 +154,8 @@
|
|||
{id: 'full_name', text: 'Full Name' },
|
||||
{id: 'status', text: 'Status' },
|
||||
{id: 'warranty_months', text: 'Warranty Months' },
|
||||
{id: 'last_audit_date', text: 'Last Audit Date' },
|
||||
{id: 'next_audit_date', text: 'Audit Date' },
|
||||
],
|
||||
consumables: [
|
||||
{id: 'item_no', text: "Item Number"},
|
||||
|
|
|
@ -16,21 +16,11 @@
|
|||
{{ trans('admin/depreciations/general.number_of_months') }}
|
||||
</label>
|
||||
<div class="col-md-7 col-sm-12 {{ (Helper::checkIfRequired($item, 'months')) ? ' required' : '' }}">
|
||||
<input class="form-control" type="text" name="months" aria-label="months" id="months" value="{{ Request::old('months', $item->months) }}" style="width: 80px;" />
|
||||
<input class="form-control" type="text" name="months" aria-label="months" id="months" value="{{ Request::old('months', $item->months) }}" style="width: 80px;"{!! (Helper::checkIfRequired($item, 'months')) ? ' data-validation="required" required' : '' !!} />
|
||||
{!! $errors->first('months', '<span class="alert-msg" aria-hidden="true"><i class="fas fa-times" aria-hidden="true"></i> :message</span>') !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Depreciation Minimum -->
|
||||
<div class="form-group {{ $errors->has('depreciation_min') ? ' has-error' : '' }}">
|
||||
<label for="depreciation_min" class="col-md-3 control-label">
|
||||
{{ trans('admin/depreciations/general.depreciation_min') }}
|
||||
</label>
|
||||
<div class="col-md-2" style="padding-left:0px">
|
||||
<input class="form-control" name="depreciation_min" id="depreciation_min" value="{{ Request::old('depreciation_min', $item->depreciation_min) }}" style="width: 80px; margin-left:15px" />
|
||||
</div>
|
||||
{!! $errors->first('depreciation_min', '<span class="alert-msg" aria-hidden="true"><i class="fas fa-times" aria-hidden="true"></i> :message</span>') !!}
|
||||
</div>
|
||||
<!-- Depreciation Minimum -->
|
||||
<div class="form-group {{ $errors->has('depreciation_min') ? ' has-error' : '' }}">
|
||||
<label for="depreciation_min" class="col-md-3 control-label">
|
||||
|
|
Loading…
Reference in a new issue