<#assign errorMsg = ''> <#assign helpMsg = ''> <#if list_responses??><#list list_responses as response><#if response.entry.idEntry == entry.idEntry && response.entry.error?? && response.entry.error.isDisplayableError><#assign error = response.entry.error><#assign errorMsg><#if error.mandatoryError>${error.errorMessage}<#else>#i18n{appointment.message.mandatory.entry} <#if entry.helpMessage?? && entry.helpMessage != ''><#assign helpMsg>${entry.helpMessage} <#assign selectClass = 'form-select ${entry.CSSClass!}' /> <@cField label='${entry.title}' required=entry.mandatory for='attribute${entry.idEntry}'> <@cSelect name='attribute${entry.idEntry}' id='attribute${entry.idEntry}' class=selectClass helpMsg=helpMsg errorMsg=errorMsg> <@cOption value='' label='#i18n{appointment.xpage.form.noValue}' /> <#list entry.fields as field> <#if field.code == 'answer_choice'> <#assign isSelected = false> <#if list_responses??><#list list_responses as response><#if response.entry.idEntry == entry.idEntry && response.field??><#if response.field.idField == field.idField><#assign isSelected = true><#else><#if field.defaultValue><#assign isSelected = true> <#assign optionParams = ''> <#if field.comment?? && field.comment != ''><#assign optionParams>title="${field.comment}" <@cOption value='${field.idField}' label=field.title! selected=isSelected params=optionParams />