A free open source IT asset/license management system
Fixed license checkin form UI
snipee26d0385893d
diff --git a/app/Http/Controllers/LicensesController.php b/app/Http/Controllers/LicensesController.phpindex c269b7a048..43254b1ef9 100755--- a/app/Http/Controllers/LicensesController.php+++ b/app/Http/Controllers/LicensesController.php@@ -357,12 +357,12 @@ class LicensesController extends Controllerpublic function getCheckin($seatId = null, $backTo = null){// Check if the asset exists- if (is_null($licenseseat = LicenseSeat::find($seatId))) {+ if (is_null($licenseSeat = LicenseSeat::find($seatId))) {// Redirect to the asset management page with errorreturn redirect()->route('licenses.index')->with('error', trans('admin/licenses/message.not_found'));}- $this->authorize('checkin', $licenseseat);- return view('licenses/checkin', compact('licenseseat'))->with('backto', $backTo);+ $this->authorize('checkin', $licenseSeat);+ return view('licenses/checkin', compact('licenseSeat'))->with('backto', $backTo);}diff --git a/resources/views/licenses/checkin.blade.php b/resources/views/licenses/checkin.blade.phpindex a04befeb76..0a55d1122e 100755--- a/resources/views/licenses/checkin.blade.php+++ b/resources/views/licenses/checkin.blade.php@@ -6,28 +6,31 @@@parent@stop+@section('header_right')-<a href="{{ URL::previous() }}" class="btn btn-primary pull-right">{{ trans('general.back') }}</a>+ <a href="{{ URL::previous() }}" class="btn btn-primary pull-right">+ {{ trans('general.back') }}</a>@stop{{-- Page content --}}@section('content')-<div class="row form-wrapper">- <!-- left column -->- <div class="col-md-10 column">-- @if ($backto=='user')- <form class="form-horizontal" method="post" action="{{ route('licenses.checkin', array('licenseeat_id'=> $licenseseat->id, 'backto'=>'user')) }}" autocomplete="off">- @else- <form class="form-horizontal" method="post" action="{{ route('licenses.checkin', $licenseseat->id) }}" autocomplete="off">- @endif- {{csrf_field()}}-- <!-- Asset name -->+ <div class="row">+ <!-- left column -->+ <div class="col-md-7">+ <form class="form-horizontal" method="post" action="{{ route('licenses.checkin.save', $licenseSeat) }}" autocomplete="off">+ {{csrf_field()}}++ <div class="box box-default">+ <div class="box-header with-border">+ <h3 class="box-title"> {{ $licenseSeat->license->name }}</h3>+ </div>+ <div class="box-body">++ <!-- license name --><div class="form-group"><label class="col-sm-2 control-label">{{ trans('admin/hardware/form.name') }}</label><div class="col-md-6">- <p class="form-control-static">{{ $licenseseat->license->name }}</p>+ <p class="form-control-static">{{ $licenseSeat->license->name }}</p></div></div>@@ -35,7 +38,7 @@<div class="form-group"><label class="col-sm-2 control-label">{{ trans('admin/hardware/form.serial') }}</label><div class="col-md-6">- <p class="form-control-static">{{ $licenseseat->license->serial }}</p>+ <p class="form-control-static">{{ $licenseSeat->license->serial }}</p></div></div>@@ -43,20 +46,16 @@<div class="form-group {{ $errors->has('note') ? 'error' : '' }}"><label for="note" class="col-md-2 control-label">{{ trans('admin/hardware/form.notes') }}</label><div class="col-md-7">- <textarea class="col-md-6 form-control" id="note" name="note">{{ Input::old('note', $licenseseat->note) }}</textarea>+ <textarea class="col-md-6 form-control" id="note" name="note">{{ Input::old('note', $licenseSeat->note) }}</textarea>{!! $errors->first('note', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!}</div></div>- <!-- Form actions -->- <div class="form-group">- <label class="col-md-2 control-label"></label>- <div class="col-md-7">- <a class="btn btn-link" href="{{ route('licenses.index') }}">{{ trans('button.cancel') }}</a>- <button type="submit" class="btn btn-success"><i class="fa fa-check icon-white"></i> {{ trans('general.checkin') }}</button>- </div>+ <div class="box-footer">+ <a class="btn btn-link" href="{{ route('licenses.index') }}">{{ trans('button.cancel') }}</a>+ <button type="submit" class="btn btn-success pull-right"><i class="fa fa-check icon-white"></i> {{ trans('general.checkin') }}</button></div>- </form>- </div> <!-- .col-md-10-->-</div>+ </div> <!-- /.box-->+</div> <!-- /.col-->+</div> <!-- /.row-->@stop