Development

Changeset 16689

You must first sign up to be able to contribute.

Changeset 16689

Show
Ignore:
Timestamp:
03/28/09 17:20:07 (4 years ago)
Author:
Jonathan.Wage
Message:

[1.0] sfSympalBlogPlugin: Updating sympal plugin for r16688

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • plugins/sfSympalBlogPlugin/trunk/config/sfSympalBlogPluginConfiguration.class.php

    r16581 r16689  
    88      'sfSympalUserProfilePlugin', 
    99    ); 
    10  
    11   public function install($installVars, $invoker) 
    12   { 
    13     $installVars['content']['BlogPost']['title'] = 'Sample Sympal Blog Post'; 
    14     $installVars['content']['BlogPost']['teaser'] = 'This is the teaser line for the sample blog post'; 
    15     $installVars['content']->save(); 
    16     $installVars['contentType']->save(); 
    17  
    18     $menuItem = new MenuItem(); 
    19     $menuItem->name = 'Blog'; 
    20     $menuItem->is_published = true; 
    21     $menuItem->label = 'Blog'; 
    22     $menuItem->ContentType = $installVars['contentType']; 
    23     $menuItem->is_content_type_list = true; 
    24  
    25     $invoker->addToMenu($menuItem); 
    26  
    27     $contentTemplate = new ContentTemplate(); 
    28     $contentTemplate->name = 'View BlogPost'; 
    29     $contentTemplate->type = 'View'; 
    30     $contentTemplate->ContentType = $installVars['contentType']; 
    31     $contentTemplate->partial_path = 'sympal_blog/view'; 
    32     $contentTemplate->save(); 
    33  
    34     $contentTemplate = new ContentTemplate(); 
    35     $contentTemplate->name = 'List BlogPost'; 
    36     $contentTemplate->type = 'List'; 
    37     $contentTemplate->ContentType = $installVars['contentType']; 
    38     $contentTemplate->partial_path = 'sympal_blog/list'; 
    39     $contentTemplate->save(); 
    40   } 
    4110} 
  • plugins/sfSympalBlogPlugin/trunk/data/fixtures/install.yml

    r16581 r16689  
    11# sfSympalBlogPlugin install data fixtures 
    2  
    3 ContentType: 
    4   ContentType_blog: 
    5     name: BlogPost 
    6     label: BlogPost 
    7     slug: blog 
    8     list_path: /blog/list 
    9     view_path: /blog/:slug 
    10  
    11 Content: 
    12   BlogPost_content_sample: 
    13     Type: ContentType_blog 
    14     slug: sample-blog 
    15     Site: Site_default 
    16     is_published: true 
    17     CreatedBy: admin 
    18  
    19 ContentTemplate: 
    20   ContentTemplate_ViewBlogPost: 
    21     name: View BlogPost 
    22     type: View 
    23     ContentType: ContentType_blog 
    24     partial_path: sympal_blog/view 
    25   ContentTemplate_ListBlogPost: 
    26     name: List BlogPost 
    27     type: List 
    28     ContentType: ContentType_blog 
    29     partial_path: sympal_blog/list 
    30  
    31 BlogPost: 
    32   BlogPost_sample: 
    33     title: Sample BlogPost 
    34     teaser: This is some sample content for the teaser your new content type. 
    35     Content: BlogPost_content_sample 
    36  
    37 MenuItem: 
    38   MenuItem_primary: 
    39     children: 
    40       Menuitem_primary_blog: 
    41         name: Blog 
    42         is_published: true 
    43         label: Blog 
    44         is_content_type_list: true 
    45         Site: Site_default 
    46         ContentType: ContentType_blog