fixes typo
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
// 03. Show participation
|
||||
// 04. List participation
|
||||
// 05. Featured
|
||||
// 06. Proposals successfull
|
||||
// 06. Proposals successful
|
||||
//
|
||||
|
||||
// 01. Votes and supports
|
||||
@@ -942,7 +942,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
// 06. Proposals successfull
|
||||
// 06. Proposals successful
|
||||
// -------------------------
|
||||
|
||||
.dark-heading {
|
||||
@@ -1001,9 +1001,9 @@
|
||||
}
|
||||
|
||||
.sucessfull-proposals-banner,
|
||||
.successfull .panel {
|
||||
.successful .panel {
|
||||
|
||||
.icon-successfull {
|
||||
.icon-successful {
|
||||
border-right: 60px solid #FFD200;
|
||||
border-top: 0;
|
||||
border-bottom: 60px solid transparent;
|
||||
@@ -1034,7 +1034,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
.successfull {
|
||||
.successful {
|
||||
|
||||
.panel {
|
||||
position: relative;
|
||||
|
||||
@@ -22,7 +22,7 @@ class DebatesController < ApplicationController
|
||||
|
||||
def index_customization
|
||||
@featured_debates = @debates.featured
|
||||
@proposal_successfull_exists = Proposal.successfull.exists?
|
||||
@proposal_successful_exists = Proposal.successful.exists?
|
||||
end
|
||||
|
||||
def show
|
||||
|
||||
@@ -28,8 +28,8 @@ class ProposalsController < ApplicationController
|
||||
def index_customization
|
||||
discard_archived
|
||||
load_retired
|
||||
load_successfull_proposals
|
||||
load_featured unless @proposal_successfull_exists
|
||||
load_successful_proposals
|
||||
load_featured unless @proposal_successful_exists
|
||||
end
|
||||
|
||||
def vote
|
||||
@@ -103,8 +103,8 @@ class ProposalsController < ApplicationController
|
||||
end
|
||||
end
|
||||
|
||||
def load_successfull_proposals
|
||||
@proposal_successfull_exists = Proposal.successfull.exists?
|
||||
def load_successful_proposals
|
||||
@proposal_successful_exists = Proposal.successful.exists?
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
@@ -50,7 +50,7 @@ class Proposal < ActiveRecord::Base
|
||||
scope :last_week, -> { where("proposals.created_at >= ?", 7.days.ago)}
|
||||
scope :retired, -> { where.not(retired_at: nil) }
|
||||
scope :not_retired, -> { where(retired_at: nil) }
|
||||
scope :successfull, -> { where("cached_votes_up + physical_votes >= ?", Proposal.votes_needed_for_success)}
|
||||
scope :successful, -> { where("cached_votes_up + physical_votes >= ?", Proposal.votes_needed_for_success)}
|
||||
|
||||
def to_param
|
||||
"#{id}-#{title}".parameterize
|
||||
@@ -159,7 +159,7 @@ class Proposal < ActiveRecord::Base
|
||||
Setting['votes_for_proposal_success'].to_i
|
||||
end
|
||||
|
||||
def successfull?
|
||||
def successful?
|
||||
total_votes >= Proposal.votes_needed_for_success
|
||||
end
|
||||
|
||||
|
||||
@@ -29,11 +29,11 @@
|
||||
<%= render "shared/banner" %>
|
||||
<% end %>
|
||||
|
||||
<% if @proposal_successfull_exists %>
|
||||
<%= render "proposals/successfull_banner" %>
|
||||
<% if @proposal_successful_exists %>
|
||||
<%= render "proposals/successful_banner" %>
|
||||
<% end %>
|
||||
|
||||
<% unless @tag_filter || @search_terms || !has_featured? || @proposal_successfull_exists %>
|
||||
<% unless @tag_filter || @search_terms || !has_featured? || @proposal_successful_exists %>
|
||||
<%= render "featured_debates" %>
|
||||
<% end %>
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<div id="<%= dom_id(proposal) %>"
|
||||
class="proposal clear <%= ("successfull" if proposal.total_votes > Proposal.votes_needed_for_success) %>"
|
||||
class="proposal clear <%= ("successful" if proposal.total_votes > Proposal.votes_needed_for_success) %>"
|
||||
data-type="proposal">
|
||||
<div class="panel">
|
||||
<div class="icon-successfull"></div>
|
||||
<div class="icon-successful"></div>
|
||||
<div class="row">
|
||||
|
||||
<div class="small-12 medium-9 column">
|
||||
@@ -53,10 +53,10 @@
|
||||
</div>
|
||||
|
||||
<div id="<%= dom_id(proposal) %>_votes" class="small-12 medium-3 column">
|
||||
<% if proposal.successfull? %>
|
||||
<% if proposal.successful? %>
|
||||
<div class="message">
|
||||
<p>
|
||||
<%= t("proposals.proposal.successfull",
|
||||
<%= t("proposals.proposal.successful",
|
||||
voting: link_to(t("proposals.proposal.voting"), polls_path)).html_safe %>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<div id="next-voting" class="row featured-proposals-ballot-banner">
|
||||
<%= link_to polls_path do %>
|
||||
<div class="small-12 column padding">
|
||||
<div class="icon-successfull"></div>
|
||||
<div class="icon-successful"></div>
|
||||
<h2><%= t("proposal_ballots.featured_title") %></h2>
|
||||
<p><%= t("proposal_ballots.info") %></p>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<div id="next-voting" class="row sucessfull-proposals-banner">
|
||||
<%= link_to polls_path do %>
|
||||
<div class="small-12 column padding">
|
||||
<div class="icon-successfull"></div>
|
||||
<div class="icon-successful"></div>
|
||||
<h2><%= t("enquiries.banner.featured_title") %></h2>
|
||||
<p><%= t("enquiries.banner.info") %></p>
|
||||
</div>
|
||||
@@ -31,8 +31,8 @@
|
||||
<%= render "shared/banner" %>
|
||||
<% end %>
|
||||
|
||||
<% if @proposal_successfull_exists %>
|
||||
<%= render "successfull_banner" %>
|
||||
<% if @proposal_successful_exists %>
|
||||
<%= render "successful_banner" %>
|
||||
<% elsif @featured_proposals.present? %>
|
||||
<div id="featured-proposals" class="row featured-proposals">
|
||||
<div class="small-12 column">
|
||||
|
||||
@@ -103,9 +103,9 @@
|
||||
<div class="sidebar-divider"></div>
|
||||
<h3><%= t("votes.supports") %></h3>
|
||||
<div id="<%= dom_id(@proposal) %>_votes">
|
||||
<% if @proposal.successfull? %>
|
||||
<% if @proposal.successful? %>
|
||||
<p>
|
||||
<%= t("proposals.proposal.successfull",
|
||||
<%= t("proposals.proposal.successful",
|
||||
voting: link_to(t("proposals.proposal.voting"), polls_path)).html_safe %>
|
||||
</p>
|
||||
<% if can? :create, Poll::Question %>
|
||||
|
||||
Reference in New Issue
Block a user