public function afterVersionedSave()
    {
        if ($this->wasDirty && static::$createRevisionOnSave) {
            // save a copy to history table
            $recordValues = $this->_prepareRecordValues();
            $set = static::_mapValuesToSet($recordValues);
            DB::nonQuery(
                'INSERT INTO `%s` SET %s',
                [
                    static::getHistoryTable(),
                    join(',', $set),
                ]
            );
        }
    }
public function afterVersionedSave()
    {
        if ($this->wasDirty && static::$createRevisionOnSave) {
            // save a copy to history table
            $recordValues = $this->_prepareRecordValues();
            $set = static::_mapValuesToSet($recordValues);
            DB::nonQuery(
                'INSERT INTO `%s` SET %s',
                [
                    static::getHistoryTable(),
                    join(',', $set),
                ]
            );
        }
    }
public function afterVersionedSave ( ) { if ( $ this -> wasDirty && static :: $ createRevisionOnSave ) { // save a copy to history table $ recordValues = $ this -> _prepareRecordValues ( ) ; $ set = static :: _mapValuesToSet ( $ recordValues ) ; DB :: nonQuery ( 'INSERT INTO `%s` SET %s' , [ static :: getHistoryTable ( ) , join ( ',' , $ set ) , ] ) ; } }
After save to regular database this saves to the history table

@return void
After save to regular database this saves to the history table