2015-01-06 01:51:45 +08:00
|
|
|
<form class="form-horizontal">
|
2014-04-24 01:25:02 +08:00
|
|
|
|
2015-01-06 01:51:45 +08:00
|
|
|
<div>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{#if model.automatic}}
|
|
|
|
<h3>{{model.name}}</h3>
|
2015-01-06 01:51:45 +08:00
|
|
|
{{else}}
|
2016-12-07 14:56:45 +08:00
|
|
|
<label for="name">{{i18n 'groups.name'}}</label>
|
|
|
|
{{text-field name="name" value=model.name placeholderKey="groups.name_placeholder"}}
|
2015-01-06 01:51:45 +08:00
|
|
|
{{/if}}
|
2014-04-24 01:25:02 +08:00
|
|
|
</div>
|
2015-01-06 01:51:45 +08:00
|
|
|
|
2015-08-13 22:01:29 +08:00
|
|
|
{{#if model.id}}
|
2015-11-09 21:52:04 +08:00
|
|
|
{{#unless model.automatic}}
|
2016-12-13 16:16:26 +08:00
|
|
|
<div>
|
|
|
|
<label for='full_name'>{{i18n 'groups.edit.full_name'}}</label>
|
|
|
|
{{input type='text' name='full_name' value=model.full_name class='group-edit-full-name'}}
|
|
|
|
</div>
|
|
|
|
|
2016-12-05 16:18:24 +08:00
|
|
|
<div>
|
2016-12-07 14:56:45 +08:00
|
|
|
<label for="bio">{{i18n 'groups.bio'}}</label>
|
2016-12-05 16:18:24 +08:00
|
|
|
{{d-editor value=model.bio_raw}}
|
|
|
|
</div>
|
|
|
|
|
2015-11-09 21:52:04 +08:00
|
|
|
{{#if model.hasOwners}}
|
|
|
|
<div>
|
|
|
|
<label for='owner-list'>{{i18n 'admin.groups.group_owners'}}</label>
|
|
|
|
<div class="ac-wrap clearfix" id='owner-list'>
|
|
|
|
{{#each model.owners as |member|}}
|
|
|
|
{{group-member member=member removeAction="removeOwner"}}
|
|
|
|
{{/each}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
<div>
|
|
|
|
<label for="owner-selector">{{i18n 'admin.groups.add_owners'}}</label>
|
|
|
|
{{user-selector usernames=model.ownerUsernames placeholderKey="admin.groups.selector_placeholder" id="owner-selector"}}
|
|
|
|
{{d-button action="addOwners" class="add" icon="plus" label="admin.groups.add"}}
|
|
|
|
</div>
|
|
|
|
{{/unless}}
|
2015-01-06 01:51:45 +08:00
|
|
|
<div>
|
2016-12-13 15:15:20 +08:00
|
|
|
{{group-members-input model=model}}
|
2015-01-06 01:51:45 +08:00
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
<div>
|
|
|
|
<label>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{input type="checkbox" checked=model.visible}}
|
2015-01-06 01:51:45 +08:00
|
|
|
{{i18n 'groups.visible'}}
|
|
|
|
</label>
|
2014-04-24 01:25:02 +08:00
|
|
|
</div>
|
2015-01-06 01:51:45 +08:00
|
|
|
|
2015-08-13 22:01:29 +08:00
|
|
|
{{#unless model.automatic}}
|
2016-12-07 14:56:45 +08:00
|
|
|
<div>
|
2016-12-12 22:46:45 +08:00
|
|
|
<label>
|
|
|
|
{{input type="checkbox"
|
|
|
|
checked=model.public
|
|
|
|
disabled=disablePublicSetting}}
|
|
|
|
|
|
|
|
{{i18n 'groups.public'}}
|
2016-12-07 14:56:45 +08:00
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div>
|
|
|
|
<label>
|
2016-12-12 22:46:45 +08:00
|
|
|
{{input type="checkbox"
|
|
|
|
checked=model.allow_membership_requests
|
|
|
|
disabled=disableMembershipRequestSetting}}
|
|
|
|
|
|
|
|
{{i18n 'groups.allow_membership_requests'}}
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div>
|
|
|
|
<label for="primary_group">
|
|
|
|
{{input type="checkbox" checked=model.primary_group}}
|
|
|
|
{{i18n 'admin.groups.primary_group'}}
|
2016-12-07 14:56:45 +08:00
|
|
|
</label>
|
|
|
|
</div>
|
2015-04-10 10:17:28 +08:00
|
|
|
{{/unless}}
|
|
|
|
|
2015-01-06 01:51:45 +08:00
|
|
|
<div>
|
|
|
|
<label for="alias">{{i18n 'groups.alias_levels.title'}}</label>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{combo-box name="alias" valueAttribute="value" value=model.alias_level content=aliasLevelOptions}}
|
2014-04-24 01:25:02 +08:00
|
|
|
</div>
|
2015-01-06 01:51:45 +08:00
|
|
|
|
2017-04-21 03:47:25 +08:00
|
|
|
<div>
|
|
|
|
<label>{{i18n 'groups.notification_level'}}</label>
|
|
|
|
{{notifications-button i18nPrefix='groups.notifications' notificationLevel=model.default_notification_level}}
|
|
|
|
<div class='clearfix'></div>
|
|
|
|
</div>
|
|
|
|
|
2015-08-13 22:01:29 +08:00
|
|
|
{{#unless model.automatic}}
|
2015-01-24 01:25:43 +08:00
|
|
|
<div>
|
|
|
|
<label for="automatic_membership">{{i18n 'admin.groups.automatic_membership_email_domains'}}</label>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{list-setting name="automatic_membership" settingValue=model.emailDomains}}
|
2015-01-24 01:25:43 +08:00
|
|
|
<label>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{input type="checkbox" checked=model.automatic_membership_retroactive}}
|
2015-01-24 01:25:43 +08:00
|
|
|
{{i18n 'admin.groups.automatic_membership_retroactive'}}
|
|
|
|
</label>
|
|
|
|
</div>
|
2015-04-10 10:17:28 +08:00
|
|
|
|
|
|
|
<div>
|
|
|
|
<label for="title">
|
|
|
|
{{i18n 'admin.groups.default_title'}}
|
|
|
|
</label>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{input value=model.title}}
|
2015-04-10 10:17:28 +08:00
|
|
|
</div>
|
2015-09-02 04:52:05 +08:00
|
|
|
|
|
|
|
<div>
|
|
|
|
<label for="grant_trust_level">{{i18n 'groups.trust_levels.title'}}</label>
|
|
|
|
{{combo-box name="grant_trust_level" valueAttribute="value" value=model.grant_trust_level content=trustLevelOptions}}
|
|
|
|
</div>
|
2015-12-07 19:39:28 +08:00
|
|
|
|
2015-12-09 19:10:46 +08:00
|
|
|
{{#if siteSettings.email_in}}
|
|
|
|
<label for="incoming_email">{{i18n 'admin.groups.incoming_email'}}</label>
|
|
|
|
{{text-field name="incoming_email" value=model.incoming_email placeholderKey="admin.groups.incoming_email_placeholder"}}
|
2016-12-20 00:19:10 +08:00
|
|
|
{{plugin-outlet name="group-email-in" args=(hash model=model)}}
|
2015-12-09 19:10:46 +08:00
|
|
|
{{/if}}
|
2015-01-24 01:25:43 +08:00
|
|
|
{{/unless}}
|
|
|
|
|
2016-08-17 00:34:04 +08:00
|
|
|
{{#unless model.automatic}}
|
2016-11-29 16:25:02 +08:00
|
|
|
{{group-flair-inputs model=model}}
|
2016-08-17 00:34:04 +08:00
|
|
|
{{/unless}}
|
|
|
|
|
2015-01-06 01:51:45 +08:00
|
|
|
<div class='buttons'>
|
2016-05-07 04:04:38 +08:00
|
|
|
<button {{action "save"}} disabled={{disableSave}} class='btn btn-primary'>{{i18n 'admin.customize.save'}}</button>
|
2015-08-13 22:01:29 +08:00
|
|
|
{{#unless model.automatic}}
|
2015-01-06 01:51:45 +08:00
|
|
|
<button {{action "destroy"}} class='btn btn-danger'>{{fa-icon "trash-o"}}{{i18n 'admin.customize.delete'}}</button>
|
|
|
|
{{/unless}}
|
2016-05-07 04:04:38 +08:00
|
|
|
|
|
|
|
<span class="saving {{unless savingStatus 'hidden'}}">{{savingStatus}}</span>
|
2015-01-06 01:51:45 +08:00
|
|
|
</div>
|
|
|
|
|
|
|
|
</form>
|