2015-07-10 12:28:56 -04:00
|
|
|
{{#if editing}}
|
2015-07-27 14:22:12 -04:00
|
|
|
{{#admin-form-row label="admin.user_fields.type"}}
|
2020-02-03 08:22:14 -05:00
|
|
|
{{combo-box
|
|
|
|
content=fieldTypes
|
|
|
|
value=buffered.field_type
|
2020-10-06 17:50:05 -04:00
|
|
|
onChange=(action (mut buffered.field_type))
|
2020-02-03 08:22:14 -05:00
|
|
|
}}
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
|
|
|
{{#admin-form-row label="admin.user_fields.name"}}
|
2018-01-30 06:34:18 -05:00
|
|
|
{{input value=buffered.name class="user-field-name" maxlength="255"}}
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
|
|
|
{{#admin-form-row label="admin.user_fields.description"}}
|
2018-01-30 06:34:18 -05:00
|
|
|
{{input value=buffered.description class="user-field-desc" maxlength="255"}}
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
2015-07-28 12:29:40 -04:00
|
|
|
{{#if bufferedFieldType.hasOptions}}
|
|
|
|
{{#admin-form-row label="admin.user_fields.options"}}
|
|
|
|
{{value-list values=buffered.options inputType="array"}}
|
|
|
|
{{/admin-form-row}}
|
|
|
|
{{/if}}
|
|
|
|
|
2015-07-27 14:22:12 -04:00
|
|
|
{{#admin-form-row wrapLabel="true"}}
|
2021-04-27 01:52:45 -04:00
|
|
|
{{input type="checkbox" checked=buffered.editable}} <span>{{i18n "admin.user_fields.editable.title"}}</span>
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
|
|
|
{{#admin-form-row wrapLabel="true"}}
|
2021-04-27 01:52:45 -04:00
|
|
|
{{input type="checkbox" checked=buffered.required}} <span>{{i18n "admin.user_fields.required.title"}}</span>
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
|
|
|
{{#admin-form-row wrapLabel="true"}}
|
2021-04-27 01:52:45 -04:00
|
|
|
{{input type="checkbox" checked=buffered.show_on_profile}} <span>{{i18n "admin.user_fields.show_on_profile.title"}}</span>
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
2016-04-08 08:35:41 -04:00
|
|
|
{{#admin-form-row wrapLabel="true"}}
|
2021-04-27 01:52:45 -04:00
|
|
|
{{input type="checkbox" checked=buffered.show_on_user_card}} <span>{{i18n "admin.user_fields.show_on_user_card.title"}}</span>
|
|
|
|
{{/admin-form-row}}
|
|
|
|
|
|
|
|
{{#admin-form-row wrapLabel="true"}}
|
|
|
|
{{input type="checkbox" checked=buffered.searchable}} <span>{{i18n "admin.user_fields.searchable.title"}}</span>
|
2016-04-08 08:35:41 -04:00
|
|
|
{{/admin-form-row}}
|
|
|
|
|
2015-07-27 14:22:12 -04:00
|
|
|
{{#admin-form-row}}
|
2019-01-10 05:06:01 -05:00
|
|
|
{{d-button action=(action "save") class="btn-primary" icon="check" label="admin.user_fields.save"}}
|
|
|
|
{{d-button action=(action "cancel") class="btn-danger" icon="times" label="admin.user_fields.cancel"}}
|
2015-07-27 14:22:12 -04:00
|
|
|
{{/admin-form-row}}
|
2015-07-10 12:28:56 -04:00
|
|
|
{{else}}
|
|
|
|
<div class="row">
|
2019-02-19 03:30:38 -05:00
|
|
|
<div class="form-display">
|
2015-07-30 14:52:53 -04:00
|
|
|
<strong>{{userField.name}}</strong>
|
|
|
|
<br>
|
2020-03-11 04:23:10 -04:00
|
|
|
{{html-safe userField.description}}
|
2015-07-30 14:52:53 -04:00
|
|
|
</div>
|
2019-02-19 03:30:38 -05:00
|
|
|
<div class="form-display">{{fieldName}}</div>
|
|
|
|
<div class="form-element controls">
|
2019-01-22 06:02:02 -05:00
|
|
|
{{d-button action=(action "edit") class="btn-default" icon="pencil-alt" label="admin.user_fields.edit"}}
|
|
|
|
{{d-button action=destroyAction actionParam=userField class="btn-danger" icon="far-trash-alt" label="admin.user_fields.delete"}}
|
2019-01-10 05:06:01 -05:00
|
|
|
{{d-button action=moveUpAction actionParam=userField class="btn-default" icon="arrow-up" disabled=cantMoveUp}}
|
|
|
|
{{d-button action=moveDownAction actionParam=userField class="btn-default" icon="arrow-down" disabled=cantMoveDown}}
|
2015-07-10 12:28:56 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="row">{{flags}}</div>
|
|
|
|
{{/if}}
|
2019-02-19 03:30:38 -05:00
|
|
|
<div class="clearfix"></div>
|