Make the fid / primary key field read-only in feature forms
I maintainer di solito rispondono entro 2 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 52/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- cpp
- Ambito
- backend-api-design, mobile
Direzione di ricerca
Start by tracing how QGIS layer primary key fields are represented in feature forms for adding, editing, and multi-feature editing; the issue does not name files or tests. Check the existing related behavior in #4580 and the QGIS form configuration handling. Done means primary keys stay read-only with the specified values and styling across these cases, while hidden fields and relation-created child features retain their stated behavior.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Current situation
Template projects hide fid, but if the author sets the primary key widget to an editable type (e.g. Text Edit), the mobile app lets surveyors change it. This can break relations and cause sync conflicts. In multi-feature editing, fid also shows as empty instead of * Mixed Values * (#4580).
Solution
Always make the layer's primary key field(s) read-only in the form, whatever the field name or widget type. Visibility still follows the QGIS form configuration.
Acceptance criteria
- The primary key field is read-only in the feature form, regardless of the widget type set in QGIS
- Applies to any primary key field, not only fields named
fid - Applies when adding a new feature, editing an existing one and editing multiple features
- On a new feature, the field shows
Autogenerateand is not validated as user input, so no constraint error blocks saving - On an existing feature, the field shows the current value
- In multi-feature editing, the field shows
* Mixed Values *like other fields, and cannot be edited (closes #4580) - If the field is hidden in the QGIS form configuration, it stays hidden
- Read-only styling matches other non-editable fields in the app
- Child features created through relations get their primary key generated as before
Related issues
- #4580
- #1694
- #1745
- Lingua principale
- C++
- Stelle
- 394
- Fork
- 91
- Merge medio
- 2g 10h
- PR unite (30g)
- 16
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di MerginMaps/mobile
-
Sign up button opens the Sign in page instead of the Sign up page for Enterprise edition serversApertaauth bug ui/ux
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
MerginMaps/mobile#4795 ·
I maintainer di solito rispondono entro 2 giorni
-
bug ui/ux
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
MerginMaps/mobile#4786 ·
I maintainer di solito rispondono entro 2 giorni
-
bluetooth bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
MerginMaps/mobile#4741 ·
I maintainer di solito rispondono entro 2 giorni
-
bug ui/ux
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
MerginMaps/mobile#4669 ·
I maintainer di solito rispondono entro 2 giorni
-
bug Good first issue ui/ux
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
MerginMaps/mobile#4665 ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di MerginMaps/mobile
Issue simili
-
Issue-Docs Needs-Triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
microsoft/winget-cli#6692 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
stratum-mining/sv2-tp#167 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
HarperFast/rocksdb-js#1118 ·
I maintainer di solito rispondono entro 1 giorno
-
bug triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
-
26.04 bug dark-mode Easy Hack impress symptom: visual
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
CollaboraOnline/online#16421 · 1 commento ·