import React, { useEffect } from 'react' import { connect } from 'react-redux' import Page from './page'; import ProjectList from '../components/ProjectList'; import { projectList } from '../actions/project'; const DashBoardDev = ({ projects = [], ...props }) => { useEffect(() => { props.dispatch(projectList()) }, []) projects = [ { id: 1, name: 'mon premier projet', requests: [ { id: 1, title: 'Demande num 1', author: 'Gael Peltey', status: { id: 1, slug: 'en-attente' }, createdAt: 'le 20 juillet 2019' }, { id: 2, title: 'Demande num 2', author: 'Jean Guy', status: { id: 2, slug: 'pris-en-compte' }, createdAt: 'le 20 juillet 2020' }, { id: 3, title: 'Demande num 3', author: 'Gael Peltey', status: { id: 3, slug: 'en-cours-de-traitement' }, createdAt: 'le 20 juillet 2021' } ] }, { id: 2, name: 'mon deuxième projet', }, { id: 3, name: 'mon troisième projet', requests: [ { id: 4, title: 'Demande num 4', author: 'David Pujadas', status: { id: 4, slug: 'traite' }, createdAt: 'le 20 juillet 2022' }, { id: 5, title: 'Demande num 5', author: 'Jean Mi', status: { id: 5, slug: 'clos' }, createdAt: 'le 20 juillet 2023' } ] }, ] return (

Developpeur Dashboard

); } const mapStateToProps = ({ project }) => ({ projects: project.items, }) export default connect(mapStateToProps)(DashBoardDev)