Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
lutece
lutece-form-plugin-forms
Commits
ddae4a55
Commit
ddae4a55
authored
Dec 10, 2021
by
Guillaume Lépine
Browse files
FORMS-314: Modify templates for placeholder
parent
e1e6ede1
Changes
23
Hide whitespace changes
Inline
Side-by-side
src/java/fr/paris/lutece/plugins/forms/resources/forms_messages.properties
View file @
ddae4a55
...
...
@@ -563,6 +563,7 @@ createEntry.labelHeight=Height of the text area
createEntry.labelWidth
=
Width of the text area
createEntry.labelUseRefList
=
Use global reference list
createEntry.labelUseRefListSelect
=
Reference list to use
createEntry.labelPlaceholder
=
Placeholder
createEntry.mapProvider
=
Map
createEntry.editMode
=
Edition mode
createEntry.viewNumber
=
View number
...
...
src/java/fr/paris/lutece/plugins/forms/resources/forms_messages_fr.properties
View file @
ddae4a55
...
...
@@ -561,6 +561,7 @@ createEntry.labelHeight=Hauteur de la zone de texte
createEntry.labelWidth
=
Largeur de la zone de texte
createEntry.labelUseRefList
=
Utiliser une liste de r
\u
00e9f
\u
00e9rence globale
createEntry.labelUseRefListSelect
=
Liste de r
\u
00e9f
\u
00e9rence
\u
00e0 utiliser
createEntry.labelPlaceholder
=
Placeholder
createEntry.mapProvider
=
Carte
createEntry.editMode
=
Mode d'
\u
00e9dition
createEntry.viewNumber
=
Num
\u
00e9ro de la vue
...
...
src/sql/plugins/genericattributes/upgrade/update_db_genericattributes-2.3.2-2.4.1.sql
View file @
ddae4a55
...
...
@@ -4,3 +4,12 @@ INSERT INTO genatt_field (id_entry, code, VALUE, title)
INNER
JOIN
genatt_entry_type
t
ON
t
.
id_type
=
e
.
id_type
WHERE
resource_type
=
'FORMS_FORM'
AND
t
.
class_name
=
'forms.entryTypeNumber'
;
INSERT
INTO
genatt_field
(
id_entry
,
code
,
VALUE
,
title
)
SELECT
e
.
id_entry
,
'placeholder'
,
''
,
null
from
genatt_entry
e
INNER
JOIN
genatt_entry_type
t
ON
t
.
id_type
=
e
.
id_type
WHERE
resource_type
=
'FORMS_FORM'
AND
t
.
class_name
IN
(
'forms.entryTypeDate'
,
'forms.entryTypeNumber'
,
'forms.entryTypeTelephoneNumber'
,
'forms.entryTypeTextArea'
,
'forms.entryTypeText'
);
\ No newline at end of file
webapp/WEB-INF/templates/admin/plugins/forms/entries/create_entry_type_date.html
View file @
ddae4a55
...
...
@@ -29,6 +29,9 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
></
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
''
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'date'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
inputGroup
>
<
@
inputGroupItem
type=
'text'
>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/create_entry_type_number.html
View file @
ddae4a55
...
...
@@ -34,6 +34,9 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
></
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
''
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'number'
name=
'value'
id=
'value'
/>
</
@
formGroup>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/create_entry_type_telephone.html
View file @
ddae4a55
...
...
@@ -30,6 +30,9 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
></
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
''
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'autocomplete'
labelKey=
'#i18n{forms.createEntry.labelAutocomplete}'
helpKey=
'#i18n{forms.createEntry.labelHelpMessageAutocomplete}'
>
<
@
input
type=
'text'
name=
'autocomplete'
id=
'autocomplete'
params=
' list="autocompleteList"'
/>
<datalist
id=
"autocompleteList"
><option
value=
"tel"
><option
value=
"tel-national"
></datalist>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/create_entry_type_text.html
View file @
ddae4a55
...
...
@@ -30,6 +30,9 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
></
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
''
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'text'
name=
'value'
id=
'value'
/>
</
@
formGroup>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/create_entry_type_text_area.html
View file @
ddae4a55
...
...
@@ -33,6 +33,9 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
></
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
''
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'textarea'
name=
'value'
id=
'value'
></
@
input>
</
@
formGroup>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/fill_entry_type_date.html
View file @
ddae4a55
...
...
@@ -22,7 +22,8 @@
<
#elseif
field.valueTypeDate
??
>
<
#assign
default=
field.valueTypeDate?iso_local
>
</
#
if>
<
@
input
type=
'date'
language=
locale.language
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
(response.toStringValueResponse)!(default)!
/>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
input
type=
'date'
language=
locale.language
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
(response.toStringValueResponse)!(default)!
placeHolder=
placeholder
/>
<
@
inputGroupItem
type=
'text'
>
<
@
icon
style=
'calendar'
/>
</
@
inputGroupItem>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/fill_entry_type_number.html
View file @
ddae4a55
...
...
@@ -35,7 +35,8 @@
</
#
if>
<
@
formGroup
labelFor=
'${idName}'
labelKey=
'${entry.title}'
helpKey=
entry.helpMessage!''
groupStyle=
groupStyle!''
mandatory=
entry.mandatory
>
<
@
inputGroup
>
<
@
input
type=
'number'
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
inputValue
min=
min
max=
max/
>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
input
type=
'number'
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
inputValue
min=
min
max=
max
placeHolder=
placeholder/
>
<
#if
suffix
!=''
>
<
@
inputGroupItem
type=
'text'
>
${suffix}
</
@
inputGroupItem>
</
#
if>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/fill_entry_type_telephone.html
View file @
ddae4a55
...
...
@@ -20,7 +20,8 @@
</
#
if>
<
@
formGroup
labelFor=
'${idName}'
labelKey=
'${entry.title}'
helpKey=
helpKey
groupStyle=
groupStyle
mandatory=
entry.mandatory
>
<
@
input
type=
'tel'
language=
locale.language
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
(response.toStringValueResponse)!
params=
autocomplete
/>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
input
type=
'tel'
language=
locale.language
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
(response.toStringValueResponse)!
params=
autocomplete
placeHolder=
placeholder
/>
</
@
formGroup>
<
#if
list_responses
??
>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/fill_entry_type_text.html
View file @
ddae4a55
...
...
@@ -27,7 +27,8 @@
</
#
if>
<
@
formGroup
labelFor=
'${idName}'
labelKey=
'${entry.title}'
helpKey=
entry.helpMessage!''
groupStyle=
groupStyle!''
mandatory=
entry.mandatory
>
<
@
input
type=
'text'
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
inputValue
/>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
input
type=
'text'
name=
'${idName}'
id=
'${idName}'
class=
'${entry.CSSClass!}'
value=
inputValue
placeHolder=
placeholder/
>
</
@
formGroup>
<
#if
list_responses
??
>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/fill_entry_type_text_area.html
View file @
ddae4a55
<
#assign
field =
getFieldByCode(entry,
"
text_config
")
/>
<
#assign
field_width=
getFieldValueByCode(
entry
,
"
width
")
/>
<
#assign
field_height=
getFieldValueByCode(
entry
,
"
height
")
/>
<
#assign
idName =
buildEntryName(
entry
,
entry_iteration_number
)
/>
...
...
@@ -18,6 +17,7 @@
</
#
if>
</
#
list>
<
#else
>
<
#assign
field =
getFieldByCode(entry,
"
text_config
")
/>
<
#if
field.value
?
exists
>
<
#assign
responseContent=
field.value
/>
<
#else
>
...
...
@@ -27,7 +27,8 @@
<
#assign
idName =
buildEntryName(
entry
,
entry_iteration_number
)
/>
<
@
formGroup
labelFor=
'${idName}'
labelKey=
'${entry.title}'
helpKey=
entry.helpMessage!''
groupStyle=
groupStyle!''
mandatory=
entry.mandatory
>
<
@
input
type=
'textarea'
name=
'${idName}'
id=
'${idName}'
cols=
field_width?number
rows=
field_height?number
class=
'${entry.CSSClass!}'
richtext=
richtext
>
${responseContent}
</
@
input>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
input
type=
'textarea'
name=
'${idName}'
id=
'${idName}'
cols=
field_width?number
rows=
field_height?number
class=
'${entry.CSSClass!}'
richtext=
richtext
placeHolder=
placeholder
>
${responseContent}
</
@
input>
</
@
formGroup>
<
#if
list_responses
??
>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/modify_entry_type_date.html
View file @
ddae4a55
...
...
@@ -28,6 +28,10 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
5
>
${entry.comment}
</
@
input>
</
@
formGroup>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
placeholder
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'date'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
#assign
field =
getFieldByCode(
entry
,
"
default_date_value
"
)
>
<
@
inputGroup
>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/modify_entry_type_number.html
View file @
ddae4a55
...
...
@@ -36,6 +36,10 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
>
${entry.comment}
</
@
input>
</
@
formGroup>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
placeholder
maxlength=
100
/>
</
@
formGroup>
<
#assign
config=
getFieldByCode(
entry
,
"
text_config
")
>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'number'
name=
'value'
id=
'value'
value=
'${config.value!}'
/>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/modify_entry_type_telephone.html
View file @
ddae4a55
...
...
@@ -31,6 +31,10 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
>
${entry.comment}
</
@
input>
</
@
formGroup>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
placeholder
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'autocomplete'
labelKey=
'#i18n{forms.createEntry.labelAutocomplete}'
helpKey=
'#i18n{forms.createEntry.labelHelpMessageAutocomplete}'
>
<
#assign
field =
getFieldByCode(
entry
,
"
autocomplete
"
)
>
<
@
input
type=
'text'
name=
'autocomplete'
id=
'autocomplete'
value=
"${field.value?if_exists}"
params=
' list="autocompleteList"'
/>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/modify_entry_type_text.html
View file @
ddae4a55
...
...
@@ -17,21 +17,24 @@ ${breadcrumb_template}
<
@
input
type=
'hidden'
name=
'id_question'
value=
'${question.id}'
/>
<
@
input
type=
'hidden'
name=
'width'
id=
'width'
value=
'0'
/>
<
@
formGroup
labelKey=
'#i18n{forms.createEntry.labelType}'
>
<
@
staticText
><
@
tag
color=
'info'
>
${entry.entryType.title}
</
@
tag></
@
staticText>
</
@
formGroup>
<
@
formGroup
labelFor=
'title'
labelKey=
'#i18n{forms.createEntry.labelTitle}'
helpKey=
'#i18n{forms.createEntry.labelTitleComment}'
mandatory=
true
>
<
@
input
type=
'text'
name=
'title'
id=
'title'
value=
'${entry.title}'
maxlength=
255
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'entry_code'
labelKey=
'#i18n{forms.createEntry.labelCode}'
helpKey=
'#i18n{forms.createEntry.labelCodeComment}'
>
<
@
input
type=
'text'
name=
'entry_code'
id=
'entry_code'
value=
'${entry.code}'
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'entry_code'
labelKey=
'#i18n{forms.createEntry.labelCode}'
helpKey=
'#i18n{forms.createEntry.labelCodeComment}'
>
<
@
input
type=
'text'
name=
'entry_code'
id=
'entry_code'
value=
'${entry.code}'
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'help_message'
labelKey=
'#i18n{forms.createEntry.labelHelpMessage}'
>
<
@
input
type=
'textarea'
name=
'help_message'
id=
'help_message'
rows=
2
>
${entry.helpMessage}
</
@
input>
</
@
formGroup>
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
>
${entry.comment}
</
@
input>
</
@
formGroup>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
placeholder
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'text'
name=
'value'
id=
'value'
value=
'${config.value}'
/>
</
@
formGroup>
...
...
webapp/WEB-INF/templates/admin/plugins/forms/entries/modify_entry_type_text_area.html
View file @
ddae4a55
...
...
@@ -29,6 +29,10 @@ ${breadcrumb_template}
<
@
formGroup
labelFor=
'comment'
labelKey=
'#i18n{forms.createEntry.labelComment}'
>
<
@
input
type=
'textarea'
name=
'comment'
id=
'comment'
rows=
2
>
${entry.comment}
</
@
input>
</
@
formGroup>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
@
formGroup
labelFor=
'placeholder'
labelKey=
'#i18n{forms.createEntry.labelPlaceholder}'
>
<
@
input
type=
'text'
name=
'placeholder'
id=
'placeholder'
value=
placeholder
maxlength=
100
/>
</
@
formGroup>
<
@
formGroup
labelFor=
'value'
labelKey=
'#i18n{forms.createEntry.labelValueDefault}'
>
<
@
input
type=
'textarea'
name=
'value'
id=
'value'
rows=
10
>
${config.value}
</
@
input>
</
@
formGroup>
...
...
webapp/WEB-INF/templates/skin/plugins/forms/entries/fill_entry_type_date.html
View file @
ddae4a55
...
...
@@ -15,7 +15,8 @@
<div
class=
"input-group"
>
<span
class=
"input-group-addon"
><i
class=
"fa fa-calendar fa-lg"
></i></span>
<
#assign
field =
getFieldByCode(
entry
,
"
default_date_value
"
)
>
<input
type=
"text"
name=
"${idName}"
id=
"${idName}"
class=
"form-control input-sm ${entry.CSSClass!} <#if error??>error</#if>"
value=
"${(response.toStringValueResponse)!(field.valueTypeDate)!}"
/>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<input
type=
"text"
name=
"${idName}"
id=
"${idName}"
class=
"form-control input-sm ${entry.CSSClass!} <#if error??>error</#if>"
value=
"${(response.toStringValueResponse)!(field.valueTypeDate)!}"
<
#if
placeholder
!=''
>
placeholder='${placeholder}'
</
#
if>
/>
<
#if
entry.helpMessage
?
exists
&&
entry.helpMessage
!=''
>
<span
class=
"help-block"
>
${entry.helpMessage}
</span>
</
#
if>
...
...
webapp/WEB-INF/templates/skin/plugins/forms/entries/fill_entry_type_number.html
View file @
ddae4a55
...
...
@@ -36,6 +36,10 @@
<
#if
field_max.value
??
>
max="${field_max.value?number}"
</
#
if>
<
#assign
placeholder =
getFieldValueByCode(entry,
"
placeholder
")
>
<
#if
placeholder
!=''
>
placeholder='${placeholder}'
</
#
if>
class="${entry.CSSClass!} " />
<
#if
suffix
!=''
>
<span
class=
"input-group-addon"
>
${suffix}
</span>
...
...
Prev
1
2
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment