chore: fix the logic for goback button in stage component
Some checks failed
Build / Build-and-ng-test (pull_request) Failing after 13s
Some checks failed
Build / Build-and-ng-test (pull_request) Failing after 13s
This commit is contained in:
parent
731b96dccc
commit
482c7455f5
@ -7,6 +7,7 @@ import { EventService } from '../services/event.service'
|
||||
import { AppService } from '../services/app.service'
|
||||
import { HotTableInterface } from '../models/HotTable.interface'
|
||||
import { LicenceService } from '../services/licence.service'
|
||||
import { globals } from '../_globals'
|
||||
|
||||
@Component({
|
||||
selector: 'app-stage',
|
||||
@ -55,7 +56,15 @@ export class StageComponent implements OnInit {
|
||||
}
|
||||
|
||||
public goBack() {
|
||||
this.route.navigateByUrl('/editor/' + this.tableDetails.BASE_TABLE)
|
||||
const xlmap = globals.xlmaps.find(
|
||||
(xlmap) => xlmap.targetDS === this.tableDetails.BASE_TABLE
|
||||
)
|
||||
if (xlmap) {
|
||||
const id = this.hotTable.data[0].XLMAP_ID
|
||||
this.route.navigateByUrl('/home/files/' + id)
|
||||
} else {
|
||||
this.route.navigateByUrl('/editor/' + this.tableDetails.BASE_TABLE)
|
||||
}
|
||||
}
|
||||
|
||||
public download(id: any) {
|
||||
|
Loading…
Reference in New Issue
Block a user