Add configurable daypart preferences and order neutral choice last
This commit is contained in:
1 parent
e1df255b0b
commit
548f04a5dc
9 files changed
+68
-14
No files matched your search
+1
-1
@@ -22,7 +22,7 @@ function hgcf_workflow_card($flow,$index,$languages,$template=false) {
|
||||
<div class="hgcf-field-matrix"><?php foreach(['phone'=>'Telefoonnummer','service'=>'Dienstenkeuze','date'=>'Voorkeursdatum','time'=>'Voorkeurstijd'] as $key=>$label): ?>
|
||||
<label><span><?php echo esc_html($label); ?></span><select data-hgcf-state="<?php echo esc_attr($key); ?>" name="<?php echo esc_attr($prefix.'['.$key.']'); ?>"><?php foreach(['hidden'=>'Niet tonen','optional'=>'Optioneel','required'=>'Verplicht'] as $value=>$name): ?><option value="<?php echo esc_attr($value); ?>" <?php selected($flow[$key],$value); ?>><?php echo esc_html($name); ?></option><?php endforeach; ?></select></label>
|
||||
<?php endforeach; ?></div><label class="hgcf-checkbox"><input type="checkbox" name="<?php echo esc_attr($prefix.'[message_required]'); ?>" value="1" <?php checked($flow['message_required']); ?>> Bericht verplicht maken</label>
|
||||
<div class="hgcf-flow-times"><h3>Toegestane voorkeurtijden</h3><div class="hgcf-admin-grid"><?php hgcf_admin_input('Vanaf',$prefix.'[opening_time]',$flow['opening_time'],'time');hgcf_admin_input('Tot',$prefix.'[closing_time]',$flow['closing_time'],'time'); ?></div><p class="description">Dit begrenst een tijdvoorkeur. Het is geen agenda of beschikbaarheidscontrole.</p></div>
|
||||
<div class="hgcf-flow-times"><h3>Tijdvoorkeur</h3><label class="hgcf-admin-field"><span>Tijdkeuze</span><select name="<?php echo esc_attr($prefix.'[time_mode]'); ?>"><option value="exact" <?php selected(hgcf_time_mode($flow),'exact'); ?>>Exact tijdstip</option><option value="daypart" <?php selected(hgcf_time_mode($flow),'daypart'); ?>>Dagdeel (ochtend, middag of avond)</option></select></label><div class="hgcf-admin-grid"><?php hgcf_admin_input('Vanaf',$prefix.'[opening_time]',$flow['opening_time'],'time');hgcf_admin_input('Tot',$prefix.'[closing_time]',$flow['closing_time'],'time'); ?></div><p class="description">Deze tijden begrenzen de tijdkeuze en bepalen welke dagdelen beschikbaar zijn. Dit is geen agenda of beschikbaarheidscontrole.</p></div>
|
||||
<div class="hgcf-flow-services"><h3>Diensten / keuzemogelijkheden</h3><p>Vul iedere keuze in. De technische code wordt automatisch bewaard.</p><div class="hgcf-service-list"><?php $i=0;foreach($flow['services'] as $id=>$names)hgcf_service_row($prefix,$i++,$id,$names,$languages); ?></div><button type="button" class="button hgcf-add-service">Keuze toevoegen</button>
|
||||
<template class="hgcf-service-template"><?php hgcf_service_row($prefix,'__SERVICE__','__SERVICE_ID__',[],$languages); ?></template></div>
|
||||
<details class="hgcf-workflow-texts"><summary>Labels en toelichting aanpassen</summary><div class="hgcf-admin-grid"><?php foreach(['subject'=>'Label in e-mailonderwerp','message_label'=>'Label berichtveld','service_label'=>'Label dienstenkeuze'] as $key=>$label)foreach($languages as $lang=>$name)hgcf_admin_input($label.' · '.$name,$prefix.'['.$key.']['.$lang.']',$flow[$key][$lang]??hgcf_translated($flow[$key],$lang)); ?></div>
|
||||
|
||||
Reference in new issue
Block a user