user crud

This commit is contained in:
2024-07-25 13:23:50 +03:00
parent 4d922096a9
commit 653bf674c9
9 changed files with 255 additions and 49 deletions

View File

@ -0,0 +1,24 @@
<?php
namespace kernel\IGTabel\btn;
class DangerBtn
{
protected string $btn = '';
public function __construct(string $title, string $url)
{
$this->btn = "<a class='btn btn-danger' href='$url' style='margin: 3px; width: 150px;' >$title</a>";
}
public function fetch(): string
{
return $this->btn;
}
public static function create(string $title, string $url): DangerBtn
{
return new self($title, $url);
}
}

View File

@ -0,0 +1,24 @@
<?php
namespace kernel\IGTabel\btn;
class SuccessBtn
{
protected string $btn = '';
public function __construct(string $title, string $url)
{
$this->btn = "<a class='btn btn-success' href='$url' style='margin: 3px; width: 150px;' >$title</a>";
}
public function fetch(): string
{
return $this->btn;
}
public static function create(string $title, string $url): SuccessBtn
{
return new self($title, $url);
}
}