public
Fork of astashov/page_versioning
Description: Extension for the Radiant CMS. Allows you to save and review all changes of the pages, snippets and layouts.
Homepage:
Clone URL: git://github.com/jeffrydegrande/page_versioning.git
Anton Astashov (author)
Fri May 15 22:32:49 -0700 2009
commit  53a6372d8dec89f00f156f6cce37da99cb9a91de
tree    f6069d69f308862966f3fa9eaff5d5519830b7e4
parent  0da43d464d0b8bcf84d048b9437a932c49dbd8fe
name age message
file LICENSE Mon Oct 27 04:19:36 -0700 2008 Initial import [Anton Astashov]
file README Loading commit data...
file Rakefile Mon Oct 27 04:19:36 -0700 2008 Initial import [Anton Astashov]
directory app/
directory config/ Wed Feb 25 23:31:28 -0800 2009 Switched 'publish_new_version' to true by defau... [Anton Astashov]
directory db/ Sun Feb 15 23:25:46 -0800 2009 Fixed extension for work with Radiant >= v0.7. ... [Anton Astashov]
directory lib/
file page_versioning_extension.rb
directory spec/
README
WARNING!!! For the RadiantCMS < v0.7.0 please use 0.6.9 tag.

== Page Versioning
 
This extension creates versioning for pages, snippets and layouts.
 
== Features:
 
 * All revisions are saved in separate tables, without affecting the 'pages', 
   'layouts' and 'snippets' tables.
 * Pages save their state with page parts.
 * You can set the fields you want to version in a config file.
   (vendor/extensions/page_versioning/config/config.yml)
 
== Installation
 
(from the radiant application root)
  
  git clone git://github.com/astashov/page_versioning.git vendor/extensions/page_versioning
  rake RAILS_ENV=production db:migrate:extensions
 
== Configuration
 
When you update any of the fields on Pages, Layouts or Snippets, they will create a new
revision.
This behavior can be configured in vendor/extensions/page_versioning/config/config.yml
 
There are two types of settings:
1. something_attributes - if user changes this attribute, new revision will be 
   created
2. something_specific_attributes - these attributes will not be replaced by 
   revisioned attributes after initializing
 
== Using the extension
 
To enable versioning you should install the plugin. Then, when you add changes to a Page, Snippet or Layout,
there will be 3 additional controls:
 
1. Revision select box - you can change revision you want to see.
2. Published revision select box - you can set what revision you want to use as 
   published. Published revision will be shown to visitors. You can set publish
   new revision by default or not in vendor/extensions/page_versioning/config/config.yml
3. Preview button - if you want to look at changes, but don't want to publish 
   them, you can press the Preview button. A new revision will be created, and you will
   be redirected to the homepage where you can see your changes, but this revision will not
   be published and visitors will not see your changes.
 
On the Snippet Edit Page or Layout Edit Page, you can see the Preview button with its select box. To preview a
snippet, the snippet should be inserted in a Layout or Page Part. With the select box
you can select a page or layout and preview changes of that snippet in the selected page/layout.
The same goes for layouts -- you can preview the changes by specifying the page to use for viewing.
 
== Screenshots

Here you can see screenshot of the plugin: http://astashov.net/images/radiant_page_versioning.png

== Additional info
 
Sometimes you might need to disable the after_initialize hook, which changes attributes 
to attributes of published revision. You can do this by setting a flag 
PageVersioning.enable_versioning = false (default is false for testing environment,
others are true).

== Bugreporting

Please, post bugs here: http://astashov.lighthouseapp.com/projects/18817-page-versioning
 
== Authors and Credits
 
Written by Anton Astashov, with Brenton Cheng, for Astrology.com (a division of iVillage Inc.)