Skip to content

A free open source IT asset/license management system

Basic container+box components

snipeec50643d9675
diff --git a/resources/views/blade/box-body.blade.php b/resources/views/blade/box-body.blade.php
new file mode 100644
index 0000000000..cc95fb01f3
--- /dev/null
+++ b/resources/views/blade/box-body.blade.php
@@ -0,0 +1,4 @@
+<!-- Start box-body component -->
+<div class="box-body">
+ {{ $slot }}
+</div>
\ No newline at end of file
diff --git a/resources/views/blade/box-footer.blade.php b/resources/views/blade/box-footer.blade.php
new file mode 100644
index 0000000000..d8c1ff2670
--- /dev/null
+++ b/resources/views/blade/box-footer.blade.php
@@ -0,0 +1,23 @@
+@props([
+ 'cancel_route' => null,
+])
+
+<!-- Start box footer component -->
+<div class="box-footer">
+ <div class="row">
+
+ <div class="col-md-3">
+ <a class="btn btn-link" href="{{ $cancel_route }}">
+ {{ trans('general.cancel') }}
+ </a>
+ </div>
+
+ <div class="col-md-9 text-right">
+ <x-input.button class="btn-success" id="submit_button">
+ <x-icon type="checkmark" class="icon-white" />
+ {{ trans('general.save') }}
+ </x-input.button>
+ </div>
+
+ </div>
+</div>
\ No newline at end of file
diff --git a/resources/views/blade/box-header.blade.php b/resources/views/blade/box-header.blade.php
new file mode 100644
index 0000000000..0c54adb5fb
--- /dev/null
+++ b/resources/views/blade/box-header.blade.php
@@ -0,0 +1,6 @@
+<!-- Start box-header component -->
+<div class="box-header with-border">
+ <h2 class="box-title">
+ {{ $slot }}
+ </h2>
+</div>
\ No newline at end of file
diff --git a/resources/views/blade/box.blade.php b/resources/views/blade/box.blade.php
new file mode 100644
index 0000000000..0acfd01127
--- /dev/null
+++ b/resources/views/blade/box.blade.php
@@ -0,0 +1,26 @@
+@props([
+ 'box_style' => 'default',
+ 'header' => false,
+ 'footer' => true,
+
+])
+
+<!-- Start box component -->
+<div class="box box-{{ $box_style }}">
+
+ @if ($header)
+ <x-box-header>
+ {{ $header }}
+ </x-box-header>
+ @endif
+
+ <div class="box-body">
+ {{ $slot }}
+ </div>
+
+ @if ($footer)
+ <x-box-footer>
+ {{ $footer }}
+ </x-box-footer>
+ @endif
+</div>
\ No newline at end of file
diff --git a/resources/views/blade/container.blade.php b/resources/views/blade/container.blade.php
new file mode 100644
index 0000000000..55952c454c
--- /dev/null
+++ b/resources/views/blade/container.blade.php
@@ -0,0 +1,10 @@
+@props([
+'class' => 'col-md-12',
+])
+
+<!-- Start container+row component -->
+<div class="row">
+ <div class="{{ $class }}">
+ {{ $slot }}
+ </div>
+</div>
\ No newline at end of file
diff --git a/resources/views/locations/index.blade.php b/resources/views/locations/index.blade.php
index 5932e01359..b1c8928632 100755
--- a/resources/views/locations/index.blade.php
+++ b/resources/views/locations/index.blade.php
@@ -6,38 +6,34 @@
@parent
@stop
-{{-- Page content --}}
+
@section('content')
-<div class="row">
- <div class="col-md-12">
- <div class="box box-default">
- <div class="box-body">
- @include('partials.locations-bulk-actions')
+ <x-container>
+ <x-box>
+ @include('partials.locations-bulk-actions')
- <table
- data-columns="{{ \App\Presenters\LocationPresenter::dataTableLayout() }}"
- data-cookie-id-table="locationTable"
- data-id-table="locationTable"
- data-toolbar="#locationsBulkEditToolbar"
- data-bulk-button-id="#bulkLocationsEditButton"
- data-bulk-form-id="#locationsBulkForm"
- data-side-pagination="server"
- data-advanced-search="false"
- data-sort-order="asc"
- data-buttons="locationButtons"
- id="locationTable"
- class="table table-striped snipe-table"
- data-url="{{ route('api.locations.index', ['company_id'=>e(request('company_id')), 'status' => e(request('status'))]) }}"
- data-export-options='{
- "fileName": "export-locations-{{ date('Y-m-d') }}",
- "ignoreColumn": ["actions","image","change","checkbox","checkincheckout","icon"]
- }'>
- </table>
- </div>
- </div>
- </div>
-</div>
+ <table
+ data-columns="{{ \App\Presenters\LocationPresenter::dataTableLayout() }}"
+ data-cookie-id-table="locationTable"
+ data-id-table="locationTable"
+ data-toolbar="#locationsBulkEditToolbar"
+ data-bulk-button-id="#bulkLocationsEditButton"
+ data-bulk-form-id="#locationsBulkForm"
+ data-side-pagination="server"
+ data-advanced-search="false"
+ data-sort-order="asc"
+ data-buttons="locationButtons"
+ id="locationTable"
+ class="table table-striped snipe-table"
+ data-url="{{ route('api.locations.index', ['company_id'=>e(request('company_id')), 'status' => e(request('status'))]) }}"
+ data-export-options='{
+ "fileName": "export-locations-{{ date('Y-m-d') }}",
+ "ignoreColumn": ["actions","image","change","checkbox","checkincheckout","icon"]
+ }'>
+ </table>
+ </x-box>
+ </x-container>
@stop
@section('moar_scripts')