diff --git a/app/Livewire/ProjectEditTabs.php b/app/Livewire/ProjectEditTabs.php new file mode 100644 index 0000000..081839f --- /dev/null +++ b/app/Livewire/ProjectEditTabs.php @@ -0,0 +1,42 @@ +project = $project; + } + + public function setActiveTab($tab) + { + $this->activeTab = $tab; + } + + public function tabChanged($tab, $projectId) + { + if ($projectId == $this->project->id) { + $this->activeTab = $tab; + } + } + + public function updateProject() + { + $this->project->save(); + + session()->flash('message', __('Project updated successfully.')); + $this->dispatch('project-updated'); + } + + public function render() + { + return view('livewire.project-edit-tabs'); + } +} \ No newline at end of file diff --git a/resources/views/livewire/project-edit-tabs.blade.php b/resources/views/livewire/project-edit-tabs.blade.php new file mode 100644 index 0000000..c8d5926 --- /dev/null +++ b/resources/views/livewire/project-edit-tabs.blade.php @@ -0,0 +1,120 @@ +
+ +
+ + + + + + + + +
+ + +
+ +
+
+ @csrf + @method('PUT') +
+ + +
+
+ + +
+
+
+ + +
+
+ + +
+
+
+ + +
+
+
+ + +
+
+ + +
+
+ +
+
+ + +
+

{{ __('Phases') }}

+ +
+ + +
+

{{ __('Users') }}

+ +
+
+
+ +{{-- Alpine.js for tab switching --}} + \ No newline at end of file diff --git a/resources/views/projects/edit.blade.php b/resources/views/projects/edit.blade.php index f4991eb..72adaaa 100644 --- a/resources/views/projects/edit.blade.php +++ b/resources/views/projects/edit.blade.php @@ -2,82 +2,6 @@

{{ __('Edit Project') }}: {{ $project->name }}

-
-
- - - - - - -
-
-
-
- @csrf - @method('PUT') -
- - -
-
- - -
-
-
- - -
-
- - -
-
-
- - -
-
-
- - -
-
- - -
-
- -
-
-
-

{{ __('Phases') }}

- -
-
-

{{ __('Users') }}

- -
-
-
- - +
\ No newline at end of file