Skip to content
Snippets Groups Projects
Select Git revision
  • c8c9c715213eb3e520666f074a993ab41d874e77
  • main default
2 results

Timetable.js

Blame
  • user avatar
    Aymeric Chaumont authored
    c8c9c715
    History
    Timetable.js 1.86 KiB
    import React from "react"
    import Table from "react-bootstrap/Table"
    
    import styles from "./Timetable.css"
    
    
    export default function Timetable (schedule) {
        const timetable = schedule.schedule;
        return(
            <div style={{ borderRadius: '5px', width: '500px', textAlign: 'center' }}>
                <Table className="table table-striped table-bordered">
                    <tbody>
                        <tr>
                            <th>Lundi</th>
                            <th>{timetable['LundiMidi'] != null ? timetable['LundiMidi'] : '-'}</th>
                            <th>{timetable['LundiSoir'] != null ? timetable['LundiSoir'] : '-'}</th>
                        </tr>
                        <tr>
                            <th>Mardi</th>
                            <th>{timetable['MardiMidi'] != null ? timetable['MardiMidi'] : '-'}</th>
                            <th>{timetable['MardiSoir'] != null ? timetable['MardiSoir'] : '-'}</th>
                        </tr>
                        <tr>
                            <th>Mercredi</th>
                            <th>{timetable['MercrediMidi'] != null ? timetable['MercrediMidi'] : '-'}</th>
                            <th>{timetable['MercrediSoir'] != null ? timetable['MercrediSoir'] : '-'}</th>
                        </tr>
                        <tr>
                            <th>Jeudi</th>
                            <th>{timetable['JeudiMidi'] != null ? timetable['JeudiMidi'] : '-'}</th>
                            <th>{timetable['JeudiSoir'] != null ? timetable['JeudiSoir'] : '-'}</th>
                        </tr>
                        <tr>
                            <th>Vendredi</th>
                            <th>{timetable['VendrediMidi'] != null ? timetable['VendrediMidi'] : '-'}</th>
                            <th>{timetable['VendrediSoir'] != null ? timetable['VendrediSoir'] : '-'}</th>
                        </tr>
                    </tbody>
                </Table>
            </div>
        )
    }