fix: restore Rappasoft tables + fix boot errors from security commit
- Restore UserTable/CompanyTable/ProjectTable usage in users, companies and projects-list pages (security commit had replaced them with plain HTML/DaisyUI tables, losing sorting/search/pagination/format) - Add missing User->company() belongsTo relationship (UserTable eager loads it; column + migration existed but relation was undefined) - Add #[Layout] attribute to CompanyManagement/ProjectList/PhaseProgress full-page Livewire components - Fix config/session.php: use env() instead of app()->environment() which fails during LoadConfiguration (env binding not yet registered) - Remove duplicate activeTab property in ProjectMap (fatal PHP error) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -3,12 +3,14 @@
|
||||
namespace App\Livewire;
|
||||
|
||||
use Livewire\Component;
|
||||
use Livewire\Attributes\Layout;
|
||||
use Livewire\WithFileUploads;
|
||||
use App\Models\Company;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
use Illuminate\Support\Facades\Storage;
|
||||
use Illuminate\Http\Response;
|
||||
|
||||
#[Layout('layouts.app')]
|
||||
class CompanyManagement extends Component
|
||||
{
|
||||
use WithFileUploads;
|
||||
@@ -236,6 +238,8 @@ class CompanyManagement extends Component
|
||||
|
||||
public function render()
|
||||
{
|
||||
return view('livewire.company-management');
|
||||
return view('livewire.company-management', [
|
||||
'companies' => $this->getCompaniesProperty(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
@@ -3,9 +3,11 @@
|
||||
namespace App\Livewire;
|
||||
|
||||
use Livewire\Component;
|
||||
use Livewire\Attributes\Layout;
|
||||
use App\Models\Phase;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
#[Layout('layouts.app')]
|
||||
class PhaseProgress extends Component
|
||||
{
|
||||
public Phase $phase;
|
||||
|
||||
@@ -3,10 +3,12 @@
|
||||
namespace App\Livewire;
|
||||
|
||||
use Livewire\Component;
|
||||
use Livewire\Attributes\Layout;
|
||||
use Livewire\WithPagination;
|
||||
use App\Models\Project;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
#[Layout('layouts.app')]
|
||||
class ProjectList extends Component
|
||||
{
|
||||
use WithPagination;
|
||||
|
||||
@@ -42,9 +42,6 @@ class ProjectMap extends Component
|
||||
public $showFeatureImages = false;
|
||||
public $featureImageMarkers = [];
|
||||
|
||||
// Tab management
|
||||
public $activeTab = 'edit'; // edit or list
|
||||
|
||||
public function mount(Project $project)
|
||||
{
|
||||
$user = Auth::user();
|
||||
|
||||
Reference in New Issue
Block a user