Add sub_menu in r_tags
This commit is contained in:
1 parent
db1b84e962
commit
a5b13e680f
8 files changed
+43
-4
No files matched your search
@@ -25,7 +25,7 @@ class Admin::PagePartsController < ApplicationController
|
||||
@module_apps = ModuleApp.all(:conditions => {:enable_frontend => true})
|
||||
@module_app = @part.module_app ? @part.module_app : @module_apps[0]
|
||||
@r_tag = @part.public_r_tag.blank? ? LIST[:public_r_tags][0] : @part.public_r_tag
|
||||
@tag_objects = @r_tag.classify.constantize.all
|
||||
@tag_objects = @r_tag.classify.constantize.all rescue nil
|
||||
case @module_app.key
|
||||
when 'bulletin'
|
||||
@categories = BulletinCategory.all
|
||||
@@ -74,5 +74,13 @@ class Admin::PagePartsController < ApplicationController
|
||||
format.js {}
|
||||
end
|
||||
end
|
||||
|
||||
def reload_r_tag_options
|
||||
@r_tag = (ModuleApp.find(params[:id]) rescue nil) || params[:id]
|
||||
@tag_objects = @r_tag.classify.constantize.all rescue nil
|
||||
respond_to do |format|
|
||||
format.js {}
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
Reference in new issue
Block a user