Ticket #23901: 23901-7.patch
File 23901-7.patch, 1.5 KB (added by , 12 years ago) |
---|
-
wp-admin/js/revisions.js
686 686 */ 687 687 Revision = revisions.model.Revision = Backbone.Model.extend({ 688 688 idAttribute: 'ID', 689 urlRoot: ajaxurl + '?action=revisions-data' + 690 '&show_autosaves=true&show_split_view=true&nonce=' + revisions.model.settings.nonce, 689 691 690 defaults: { 692 691 ID: 0, 693 692 titleTo: '', … … 705 704 706 705 url: function() { 707 706 if ( Diff.singleRevision ) { 708 return this.urlRoot + 707 return ajaxurl + 708 '?action=revisions-data' + 709 '&show_autosaves=true' + 710 '&show_split_view=true' + 711 '&nonce=' + revisions.model.settings.nonce + 709 712 '&single_revision_id=' + this.id + 710 713 '&compare_to=' + this.get( 'previous_revision_id' ) + 711 714 '&post_id=' + revisions.model.settings.post_id; 712 715 } else { 713 716 return this.collection.url() + '&single_revision_id=' + this.id; 714 717 } 715 716 718 } 717 719 }); 718 720 … … 721 723 */ 722 724 Revisions = revisions.Revisions = Backbone.Collection.extend({ 723 725 model: Revision, 724 urlRoot: ajaxurl + '?action=revisions-data',725 726 726 727 initialize: function( models, options ) { 727 728 this.options = _.defaults( options || {}, { … … 736 737 }, 737 738 738 739 url: function() { 739 return this.urlRoot + 740 return ajaxurl + 741 '?action=revisions-data' + 740 742 '&compare_to=' + this.options.compareTo + 741 743 '&post_id=' + this.options.post_id + 742 744 '&show_autosaves=' + this.options.showAutosaves +