26 lines
597 B
PHP
26 lines
597 B
PHP
<?php
|
|
|
|
namespace kernel\widgets\IconBtn;
|
|
|
|
use kernel\Widget;
|
|
use kernel\widgets\ActionButtonWidget;
|
|
|
|
class IconBtnDeactivateWidget extends Widget
|
|
{
|
|
public static function create(array $data = []): IconBtnDeactivateWidget
|
|
{
|
|
return new static($data);
|
|
}
|
|
|
|
public function run()
|
|
{
|
|
$url = $this->data['url'];
|
|
|
|
return ActionButtonWidget::create([
|
|
'label' => "<i class='fa-regular fa-circle-xmark'></i>",
|
|
'url' => $url,
|
|
'btn_type' => "warning",
|
|
'title' => "Деактивировать"
|
|
])->run();
|
|
}
|
|
} |