Changeset 702

Show
Ignore:
Timestamp:
01/24/08 10:57:36 (7 months ago)
Author:
lorenjohnson
Message:

Event Calendar 0.7 -- Documentation updates

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/extensions/event_calendar/README

    r701 r702  
    1 = Event Calendar (iCal) Extension for Radiant 
     1= Event Calendar (iCal) Extension for Radiant = 
    22 
    33Created by: Loren Johnson - www.hellovenado.com 
     
    66 
    77 
    8 INSTALLATION  
     8== INSTALLATION ==  
     9* Req'd Radiant Version: 0.6.4+ (not tested with earlier versions, may work with all 0.6+) 
    910 
    10111. Checkout extension to the vendor/extensions directory of your Radiant app using svn (you may have already done this):  
     
    1213  svn co http://svn.fn-group.com/radiant_extensions/event_calendar 
    1314 
    14 2. Install VPIM iCal/vCal parsing gem: gem install vpim 
     152. Install the VPIM iCal/vCal parsing gem: gem install vpim 
    1516 
    16 3. Copy extension public assets to Radiant public directory. Currently this will create the default public/icals directory which is required 
     173. Migrate extensions: rake db:migrate:extensions 
     18 
     194. Copy extension public assets to Radiant public directory. Currently this will create the default public/icals directory which is required 
    1720as a home for the cached ical subscription files, this is configurable via Radiant::Config["event_calendar.icals_path"]: 
    1821 
    1922  rake radiant:extensions:event_calendar:update 
    2023 
    21 4. Migrate extensions: rake db:migrate:extensions 
    22  
    23 5. From Admin navigate to your new "Event Calendars" tab and click "Add a Calendar", enter your iCal subscription URL at this point and press Save. 
     245. From Admin navigate to your new "Event Calendars" tab and click "Add a Calendar", enter your iCal subscription URL and name for the calendar and press Save. 
    2425 
    25266. You can now manually refresh the calendar from the subscription once you've saved it by clicking on the Refresh link.  
    26 You may wish to setup a cron job to do this for you automatically: script/runner -e production "Calendar::refresh_all" 
    2727 
    2828 
    29 NOTES 
     29== AN EXAMPLE EVENT-CALENDAR IMPLEMENTATION == 
    3030 
    31 * The handling of all paths below the node where the Event Calendar Page type gets applied are overridden to capture the calendar "category" and "slug".  
    32 So, if you create a page under Root > Calendar and apply the EventCalendar page type to it, then through admin create a calendar with the category of  
    33 "master" and a name of "youth" you'll be able to access your calendar at http://yoursite.com/calendar/master/youth. Also, you'll also be able to see  
    34 events for all calendars with a category of "master" by navigating to http://yoursite.com/calendar/master/all.  
     311. Create a new Calendar under the EventCalendar tab in admin entering at minimum a Name and iCal URL 
    3532 
    36 * For add'l documentation please refer to the Radiant tag reference for the <r:calendar /> tag series. 
    37    
     332. Click on the "Refresh" link for the calendar after it's been successfuly created to download all the events from the iCal subscription 
    3834 
     353. Create a new page and select EventCalendar as the Page Type 
    3936 
    40 AN EXAMPLE EVENT-CALENDAR IMPLEMENTATION 
    41 ** The EventCalendar tag library has been refactored (they make more sense now) and a couple of the tags in this example are no longer valid.  
    42 ** I'll update the example shortly but until then please refer to the tag documentation under "Available Tags" when creating/editing a page in Radiant. 
     374. Paste the following code in the body page part then save the page 
    4338 
    4439<r:calendar> 
     
    4742      <td> 
    4843        <ul> 
    49           <li><r:calendar:nav:week_link class="navLink" /></li>  
    50           <li><r:calendar:nav:month_link class="navLink" /></li> 
    51           <li><r:calendar:nav:year_link class="navLink" /></li> 
    52          </ul> 
     44          <r:nav> 
     45            <li><r:week_link class="navLink" /></li>  
     46            <li><r:month_link class="navLink" /></li> 
     47            <li><r:year_link class="navLink" /></li> 
     48          </r:nav> 
     49       </ul> 
    5350      </td> 
    5451    </tr> 
     
    7875          <td> 
    7976           <div id="detail<r:id />" class="detail"> 
    80              <r:timeperiod format="%I:%M %p" /><br /> 
     77             <r:daterange format="%I:%M %p" /><br /> 
    8178             <r:location /><br /> 
    8279             <r:description /> 
     
    9087</r:calendar> 
    9188 
     895. Navigate to the newly created page within the public site  
     90            
     91 
     92== NOTES == 
     93 
     94* The handling of all paths below the node an EventCalendar Page are overridden to capture the calendar "category" and "slug".  
     95So, if you create a page under Home > Calendar and apply the EventCalendar page type to it, and through admin create a calendar with the category of  
     96"master" and a name of "youth" you'll be able to access your calendar at http://yoursite.com/calendar/master/youth. Also, you'll also be able to see  
     97events for all calendars with a category of "master" by navigating to http://yoursite.com/calendar/master/all.  
     98 
     99* For add'l documentation please refer to the Radiant tag reference (the "Available tags" link within Page edit) for the <r:calendar /> tag series,  
     100you'll only see the Calendar tag documentation available when editing a page that has already been saved as the EventCalendar Page Type. 
     101 
     102* Please refer to the tag documentation under "Available Tags" when editing a page in Radiant (page must be already created and of EventCalendar type). 
     103 
     104* If you wish to setup a Cron job to automatically keep you Radiant calendar in-sync with the iCal feed have Cron run the following from within the root  
     105of your Radiant application: script/runner -e production "Calendar::refresh_all" 
    92106 
    93107 
    94 ROADMAP 
     108== DEVELOPMENT ROADMAP == 
    95109 
    96110* Single page view for each Event, possibly adding ability to associate an Event with a particular Radiant page also. 
  • trunk/extensions/event_calendar/app/models/event_calendar_tags.rb

    r700 r702  
    199199           Usage: 
    200200           <pre><code> 
    201            <r:calendar:event:each:timeperiod format="" separator="" /> 
     201           <r:calendar:event:each:daterange format="" separator="" /> 
    202202           </code></pre>} 
    203203   tag "calendar:event:each:daterange" do |tag|