Fix for ad_image
This commit is contained in:
parent
7416020161
commit
6273300c28
|
@ -1,8 +1,13 @@
|
||||||
class Admin::AdImagesController < OrbitBackendController
|
class Admin::AdImagesController < Admin::AdBannersController
|
||||||
|
|
||||||
before_filter :force_order_for_user
|
# before_filter :force_order_for_user
|
||||||
before_filter :for_app_sub_manager
|
# before_filter :for_app_sub_manager
|
||||||
before_filter :for_app_manager
|
# before_filter :for_app_manager
|
||||||
|
|
||||||
|
def initialize
|
||||||
|
super
|
||||||
|
@app_title = "ad_banner"
|
||||||
|
end
|
||||||
|
|
||||||
def edit
|
def edit
|
||||||
@ad_banner = AdBanner.find params[:ad_banner_id]
|
@ad_banner = AdBanner.find params[:ad_banner_id]
|
||||||
|
|
|
@ -11,7 +11,7 @@ class OrbitBackendController < ApplicationController
|
||||||
layout 'new_admin'
|
layout 'new_admin'
|
||||||
|
|
||||||
def setup_vars
|
def setup_vars
|
||||||
@app_title = controller_path.split('/')[1].singularize
|
@app_title ||= controller_path.split('/')[1].singularize
|
||||||
@module_app ||= ModuleApp.first(conditions: {:key => @app_title} )
|
@module_app ||= ModuleApp.first(conditions: {:key => @app_title} )
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue