Reapplied "Merge pull request #321 from raboof/wantsToDrive"
This commit is contained in:
parent
317c91a22f
commit
cdf14f9d3f
|
@ -29,8 +29,8 @@ function UserDriverLicense_new()
|
||||||
*/
|
*/
|
||||||
function UserDriverLicense_valid($user_driver_license)
|
function UserDriverLicense_valid($user_driver_license)
|
||||||
{
|
{
|
||||||
return $user_driver_license['has_car']
|
return
|
||||||
|| $user_driver_license['has_license_car']
|
$user_driver_license['has_license_car']
|
||||||
|| $user_driver_license['has_license_3_5t_transporter']
|
|| $user_driver_license['has_license_3_5t_transporter']
|
||||||
|| $user_driver_license['has_license_7_5t_truck']
|
|| $user_driver_license['has_license_7_5t_truck']
|
||||||
|| $user_driver_license['has_license_12_5t_truck']
|
|| $user_driver_license['has_license_12_5t_truck']
|
||||||
|
|
|
@ -182,7 +182,7 @@ function AngelType_view_members($angeltype, $members, $admin_user_angeltypes, $a
|
||||||
$member['Nick'] = User_Nick_render($member);
|
$member['Nick'] = User_Nick_render($member);
|
||||||
|
|
||||||
if ($angeltype['requires_driver_license']) {
|
if ($angeltype['requires_driver_license']) {
|
||||||
$member['wants_to_drive'] = glyph_bool($member['user_id']);
|
$member['wants_to_drive'] = glyph_bool($member['wants_to_drive']);
|
||||||
$member['has_car'] = glyph_bool($member['has_car']);
|
$member['has_car'] = glyph_bool($member['has_car']);
|
||||||
$member['has_license_car'] = glyph_bool($member['has_license_car']);
|
$member['has_license_car'] = glyph_bool($member['has_license_car']);
|
||||||
$member['has_license_3_5t_transporter'] = glyph_bool($member['has_license_3_5t_transporter']);
|
$member['has_license_3_5t_transporter'] = glyph_bool($member['has_license_3_5t_transporter']);
|
||||||
|
|
|
@ -17,12 +17,12 @@ function UserDriverLicense_edit_view($user_source, $wants_to_drive, $user_driver
|
||||||
msg(),
|
msg(),
|
||||||
form([
|
form([
|
||||||
form_info(_('Privacy'), _('Your driving license information is only visible for supporters and admins.')),
|
form_info(_('Privacy'), _('Your driving license information is only visible for supporters and admins.')),
|
||||||
form_checkbox('wants_to_drive', _('I am willing to operate cars for the PL'), $wants_to_drive),
|
form_checkbox('wants_to_drive', _('I am willing to drive a car for the event'), $wants_to_drive),
|
||||||
div('panel panel-default', [
|
div('panel panel-default', [
|
||||||
div('panel-body', [
|
div('panel-body', [
|
||||||
form_checkbox(
|
form_checkbox(
|
||||||
'has_car',
|
'has_car',
|
||||||
_('I have my own car with me and am willing to use it for the PL (You\'ll get reimbursed for fuel)'),
|
_('I have my own car with me and am willing to use it for the event (You\'ll get reimbursed for fuel)'),
|
||||||
$user_driver_license['has_car']
|
$user_driver_license['has_car']
|
||||||
),
|
),
|
||||||
heading(_('Driver license'), 3),
|
heading(_('Driver license'), 3),
|
||||||
|
|
Loading…
Reference in New Issue