You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
1.7 KiB
43 lines
1.7 KiB
{{< core_form/element-template }}
|
|
{{$element}}
|
|
{{^element.frozen}}
|
|
{{#element.multiple}}
|
|
<input type="hidden" name="{{element.nameraw}}" value="_qf__force_multiselect_submission">
|
|
{{/element.multiple}}
|
|
<select class="custom-select {{#error}}is-invalid{{/error}}" name="{{element.name}}"
|
|
id="{{element.id}}"
|
|
{{#element.multiple}}multiple{{/element.multiple}}
|
|
{{#error}}
|
|
autofocus aria-describedby="{{element.iderror}}"
|
|
{{/error}}
|
|
{{{element.attributes}}} >
|
|
{{#element.options}}
|
|
<option value="{{value}}" {{#selected}}selected{{/selected}}{{#html}} data-html="{{html}}"{{/html}}>{{{text}}}</option>
|
|
{{/element.options}}
|
|
</select>
|
|
{{/element.frozen}}
|
|
{{#element.frozen}}
|
|
{{#element.options}}
|
|
{{#selected}}
|
|
{{{text}}}
|
|
{{^element.hardfrozen}}
|
|
<input type="hidden" name="{{element.name}}" value="{{value}}">
|
|
{{/element.hardfrozen}}
|
|
{{/selected}}
|
|
{{/element.options}}
|
|
{{/element.frozen}}
|
|
{{/element}}
|
|
{{/ core_form/element-template }}
|
|
{{^element.frozen}}
|
|
{{#js}}
|
|
require(['core/form-autocomplete'], function(module) {
|
|
module.enhance({{#quote}}#{{element.id}}{{/quote}},
|
|
{{element.tags}},
|
|
{{#quote}}{{element.ajax}}{{/quote}},
|
|
{{#quote}}{{element.placeholder}}{{/quote}},
|
|
{{element.casesensitive}},
|
|
{{element.showsuggestions}},
|
|
{{#quote}}{{element.noselectionstring}}{{/quote}});
|
|
});
|
|
{{/js}}
|
|
{{/element.frozen}}
|
|
|