public
Fork of halorgium/mephisto
Description: A mirror of the mephisto code-base
Homepage: http://mephistoblog.com/
Clone URL: git://github.com/technoweenie/mephisto.git
Click here to lend your support to: mephisto and make a donation at www.pledgie.com !
minor fixes

git-svn-id: http://svn.techno-weenie.net/projects/mephisto/trunk@1344 
567b1171-46fb-0310-a4c9-b4bef9110e78
technoweenie (author)
Mon Jul 10 07:07:23 -0700 2006
commit  649b156e77c6520e345756cc547bba9035d2246c
tree    e52b04707de59b9d51753c3689a708e0a6bc336f
parent  d9bacab5fb5b1afb53470f02e00557475541848a
...
31
32
33
34
35
36
37
38
39
40
41
42
 
 
 
 
 
 
 
 
 
 
43
44
45
46
...
31
32
33
 
 
 
 
 
 
 
 
 
34
35
36
37
38
39
40
41
42
43
44
 
45
46
0
@@ -31,15 +31,15 @@ class ArticleSweeper < ActionController::Caching::Sweeper
0
   alias after_destroy after_save
0
 
0
   protected
0
- def expire_overview_feed!
0
- controller.class.expire_page overview_url(:only_path => true, :skip_relative_url_root => true) if controller
0
- end
0
-
0
- def expire_assigned_sections!(record)
0
- record.send :save_assigned_sections
0
- record.sections.each do |section|
0
- controller.expire_page :sections => section.to_url, :controller => '/mephisto', :action => 'list'
0
- controller.expire_page :sections => section.to_feed_url, :controller => '/feed', :action => 'feed'
0
+ def expire_overview_feed!
0
+ controller.class.expire_page overview_url(:only_path => true, :skip_relative_url_root => true) if controller
0
+ end
0
+
0
+ def expire_assigned_sections!(record)
0
+ record.send :save_assigned_sections
0
+ record.sections.each do |section|
0
+ controller.expire_page :sections => section.to_url, :controller => '/mephisto', :action => 'list'
0
+ controller.expire_page :sections => section.to_feed_url, :controller => '/feed', :action => 'feed'
0
+ end
0
     end
0
- end
0
 end
0
\ No newline at end of file
...
23
24
25
26
27
28
29
30
31
32
 
 
 
 
 
 
 
33
...
23
24
25
 
 
 
 
 
 
 
26
27
28
29
30
31
32
33
0
@@ -23,11 +23,11 @@ class Admin::TemplatesController < Admin::BaseController
0
   end
0
 
0
   protected
0
- # @template var clashes with ActionView instance, so use @tmpl
0
- # Selects all templates for sidebar
0
- # Create system template if it does not exist
0
- def select_template
0
- @tmpl = @templates.detect { |t| t.filename == params[:id] }
0
- @tmpl ||= site.templates.find_or_create_by_filename(params[:id]) if Template.template_types.include?(params[:id].to_sym)
0
- end
0
+ # @template var clashes with ActionView instance, so use @tmpl
0
+ # Selects all templates for sidebar
0
+ # Create system template if it does not exist
0
+ def select_template
0
+ @tmpl = @templates.detect { |t| t.filename == params[:id] }
0
+ @tmpl ||= site.templates.find_or_create_by_filename(params[:id]) if Template.template_types.include?(params[:id].to_sym)
0
+ end
0
 end
...
1
2
3
 
 
 
 
4
5
 
 
 
6
7
8
9
10
...
 
 
 
1
2
3
4
5
 
6
7
8
9
 
10
11
12
0
@@ -1,10 +1,12 @@
0
-class OldTemplate < ActiveRecord::Base
0
- set_table_name 'templates'
0
-end
0
+class AddAssetsAndResources < ActiveRecord::Migration
0
+ class OldTemplate < ActiveRecord::Base
0
+ set_table_name 'templates'
0
+ end
0
 
0
-Template.set_table_name 'assets'
0
+ class Template < ActiveRecord::Base
0
+ set_table_name 'assets'
0
+ end
0
 
0
-class AddAssetsAndResources < ActiveRecord::Migration
0
   def self.up
0
     create_table :assets, :force => true do |t|
0
       t.column :type, :string, :limit => 15
...
1
2
 
 
 
 
3
4
5
...
 
1
2
3
4
5
6
7
8
0
@@ -1,5 +1,8 @@
0
-Template.set_table_name 'attachments'
0
 class AddSectionAttributes < ActiveRecord::Migration
0
+ class Template < ActiveRecord::Base
0
+ set_table_name 'attachments'
0
+ end
0
+
0
   def self.up
0
     add_column :sections, :articles_per_page, :integer, :default => 15
0
     add_column :sections, :layout, :string

Comments

    No one has commented yet.