2023-05-21 10:56:38 +02:00
|
|
|
@php require_frontend_packages(['datatables']); @endphp
|
|
|
|
|
2018-09-23 09:22:54 +02:00
|
|
|
@extends('layout.default')
|
|
|
|
|
2019-05-01 20:19:18 +02:00
|
|
|
@section('title', $__t('Task categories'))
|
2018-09-23 09:22:54 +02:00
|
|
|
|
|
|
|
@section('content')
|
|
|
|
<div class="row">
|
|
|
|
<div class="col">
|
2020-04-19 08:51:02 -04:00
|
|
|
<div class="title-related-links">
|
|
|
|
<h2 class="title">@yield('title')</h2>
|
2020-11-07 14:53:45 +01:00
|
|
|
<div class="float-right">
|
|
|
|
<button class="btn btn-outline-dark d-md-none mt-2 order-1 order-md-3"
|
|
|
|
type="button"
|
|
|
|
data-toggle="collapse"
|
|
|
|
data-target="#table-filter-row">
|
2022-04-04 20:10:29 +02:00
|
|
|
<i class="fa-solid fa-filter"></i>
|
2020-11-07 14:53:45 +01:00
|
|
|
</button>
|
|
|
|
<button class="btn btn-outline-dark d-md-none mt-2 order-1 order-md-3"
|
|
|
|
type="button"
|
|
|
|
data-toggle="collapse"
|
|
|
|
data-target="#related-links">
|
2022-04-04 20:10:29 +02:00
|
|
|
<i class="fa-solid fa-ellipsis-v"></i>
|
2020-11-07 14:53:45 +01:00
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="related-links collapse d-md-flex order-2 width-xs-sm-100"
|
|
|
|
id="related-links">
|
2020-11-08 19:00:12 +01:00
|
|
|
<a class="btn btn-primary responsive-button m-1 mt-md-0 mb-md-0 float-right show-as-dialog-link"
|
|
|
|
href="{{ $U('/taskcategory/new?embedded') }}">
|
2020-10-31 18:37:10 +01:00
|
|
|
{{ $__t('Add') }}
|
|
|
|
</a>
|
2020-08-31 20:32:50 +02:00
|
|
|
<a class="btn btn-outline-secondary"
|
|
|
|
href="{{ $U('/userfields?entity=task_categories') }}">
|
2020-04-19 08:51:02 -04:00
|
|
|
{{ $__t('Configure userfields') }}
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
2018-09-23 09:22:54 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2020-10-31 18:37:10 +01:00
|
|
|
|
2020-11-08 15:09:10 +01:00
|
|
|
<hr class="my-2">
|
2020-10-31 18:37:10 +01:00
|
|
|
|
2020-11-07 14:53:45 +01:00
|
|
|
<div class="row collapse d-md-flex"
|
|
|
|
id="table-filter-row">
|
2021-06-24 22:46:47 +02:00
|
|
|
<div class="col-12 col-md-6 col-xl-3">
|
2020-10-31 18:37:10 +01:00
|
|
|
<div class="input-group">
|
2020-04-19 08:51:02 -04:00
|
|
|
<div class="input-group-prepend">
|
2022-04-04 20:10:29 +02:00
|
|
|
<span class="input-group-text"><i class="fa-solid fa-search"></i></span>
|
2020-04-19 08:51:02 -04:00
|
|
|
</div>
|
2020-08-31 20:32:50 +02:00
|
|
|
<input type="text"
|
|
|
|
id="search"
|
|
|
|
class="form-control"
|
|
|
|
placeholder="{{ $__t('Search') }}">
|
2020-04-19 08:51:02 -04:00
|
|
|
</div>
|
2018-09-23 09:22:54 +02:00
|
|
|
</div>
|
2023-05-13 14:24:52 +02:00
|
|
|
<div class="col-12 col-md-6 col-xl-3">
|
|
|
|
<div class="form-check custom-control custom-checkbox">
|
|
|
|
<input class="form-check-input custom-control-input"
|
|
|
|
type="checkbox"
|
|
|
|
id="show-disabled">
|
|
|
|
<label class="form-check-label custom-control-label"
|
|
|
|
for="show-disabled">
|
|
|
|
{{ $__t('Show disabled') }}
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-11-07 14:53:45 +01:00
|
|
|
<div class="col">
|
|
|
|
<div class="float-right">
|
2022-04-04 22:42:10 +02:00
|
|
|
<button id="clear-filter-button"
|
2020-11-07 14:53:45 +01:00
|
|
|
class="btn btn-sm btn-outline-info"
|
2022-04-04 21:07:14 +02:00
|
|
|
data-toggle="tooltip"
|
|
|
|
title="{{ $__t('Clear filter') }}">
|
|
|
|
<i class="fa-solid fa-filter-circle-xmark"></i>
|
2022-04-04 22:42:10 +02:00
|
|
|
</button>
|
2020-11-07 14:53:45 +01:00
|
|
|
</div>
|
|
|
|
</div>
|
2018-09-23 09:22:54 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="col">
|
2020-08-31 20:32:50 +02:00
|
|
|
<table id="taskcategories-table"
|
2020-11-07 14:53:45 +01:00
|
|
|
class="table table-sm table-striped nowrap w-100">
|
2018-09-23 09:22:54 +02:00
|
|
|
<thead>
|
|
|
|
<tr>
|
2020-11-11 22:28:05 +01:00
|
|
|
<th class="border-right"><a class="text-muted change-table-columns-visibility-button"
|
|
|
|
data-toggle="tooltip"
|
2020-11-11 21:11:17 +01:00
|
|
|
data-toggle="tooltip"
|
2020-12-16 18:18:03 +01:00
|
|
|
title="{{ $__t('Table options') }}"
|
2020-11-11 21:11:17 +01:00
|
|
|
data-table-selector="#taskcategories-table"
|
2022-04-04 20:10:29 +02:00
|
|
|
href="#"><i class="fa-solid fa-eye"></i></a>
|
2020-11-11 21:11:17 +01:00
|
|
|
</th>
|
2019-05-01 20:19:18 +02:00
|
|
|
<th>{{ $__t('Name') }}</th>
|
|
|
|
<th>{{ $__t('Description') }}</th>
|
2019-04-22 22:16:35 +02:00
|
|
|
|
|
|
|
@include('components.userfields_thead', array(
|
2020-08-31 20:32:50 +02:00
|
|
|
'userfields' => $userfields
|
2019-04-22 22:16:35 +02:00
|
|
|
))
|
|
|
|
|
2018-09-23 09:22:54 +02:00
|
|
|
</tr>
|
|
|
|
</thead>
|
2019-01-05 20:06:35 +01:00
|
|
|
<tbody class="d-none">
|
2018-09-23 09:22:54 +02:00
|
|
|
@foreach($taskCategories as $taskCategory)
|
2023-05-13 14:24:52 +02:00
|
|
|
<tr class="@if($taskCategory->active == 0) text-muted @endif">
|
2019-03-09 10:49:26 +01:00
|
|
|
<td class="fit-content border-right">
|
2020-11-08 19:00:12 +01:00
|
|
|
<a class="btn btn-info btn-sm show-as-dialog-link"
|
2020-11-12 21:35:10 +01:00
|
|
|
href="{{ $U('/taskcategory/') }}{{ $taskCategory->id }}?embedded"
|
|
|
|
data-toggle="tooltip"
|
|
|
|
title="{{ $__t('Edit this item') }}">
|
2022-04-04 20:10:29 +02:00
|
|
|
<i class="fa-solid fa-edit"></i>
|
2018-09-23 09:22:54 +02:00
|
|
|
</a>
|
2020-08-31 20:32:50 +02:00
|
|
|
<a class="btn btn-danger btn-sm task-category-delete-button"
|
|
|
|
href="#"
|
|
|
|
data-category-id="{{ $taskCategory->id }}"
|
2020-11-12 21:35:10 +01:00
|
|
|
data-category-name="{{ $taskCategory->name }}"
|
|
|
|
data-toggle="tooltip"
|
|
|
|
title="{{ $__t('Delete this item') }}">
|
2022-04-04 20:10:29 +02:00
|
|
|
<i class="fa-solid fa-trash"></i>
|
2018-09-23 09:22:54 +02:00
|
|
|
</a>
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{{ $taskCategory->name }}
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{{ $taskCategory->description }}
|
|
|
|
</td>
|
2019-04-22 22:16:35 +02:00
|
|
|
|
|
|
|
@include('components.userfields_tbody', array(
|
2020-08-31 20:32:50 +02:00
|
|
|
'userfields' => $userfields,
|
|
|
|
'userfieldValues' => FindAllObjectsInArrayByPropertyValue($userfieldValues, 'object_id', $taskCategory->id)
|
2019-04-22 22:16:35 +02:00
|
|
|
))
|
|
|
|
|
2018-09-23 09:22:54 +02:00
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@stop
|