89 lines
3.8 KiB
PHP
89 lines
3.8 KiB
PHP
@extends('layouts.app')
|
|
@inject('employeeRepository', 'Modules\Employee\Repositories\EmployeeRepository')
|
|
@section('content')
|
|
<div class="page-content">
|
|
<div class="container-fluid">
|
|
@include('layouts.partials.breadcrumb', ['title' => $title])
|
|
|
|
@include('pms::task.partials.menu')
|
|
|
|
<div class="row">
|
|
<div class="col-lg-12">
|
|
<div class="card">
|
|
<div class="card-body">
|
|
<div class="table-responsive">
|
|
<table id="buttons-datatables" class="display table-sm table-bordered table" style="width:100%">
|
|
<thead>
|
|
<tr>
|
|
<th>S.N</th>
|
|
<th>Task</th>
|
|
<th>Project</th>
|
|
<th>Start Date</th>
|
|
<th>Deadline</th>
|
|
<th>Assigned</th>
|
|
<th>Priority</th>
|
|
<th>Status</th>
|
|
<th>Action</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@forelse ($tasks as $key => $task)
|
|
<tr>
|
|
<td>{{ $key + 1 }}</td>
|
|
<td>{{ $task->title }}</td>
|
|
<td>{{ optional($task->project)->project_name }}</td>
|
|
<td>{{ $task->start_date }}</td>
|
|
<td class="text-danger">{{ $task->due_date }}</td>
|
|
<td>
|
|
<div class="avatar-group flex-nowrap">
|
|
@isset($task->assigned_id)
|
|
@foreach ($task->assigned_id as $assignedId)
|
|
<div class="avatar-group-item">
|
|
<a href="javascript: void(0);" class="d-inline-block">
|
|
<img
|
|
src="{{ asset(optional($employeeRepository->getEmployeeById($assignedId))->profile_pic) }}"
|
|
alt="" class="rounded-circle avatar-xxs">
|
|
</a>
|
|
</div>
|
|
@endforeach
|
|
@endisset
|
|
|
|
</div>
|
|
</td>
|
|
<td>{!! $task->priority_status !!}</td>
|
|
<td>
|
|
<span class="badge bg-{{ $task->status_name['color'] }}"> {!! $task->status_name['status'] !!} </span>
|
|
</td>
|
|
<td>
|
|
<div class="hstack flex-wrap gap-3">
|
|
@can('task.show')
|
|
<a href="{{ route('task.show', $task->id) }}" class="link-info fs-15">
|
|
<i class="ri-eye-line"></i>
|
|
</a>
|
|
@endcan
|
|
@can('task.edit')
|
|
<a href="{{ route('task.edit', $task->id) }}" class="link-success fs-15 edit-item-btn"><i
|
|
class="ri-edit-2-line"></i></a>
|
|
@endcan
|
|
@can('task.destroy')
|
|
<a href="javascript:void(0);" data-link="{{ route('task.destroy', $task->id) }}"
|
|
data-id="{{ $task->id }}" class="link-danger fs-15 remove-item-btn"><i
|
|
class="ri-delete-bin-line"></i></a>
|
|
@endcan
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
@empty
|
|
@endforelse
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!--end row-->
|
|
</div>
|
|
</div>
|
|
@endsection
|