import React from "react"; import {Form, Col, Button} from "react-bootstrap"; import "./GeneralSettings.css" class GeneralSettings extends React.Component { constructor(props) { super(props); this.state = { tvshowsupport: false, videopath: "", tvshowpath: "" }; } componentDidMount() { const updateRequest = new FormData(); updateRequest.append('action', 'loadVideo'); updateRequest.append('movieid', this.props.movie_id); fetch('/api/videoload.php', {method: 'POST', body: updateRequest}) .then((response) => response.json() .then((result) => { // todo 2020-07-3: set state here })); } render() { return ( <>
Video Path TV Show Path { this.setState({tvshowsupport: !this.state.tvshowsupport}) }} /> {this.state.tvshowsupport ? Password : null }
); } } export default GeneralSettings;