@extends('admin.layouts.master') @section('page_title', __('admin.Complaints')) @section('page_heading', __('admin.Complaints')) @section('page_text', __('admin.Complaints')) @section('page_breadcrumb_icon') @endsection @section('page_breadcrumb_item', 'Complaints') @section('page_breadcrumb_item2', 'Complaints') @section('css') @endsection @section('content')
@foreach ($complaint as $item)

{{ date('l jS \\of F Y', strtotime($item->created_at)) }}

Complaint Type: {{ $item->complaint_type }}

@if ($item->incident_time_date)

Date / Time: {{ $item->incident_time_date }}

@endif @if ($item->incident_cause)

Location: {{ $item->incident_cause }}

@endif

{{ $item->complaint_detail }}

{{ $item->name }}

{{ $item->apart_number }}

{{ $item->email }}

{{ $item->phone }}

Occupier Status: {{ $item->occupier_status }}

View/Reply      {!! Form::open([ 'method' => 'DELETE', 'onsubmit' => 'return confirm("Are you sure you want to delete this?")', 'route' => ['request.complaint.destroy', $item->id], 'style' => 'display:inline', ]) !!} {!! Form::hidden('id', $item->id, ['required' => 'required', 'placeholder' => '', 'class' => 'form-control']) !!} {!! Form::button('Delete', [ 'type' => 'submit', 'class' => 'border-0 btn-transition btn btn-outline-danger', 'data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => '', 'data-original-title' => 'Delete', ]) !!}

Resident
@if ($item->user) {{ $item->user->title }} {{ $item->user->first_name }} {{ $item->user->last_name }}
{{ $item->user->residence->apartment->name }}
Floor {{ $item->user->residence->apartment->floor_no }}
{{ $item->user->email }} @endif

@endforeach
@endsection