plugin = $plugin; } public function init() { $this->register(); $this->loadConfig(); $this->boot(); } public function register() { } public function boot() { } protected function setConfig() { } protected function setMenuConfig() { } public function getWidgetItems() { return []; } /** * 前端插件挂件配置 * @return array */ public function getFrontendWidgetConfig() :array { return []; } public function loadMenuConfig() { return $this->setMenuConfig(); } public function getIncomePageItems() { return []; } public function getIncomeItems() { return []; } public function getTemplateItems() { return []; } public function getNoticeTemplateItems() { return []; } public function getShopConfigItems() { return []; } public function getPluginConfigItems() { return []; } protected function loadConfig() { $this->setConfig(); } }