Commit | Line | Data |
---|---|---|
6f2bc235 | 1 | <label><input type="checkbox" id="search_{$option->optionName}" name="searchOptions[{$option->optionName}]"{if $searchOption} checked{/if}> {lang}wcf.user.option.searchTextOption{/lang}</label> |
9e11a63f | 2 | <input type="{@$inputType}" id="{$option->optionName}" name="values[{$option->optionName}]" value="{$value}"{if $inputClass} class="{@$inputClass}"{/if}{if !$searchOption} disabled{/if}{if $option->required} required{/if}> |
567b90a3 MS |
3 | |
4 | <script data-relocate="true"> | |
20c02598 MS |
5 | $(function() { |
6 | $('#search_{$option->optionName}').change(function(event) { | |
7 | if ($(event.currentTarget).prop('checked')) { | |
8 | $('#{$option->optionName}').enable(); | |
9 | ||
10 | {if $inputType === 'date'} | |
11 | $('#{$option->optionName}DatePicker').enable(); | |
12 | {/if} | |
13 | } | |
14 | else { | |
15 | $('#{$option->optionName}').disable(); | |
16 | ||
17 | {if $inputType === 'date'} | |
18 | $('#{$option->optionName}DatePicker').disable(); | |
19 | {/if} | |
20 | } | |
21 | }); | |
22 | ||
23 | {if !$searchOption} | |
24 | $('#{$option->optionName}DatePicker').disable(); | |
25 | {/if} | |
567b90a3 | 26 | }); |
567b90a3 | 27 | </script> |