import React from 'react'; import {connect} from 'react-redux' import {Link} from 'react-router-dom' import {Switch, Route} from "react-router-dom"; import { setSheduleDoctor, postShedule, changeInputValueDoctorForm, changeInputValueServiceForm, postDoctors, changeSelectedDoctorId, changeSelectedServiceId, putDoctors, deleteDoctors, postServices, putServices, deleteServices, changeSpecialityArray } from "../../actions/actions"; import { changeFindUserInput, findUser, deleteUser, changeInputValueUserForm, putUser } from "../../actions/user" import Shedule from './Shedule' import ChangeUser from './ChangeUser' import ChangeServicesDoctors from './ChangeServices-Doctors' export class Admin extends React.Component { render() { const { doctors, postNewShedule, postNewDoctor, postNewService, changeDoctorId, changeServiceId, services, categories, setSheduleDoctor, postShedule, changeInputValueDoctorForm, changeInputValueServiceForm, postDoctors, changeSelectedDoctorId, changeSelectedServiceId, putDoctors, deleteDoctors, putServices, deleteServices, postServices, changeSpecialityArray, specialityArray, user, findUserInput, changeFindUserInput, findUser, deleteUser, userError, changeUserForm, changeInputValueUserForm, putUser } = this.props; return (
Расписание Сотрудники Сервисы Пользователи
} /> } /> } /> } />
); } } const mapStateToProps = state => { return { doctors:state.app.doctors, postNewShedule:state.app.postNewShedule, postNewDoctor:state.app.postNewDoctor, postNewService:state.app.postNewService, changeDoctorId:state.app.changeDoctorId, changeServiceId:state.app.changeServiceId, specialityArray:state.app.specialityArray, services: state.services.services, categories: state.services.categories, user:state.user.user, findUserInput:state.user.findUserInput, userError:state.user.error, changeUserForm:state.user.changeUserForm, } }; const mapDispatchToProps = { setSheduleDoctor, postShedule, changeInputValueDoctorForm, changeInputValueServiceForm, postDoctors, changeSelectedDoctorId, changeSelectedServiceId, putDoctors, deleteDoctors, postServices, putServices, deleteServices, changeSpecialityArray, changeFindUserInput, findUser, deleteUser, changeInputValueUserForm, putUser }; export default connect (mapStateToProps,mapDispatchToProps)(Admin)