Commit 4da689177db1254eedfcdf7b2fce4647ccee68bc
1 parent
399e6339
Exists in
master
and in
1 other branch
added serv notification partial, lots of css
Showing
6 changed files
with
32 additions
and
12 deletions
Show diff stats
Gemfile
| ... | ... | @@ -49,7 +49,7 @@ group :development, :test do |
| 49 | 49 | gem 'webmock', :require => false |
| 50 | 50 | unless ENV["CI"] |
| 51 | 51 | gem 'ruby-debug', :platform => :mri_18 |
| 52 | - gem (RUBY_VERSION == "1.9.2" ? 'ruby-debug19' : 'debugger'), :platform => :mri_19 | |
| 52 | + gem (RUBY_VERSION >= "1.9.2" ? 'ruby-debug19' : 'debugger'), :platform => :mri_19 | |
| 53 | 53 | end |
| 54 | 54 | # gem 'rpm_contrib', :git => "git://github.com/bensymonds/rpm_contrib.git", :branch => "mongo-1.4.0_update" |
| 55 | 55 | end | ... | ... |
app/assets/stylesheets/application.css.erb
app/assets/stylesheets/errbit.css
| ... | ... | @@ -535,10 +535,11 @@ a.button.active { |
| 535 | 535 | display: inline-block; |
| 536 | 536 | } |
| 537 | 537 | |
| 538 | -/* Watchers and Issue Tracker Forms */ | |
| 539 | -div.watcher.nested .watcher_params, div.issue_tracker.nested .tracker_params { | |
| 538 | +/* Watchers / Issue Tracker / Notification Forms */ | |
| 539 | +div.watcher.nested .watcher_params, div.issue_tracker.nested .tracker_params, div.notification_service.nested .notification_params { | |
| 540 | 540 | display: none; |
| 541 | 541 | } |
| 542 | + | |
| 542 | 543 | div.nested .chosen { |
| 543 | 544 | display: block !important; |
| 544 | 545 | } |
| ... | ... | @@ -546,35 +547,35 @@ div.nested .choose { |
| 546 | 547 | margin-bottom: 0.5em; |
| 547 | 548 | } |
| 548 | 549 | |
| 549 | -div.issue_tracker.nested .choose { | |
| 550 | +div.issue_tracker.nested .choose, div.notification_service.nested .choose { | |
| 550 | 551 | background-color: #ebebeb; |
| 551 | 552 | border: 1px solid #dddddd; |
| 552 | 553 | margin: 0 0 15px; |
| 553 | 554 | padding: 12px; |
| 554 | 555 | } |
| 555 | -div.issue_tracker.nested img { | |
| 556 | +div.issue_tracker.nested img, div.notification_service.nested img { | |
| 556 | 557 | vertical-align: middle; |
| 557 | 558 | } |
| 558 | 559 | |
| 559 | 560 | /* Icons for Issue Tracker Radio Buttons */ |
| 560 | -div.issue_tracker.nested label.label_radio { | |
| 561 | +div.issue_tracker.nested label.label_radio, div.notification_service.nested label.label_radio { | |
| 561 | 562 | color: #929292; |
| 562 | 563 | padding-left: 33px; |
| 563 | 564 | margin-bottom: 6px; |
| 564 | 565 | margin-right: 8px; |
| 565 | 566 | line-height: 30px; |
| 566 | 567 | } |
| 567 | -div.issue_tracker.nested .choose { | |
| 568 | +div.issue_tracker.nested .choose, div.notification_service.nested .choose { | |
| 568 | 569 | padding-bottom: 6px; |
| 569 | 570 | } |
| 570 | -div.issue_tracker.nested label.label_radio:hover { | |
| 571 | +div.issue_tracker.nested label.label_radio:hover, div.notification_service.nested label.label_radio:hover { | |
| 571 | 572 | color: #696969; |
| 572 | 573 | } |
| 573 | -div.issue_tracker.nested .label_radio input { | |
| 574 | +div.issue_tracker.nested .label_radio input, div.notification_service.nested .label_radio input { | |
| 574 | 575 | position: absolute; left: -9999px; |
| 575 | 576 | } |
| 576 | 577 | |
| 577 | -div.issue_tracker.nested label.r_on, div.issue_tracker.nested label.r_on:hover { | |
| 578 | +div.issue_tracker.nested label.r_on, div.issue_tracker.nested label.r_on:hover, div.notification_service.nested label.r_on, div.notification_service.nested label.r_on:hover { | |
| 578 | 579 | color: #191919; |
| 579 | 580 | } |
| 580 | 581 | ... | ... |
app/assets/stylesheets/issue_tracker_icons.css.erb
app/assets/stylesheets/notification_service_icons.css.erb
0 → 100644
| ... | ... | @@ -0,0 +1,18 @@ |
| 1 | + /* Notification Service inactive, select, create and goto icons */ | |
| 2 | +<% notification_services = NotificationService.subclasses.map{|t| t.label } << 'none' %> | |
| 3 | + | |
| 4 | +<% notification_services.each do |notification_service| %> | |
| 5 | +div.notification_service.nested label.<%= notification_service %> { | |
| 6 | + background: url(/assets/<%= notification_service %>_inactive.png) no-repeat; | |
| 7 | +} | |
| 8 | +div.notification_service.nested label.r_on.<%= notification_service %> { | |
| 9 | + background: url(/assets/<%= notification_service %>_create.png) no-repeat; | |
| 10 | +} | |
| 11 | +#action-bar a.<%= notification_service %>_create { | |
| 12 | + background: transparent url(/assets/<%= notification_service %>_create.png) 6px 5px no-repeat; | |
| 13 | +} | |
| 14 | +#action-bar a.<%= notification_service %>_goto { | |
| 15 | + background: transparent url(/assets/<%= notification_service %>_goto.png) 6px 5px no-repeat; | |
| 16 | +} | |
| 17 | +<% end %> | |
| 18 | + | ... | ... |
app/views/apps/_service_notification_fields.html.haml
| 1 | 1 | %fieldset |
| 2 | 2 | %legend Notification Service |
| 3 | 3 | = f.fields_for :notification_service do |w| |
| 4 | - %div.notification.nested | |
| 4 | + %div.notification_service.nested | |
| 5 | 5 | %div.choose |
| 6 | 6 | = label_tag :type_none, :for => label_for_attr(w, 'type_notificationservice'), :class => "label_radio none" do |
| 7 | 7 | = w.radio_button :type, "NotificationService", 'data-section' => 'none' |
| ... | ... | @@ -12,7 +12,6 @@ |
| 12 | 12 | = notification_service.name[/::(.*)Service/,1].titleize |
| 13 | 13 | |
| 14 | 14 | %div.notification_params.none{:class => (w.object && !(w.object.class < NotificationService)) ? 'chosen' : nil} |
| 15 | - %p When no issue tracker has been configured, you will be able to leave comments on errors. | |
| 16 | 15 | - NotificationService.subclasses.each do |notification_service| |
| 17 | 16 | %div.notification_params{:class => (w.object.is_a?(notification_service) ? 'chosen ' : '') << notification_service.label} |
| 18 | 17 | - notification_service::Fields.each do |field, field_info| | ... | ... |