承接 tomatophp/filament-plugins 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

tomatophp/filament-plugins

Composer 安装命令:

composer require tomatophp/filament-plugins

包简介

Manage your modules as a plugin system with plugin generator

README 文档

README

Screenshot

Filament Plugins Manager & Generator

Latest Stable Version License Downloads

Manage your modules as a plugin system with plugin generator

Screenshots

Plugins Tables Generate Create Col Table cols

Installation

composer require tomatophp/filament-plugins

after install your package please run this command

php artisan filament-plugins:install

By default the module classes are not loaded automatically. You can autoload your modules by adding merge-plugin to the extra section:

"extra": {
    "laravel": {
        "dont-discover": []
    },
    "merge-plugin": {
        "include": [
            "Modules/*/composer.json"
        ]
    }
},

now you need to run this command to autoload your modules

composer dump-autoload

finally reigster the plugin on /app/Providers/Filament/AdminPanelProvider.php

->plugin(\TomatoPHP\FilamentPlugins\FilamentPluginsPlugin::make())

Usage

you can create a new plugin using just a command

php artisan filament-plugins:generate

or you can use the GUI to create a new plugin, after create a plugin you need to make sure that it's loaded on composer by run this command

composer dump-autoload

after create the plugin you can create a new table inside it and than run the migration generator to convert it to a migration file then you can use the GUI to generate resources, pages, widget or model, or you can easy use this commands

php artisan filament-plugins:model
php artisan filament-plugins:resource
php artisan filament-plugins:page
php artisan filament-plugins:widget

it will generate the files for you and you can use it directly, please note that you need to generate the model first than use other commands

Install Plugins using command line

you can install a plugins using the command line by using this command

php artisan filament:plugins

you can select all to install all TomatoPHP ecosystem plugins or you can select the plugin you want to install

List of all TomatoPHP Plugins

you can list all TomatoPHP plugins by using this command

php artisan filament-plugins:list

List your package on the plugins list

you can list your package on the plugins list by adding this a json file in your package root folder with name module.json with content like this:

{
    "name": "FilamentAccounts",
    "alias": "filament-accounts",
    "description": {
        "ar": "full accounts manager with API\/Notifications\/Contacts to manage your contacts and accounts",
        "en": "full accounts manager with API\/Notifications\/Contacts to manage your contacts and accounts",
        "gr": "full accounts manager with API\/Notifications\/Contacts to manage your contacts and accounts",
        "sp": "full accounts manager with API\/Notifications\/Contacts to manage your contacts and accounts"
    },
    "keywords": [],
    "priority": 0,
    "providers": [
        "TomatoPHP\\FilamentAccounts\\FilamentAccountsServiceProvider"
    ],
    "files": [],
    "title": {
        "ar": "Filament Accounts",
        "en": "Filament Accounts",
        "gr": "Filament Accounts",
        "sp": "Filament Accounts"
    },
    "color": "#007dff",
    "icon": "heroicon-c-user-circle",
    "placeholder": "placeholder.webp",
    "type": "lib",
    "version": "v1.0",
    "github" : "https://github.com/tomatophp/filament-accounts",
    "docs" : "https://github.com/tomatophp/filament-accounts"
}

make sure you allow packages scan on the filament-plugins.php config file

'scan' => true

now you can publish your package as module with the very easy way use this command

php artisan filament-plugins:publish

and input your package name from the list and it will move it to your module folder and register the provider to you, so you can custom anything you like on the package.

Use Selected Module in your panel

you can use the selected module in your panel by using this code in your PanelProvider

->plugin(\TomatoPHP\FilamentPlugins\FilamentPluginsPlugin::make()->modules([
    'CRM'
]))

so you will see only the selected modules in your panel

Get Only Current Panel Plugins

on any plugin you can create a Page/Resource/Widget for selected panel, so if you need to showup only the current panel Page/Resources/Widgets you can use this code in your PanelProvider

->plugin(\TomatoPHP\FilamentPlugins\FilamentPluginsPlugin::make()->discoverCurrentPanelOnly())

Stop Auto Discover Module Resources

you can stop auto-load module resources by using this code in your PanelProvider

->plugin(\TomatoPHP\FilamentPlugins\FilamentPluginsPlugin::make()->autoDiscoverModules(false))

Stop Using Plugins UI

you can stop using the plugins UI by using this code in your PanelProvider

->plugin(\TomatoPHP\FilamentPlugins\FilamentPluginsPlugin::make()->useUI(false))

Publish Assets

you can publish config file by use this command

php artisan vendor:publish --tag="filament-plugins-config"

you can publish views file by use this command

php artisan vendor:publish --tag="filament-plugins-views"

you can publish languages file by use this command

php artisan vendor:publish --tag="filament-plugins-lang"

you can publish migrations file by use this command

php artisan vendor:publish --tag="filament-plugins-migrations"

Other Filament Packages

Checkout our Awesome TomatoPHP

tomatophp/filament-plugins 适用场景与选型建议

tomatophp/filament-plugins 是一款 基于 Dart 开发的 Composer 扩展包,目前已累计 4.85k 次下载、GitHub Stars 达 63, 最近一次更新时间为 2024 年 04 月 14 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「generator」 「php」 「plugins」 「template」 「modules」 「hmvc」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 tomatophp/filament-plugins 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 tomatophp/filament-plugins 我们能提供哪些服务?
定制开发 / 二次开发

基于 tomatophp/filament-plugins 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 4.85k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 63
  • 点击次数: 35
  • 依赖项目数: 3
  • 推荐数: 0

GitHub 信息

  • Stars: 63
  • Watchers: 2
  • Forks: 16
  • 开发语言: Dart

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-04-14