fix: add uuid to volume names
This commit is contained in:
@@ -6,6 +6,7 @@ use Livewire\Component;
|
|||||||
|
|
||||||
class Add extends Component
|
class Add extends Component
|
||||||
{
|
{
|
||||||
|
public $uuid;
|
||||||
public $parameters;
|
public $parameters;
|
||||||
public string $name;
|
public string $name;
|
||||||
public string $mount_path;
|
public string $mount_path;
|
||||||
@@ -31,8 +32,9 @@ class Add extends Component
|
|||||||
public function submit()
|
public function submit()
|
||||||
{
|
{
|
||||||
$this->validate();
|
$this->validate();
|
||||||
|
$name = $this->uuid . '-' . $this->name;
|
||||||
$this->emitUp('submit', [
|
$this->emitUp('submit', [
|
||||||
'name' => $this->name,
|
'name' => $name,
|
||||||
'mount_path' => $this->mount_path,
|
'mount_path' => $this->mount_path,
|
||||||
'host_path' => $this->host_path,
|
'host_path' => $this->host_path,
|
||||||
]);
|
]);
|
||||||
|
@@ -8,7 +8,7 @@
|
|||||||
volume
|
volume
|
||||||
name, example: <span class='text-helper'>-pr-1</span>" />
|
name, example: <span class='text-helper'>-pr-1</span>" />
|
||||||
<x-forms.button class="btn" onclick="newStorage.showModal()">+ Add</x-forms.button>
|
<x-forms.button class="btn" onclick="newStorage.showModal()">+ Add</x-forms.button>
|
||||||
<livewire:project.shared.storages.add />
|
<livewire:project.shared.storages.add :uuid="$resource->uuid" />
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
<div>Persistent storage to preserve data between deployments.</div>
|
<div>Persistent storage to preserve data between deployments.</div>
|
||||||
|
Reference in New Issue
Block a user