before_filter :authenticate_author, :only => [:new, :create, :edit, :update, :destroy]
end
- def self.model
- Scroll
- end
-
def index
filer_list
end
def show_html_format format
format.html {
- play_list = Locmare::ListGroup.list 'scroll_panel', 'play'
- @play_count = play_list.count(@operators,
- {:id => @item.id, :my_play => @item.own?(@operators)}
+ @play_list = Locmare::ListGroup.list(
+ 'scroll_panels', 'by_scroll', @operators,
+ {:id => @item.id, :page_size => -1} # set no limit options}
)
}
end
respond_to do |format|
format.html {
if @item.own? @operators
- @fresh_panel_items = assist_items('panel', 'public')
- @new_panel_items = assist_items('panel', 'private')
+ @fresh_panel_items = assist_items('panels', 'index')
+ @new_panel_items = assist_items('home', 'panels')
end
}
- format.json { render json: @items.to_json }
+ list_json_format @list, format
end
end
- def count
- list_count
- end
-
- def count_by_author
- list_count
- end
-
- def count_by_panel
- list_count
- end
-
def new
form_new
end