diff --git a/README.md b/README.md index 8a55b5cc..e0a687fe 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,24 @@ # Help Desk -
+
Help Desk is a Laravel based project, that let you manage your support tickets and communicate with your customers, with diff --git a/app/Http/Livewire/Kanban.php b/app/Http/Livewire/Kanban.php new file mode 100644 index 00000000..92cac6cf --- /dev/null +++ b/app/Http/Livewire/Kanban.php @@ -0,0 +1,148 @@ +withCount('comments'); + if (has_all_permissions(auth()->user(), 'view-own-tickets') && !has_all_permissions(auth()->user(), 'view-all-tickets')) { + $query->where(function ($query) { + $query->where('owner_id', auth()->user()->id) + ->orWhere('responsible_id', auth()->user()->id); + }); + } + return $query->get() + ->map(function (Ticket $ticket) { + $priority = config('system.priorities.' . $ticket->priority); + $type = config('system.types.' . $ticket->type); + return [ + 'id' => $ticket->id, + 'title' => new HtmlString(' +