feat: split name into first_name + last_name across users, persons, and companies

Cross-cutting migration affecting the entire stack:
- Database: 3 migrations splitting name columns with data migration
- Models: first_name/last_name on User, Person; contact_first_name/contact_last_name on Company; backward-compatible name accessors
- API: all resources return first_name, last_name, full_name; assignablePersons endpoint updated
- Requests: validation rules updated for all person/user/company forms
- Services: VolunteerRegistrationService, ShiftAssignmentService, InvitationService updated
- Frontend: TypeScript types, Zod schemas, all forms split into Voornaam/Achternaam fields
- Display: all person/user name references use full_name; initials use first_name[0]+last_name[0]
- Tests: all 371 tests passing
- Docs: SCHEMA.md and API.md updated

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-10 23:04:55 +02:00
parent bd4297f891
commit d2f282eb4c
66 changed files with 654 additions and 220 deletions

View File

@@ -68,7 +68,7 @@ const filteredPersons = computed(() => {
if (searchQuery.value) {
const q = searchQuery.value.toLowerCase()
result = result.filter(
(p: Person) => p.name.toLowerCase().includes(q) || p.email.toLowerCase().includes(q),
(p: Person) => p.full_name.toLowerCase().includes(q) || p.email.toLowerCase().includes(q),
)
}
@@ -181,7 +181,7 @@ function getInitials(name: string) {
function onApprove(person: Person) {
approvePerson(person.id, {
onSuccess: () => {
successMessage.value = `${person.name} goedgekeurd`
successMessage.value = `${person.full_name} goedgekeurd`
showSuccess.value = true
refetchPersons()
},
@@ -195,7 +195,7 @@ function onRemoveConfirm(person: Person) {
function onRemoveExecute() {
if (!removingPerson.value || !props.crowdList) return
const name = removingPerson.value.name
const name = removingPerson.value.full_name
removePerson(
{ listId: props.crowdList.id, personId: removingPerson.value.id },
@@ -613,11 +613,11 @@ function onApproveAllExecute() {
color="primary"
variant="tonal"
>
<span class="text-caption">{{ getInitials(person.name) }}</span>
<span class="text-caption">{{ getInitials(person.full_name) }}</span>
</VAvatar>
<div style="min-width: 0;">
<p class="text-body-1 font-weight-medium mb-0 text-truncate">
{{ person.name }}
{{ person.full_name }}
</p>
<p class="text-body-2 text-medium-emphasis mb-1 text-truncate">
{{ person.email }}
@@ -715,7 +715,7 @@ function onApproveAllExecute() {
>
<VCard title="Persoon verwijderen van lijst">
<VCardText>
Weet je zeker dat je <strong>{{ removingPerson?.name }}</strong> van de lijst
Weet je zeker dat je <strong>{{ removingPerson?.full_name }}</strong> van de lijst
<strong>{{ crowdList?.name }}</strong> wilt verwijderen?
<br><br>
<span class="text-medium-emphasis">