Really cool, but no versioning within the backend...
With the following patch also new version created in the backend are stored in the content_backup table:
Index: administrator/components/com_content/admin.content.php
===================================================================
658a659
> $isNew = true;
661a663
> $isNew = false;
719a722,746
> if ( !$isNew ) {
> $database->setQuery("SELECT * FROM #__content WHERE id =".$row->id);
> $contents = $database->loadAssocList();
> if (isset($contents[0])) {
> if ($database -> getErrorNum()) {
> echo $database -> stderr();
> return false;
> }
> $content=$contents[0];
> $row = new mosContentBackup($database);
>
> // bind it to the table
> if (!$row ->bind($content)) {
> echo " alert('"
> .$row -> getError()
> ."'); window.history.go(-1); \n";
> exit();
> }
> $row->checked_out = 0;
> $row->checked_out_time = 0;
> // store it in the db
> $row ->storeBackup();
> }
> }
>
Index: components/com_content/content.php
===================================================================
Index: includes/joomla.php
===================================================================
2491a2492,2569
> class mosContentBackup extends mosDBTable {
> /** @var int Primary key */
> var $id = null;
> /** @var string */
> var $title = null;
> /** @var string */
> var $title_alias = null;
> /** @var string */
> var $introtext = null;
> /** @var string */
> var $fulltext = null;
> /** @var int */
> var $state = null;
> /** @var int The id of the category section*/
> var $sectionid = null;
> /** @var int DEPRECATED */
> var $mask = null;
> /** @var int */
> var $catid = null;
> /** @var datetime */
> var $created = null;
> /** @var int User id*/
> var $created_by = null;
> /** @var string An alias for the author*/
> var $created_by_alias = null;
> /** @var datetime */
> var $modified = null;
> /** @var int User id*/
> var $modified_by = null;
> /** @var boolean */
> var $checked_out = null;
> /** @var time */
> var $checked_out_time = null;
> /** @var datetime */
> var $frontpage_up = null;
> /** @var datetime */
> var $frontpage_down = null;
> /** @var datetime */
> var $publish_up = null;
> /** @var datetime */
> var $publish_down = null;
> /** @var string */
> var $images = null;
> /** @var string */
> var $urls = null;
> /** @var string */
> var $attribs = null;
> /** @var int */
> var $version = null;
> /** @var int */
> var $parentid = null;
> /** @var int */
> var $ordering = null;
> /** @var string */
> var $metakey = null;
> /** @var string */
> var $metadesc = null;
> /** @var int */
> var $access = null;
> /** @var int */
> var $hits = null;
>
> /**
> * @param database A database connector object
> */
> function mosContentBackup( &$db ) {
> $this->mosDBTable( '#__content_backup', 'id,version', $db );
> }
>
> function storeBackup( $updateNulls=false ) {
> $ret = $this->_db->insertObject( $this->_tbl, $this, $this->_tbl_key );
> }
> }
>
> /**
> * Module database table class
> * @package Joomla
> */