filament/spatie-laravel-tags-plugin 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

filament/spatie-laravel-tags-plugin

最新稳定版本:v5.0.0-beta8

Composer 安装命令:

composer require filament/spatie-laravel-tags-plugin

包简介

Filament support for `spatie/laravel-tags`.

README 文档

README

Installation

Install the plugin with Composer:

composer require filament/spatie-laravel-tags-plugin:"^4.0" -W

If you haven't already done so, you need to publish the migration to create the tags table:

php artisan vendor:publish --provider="Spatie\Tags\TagsServiceProvider" --tag="tags-migrations"

Run the migrations:

php artisan migrate

You must also prepare your Eloquent model for attaching tags.

For more information, check out Spatie's documentation.

Form component

This guide assumes that you've already set up your model to attach tags as per Spatie's documentation.

You may use the field in the same way as the original tags input field:

use Filament\Forms\Components\SpatieTagsInput;

SpatieTagsInput::make('tags')

Optionally, you may pass a type() that allows you to group tags into collections:

use Filament\Forms\Components\SpatieTagsInput;

SpatieTagsInput::make('tags')
    ->type('categories')

The tags input supports all the customization options of the original tags input component.

Table column

This guide assumes that you've already set up your model attach tags as per Spatie's documentation.

To use the tags column:

use Filament\Tables\Columns\SpatieTagsColumn;

SpatieTagsColumn::make('tags')

Optionally, you may pass a type():

use Filament\Tables\Columns\SpatieTagsColumn;

SpatieTagsColumn::make('tags')
    ->type('categories')

The type allows you to group tags into collections.

The tags column supports all the customization options of the original tags column.

Infolist entry

This guide assumes that you've already set up your model attach tags as per Spatie's documentation.

To use the tags entry:

use Filament\Infolists\Components\SpatieTagsEntry;

SpatieTagsEntry::make('tags')

Optionally, you may pass a type():

use Filament\Infolists\Components\SpatieTagsEntry;

SpatieTagsEntry::make('tags')
    ->type('categories')

The type allows you to group tags into collections.

The tags entry supports all the customization options of the text entry.

统计信息

  • 总下载量: 1.25M
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 34
  • 点击次数: 0
  • 依赖项目数: 34
  • 推荐数: 0

GitHub 信息

  • Stars: 33
  • Watchers: 2
  • Forks: 11
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固