installed

This commit is contained in:
Edward Yang 2022-07-01 14:16:59 +08:00
parent f5576daa93
commit 64422cec3f
3 changed files with 6 additions and 1 deletions

View File

@ -11,7 +11,6 @@
namespace Beike\Admin\Http\Controllers;
use Beike\Models\Customer;
use Exception;
use Beike\Plugin\Manager;
use Illuminate\Http\Request;

View File

@ -25,6 +25,7 @@ class PluginResource extends JsonResource
'icon' => $this->icon,
'author' => $this->author,
'status' => $this->getStatus(),
'installed' => $this->getInstalled(),
'edit_url' => $this->getEditUrl(),
];

View File

@ -106,6 +106,11 @@ class Plugin implements Arrayable, \ArrayAccess
return SettingRepo::getPluginStatus($this->code);
}
public function getInstalled(): bool
{
return true;
}
public function getEnabled(): bool
{
return $this->enabled;