Need to change tab when a button in another tab is clicked
- Lingua principale
- TypeScript
- Stelle
- 8.1k
- Fork
- 1.5k
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Hi, so I have a nb-tab which contains a ng2-smart-table.
In the table there is a column with a button:
```typescript
id: {
title: 'Facility Rules',
type: 'custom',
renderComponent: ButtonRenderComponent,
onComponentInitFunction(instance) {
instance.save.subscribe();
}
}
```
```typescript
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
@Component({
template: `click me`,
selector: 'button-render',
providers: []
})
export class ButtonRenderComponent implements OnInit {
@Input() value: string | number;
@Input() rowData: any;
@Output() save: EventEmitter = new EventEmitter();
ngOnInit(): void {
console.log(this.value)
}
onClick() {
// something to auto change tab
}
}
```
What I want is to auto change tab when this button is clicked.
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.