fix widget reload_web_links
This commit is contained in:
parent
be8d8ff1e6
commit
a357ce6669
|
@ -146,7 +146,15 @@ class Panel::Announcement::Widget::BulletinsController < OrbitWidgetController
|
|||
|
||||
@selected_tag = Tag.find(params[:tag_id]).first
|
||||
@ModuleApp = ModuleApp.first(:conditions => {:key=>'web_resource'})
|
||||
@link_selected_tag = Tag.first(:conditions => {:name => @selected_tag.name, :module_tag_id => @ModuleApp.id})
|
||||
@link_module_tag = ModuleTag.first(:conditions => {:name => @selected_tag.name, :module_app_id => @ModuleApp.id})
|
||||
# @link_selected_tag = Tag.first(:conditions => {:name => @selected_tag.name, :tag_lease_id => @ModuleApp.id})
|
||||
|
||||
if !@link_module_tag.blank?
|
||||
@link_selected_tag = Tag.first(:conditions => {:name => @selected_tag.name, :tag_lease_id => @link_module_tag.id})
|
||||
else
|
||||
@link_selected_tag = @link_module_tag
|
||||
end
|
||||
|
||||
@web_links = WebLink.where(:tagged_ids => @link_selected_tag.id.to_s, :is_hidden => false).desc(:is_top,:created_at).available_for_lang(I18n.locale).page(params[:page]).per(@page_num) rescue nil
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue