Robert Vogel has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/356331 )
Change subject: Fix for missing blog segment on Special:RSS_Feeder ...................................................................... Fix for missing blog segment on Special:RSS_Feeder On Special:RSS_Feeder there should be "Blog", this wasnt working because wrong function is passed to registerFeed to create it Its strange to me that evidently this functionality existed it the past, but i had to implement js part all over again. I wonder if this functionality was removed intentionaly, or planned to reimplement in a different way I hope the german message is ok ERM: #6407 Needs cherry-picking to REL1_27 and REL1_23 Change-Id: I08d509bf2e98203bbe9271d2dcee78c94d1e9d79 --- M Blog/Blog.class.php M Blog/extension.json M Blog/i18n/de.json M Blog/i18n/en.json M Blog/i18n/qqq.json A Blog/resources/bluespice.blog.rssfeeder.integration.js 6 files changed, 32 insertions(+), 7 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions refs/changes/31/356331/1 diff --git a/Blog/Blog.class.php b/Blog/Blog.class.php index 197ec38..375144c 100644 --- a/Blog/Blog.class.php +++ b/Blog/Blog.class.php @@ -128,7 +128,11 @@ * @return bool */ public function onBeforePageDisplay( &$oOutputPage, &$oSkin ) { - $oOutputPage->addModuleStyles( 'ext.bluespice.blog' ); + $oOutputPage->addModuleStyles( 'ext.bluespice.blog.styles' ); + + if( $oOutputPage->getTitle()->isSpecial( 'RSSFeeder' ) ) { + $oOutputPage->addModules( 'ext.bluespice.blog.rssfeeder.integration' ); + } return true; } @@ -687,7 +691,7 @@ $this, 'buildRssNsBlog', null, - 'buildRssNsBlog' + 'buildLinksNs' ); return true; } @@ -724,7 +728,7 @@ $oChannel = RSSCreator::createChannel( RSSCreator::xmlEncode( $wgSitename . ' - ' . $sPageName ), - 'http://'.$_SERVER['HTTP_HOST'].$_SERVER['PHP_SELF'], wfMessage( 'bs-rssstandards-description_page' )->plain() + 'http://'.$_SERVER['HTTP_HOST'].$_SERVER['PHP_SELF'], wfMessage( 'bs-blog-rss-desc-blog' )->plain() ); $oTitle = Title::makeTitle( $iNSid , 'Blog' ); diff --git a/Blog/extension.json b/Blog/extension.json index 9e4d03f..cd63579 100644 --- a/Blog/extension.json +++ b/Blog/extension.json @@ -34,7 +34,13 @@ "SpecialBlog": "includes/specials/SpecialBlog.class.php" }, "ResourceModules": { - "ext.bluespice.blog": { + "ext.bluespice.blog.rssfeeder.integration": { + "scripts": "bluespice.blog.rssfeeder.integration.js", + "dependencies": [ + "ext.bluespice.extjs" + ] + }, + "ext.bluespice.blog.styles": { "styles": "bluespice.blog.less" } }, diff --git a/Blog/i18n/de.json b/Blog/i18n/de.json index 8528c52..83f9968 100644 --- a/Blog/i18n/de.json +++ b/Blog/i18n/de.json @@ -36,5 +36,6 @@ "bs-blog-tag-blogtime-desc": "Fügt einen selbstdefinierten Zeitstempel zur Anzeige und Sortierung in Blogbeiträgen ein. Das Format ist JJJJMMTTSSmm.", "bs-blog-tag-blogtime-err": "Das Format ist YYYYMMDDHHmm, d. h. für den 12. Jan. 2013 15:43 muss der Zeitstempel wie folgt angegeben sein: 201301121543", "bs-tag-blog": "das Blog-Tag", - "action-blog-viewspecialpage": "die Spezialseite „{{int:bs-blog-blog}}“ anzusehen" + "action-blog-viewspecialpage": "die Spezialseite „{{int:bs-blog-blog}}“ anzusehen", + "bs-blog-rss-desc-blog": "Überblick über die Blogeinträge" } diff --git a/Blog/i18n/en.json b/Blog/i18n/en.json index a0777a9..7667ea4 100644 --- a/Blog/i18n/en.json +++ b/Blog/i18n/en.json @@ -34,5 +34,6 @@ "bs-blog-tag-blogtime-desc": "Inserts a self defined time stamp for display and sorting in blog posts. The format is YYYYMMDDHHmm.", "bs-blog-tag-blogtime-err": "The format has to be YYYYMMDDHHmm i.e. for 12. Jan. 2013 15:43 the timestamps looks like: 201301121543", "bs-tag-blog": "the blog tag", - "action-blog-viewspecialpage":"view the special page \"{{int:bs-blog-blog}}\"" + "action-blog-viewspecialpage":"view the special page \"{{int:bs-blog-blog}}\"", + "bs-blog-rss-desc-blog": "Feed with an overview over the blog entries" } diff --git a/Blog/i18n/qqq.json b/Blog/i18n/qqq.json index bd51246..716da02 100644 --- a/Blog/i18n/qqq.json +++ b/Blog/i18n/qqq.json @@ -38,5 +38,6 @@ "bs-blog-tag-blogtime-desc": "Used in InsertMagic extension, tag description for setting blog timestamp on every page.\n{{Related|Bs-tag-desc}}", "bs-blog-tag-blogtime-err": "Error message on bs:blog:time tag when there is a wrong timestamp format.\nShould be YYYYMMDDHHmm (YmdHi).", "bs-tag-blog": "Name of the descriptor used in [[Special:UsageTracker|Special:UsageTracker]] output", - "action-blog-viewspecialpage": "placeholder to describe that view of special page \"{{int:bs-blog-blog}}\" is restricted for the current user\n\n{{Doc-action|blog-viewspecialpage}}" + "action-blog-viewspecialpage": "placeholder to describe that view of special page \"{{int:bs-blog-blog}}\" is restricted for the current user\n\n{{Doc-action|blog-viewspecialpage}}", + "bs-blog-rss-desc-blog": "Description of blog entry RSS feed" } diff --git a/Blog/resources/bluespice.blog.rssfeeder.integration.js b/Blog/resources/bluespice.blog.rssfeeder.integration.js new file mode 100644 index 0000000..262554e --- /dev/null +++ b/Blog/resources/bluespice.blog.rssfeeder.integration.js @@ -0,0 +1,12 @@ +Ext.onReady( function() { + var button = Ext.get( 'btnFeedNsBlog' ); + var combo = Ext.get( 'selFeedNsBlog' ); + + if( button && combo ) { + button.addListener( 'click', function() { + location.href = combo.getValue(); + }); + } +}); + + -- To view, visit https://gerrit.wikimedia.org/r/356331 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I08d509bf2e98203bbe9271d2dcee78c94d1e9d79 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions Gerrit-Branch: REL1_27 Gerrit-Owner: Robert Vogel <vo...@hallowelt.biz> Gerrit-Reviewer: ItSpiderman <d.savulje...@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits