[3.x] Tags: store an order for secondary tags

Aperta
#5,456 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
laravel, php
Ambito
api, backend

Direzione di ricerca

Read the tag ordering implementation for position, POST /api/tags/order, and the admin Tags page, along with the migration that assigns existing tag positions. The issue leaves two product decisions open: where manual ordering applies and how child tags count toward required tag limits. Once those decisions are made, verify secondary tags can be reordered and existing order matches the admin's current name order.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

needs-discussion type/feature

Secondary tags have no order: the admin lists them by name, and the forum's Tags page and sidebar by number of discussions. This was a deliberate choice in #1549 (so the sidebar can show the three most-used secondary tags). The fix proposed for #5236 disables dragging within the secondary list instead of accepting an order and discarding it.

For 3.0, once extensions identify a tag's kind through isPrimary() / isSecondary() instead of position (#5455), position can mean the order within a tag's own list for every kind.

To do
  • position orders secondary tags too. Secondary tags no longer have a null position, which is a breaking change for anything still checking it.
  • POST /api/tags/order accepts the secondary list as well, and the admin Tags page lets it be reordered again.
  • A migration gives existing secondary tags positions, by name, matching what the admin shows today.
To decide
  • Where the manual order applies: the admin list, the forum Tags page cloud, and the sidebar's "most-used three". Options: always manual; manual with the sidebar keeping its most-used choice; or a setting.
  • Whether the required tag counts should treat child tags as primary, since "primary" now means the whole primary tree. If they do, the primary limits may need separate settings for children.

Related: #3640 and #4065 cover the existing child-tag counting inconsistency.

Lingua principale
PHP
Stelle
6.8k
Fork
891
Merge medio
1g 10h
PR unite (30g)
209

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di flarum/framework

Tutte le issue di flarum/framework

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.