Pushing the first elements to work on another machine
This commit is contained in:
@@ -6,25 +6,24 @@ import Constants from 'expo-constants'; //pour connaître la taille de la barre
|
||||
import React from 'react';
|
||||
import { StyleSheet, View } from 'react-native';
|
||||
import { useChantier } from '../ContextChantier';
|
||||
|
||||
import { useUser } from '../ContextUser';
|
||||
|
||||
|
||||
|
||||
export default function Home() {
|
||||
const { chantier, setChantier } = useChantier();
|
||||
|
||||
const { role } = useUser();
|
||||
|
||||
|
||||
return(
|
||||
<ThemedView lvl={3} style={styles.back}>
|
||||
<View style={styles.container}>
|
||||
|
||||
<View style={{width:"100%", position: 'absolute',marginLeft:"50%"}}>
|
||||
<SetStatus></SetStatus>
|
||||
</View>
|
||||
<View style={{width:"100%", position: 'absolute'}}>
|
||||
<SelectChantier></SelectChantier>
|
||||
</View>
|
||||
<ChantierSummary style={styles.summary} data={{chantier}}/>
|
||||
|
||||
{role === "chef" && <SetStatus />}
|
||||
{role === "resp" && <SelectChantier />}
|
||||
{role === "ouvrier" && (
|
||||
<ChantierSummary style={styles.summary} data={{ chantier }} />
|
||||
)}
|
||||
|
||||
</View>
|
||||
</ThemedView>
|
||||
|
||||
Reference in New Issue
Block a user