Add mobile phone nami type
This commit is contained in:
parent
cb3cc087d6
commit
fa2d93174a
|
@ -20,6 +20,7 @@ enum NamiType: string
|
||||||
case ZIP = 'PLZ';
|
case ZIP = 'PLZ';
|
||||||
case LOCATION = 'Ort';
|
case LOCATION = 'Ort';
|
||||||
case GENDER = 'Geschlecht';
|
case GENDER = 'Geschlecht';
|
||||||
|
case MOBILEPHONE = 'Handynummer';
|
||||||
case AGE = 'Alter (zum Zeitpunkt der Anmeldung)';
|
case AGE = 'Alter (zum Zeitpunkt der Anmeldung)';
|
||||||
case AGEEVENT = 'Alter (zum Zeitpunkt der Veranstaltung)';
|
case AGEEVENT = 'Alter (zum Zeitpunkt der Veranstaltung)';
|
||||||
|
|
||||||
|
@ -49,6 +50,7 @@ enum NamiType: string
|
||||||
static::GENDER => $member->gender?->name,
|
static::GENDER => $member->gender?->name,
|
||||||
static::AGE => $member->birthday->diffInYears(now()),
|
static::AGE => $member->birthday->diffInYears(now()),
|
||||||
static::AGEEVENT => $member->birthday->diffInYears($form->from),
|
static::AGEEVENT => $member->birthday->diffInYears($form->from),
|
||||||
|
static::MOBILEPHONE => $member->mobile_phone,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -512,6 +512,12 @@ class FormRegisterActionTest extends FormTestCase
|
||||||
NamiType::AGEEVENT,
|
NamiType::AGEEVENT,
|
||||||
'32'
|
'32'
|
||||||
];
|
];
|
||||||
|
|
||||||
|
yield [
|
||||||
|
['mobile_phone' => '+49 7776666'],
|
||||||
|
NamiType::MOBILEPHONE,
|
||||||
|
'+49 7776666'
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue