improve go back

This commit is contained in:
Peter Maquiran
2022-01-06 14:47:22 +01:00
parent be06d3b3d1
commit 73354e00af
28 changed files with 153 additions and 58 deletions
@@ -9,7 +9,7 @@ import { Location } from '@angular/common';
import { SqliteService } from 'src/app/services/sqlite.service';
import { BackgroundService } from 'src/app/services/background.service';
import { ThemeService } from 'src/app/services/theme.service'
import { RouteService } from 'src/app/services/route.service';
@Component({
selector: 'app-publication-detail',
@@ -28,7 +28,7 @@ export class PublicationDetailPage implements OnInit {
private publications:PublicationsService,
private animationController: AnimationController,
private toastService: ToastService,
private location: Location,
private RouteService: RouteService,
private sqliteservice: SqliteService,
private backgroundservice: BackgroundService,
public ThemeService: ThemeService ) {
@@ -88,7 +88,7 @@ export class PublicationDetailPage implements OnInit {
}
close() {
this.location.back()
this.RouteService.goBack()
}
@@ -9,7 +9,7 @@ import { NewPublicationPage } from '../../new-publication/new-publication.page';
import { Location } from '@angular/common';
import { ThemeService } from 'src/app/services/theme.service'
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
import { RouteService } from 'src/app/services/route.service';
@Component({
selector: 'app-publication-detail',
@@ -30,7 +30,7 @@ export class PublicationDetailPage implements OnInit {
private toastService: ToastService,
private activatedRoute: ActivatedRoute,
private router: Router,
private location: Location,
private RouteService: RouteService,
public ThemeService: ThemeService
) {
@@ -100,7 +100,7 @@ export class PublicationDetailPage implements OnInit {
this.close()
} else {
// alert('go back')
this.location.back();
this.RouteService.goBack();
}
}