MenuControl.jsx
    
    
    
    
    
        Home
            /
FileServer                    /
Web                    /
Scripts                    /
React                    /
Controls                    /
                    MenuControl.jsx
    
    
            
            
class MenuControl extends React.Component {
    constructor(props) {
        super(props);
        console.log('MenuControl start');
        //this.state = { counter: 0 };
        this.userServices = new UserServices();
        this.OnAuthChange = this.OnAuthChange.bind(this);
    }
    OnAuthChange() {
        this.forceUpdate();
    }
    render() {
        return (
            <div>
                <table>
                    <tr>
                        <th>Menu:</th>
                        <th>
                            <Link to={`/`}>
                                <button>FS</button>
                            </Link>
                        </th>
                        {this.userServices.IsAuth()
                            ?
                            <th>
                                <Link to={`/Admin`}>
                                    <button>Admin</button>
                                </Link>
                            </th>
                            : ""
                        }                        
                    </tr>
                </table>
            </div>
        );
    }
}