@extends('layouts/contentNavbarLayout') @section('title', 'Tables - Basic Tables') @section('page-script') @endsection @section('content')

Projects / Manage Projects


@if(session('success') || session('error'))
{{ session('success') ? session('success') : session('error') }}
@endif @if(count($projects) > 0)
@foreach($projects->first()->getTableColumns() as $column) @if ($column !== 'id' && $column !== 'description' && $column !== 'location' && $column !== 'area' && $column !== 'status' && $column !== 'alt'&& $column !== 'metta_description'&& $column !== 'metta_title'&& $column !== 'metta_keyword'&& $column !== 'location_url'&& $column !== 'url') @endif @endforeach @foreach($projects as $project) @foreach($project->getTableColumns() as $column) @if ($column !== 'id' && $column !== 'description' && $column !== 'location' && $column !== 'area' && $column !== 'status' && $column !== 'alt'&& $column !== 'metta_description'&& $column !== 'metta_title'&& $column !== 'metta_keyword'&& $column !== 'location_url'&& $column !== 'url') @endif @endforeach @endforeach
{{ ucfirst($column) }}Actions
@if ($column === 'image_path' && !empty($project->{$column})) {{ $project->image_alt }} @elseif ($column === 'status') {{ $project->{$column} == 1 ? 'Active' : 'Inactive' }} @elseif ($column === 'category') {{ $project->categoryModel->category }} @elseif ($column === 'project_status') {{-- Display human-readable status --}} @if ($project->{$column} == 1) Completed @elseif ($project->{$column} == 2) Proposed @else Ongoing @endif @else {{ $project->{$column} }} @endif
@else
No projects found.
@endif
@endsection