r73422 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r73421‎ | r73422 | r73423 >
Date:23:23, 20 September 2010
Author:dale
Status:deferred
Tags:
Comment:
always link to another page for sequence edit
Modified paths:
  • /branches/MwEmbedStandAlone/modules/Sequencer/remotes/mw.MediaWikiRemoteSequencer.js (modified) (history)

Diff [purge]

Index: branches/MwEmbedStandAlone/modules/Sequencer/remotes/mw.MediaWikiRemoteSequencer.js
@@ -105,23 +105,21 @@
106106 }
107107
108108 if(! $j( '#' + embedPlayerId ).siblings( '.kalturaEditOverlay' ).length ){
109 - var editLink = '#';
110 - if( ! mw.isLocalDomain( mw.getApiProviderURL( embedPlayer.apiProvider ) ) ) {
111 - var seqTitle = embedPlayer.apiTitleKey
112 - .replace( 'Sequence-', 'Sequence:')
113 - // strip the extension
114 - seqTitle = seqTitle.substr(0, seqTitle.length -4 );
115 - // not ideal details page builder but 'should work' ::
116 - editLink = mw.getApiProviderURL( embedPlayer.apiProvider ).replace( 'api.php', 'index.php' );
117 - editLink = mw.getRemoteSequencerLink (
118 - mw.replaceUrlParams( editLink,
119 - {
120 - 'title' : seqTitle,
121 - 'action' : 'edit'
122 - }
123 - )
124 - );
125 - }
 109+
 110+ var seqTitle = embedPlayer.apiTitleKey
 111+ .replace( 'Sequence-', 'Sequence:')
 112+ // strip the extension
 113+ seqTitle = seqTitle.substr(0, seqTitle.length -4 );
 114+ // not ideal details page builder but 'should work' ::
 115+ var editLink = mw.getApiProviderURL( embedPlayer.apiProvider ).replace( 'api.php', 'index.php' );
 116+ editLink = mw.getRemoteSequencerLink (
 117+ mw.replaceUrlParams( editLink,
 118+ {
 119+ 'title' : seqTitle,
 120+ 'action' : 'edit'
 121+ }
 122+ )
 123+ );
126124 var kalturaLinkAttr = {
127125 'href': 'http://kaltura.com',
128126 'target' : '_new',

Status & tagging log