Fixes gather music not playing during voting phase

Fixes issues with topic ordering
Tweaked read/unread icon colours for forums
This commit is contained in:
Luke Barratt 2014-05-16 23:54:41 +01:00
parent 1a4a0f4d83
commit f41e6e0d5a
9 changed files with 43 additions and 11 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.2 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

View file

@ -75,7 +75,7 @@ div#errors {
top: 0;
.message {
background: image-url("#{theme-path}/layout/flash-notice-background.png");
background: image-url("#{$theme-path}/layout/flash-notice-background.png");
position: relative;
width: 730px;
height: 60px;
@ -89,7 +89,7 @@ div#errors {
z-index: 2;
&:before {
background: image-url("#{theme-path}/layout/flash-notice-icon.png");
background: image-url("#{$theme-path}/layout/flash-notice-icon.png");
content: '';
display: block;
width: 30px;
@ -102,10 +102,10 @@ div#errors {
&.warning,
&.error,
&.alert {
background: image-url("#{theme-path}/layout/flash-error-background.png");
background: image-url("#{$theme-path}/layout/flash-error-background.png");
&:before {
background: image-url("#{theme-path}/layout/flash-error-icon.png");
background: image-url("#{$theme-path}/layout/flash-error-icon.png");
}
}
}

View file

@ -120,8 +120,12 @@ div#categories {
border-radius: $base-border-radius;
border: 0;
.read {
color: $base-font-color;
}
.unread {
color: $red;
color: $blue;
}
thead th {

View file

@ -62,4 +62,28 @@ div#errors {
}
}
}
}
/*
Notification Messages
*/
#notification {
position: absolute;
margin: 0 auto;
left: 50%;
top: 0;
.message {
@extend .flash;
position: relative;
width: auto;
left: -50%;
text-align: center;
font-family: $header-font-family;
color: white;
padding: 0 100px;
z-index: 2;
}
}

View file

@ -130,6 +130,11 @@ div#categories {
border-radius: $base-border-radius;
border: 0;
.read {
color: $base-font-color;
font-weight: normal;
}
.unread {
color: $red;
}

View file

@ -11,8 +11,7 @@ class ForumsController < ApplicationController
raise AccessError unless @forum.can_show? cuser
@topics = Topic.where(forum_id: @forum.id)
.joins(:posts, :user, :users_who_read)
.includes(:lock)
.includes(:posts, :user, :users_who_read, :lock)
.group('topics.id')
.order('state DESC, posts.id DESC')
.paginate(page: params[:page], per_page: 30)

View file

@ -8,8 +8,8 @@
type: "script",
minTimeout: 5000,
maxTimeout: 15000,
success: function(response) {
if (response.match(/Gather:voting/)) {
success: function(response, text, request) {
if (request.getResponseHeader('Gather') == 'voting') {
if (!played) {
$("#jplayer").jPlayer({
ready: function() {

View file

@ -17,7 +17,7 @@ Capybara.register_driver :poltergeist do |app|
)
end
Capybara.javascript_driver = :poltergeist
Capybara.javascript_driver = :selenium
Dir[Rails.root.join("spec/support/**/*.rb")].each { |f| require f }
@ -33,7 +33,7 @@ RSpec.configure do |config|
config.before(:each) do
if example.metadata[:type] == :feature
Capybara.current_driver = :poltergeist
Capybara.current_driver = :selenium
else
Capybara.use_default_driver
end