mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
parent
6af1bfab56
commit
0d07ba1a1e
1 changed files with 2 additions and 1 deletions
|
|
@ -15,13 +15,14 @@ export default class ListDetailsModal extends React.Component<any, any> {
|
|||
|
||||
componentWillReceiveProps(nextProps: any) {
|
||||
this.listId = nextProps.listId;
|
||||
this.setState({ filterListDetails: null });
|
||||
}
|
||||
|
||||
handleOpenModal() {
|
||||
this.setState({ showModal: true });
|
||||
fetch(`https://api.filterlists.com/v1/lists/${this.listId}`)
|
||||
.then(response => response.json() as Promise<IFilterListDetailsDto[]>)
|
||||
.then(data => { this.setState({ filterListDetails: data, loading: false }); });
|
||||
this.setState({ showModal: true });
|
||||
}
|
||||
|
||||
handleCloseModal() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue