Files
Nexora/resources/views/livewire/project-show.blade.php
Javi 356f56eebd
Some checks failed
linter / quality (push) Has been cancelled
tests / ci (push) Has been cancelled
first commit
2025-04-23 00:14:33 +06:00

84 lines
3.9 KiB
PHP

<div>
<!-- Header del Proyecto -->
<div class="flex items-center justify-between pb-6 border-b">
<div>
<h1 class="text-2xl font-bold">{{ $project->name }}</h1>
<div class="flex items-center mt-2 space-x-4">
<span class="px-2 py-1 text-sm rounded-full bg-blue-100 text-blue-800">
{{ ucfirst($project->status) }}
</span>
<span class="text-sm text-gray-500">
{{ $project->created_at->format('d/m/Y') }}
</span>
</div>
</div>
<a href="{{ route('projects.edit', $project) }}"
class="px-4 py-2 text-white bg-blue-600 rounded-lg hover:bg-blue-700">
Editar Proyecto
</a>
</div>
<!-- Layout Principal -->
<div class="grid grid-cols-1 gap-6 mt-6 lg:grid-cols-4">
<!-- Treeview de Carpetas -->
<div class="col-span-1 bg-white rounded-lg shadow">
<div class="p-4 border-b">
<h3 class="font-medium">Estructura de Carpetas</h3>
</div>
<div class="p-4">
<ul class="space-y-2">
@foreach($rootFolders as $folder)
<x-folder-item
:folder="$folder"
:selectedFolderId="$selectedFolderId"
:expandedFolders="$expandedFolders"
wire:key="folder-{{ $folder->id }}"
/>
@endforeach
</ul>
</div>
</div>
<!-- Listado de Documentos -->
<div class="col-span-3">
<div class="bg-white rounded-lg shadow">
<div class="p-4 border-b">
<h3 class="font-medium">Documentos</h3>
</div>
<div class="overflow-x-auto">
<table class="min-w-full divide-y divide-gray-200">
<thead class="bg-gray-50">
<tr>
<th class="px-6 py-3 text-xs font-medium tracking-wider text-left text-gray-500 uppercase">Nombre</th>
<th class="px-6 py-3 text-xs font-medium tracking-wider text-left text-gray-500 uppercase">Versiones</th>
<th class="px-6 py-3 text-xs font-medium tracking-wider text-left text-gray-500 uppercase">Tamaño</th>
<th class="px-6 py-3 text-xs font-medium tracking-wider text-left text-gray-500 uppercase">Estado</th>
</tr>
</thead>
<tbody class="bg-white divide-y divide-gray-200">
@foreach($this->documents as $document)
<tr class="hover:bg-gray-50">
<td class="px-6 py-4 whitespace-nowrap">
<div class="flex items-center">
<x-icons icon="document" class="w-5 h-5 mr-2 text-gray-400" />
{{ $document->name }}
</div>
</td>
<td class="px-6 py-4 whitespace-nowrap">
{{ $document->versions->count() }}
</td>
<td class="px-6 py-4 whitespace-nowrap">
{{ $document->human_readable_size }}
</td>
<td class="px-6 py-4 whitespace-nowrap">
<x-status-badge :status="$document->status" />
</td>
</tr>
@endforeach
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>