Fix old tags
This commit is contained in:
parent
fd2b176798
commit
5b289bc1d2
|
@ -46,12 +46,16 @@ class Admin::TagsController < OrbitBackendController
|
|||
|
||||
protected
|
||||
|
||||
def set_module_app
|
||||
@module_app ||= ModuleApp.first(:conditions => {:key => @app_title.underscore}) rescue nil
|
||||
end
|
||||
|
||||
def get_tags
|
||||
@tags = (@module_app ? @module_app.tags : Tag.all)
|
||||
end
|
||||
|
||||
def setup_vars
|
||||
@app_key = request.env['HTTP_REFERER'].split('/')[4]
|
||||
if @app_key
|
||||
@app_key.gsub!(/[?].*/, '')
|
||||
@module_app = ModuleApp.first(conditions: {:key => @app_key})
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue