Fix for manager and admin can see all post in announcement. Haven't applied to news
This commit is contained in:
parent
82d1d3fed8
commit
e696516aae
|
@ -43,10 +43,12 @@ class Panel::Announcement::BackEnd::BulletinsController < OrbitBackendController
|
|||
@bulletin_file = BulletinFile.new
|
||||
@file_url = panel_announcement_back_end_bulletins_path
|
||||
|
||||
@bulletins.delete_if{ |bulletin|
|
||||
bulletin.is_pending == true && (!bulletin.bulletin_category.authed_users('fact_check').include?(current_user) || bulletin.create_user_id!=current_user.id)
|
||||
}
|
||||
|
||||
if(!is_admin? || !is_manager?)
|
||||
@bulletins.delete_if{ |bulletin|
|
||||
bulletin.is_pending == true && (!bulletin.bulletin_category.authed_users('fact_check').include?(current_user) || bulletin.create_user_id!=current_user.id)
|
||||
}
|
||||
end
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
format.js { }
|
||||
|
|
Reference in New Issue