Proposals dashboard refactored to dashboard.
Added missing specs for the dashboard.
This commit is contained in:
Juan Salvador Pérez García
2018-07-24 15:52:43 +02:00
parent 0ea0a0031c
commit e5f9cf6710
82 changed files with 1131 additions and 694 deletions

View File

@@ -31,8 +31,8 @@ class Proposal < ActiveRecord::Base
belongs_to :geozone
has_many :comments, as: :commentable, dependent: :destroy
has_many :proposal_notifications, dependent: :destroy
has_many :proposal_executed_dashboard_actions, dependent: :destroy
has_many :proposal_dashboard_actions, through: :proposal_executed_dashboard_actions
has_many :dashboard_executed_actions, dependent: :destroy, class_name: 'Dashboard::ExecutedAction'
has_many :dashboard_actions, through: :dashboard_executed_actions, class_name: 'Dashboard::Action'
has_many :polls, as: :related
validates :title, presence: true