WIP more delete confirmations
This commit is contained in:
@@ -13,9 +13,12 @@ class DeleteEnvironment extends Component
|
|||||||
|
|
||||||
public bool $disabled = false;
|
public bool $disabled = false;
|
||||||
|
|
||||||
|
public string $environmentName = '';
|
||||||
|
|
||||||
public function mount()
|
public function mount()
|
||||||
{
|
{
|
||||||
$this->parameters = get_route_parameters();
|
$this->parameters = get_route_parameters();
|
||||||
|
$this->environmentName = Environment::findOrFail($this->environment_id)->name;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function delete()
|
public function delete()
|
||||||
|
|||||||
@@ -13,9 +13,12 @@ class DeleteProject extends Component
|
|||||||
|
|
||||||
public bool $disabled = false;
|
public bool $disabled = false;
|
||||||
|
|
||||||
|
public string $projectName = '';
|
||||||
|
|
||||||
public function mount()
|
public function mount()
|
||||||
{
|
{
|
||||||
$this->parameters = get_route_parameters();
|
$this->parameters = get_route_parameters();
|
||||||
|
$this->projectName = Project::findOrFail($this->project_id)->name;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function delete()
|
public function delete()
|
||||||
|
|||||||
@@ -1,3 +1,14 @@
|
|||||||
<x-modal-confirmation isErrorButton buttonTitle="Delete Environment" disabled="{{ $disabled }}">
|
<x-modal-confirmation
|
||||||
This environment will be deleted. It is not reversible. <br>Please think again.
|
title="Confirm Delete Environment?"
|
||||||
|
buttonTitle="Delete Environment"
|
||||||
|
isErrorButton
|
||||||
|
action="delete_environment"
|
||||||
|
:actions="['This will delete the selected environment.']"
|
||||||
|
confirmationLabel="Please confirm the execution of the actions by entering the Environment Name below"
|
||||||
|
shortConfirmationLabel="Environment Name"
|
||||||
|
submitAction="delete_environment"
|
||||||
|
buttonTitle="Delete Environment"
|
||||||
|
confirmText="{{ $environmentName }}"
|
||||||
|
step3ButtonText="Permanently Delete Environment"
|
||||||
|
>
|
||||||
</x-modal-confirmation>
|
</x-modal-confirmation>
|
||||||
|
|||||||
@@ -1,3 +1,13 @@
|
|||||||
<x-modal-confirmation isErrorButton buttonTitle="Delete Project" disabled="{{ $disabled }}">
|
<x-modal-confirmation
|
||||||
This project will be deleted. It is not reversible. <br>Please think again.
|
title="Confirm Project Deletion?"
|
||||||
</x-modal-confirmation>
|
buttonTitle="Delete Project"
|
||||||
|
isErrorButton
|
||||||
|
action="delete_project"
|
||||||
|
:actions="['This will delete the selected project.']"
|
||||||
|
confirmationLabel="Please confirm the execution of the actions by entering the Project Name below"
|
||||||
|
shortConfirmationLabel="Project Name"
|
||||||
|
submitAction="delete_project"
|
||||||
|
buttonTitle="Delete Project"
|
||||||
|
confirmText="{{ $projectName }}"
|
||||||
|
step3ButtonText="Permanently Delete Project"
|
||||||
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user