Master data management Β· features 286-305
πŸ›’οΈ SQL Server Β· MasterDataLabDB
🏷️

287Tags

Free labels with a color. The URL slug is created from the name.

Try it

Tag preview

How active tags look on a product page. The small text is the slug used in URLs.
Best Seller/best-seller Clearance/clearance Eco Friendly/eco-friendly Imported/imported Limited Edition/limited-edition Made in Thailand/made-in-thailand New Arrival/new-arrival Promotion/promotion

Add a tag and leave the slug empty: TagService.slugify("Made in Thailand!") β†’ made-in-thailand.

# Name Slug Color Status
2 Best Seller best-seller #f59e0b Active ✏️
8 Clearance clearance #64748b Active ✏️
4 Eco Friendly eco-friendly #16a34a Active ✏️
6 Imported imported #0891b2 Active ✏️
5 Limited Edition limited-edition #9333ea Active ✏️
7 Made in Thailand made-in-thailand #db2777 Active ✏️
1 New Arrival new-arrival #2563eb Active ✏️
3 Promotion promotion #dc2626 Active ✏️
Showing 1–8 of 8
πŸŽ“ Learn: how this master is built table tag
  • beforeSave hook: TagService.slugify("Made in Thailand") β†’ made-in-thailand.
  • Two UNIQUE constraints (uq_tag_name, uq_tag_slug): the database is the final guard against duplicates.
Entity
domain/Tag.java
Repository
repo/TagRepository.java
Definition
MasterRegistry: "tags"
Page / form
web/MasterController.java
Try-it panel
templates/tools/tag-cloud.html
REST API
GET /api/masters/tags
SELECT name, slug, color FROM tag WHERE active = 1 ORDER BY name;