MOBILE-3068 blocks: Don't use phantom tabs in title blocks
parent
43d6839a8d
commit
344a3c639f
|
@ -13,8 +13,9 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Injector, OnInit, Component } from '@angular/core';
|
import { Injector, OnInit, Component } from '@angular/core';
|
||||||
|
import { NavController } from 'ionic-angular';
|
||||||
import { CoreBlockBaseComponent } from '../../classes/base-block-component';
|
import { CoreBlockBaseComponent } from '../../classes/base-block-component';
|
||||||
import { CoreLoginHelperProvider } from '@core/login/providers/helper';
|
import { CoreContentLinksHelperProvider } from '@core/contentlinks/providers/helper';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component to render blocks with only a title and link.
|
* Component to render blocks with only a title and link.
|
||||||
|
@ -25,11 +26,8 @@ import { CoreLoginHelperProvider } from '@core/login/providers/helper';
|
||||||
})
|
})
|
||||||
export class CoreBlockOnlyTitleComponent extends CoreBlockBaseComponent implements OnInit {
|
export class CoreBlockOnlyTitleComponent extends CoreBlockBaseComponent implements OnInit {
|
||||||
|
|
||||||
protected loginHelper: CoreLoginHelperProvider;
|
constructor(injector: Injector, protected navCtrl: NavController, protected linkHelper: CoreContentLinksHelperProvider) {
|
||||||
|
|
||||||
constructor(injector: Injector) {
|
|
||||||
super(injector, 'CoreBlockOnlyTitleComponent');
|
super(injector, 'CoreBlockOnlyTitleComponent');
|
||||||
this.loginHelper = injector.get(CoreLoginHelperProvider);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -45,6 +43,6 @@ export class CoreBlockOnlyTitleComponent extends CoreBlockBaseComponent impleme
|
||||||
* Go to the block page.
|
* Go to the block page.
|
||||||
*/
|
*/
|
||||||
gotoBlock(): void {
|
gotoBlock(): void {
|
||||||
this.loginHelper.redirect(this.link, this.linkParams);
|
this.linkHelper.goInSite(this.navCtrl, this.link, this.linkParams, undefined, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue