jobmetric/panelio
Composer 安装命令:
composer require jobmetric/panelio
包简介
Panelio is a very useful package for creating a cool admin panel.
README 文档
README
Panelio for laravel
Panelio is a very useful package for creating a cool admin panel.
Install via composer
Run the following command to pull in the latest version:
composer require jobmetric/panelio
Publish the config
Run the following command to publish the package config file:
php artisan vendor:publish --provider="JobMetric\Panelio\PanelioServiceProvider" --tag="panelio-assets"
Documentation
Panelio is a Laravel package that allows you to create dynamic panels, each with menus, submenus, dashboard links, and profile links. You can also organize these panels into sections and manage permissions and positions.
Usage
The Panelio class allows you to define panels and their sections, menus, and links. Below are the main methods you will use:
This is an example for the Findr package, whose information we bring here as an example
Add a panel
To add a panel or a new environment, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addPanel('findr', [ 'name' => 'findr::base.panel_name', 'namespace' => 'JobMetric\Findr\Http\Controllers', 'args' => [ 'description' => 'findr::base.description', 'icon' => '<i class="ki-duotone ki-abstract-20 fs-2x"><span class="path1"></span><span class="path2"></span></i>', ], 'permission' => 'findr', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.Parameters:
name(translation key): The name of the panel.namespace(Psr 4 namespace): The namespace of the panel.args(array): The arguments of the panel.description(translation key): The description of the panel.icon(html tag i): The icon of the panel.permission(string permission key): The permission of the panel.position(int): The position of the panel.
Add a section
To add a section to a panel, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addSection('findr', 'content', [ 'name' => 'findr::base.sections.content.name', 'args' => [ 'title' => 'findr::base.sections.content.title', 'description' => 'findr::base.sections.content.description', 'icon' => '<i class="ki-duotone ki-abstract-26 fs-2x"><span class="path1"></span><span class="path2"></span></i>', ], 'permission' => 'findr.content', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.section slug(string): The slug of the section.Parameters:
name(translation key): The name of the section.args(array): The arguments of the section.title(translation key): The title of the section.description(translation key): The description of the section.icon(html tag i): The icon of the section.permission(string permission key): The permission of the section.position(int): The position of the section.
Add a group menu
To add a group menu to a section, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addMenu('findr', 'content', [ 'type' => 'group', 'name' => 'findr::base.sections.content.menus.group_name_1', 'permission' => 'findr.content.group_1', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.section slug(string): The slug of the section.Parameters:
type(string): The type of the menu.name(translation key): The name of the menu.permission(string permission key): The permission of the menu.position(int): The position of the menu.
Add a link menu
To add a link menu to a group menu, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addMenu('findr', 'content', [ 'type' => 'link', 'name' => 'findr::base.sections.content.menus.link_name_1', 'link' => route('findr.content.sample'), 'icon' => '<i class="ki-duotone ki-calendar-8 fs-2"><span class="path1"></span><span class="path2"></span><span class="path3"></span><span class="path4"></span><span class="path5"></span><span class="path6"></span></i>', 'permission' => 'findr.content.link_1', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.section slug(string): The slug of the section.Parameters:
type(string): The type of the menu.name(translation key): The name of the menu.link(route name): The link of the menu.icon(html tag i): The icon of the menu.permission(string permission key): The permission of the menu.position(int): The position of the menu.
Add a submenu link
To add a submenu link to a group menu, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addSubmenu('findr', 'content', 'findr::base.sections.content.menus.link_name_1', [ 'name' => 'findr::base.sections.content.menus.submenu_name_1', 'link' => route('findr.content.sample'), 'permission' => 'findr.content.submenu_1', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.section slug(string): The slug of the section.menu name(string): The name of the menu.Parameters:
name(translation key): The name of the submenu.link(route name): The link of the submenu.permission(string permission key): The permission of the submenu.position(int): The position of the submenu.
Add a dashboard link
To add a dashboard link to a section, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addDashboardLink('findr', [ 'name' => 'findr::base.sections.dashboard.dashboard_name_1', 'link' => route('findr.content.sample'), 'icon' => '<span class="symbol-label bg-light-success"><i class="ki-duotone ki-abstract-26 fs-2x text-success"><span class="path1"></span><span class="path2"></span></i></span>', 'permission' => 'findr.content.dashboard_1', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.Parameters:
name(translation key): The name of the dashboard link.link(route name): The link of the dashboard link.icon(html tag i): The icon of the dashboard link.permission(string permission key): The permission of the dashboard link.position(int): The position of the dashboard link.
Add a profile link
To add a profile link to a section, we add the following command in the Findr package provider service
use JobMetric\Panelio\Facades\Panelio; Panelio::addProfileLink('findr', [ 'name' => 'findr::base.sections.profile.profile_name_1', 'link' => route('findr.content.sample'), 'permission' => 'findr.content.profile_1', 'position' => 0, ]);
arguments:
panel slug(string): The slug of the panel.Parameters:
name(translation key): The name of the profile link.link(route name): The link of the profile link.permission(string permission key): The permission of the profile link.position(int): The position of the profile link.
Contributing
Thank you for considering contributing to the Panelio! The contribution guide can be found in the CONTRIBUTING.md.
License
The MIT License (MIT). Please see License File for more information.
jobmetric/panelio 适用场景与选型建议
jobmetric/panelio 是一款 基于 CSS 开发的 Composer 扩展包,目前已累计 82 次下载、GitHub Stars 达 5, 最近一次更新时间为 2024 年 11 月 20 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「admin」 「package」 「panel」 「laravel」 「jobmetric」 「panel maker」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 jobmetric/panelio 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 jobmetric/panelio 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 jobmetric/panelio 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
2lenet/EasyAdminPlusBundle
Analysis module for finding problematical shop data.
Yii2 panel widget
A Laravel Admin Package for The Control Group to make your life easier and steer your project in the right direction
Simple ASCII output of array data
统计信息
- 总下载量: 82
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 5
- 点击次数: 17
- 依赖项目数: 4
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-11-20