html_code_entry_type_text_area.html
1 <#macro getTextAreaContent responseContent has_error entry field>
2 <!#-- fieldInLine means use rich text -->
3 <#if has_error>
4 <textarea name="attribute${entry.idEntry}" id="attribute${entry.idEntry}" cols="${field.width}" rows="${field.height}" class="alert alert-danger<#if entry.fieldInLine> richtext</#if> form-control">${responseContent}</textarea>
5 <#else>
6 <textarea name="attribute${entry.idEntry}" id="attribute${entry.idEntry}" cols="${field.width}" rows="${field.height}" class="${entry.CSSClass!}<#if entry.fieldInLine> richtext</#if> form-control">${responseContent}</textarea>
7 </#if>
8 </#macro>
9
10 <div class="form-group">
11 <label class="col-xs-12" for="attribute${entry.idEntry}">${entry.title}<#if entry.mandatory> *</#if></label>
12 <div class="col-xs-12 col-sm-6">
13 <#list entry.fields as field>
14 <#if list_responses??>
15 <#list list_responses as response>
16 <#if response.entry.idEntry == entry.idEntry && response.toStringValueResponse??>
17 <#if response.entry.error??>
18 <@getTextAreaContent responseContent=response.toStringValueResponse has_error=true entry=entry field=field/>
19 <#else>
20 <@getTextAreaContent responseContent=response.toStringValueResponse has_error=false entry=entry field=field/>
21 </#if>
22 </#if>
23 </#list>
24 <#else>
25 <#if field.value?exists>
26 <@getTextAreaContent responseContent=field.value has_error=false entry=entry field=field/>
27 <#else>
28 <@getTextAreaContent responseContent="" has_error=false entry=entry field=field/>
29 </#if>
30 </#if>
31 </#list>
32 <#if entry.helpMessage?exists&&entry.helpMessage!=''>
33 <span class="help-block">${entry.helpMessage}</span>
34 </#if>
35 <#if list_responses??>
36 <#list list_responses as response>
37 <#if response.entry.idEntry == entry.idEntry && response.entry.error?? && response.entry.error.isDisplayableError>
38 <div class="alert alert-danger">
39 <#assign error = response.entry.error>
40 <#if error.mandatoryError>#i18n{form.message.mandatory.entry}<#else>${error.errorMessage}</#if>
41 </div>
42 </#if>
43 </#list>
44 </#if>
45 </div>
46 </div>
47
48 <#if entry.fieldInLine>
49 <#include "/util/editor/editor.html" />
50 <@initEditor />
51 </#if>