gitlab-org--gitlab-foss/app/views/profiles/notifications/show.html.haml
Dmitriy Zaporozhets 936353edfd
Improve notification settings page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-02-17 18:06:24 +02:00

51 lines
2 KiB
Text

%h3.page-title
Notifications settings
%p.light
GitLab uses the email specified in your profile for notifications
%hr
= form_tag profile_notifications_path, method: :put, remote: true, class: 'update-notifications form-horizontal global-notifications-form' do
= hidden_field_tag :notification_type, 'global'
= label_tag :notification_level, 'Notification level', class: 'control-label'
.col-sm-10
.radio
= label_tag nil, class: '' do
= radio_button_tag :notification_level, Notification::N_DISABLED, @notification.disabled?, class: 'trigger-submit'
.level-title
Disabled
%p You will not get any notifications via email
.radio
= label_tag nil, class: '' do
= radio_button_tag :notification_level, Notification::N_PARTICIPATING, @notification.participating?, class: 'trigger-submit'
.level-title
Participating
%p You will only receive notifications from related resources (e.g. from your commits or assigned issues)
.radio
= label_tag nil, class: '' do
= radio_button_tag :notification_level, Notification::N_WATCH, @notification.watch?, class: 'trigger-submit'
.level-title
Watch
%p You will receive all notifications from projects in which you participate
.clearfix
%hr
%p
You can also specify notification level per group or per project
%br
By default all projects and groups uses notification level set above
.row.all-notifications
.col-md-6
%h4 Groups:
%ul.bordered-list
- @users_groups.each do |users_group|
- notification = Notification.new(users_group)
= render 'settings', type: 'group', membership: users_group, notification: notification
.col-md-6
%h4 Projects:
%ul.bordered-list
- @users_projects.each do |users_project|
- notification = Notification.new(users_project)
= render 'settings', type: 'project', membership: users_project, notification: notification