2012-10-16 06:03:29 +02:00
|
|
|
{# Settings tab of the app. #}
|
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<h1><i class="icon-vector-wrench settings-icon"></i>Settings</h1>
|
2013-04-03 23:17:20 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div id="settings-change-box">
|
2013-10-25 20:47:03 +02:00
|
|
|
|
2013-10-25 23:52:45 +02:00
|
|
|
<div class="alert" id="settings-status"></div>
|
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div id="account-settings" class="settings-section">
|
|
|
|
<div class="settings-section-title"><i class="icon-vector-user settings-section-icon"></i>Your Account</div>
|
2013-10-25 20:47:03 +02:00
|
|
|
<div class="account-settings-form">
|
2013-10-28 15:49:38 +01:00
|
|
|
<form action="/json/settings/change" method="post"
|
|
|
|
class="form-horizontal your-account-settings">{% csrf_token %}
|
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="control-group" id="name_change_container">
|
|
|
|
<label for="full_name" class="control-label">Full name</label>
|
|
|
|
<div class="controls">
|
|
|
|
<input type="text" name="full_name" id="full_name"
|
|
|
|
value="{{ user_profile.full_name }}" />
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2013-11-04 23:42:31 +01:00
|
|
|
{% if password_auth_enabled %}
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="control-group" id="pw_change_link">
|
|
|
|
<label for="change_password_button" class="control-label">Password</label>
|
|
|
|
<div class="controls">
|
|
|
|
<button class="btn change_password_button" data-dismiss="modal" aria-hidden="true">Change Password</button>
|
2013-10-25 20:47:03 +02:00
|
|
|
</div>
|
2013-10-21 01:04:25 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div id="pw_change_controls">
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="old_password" class="control-label">Old password</label>
|
|
|
|
<div class="controls">
|
|
|
|
<input type="password" autocomplete="off"
|
|
|
|
name="old_password" id="old_password" value="" />
|
2013-11-05 02:02:53 +01:00
|
|
|
(<a href="/accounts/password/reset/" target="_blank">Forgotten it?</a>)
|
2013-10-21 01:04:25 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="new_password" class="control-label">New password</label>
|
|
|
|
<div class="controls">
|
|
|
|
<input type="password" autocomplete="off"
|
|
|
|
name="new_password" id="new_password" value="" />
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label">Password strength</label>
|
|
|
|
<div class="controls">
|
|
|
|
<div class="progress" id="pw_strength">
|
|
|
|
<div class="bar bar-danger" style="width: 10%;"></div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="confirm_password" class="control-label">Confirm password</label>
|
|
|
|
<div class="controls">
|
|
|
|
<input type="password" autocomplete="off"
|
|
|
|
name="confirm_password" id="confirm_password" value="" />
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
2013-11-04 23:42:31 +01:00
|
|
|
{% endif %}
|
2013-10-21 01:04:25 +02:00
|
|
|
|
2013-10-28 15:49:38 +01:00
|
|
|
<div id="user_avatar_file_input_error" class="text-error"></div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<div class="controls">
|
|
|
|
<div id="user_avatar_file"></div>
|
2013-11-18 22:43:24 +01:00
|
|
|
<input type="file" name="user_avatar_file_input" class="notvisible" id="user_avatar_file_input" value="Upload avatar" />
|
2013-10-28 15:49:38 +01:00
|
|
|
<button class="btn" id="user_avatar_upload_button">Customize avatar</button>
|
|
|
|
<p>
|
|
|
|
<img id="user-settings-avatar" src="{{ avatar_url }}" />
|
|
|
|
</p>
|
2013-11-22 20:50:39 +01:00
|
|
|
<div id="upload_avatar_spinner"></div>
|
2013-10-28 15:49:38 +01:00
|
|
|
</div>
|
|
|
|
</div>
|
2013-08-08 18:24:07 +02:00
|
|
|
|
2013-11-22 20:50:39 +01:00
|
|
|
<div class="control-group">
|
|
|
|
<div class="controls">
|
|
|
|
<input type="submit" name="change_settings"
|
|
|
|
value="Save changes" class="btn btn-big btn-primary" />
|
|
|
|
</div>
|
|
|
|
</div>
|
2013-10-28 15:49:38 +01:00
|
|
|
|
2013-11-22 20:50:39 +01:00
|
|
|
</form>
|
2013-10-28 15:49:38 +01:00
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
2013-10-25 23:52:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
2013-10-25 22:41:35 +02:00
|
|
|
<form action="/json/notify_settings/change" method="post"
|
|
|
|
class="form-horizontal notify-settings">{% csrf_token %}
|
2013-05-28 23:10:11 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div id="notification-settings" class="settings-section">
|
|
|
|
<div class="settings-section-title"><i class="icon-vector-warning-sign settings-section-icon"></i>Notifications <i class="tiny icon-vector-question-sign" id="notification-docs"></i></div>
|
2013-11-22 20:50:39 +01:00
|
|
|
<div class="alert" id="notify-settings-status"></div>
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="notification-settings-form">
|
2013-04-03 22:47:59 +02:00
|
|
|
<div class="control-group">
|
2013-08-08 18:24:07 +02:00
|
|
|
<div class="controls">
|
|
|
|
<input type="checkbox" name="enable_desktop_notifications" id="enable_desktop_notifications"
|
|
|
|
{% if user_profile.enable_desktop_notifications %}
|
|
|
|
checked="yes"
|
|
|
|
{% endif %} />
|
|
|
|
</div>
|
2013-10-21 01:04:25 +02:00
|
|
|
<label for="enable_desktop_notifications" class="control-label">
|
|
|
|
Desktop notifications
|
|
|
|
</label>
|
2013-04-03 22:47:59 +02:00
|
|
|
</div>
|
2013-10-08 02:38:42 +02:00
|
|
|
|
2013-05-03 21:49:01 +02:00
|
|
|
<div class="control-group">
|
2013-08-08 18:24:07 +02:00
|
|
|
<div class="controls">
|
|
|
|
<input type="checkbox" name="enable_sounds" id="enable_sounds"
|
|
|
|
{% if user_profile.enable_sounds %}
|
|
|
|
checked="yes"
|
|
|
|
{% endif %} />
|
|
|
|
</div>
|
2013-10-21 01:04:25 +02:00
|
|
|
<label for="enable_sounds" class="control-label">
|
|
|
|
Audible notifications
|
|
|
|
</label>
|
2013-05-03 21:49:01 +02:00
|
|
|
</div>
|
2013-04-03 22:47:59 +02:00
|
|
|
|
2013-05-07 23:19:52 +02:00
|
|
|
<div class="control-group">
|
2013-08-08 18:24:07 +02:00
|
|
|
<div class="controls">
|
|
|
|
<input type="checkbox" name="enable_offline_email_notifications" id="enable_offline_email_notifications"
|
|
|
|
{% if user_profile.enable_offline_email_notifications %}
|
|
|
|
checked="yes"
|
|
|
|
{% endif %} />
|
|
|
|
</div>
|
2013-10-21 01:04:25 +02:00
|
|
|
<label for="enable_offline_email_notifications" class="control-label">
|
|
|
|
Email notifications when offline
|
|
|
|
</label>
|
2013-05-07 23:19:52 +02:00
|
|
|
</div>
|
|
|
|
|
2013-10-16 17:24:52 +02:00
|
|
|
<div class="control-group">
|
|
|
|
<div class="controls">
|
|
|
|
<input type="checkbox" name="enable_offline_push_notifications" id="enable_offline_push_notifications"
|
|
|
|
{% if user_profile.enable_offline_push_notifications %}
|
|
|
|
checked="yes"
|
|
|
|
{% endif %} />
|
|
|
|
</div>
|
|
|
|
<label for="enable_offline_push_notifications" class="control-label">
|
|
|
|
Mobile push notifications when offline
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
|
2013-12-02 03:01:09 +01:00
|
|
|
<div class="control-group" id="digest_container">
|
2013-12-02 02:00:23 +01:00
|
|
|
<div class="controls">
|
|
|
|
<input type="checkbox" name="enable_digest_emails" id="enable_digest_emails"
|
|
|
|
{% if user_profile.enable_digest_emails %}
|
|
|
|
checked="yes"
|
|
|
|
{% endif %} />
|
|
|
|
</div>
|
|
|
|
<label for="enable_digest_emails" class="control-label">
|
|
|
|
Digest emails when I'm away
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<p class="notification-settings-note">Change notification settings for individual streams on your <a href="/#subscriptions">Streams page</a>.</p>
|
|
|
|
|
2013-04-03 22:47:59 +02:00
|
|
|
<div class="control-group">
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="controls notification-submission">
|
2013-08-08 18:24:07 +02:00
|
|
|
<input type="submit" name="change_settings" value="Save changes" class="btn btn-big btn-primary" />
|
|
|
|
</div>
|
2013-04-03 22:47:59 +02:00
|
|
|
</div>
|
2013-10-25 20:47:03 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
2012-09-21 19:32:01 +02:00
|
|
|
</form>
|
2013-10-25 20:47:03 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
</div>
|
2013-08-08 18:24:07 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div id="bot-settings" class="settings-section">
|
2013-10-25 20:47:03 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="settings-section-title"><i class="icon-vector-github settings-section-icon"></i>Your Bots</div>
|
2013-10-25 20:47:03 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="bot-settings-form">
|
|
|
|
<p class="bot-settings-note">Looking for our <a href="/integrations" target="_blank">Integrations</a>
|
|
|
|
or <a href="/api" target="_blank">API</a> documentation?</p>
|
2013-09-17 23:03:36 +02:00
|
|
|
|
2013-08-08 18:24:07 +02:00
|
|
|
<ol id="bots_list">
|
|
|
|
</ol>
|
2013-06-27 22:36:41 +02:00
|
|
|
<div id="bot_table_error" class="alert alert-error hide"></div>
|
2013-10-21 01:04:25 +02:00
|
|
|
<form id="create_bot_form" class="form-horizontal">
|
2013-11-16 19:43:14 +01:00
|
|
|
<div class="add-new-bot-box">
|
|
|
|
<div class="settings-section-title new-bot-section-title">Add a New Bot</div>
|
|
|
|
<div class="new-bot-form">
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="create_bot_name" class="control-label">Full name</label>
|
|
|
|
<input type="text" name="bot_name" id="create_bot_name" class="required"
|
|
|
|
maxlength=100 placeholder="Full Bot Name" value="" />
|
|
|
|
<div><label for="create_bot_name" generated="true" class="text-error"></label></div>
|
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="bot_short_name" class="control-label">Username</label>
|
|
|
|
<input type="text" name="bot_short_name" id="create_bot_short_name" class="required bot_local_part"
|
|
|
|
placeholder="bot_user_name" value="" />-bot@{{ user_profile.realm.domain }}
|
|
|
|
<div><label for="create_bot_short_name" generated="true" class="text-error"></label></div>
|
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<div class="controls">
|
|
|
|
<div id="bot_avatar_file"></div>
|
2013-11-18 22:43:24 +01:00
|
|
|
<input type="file" name="bot_avatar_file_input" class="notvisible" id="bot_avatar_file_input" value="Upload avatar" />
|
2013-11-16 19:43:14 +01:00
|
|
|
<button class="btn" id="bot_avatar_clear_button">Clear avatar</button>
|
|
|
|
<button class="btn" id="bot_avatar_upload_button">Customize avatar</button> (Optional)
|
|
|
|
</div>
|
|
|
|
</div>
|
2013-11-16 19:53:39 +01:00
|
|
|
<p>
|
|
|
|
<div id="bot_avatar_file_input_error" class="text-error"></div>
|
|
|
|
</p>
|
|
|
|
<div class="control-group">
|
|
|
|
<div class="controls">
|
|
|
|
<input type="submit" class="btn btn-primary" id="create_bot_button" value="Create Bot" />
|
|
|
|
</div>
|
2013-11-16 19:43:14 +01:00
|
|
|
</div>
|
2013-10-21 01:04:25 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2013-05-03 00:29:52 +02:00
|
|
|
</form>
|
2013-11-16 19:43:14 +01:00
|
|
|
|
2013-05-03 00:29:52 +02:00
|
|
|
<hr class="settings_separator" />
|
|
|
|
|
2013-05-28 20:03:38 +02:00
|
|
|
<div class="form-horizontal" id="api_key_button_box">
|
2013-10-21 01:04:25 +02:00
|
|
|
<p class="api-key-note">For most bots using the API, you'll want to give each bot
|
2013-05-28 20:03:38 +02:00
|
|
|
its own name and API key using the above section. But if you
|
2013-10-21 01:04:25 +02:00
|
|
|
want to write a bot that can access your own private
|
2013-10-25 20:47:03 +02:00
|
|
|
messages, you should use your personal API key.
|
|
|
|
</p>
|
2013-10-21 01:04:25 +02:00
|
|
|
<div class="control-group">
|
2013-08-08 18:08:30 +02:00
|
|
|
<button class="btn" id="api_key_button">Show/change your API key</button>
|
2013-05-28 23:10:11 +02:00
|
|
|
</div>
|
2013-05-28 20:03:38 +02:00
|
|
|
</div>
|
|
|
|
<div id="get_api_key_box">
|
2013-08-08 18:24:07 +02:00
|
|
|
<p>Please re-enter your password to confirm your identity.
|
|
|
|
(<a href="/accounts/password/reset/" target="_blank">Forgotten it?</a>)</p>
|
|
|
|
<form action="/json/fetch_api_key" method="post" class="form-horizontal">{% csrf_token %}
|
|
|
|
<div class="control-group">
|
|
|
|
<label for="password" class="control-label">Current password</label>
|
|
|
|
<input type="password" autocomplete="off"
|
|
|
|
name="password" id="get_api_key_password" value="" />
|
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<input type="submit" name="view_api_key" value="Get API key"
|
|
|
|
class="btn btn-primary" />
|
|
|
|
</div>
|
|
|
|
</form>
|
2013-05-28 20:03:38 +02:00
|
|
|
</div>
|
|
|
|
<div id="show_api_key_box">
|
2013-08-08 18:24:07 +02:00
|
|
|
<p>Your API key:</p>
|
|
|
|
<p><b><span id="api_key_value"></span></b></p>
|
|
|
|
<button type="submit" class="btn btn-primary regenerate_api_key">
|
|
|
|
Generate new API Key
|
|
|
|
</button>
|
2013-08-08 19:13:27 +02:00
|
|
|
<div id="user_api_key_error text-error">
|
2013-08-08 18:24:07 +02:00
|
|
|
</div>
|
2013-05-28 20:03:38 +02:00
|
|
|
</div>
|
2013-10-06 00:17:37 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
</div>
|
2013-10-25 20:47:03 +02:00
|
|
|
</div>
|
|
|
|
|
2013-10-06 00:17:37 +02:00
|
|
|
|
2013-10-05 21:49:39 +02:00
|
|
|
|
2013-10-21 01:04:25 +02:00
|
|
|
<div id="word-alert-settings" class="settings-section">
|
|
|
|
<div class="settings-section-title"><i class="icon-vector-book settings-section-icon"></i>Custom Word Alerts</div>
|
|
|
|
<ul id="word-alerts">
|
|
|
|
</ul>
|
|
|
|
</div>
|
2013-10-05 21:49:39 +02:00
|
|
|
|