Skip to content

Commit

Permalink
Reordered list page alphabetically and added content type create support
Browse files Browse the repository at this point in the history
  • Loading branch information
cykod committed Apr 23, 2010
1 parent 1a663be commit f9edf75
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/controllers/modules_controller.rb
Expand Up @@ -10,6 +10,8 @@ def index

@domain = Domain.find(DomainModel.active_domain_id)
@available_modules = SiteModule.available_modules(@domain)

@available_modules = @available_modules.sort { |a,b| a[:name] <=> b[:name] }

expire_site if params[:refresh]

Expand Down
5 changes: 5 additions & 0 deletions app/models/model_extension/content_cache_extension.rb
Expand Up @@ -188,6 +188,11 @@ def self.append_features(mod) #:nodoc:

module CacheClassMethods

def cache_expire_by_id(item_id)
DataCache.expire_content(self.to_s,"ID#{item_id}")
content_cache_expire_list
end

# Expire any lists data cache elements
def content_cache_expire_list
logger.warn("Content Cache Expire List: #{self.to_s}") unless RAILS_ENV == 'production'
Expand Down
1 change: 1 addition & 0 deletions app/models/site_module.rb
Expand Up @@ -336,6 +336,7 @@ def options_url

def post_initialization!
if self.status == 'initialized'
self.admin_controller_class.content_node_type_generate
if ( self.admin_controller_class.method_defined?('options') ||
self.admin_controller_class.respond_to?('module_options') )
if self.admin_controller_class.respond_to?('module_options')
Expand Down

0 comments on commit f9edf75

Please sign in to comment.