2021-04-12 16:19:53 +02:00
|
|
|
{{#if showUndo}}
|
|
|
|
{{d-button
|
2022-03-29 21:15:09 +02:00
|
|
|
action=(action "undoChanges")
|
2021-04-12 16:19:53 +02:00
|
|
|
icon=undoIcon
|
|
|
|
label=undoKey
|
|
|
|
class="undo-changes"}}
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.label"}}</label>
|
|
|
|
</div>
|
|
|
|
<div class="setting-value">
|
|
|
|
{{input name="label" value=field.label}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.required"}}</label>
|
|
|
|
</div>
|
2022-03-12 15:08:56 +01:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
<span>{{i18n "admin.wizard.field.required_label"}}</span>
|
|
|
|
{{input type="checkbox" checked=field.required}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.description"}}</label>
|
|
|
|
</div>
|
|
|
|
<div class="setting-value">
|
|
|
|
{{textarea name="description" value=field.description}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.image"}}</label>
|
|
|
|
</div>
|
|
|
|
<div class="setting-value">
|
2021-12-21 06:15:11 +01:00
|
|
|
{{uppy-image-uploader
|
2021-04-12 16:19:53 +02:00
|
|
|
imageUrl=field.image
|
|
|
|
onUploadDone=(action "imageUploadDone")
|
|
|
|
onUploadDeleted=(action "imageUploadDeleted")
|
2022-08-02 14:54:57 +02:00
|
|
|
type="wizard-field-image"
|
2021-12-21 06:15:11 +01:00
|
|
|
class="no-repeat contain-image"
|
|
|
|
id=(concat "wizard-field-" field.id "-image-upload")}}
|
2021-04-12 16:19:53 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.type"}}</label>
|
|
|
|
</div>
|
2022-03-12 15:08:56 +01:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{combo-box
|
|
|
|
value=field.type
|
|
|
|
content=fieldTypes
|
|
|
|
onChange=(action "changeType")
|
|
|
|
options=(hash
|
|
|
|
none="admin.wizard.select_type"
|
|
|
|
)}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{{wizard-message
|
|
|
|
key=messageKey
|
|
|
|
url=messageUrl
|
|
|
|
component="field"}}
|
|
|
|
|
|
|
|
{{#if isTextType}}
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.min_length"}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{input
|
|
|
|
type="number"
|
|
|
|
name="min_length"
|
|
|
|
value=field.min_length
|
|
|
|
class="small"}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting full">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.max_length"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
|
|
|
{{input
|
|
|
|
type="number"
|
|
|
|
name="max_length"
|
|
|
|
value=field.max_length
|
|
|
|
class="small"}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.char_counter"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
|
|
|
<span>{{i18n "admin.wizard.field.char_counter_placeholder"}}</span>
|
|
|
|
{{input
|
|
|
|
type="checkbox"
|
|
|
|
checked=field.char_counter}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-07-03 12:11:49 +02:00
|
|
|
|
|
|
|
<div class="setting full">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.field_placeholder"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
2021-07-10 08:03:00 +02:00
|
|
|
{{textarea
|
|
|
|
name="field_placeholder"
|
2021-07-14 10:02:19 +02:00
|
|
|
class="medium"
|
2021-07-03 12:11:49 +02:00
|
|
|
value=field.placeholder}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-04-12 16:19:53 +02:00
|
|
|
{{/if}}
|
|
|
|
|
2021-07-12 13:35:05 +02:00
|
|
|
{{#if isComposerPreview}}
|
2021-12-14 02:11:23 +01:00
|
|
|
<div class="setting full">
|
2021-07-12 13:35:05 +02:00
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.preview_template"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
2021-12-14 02:11:23 +01:00
|
|
|
{{textarea name="preview-template" value=field.preview_template class="preview-template"}}
|
2021-07-12 13:35:05 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
{{#if isUpload}}
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.file_types"}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{input value=field.file_types class="medium"}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if showLimit}}
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.limit"}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{input type="number" value=field.limit class="small"}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if isDateTime}}
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{html-safe (i18n "admin.wizard.field.date_time_format.label")}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{input value=field.format class="medium"}}
|
|
|
|
<label>{{html-safe (i18n "admin.wizard.field.date_time_format.instructions")}}</label>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if showPrefill}}
|
|
|
|
<div class="setting full field-mapper-setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.prefill"}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{wizard-mapper
|
|
|
|
inputs=field.prefill
|
|
|
|
property="prefill"
|
|
|
|
onUpdate=(action "mappedFieldUpdated")
|
|
|
|
options=prefillOptions}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if showContent}}
|
|
|
|
<div class="setting full field-mapper-setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.content"}}</label>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-04-12 16:19:53 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{wizard-mapper
|
|
|
|
inputs=field.content
|
|
|
|
property="content"
|
|
|
|
onUpdate=(action "mappedFieldUpdated")
|
|
|
|
options=contentOptions}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
2022-02-07 06:40:52 +01:00
|
|
|
{{#if isTag}}
|
|
|
|
<div class="setting full field-mapper-setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.tag_groups"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
|
|
|
{{tag-group-chooser
|
2022-06-13 09:25:34 +02:00
|
|
|
id=(concat field.id "-tag-groups")
|
2022-02-07 06:40:52 +01:00
|
|
|
tagGroups=field.tag_groups
|
2022-06-13 09:25:34 +02:00
|
|
|
onChange=(action (mut field.tag_groups))
|
2022-02-07 06:40:52 +01:00
|
|
|
}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-10-26 10:04:50 +02:00
|
|
|
|
|
|
|
<div class="setting">
|
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.can_create_tag"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
|
|
|
{{input
|
|
|
|
type="checkbox"
|
|
|
|
checked=field.can_create_tag}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-02-07 06:40:52 +01:00
|
|
|
{{/if}}
|
|
|
|
|
2022-03-25 12:18:54 +01:00
|
|
|
{{#wizard-subscription-container}}
|
2021-09-24 11:58:42 +02:00
|
|
|
<div class="setting full field-mapper-setting">
|
2021-08-10 11:18:49 +02:00
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.condition"}}</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="setting-value">
|
|
|
|
{{wizard-mapper
|
|
|
|
inputs=field.condition
|
|
|
|
options=fieldConditionOptions}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-09-24 11:58:42 +02:00
|
|
|
<div class="setting full field-mapper-setting">
|
2021-09-01 04:19:00 +02:00
|
|
|
<div class="setting-label">
|
2022-03-25 12:18:54 +01:00
|
|
|
<label>{{i18n "admin.wizard.index"}}</label>
|
2021-09-01 04:19:00 +02:00
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-09-01 04:19:00 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{wizard-mapper
|
|
|
|
inputs=field.index
|
|
|
|
options=fieldIndexOptions}}
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-09-01 04:19:00 +02:00
|
|
|
{{#if isCategory}}
|
2022-03-25 12:18:54 +01:00
|
|
|
<div class="setting">
|
2021-09-01 04:19:00 +02:00
|
|
|
<div class="setting-label">
|
|
|
|
<label>{{i18n "admin.wizard.field.property"}}</label>
|
2021-04-20 19:58:19 +02:00
|
|
|
</div>
|
|
|
|
|
2021-09-01 04:19:00 +02:00
|
|
|
<div class="setting-value">
|
|
|
|
{{combo-box
|
|
|
|
value=field.property
|
|
|
|
content=categoryPropertyTypes
|
|
|
|
onChange=(action (mut field.property))
|
|
|
|
options=(hash
|
|
|
|
none="admin.wizard.selector.placeholder.property"
|
|
|
|
)}}
|
2021-04-12 16:19:53 +02:00
|
|
|
</div>
|
2021-09-01 04:19:00 +02:00
|
|
|
</div>
|
|
|
|
{{/if}}
|
2021-04-20 19:58:19 +02:00
|
|
|
|
2021-09-01 04:19:00 +02:00
|
|
|
{{#if validations}}
|
|
|
|
{{wizard-realtime-validations field=field validations=validations}}
|
2021-04-12 16:19:53 +02:00
|
|
|
{{/if}}
|
2022-03-25 12:18:54 +01:00
|
|
|
{{/wizard-subscription-container}}
|