Checkin/checkout fixes
This commit is contained in:
parent
cff2a65f62
commit
05e9861b71
2 changed files with 218 additions and 252 deletions
|
@ -2,21 +2,21 @@
|
||||||
|
|
||||||
{{-- Page title --}}
|
{{-- Page title --}}
|
||||||
@section('title')
|
@section('title')
|
||||||
{{ trans('admin/hardware/general.checkin') }}
|
{{ trans('admin/hardware/general.checkin') }}
|
||||||
@parent
|
@parent
|
||||||
@stop
|
@stop
|
||||||
|
|
||||||
{{-- Page content --}}
|
{{-- Page content --}}
|
||||||
@section('content')
|
@section('content')
|
||||||
<style>
|
<style>
|
||||||
|
|
||||||
.input-group {
|
.input-group {
|
||||||
padding-left: 0px !important;
|
padding-left: 0px !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<!-- left column -->
|
<!-- left column -->
|
||||||
<div class="col-md-9">
|
<div class="col-md-9">
|
||||||
<div class="box box-default">
|
<div class="box box-default">
|
||||||
|
@ -55,25 +55,14 @@
|
||||||
|
|
||||||
|
|
||||||
<!-- Asset Name -->
|
<!-- Asset Name -->
|
||||||
<!-- Only allow an asset name to be changed if the checker-outer has permission to edit the asset -->
|
|
||||||
@can('update', $asset)
|
|
||||||
<div class="form-group {{ $errors->has('name') ? 'error' : '' }}">
|
<div class="form-group {{ $errors->has('name') ? 'error' : '' }}">
|
||||||
{{ Form::label('name', trans('admin/hardware/form.name'), array('class' => 'col-md-3 control-label')) }}
|
{{ Form::label('name', trans('admin/hardware/form.name'), array('class' => 'col-md-3 control-label')) }}
|
||||||
<div class="col-md-8">
|
<div class="col-md-8">
|
||||||
<input class="form-control" type="text" name="name" aria-label="name" id="name"
|
<input class="form-control" type="text" name="name" aria-label="name" id="name"
|
||||||
|
value="{{ old('name', $asset->name) }}"/>
|
||||||
{!! $errors->first('name', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}
|
{!! $errors->first('name', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@else
|
|
||||||
@if ($asset->name!='')
|
|
||||||
<div class="form-group {{ $errors->has('name') ? 'error' : '' }}">
|
|
||||||
{{ Form::label('name', trans('admin/hardware/form.name'), array('class' => 'col-md-3 control-label')) }}
|
|
||||||
<div class="col-md-8">
|
|
||||||
<p class="form-control-static">{{ $asset->name }}</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@endif
|
|
||||||
@endcan
|
|
||||||
|
|
||||||
<!-- Status -->
|
<!-- Status -->
|
||||||
<div class="form-group {{ $errors->has('status_id') ? 'error' : '' }}">
|
<div class="form-group {{ $errors->has('status_id') ? 'error' : '' }}">
|
||||||
|
@ -122,6 +111,6 @@
|
||||||
|
|
||||||
</div> <!--/.box.box-default-->
|
</div> <!--/.box.box-default-->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@stop
|
@stop
|
|
@ -3,20 +3,20 @@
|
||||||
{{-- Page title --}}
|
{{-- Page title --}}
|
||||||
@section('title')
|
@section('title')
|
||||||
{{ trans('admin/hardware/general.checkout') }}
|
{{ trans('admin/hardware/general.checkout') }}
|
||||||
@parent
|
@parent
|
||||||
@stop
|
@stop
|
||||||
|
|
||||||
{{-- Page content --}}
|
{{-- Page content --}}
|
||||||
@section('content')
|
@section('content')
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|
||||||
.input-group {
|
.input-group {
|
||||||
padding-left: 0px !important;
|
padding-left: 0px !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<!-- left column -->
|
<!-- left column -->
|
||||||
<div class="col-md-7">
|
<div class="col-md-7">
|
||||||
<div class="box box-default">
|
<div class="box box-default">
|
||||||
|
@ -51,29 +51,6 @@
|
||||||
{!! $errors->first('name', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}
|
{!! $errors->first('name', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@endif
|
|
||||||
|
|
||||||
<!-- Asset Name -->
|
|
||||||
<!-- Only allow an asset name to be changed if the checker-outer has permission to edit the asset -->
|
|
||||||
@can('update', $asset)
|
|
||||||
<div class="form-group {{ $errors->has('name') ? 'error' : '' }}">
|
|
||||||
{{ Form::label('name', trans('admin/hardware/form.name'), array('class' => 'col-md-3 control-label')) }}
|
|
||||||
<div class="col-md-8">
|
|
||||||
<input class="form-control" type="text" name="name" id="name" value="{{ Request::old('name', $asset->name) }}" tabindex="1">
|
|
||||||
{!! $errors->first('name', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@else
|
|
||||||
@if ($asset->name!='')
|
|
||||||
<div class="form-group {{ $errors->has('name') ? 'error' : '' }}">
|
|
||||||
{{ Form::label('name', trans('admin/hardware/form.name'), array('class' => 'col-md-3 control-label')) }}
|
|
||||||
<div class="col-md-8">
|
|
||||||
<p class="form-control-static">{{ $asset->name }}</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@endif
|
|
||||||
@endcan
|
|
||||||
|
|
||||||
@include ('partials.forms.checkout-selector', ['user_select' => 'true','asset_select' => 'true', 'location_select' => 'true'])
|
@include ('partials.forms.checkout-selector', ['user_select' => 'true','asset_select' => 'true', 'location_select' => 'true'])
|
||||||
|
|
||||||
@include ('partials.forms.edit.user-select', ['translated_name' => trans('general.user'), 'fieldname' => 'assigned_user', 'required'=>'true'])
|
@include ('partials.forms.edit.user-select', ['translated_name' => trans('general.user'), 'fieldname' => 'assigned_user', 'required'=>'true'])
|
||||||
|
@ -165,19 +142,19 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@stop
|
@stop
|
||||||
|
|
||||||
@section('moar_scripts')
|
@section('moar_scripts')
|
||||||
@include('partials/assets-assigned')
|
@include('partials/assets-assigned')
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// $('#checkout_at').datepicker({
|
// $('#checkout_at').datepicker({
|
||||||
// clearBtn: true,
|
// clearBtn: true,
|
||||||
// todayHighlight: true,
|
// todayHighlight: true,
|
||||||
// endDate: '0d',
|
// endDate: '0d',
|
||||||
// format: 'yyyy-mm-dd'
|
// format: 'yyyy-mm-dd'
|
||||||
// });
|
// });
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
Loading…
Add table
Reference in a new issue