Skip to content

Feature/revisions#1120

Merged
KingYes merged 78 commits intoelementor:feature/revisionsfrom
kobizz:feature/revisions
Jan 9, 2017
Merged

Feature/revisions#1120
KingYes merged 78 commits intoelementor:feature/revisionsfrom
kobizz:feature/revisions

Conversation

@kobizz
Copy link
Copy Markdown
Contributor

@kobizz kobizz commented Jan 5, 2017

No description provided.

matipojo and others added 30 commits December 12, 2016 18:13
…ture/revisions

# Conflicts:
#	assets/css/editor-rtl.min.css
#	assets/css/editor.min.css
#	assets/js/editor.js
#	assets/js/editor.min.js
#	includes/db.php
Feature/revisions - Merge from release/1.0.10
setEditorData: function( data ) {
var collection = elementor.getRegion( 'sections' ).currentView.collection;

collection.reset();
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use just reset method

},
success: function( data ) {
if ( data.last_revision ) {
elementor.revisions.addRevision( data.last_revision );
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do re-calc of ids

} );
},

enterPreviewMode: function() {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change method name

elementor.changeEditMode( 'review' );
},

exitPreviewMode: function() {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change method name


self.currentPreviewId = id;

this.jqueryXhr = elementor.ajax.send( 'get_revision_preview', {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change AJAX name


onChildviewDetailsAreaClick: function( childView ) {
var self = this,
id = childView.model.get( 'id' );
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to revisionId


var title = 'preview' === currentMode ? 'Back to Editor' : 'Preview';
onEditModeChanged: function( newMode ) {
var title = 'preview' === newMode ? 'Back to Editor' : 'Preview';
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add i18n for this

<script type="text/template" id="tmpl-elementor-panel-revisions-revision-item">
<div class="elementor-revision-item__gravatar">{{{ gravatar }}}</div>
<div class="elementor-revision-item__details">
<div class="elementor-revision-date">{{ date }}</div>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to {{{ }}}

] );

if ( $autosave_id ) {
update_metadata( 'post', $autosave_id, '_elementor_data', $json_value );
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please write comment

includes/db.php Outdated
$value = wp_slash( $value );
}

if ( $update ) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just use with update_metadata

],
'default_schemes' => $plugin->schemes_manager->get_schemes_defaults(),
'revisions' => Revisions_Manager::get_revisions(),
'revisions_to_keep' => wp_revisions_to_keep( get_post() ),
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this line

@KingYes KingYes merged commit 0aeae47 into elementor:feature/revisions Jan 9, 2017
@arielk arielk mentioned this pull request Jan 23, 2017
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants