Envoi message apres candidature

This commit is contained in:
2020-09-24 17:10:25 +02:00
parent 58bf654651
commit e380dec152
8 changed files with 77 additions and 12 deletions
+1
View File
@@ -18,6 +18,7 @@ const JobPosting = props => {
title={props.job_title}
validThrough="2020-01-06"
applicantLocationRequirements="FR"
employmentType = "FULL_TIME"
/>
+1 -1
View File
@@ -6,7 +6,7 @@ const OgHead = props => {
return (
<Head>
<title key="title">{props.seo_title}</title>
{/* <meta name="robots" content="noindex, nofollow"></meta> */}
<meta name="robots" content="noindex, nofollow"></meta>
<meta name="description" kenoindexy="description" content={props.seo_description} />
<meta name="keywords" content={props.seo_key}/>
<meta key="og:url" property="og:url" content={props.seo_url} />
+7 -2
View File
@@ -160,7 +160,12 @@ class Answer extends Component {
//TODO:maybe add this two in a single transactionnal saga
this.props.updateUserRequest(data)
//TODO: faire appel à une méthode qui va encoyer le mail a l'entreprise
this.props.companyMails.map((user) =>
//TODO Envoyer un mail a chaque user
console.log(user.email)
)
this.props.postAdAnswerRequest(
{
adId: this.props.adId,
@@ -308,7 +313,7 @@ class Answer extends Component {
/>
</form>
<div id="F" className={classes.foot}>
<Button variant="contained" className={classes.button + ' cypButtonSendApplication'} onClick={this.onSubmit}>Postuler</Button>
<Button variant="contained" className={classes.button + ' cypButtonSendApplication'} onClick={this.onSubmit}>Postuler</Button>
</div>
</section>
)
+16 -3
View File
@@ -247,12 +247,11 @@ const styles = theme => ({
},
button: {
textTransform: 'inherit',
marginLeft: theme.spacing(8),
marginRight: theme.spacing(8),
marginLeft: theme.spacing(1),
marginRight: theme.spacing(1),
padding: theme.spacing(1.2, 2),
color: theme.palette.secondary.main,
backgroundColor: theme.palette.primary.important,
alignSelf: 'center',
},
chip: {
color: theme.palette.secondary.main,
@@ -367,7 +366,21 @@ function OffreDetail(props) {
variant="contained"
className={classes.button + ' cypButtonApply'}
>Postuler</Button>
</Link>
)}
{!!!offre.is_promoted && (
<Link href={`/Entreprise/${offre.company.id}-${_.kebabCase(offre.company.brand_name)}`} >
<Button
variant="contained"
className={classes.button + ' cypButtonApply'}
>Découvrir</Button>
</Link>
)}
</section>
</Hidden>
+1 -1
View File
@@ -20,7 +20,7 @@ class Loader extends React.Component {
render() {
const { classes } = this.props;
return (
<div className={classes.loader + ' ' + 'alert alert-info'}><CircularProgress color="primary" />Chargement... <br/>Le temps de chargement peut varier de quelques secondes à <b>plusieurs minutes</b> en fonction de la qualité de votre connexion internet.<br/></div>
<div className={classes.loader + ' ' + 'alert alert-info'}><CircularProgress color="primary" />Chargement... </div>
)
}
@@ -0,0 +1,29 @@
import React, { Fragment } from 'react'
import CircularProgress from '@material-ui/core/CircularProgress'
import { withStyles } from '@material-ui/core/styles'
const styles = theme => ({
loader: {
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
textAlign: 'center',
justifyContent: 'center',
fontFamily: 'Dosis',
fontWeight: '500',
fontSize: '1em',
padding: theme.spacing(6,0),
color: theme.palette.primary.main,
},
})
class LoaderVideo extends React.Component {
render() {
const { classes } = this.props;
return (
<div className={classes.loader + ' ' + 'alert alert-info'}><CircularProgress color="primary" />Chargement... <br/>Le temps de chargement peut varier de quelques secondes à <b>plusieurs minutes</b> en fonction de la qualité de votre connexion internet.<br/></div>
)
}
}
export default withStyles(styles)(LoaderVideo)
+17 -2
View File
@@ -278,8 +278,8 @@ const styles = theme => ({
},
button: {
textTransform: 'inherit',
marginLeft: theme.spacing(4),
marginRight: theme.spacing(4),
marginLeft: theme.spacing(1),
marginRight: theme.spacing(1),
padding: theme.spacing(1.2, 2),
color: theme.palette.secondary.main,
backgroundColor: theme.palette.primary.important,
@@ -415,6 +415,7 @@ class Entreprise extends React.Component {
:
(<Chip label={nbOffre} className={classes.chip + ' ' + classes.chipHeader} />)
}
{/* ville */}
</div>
</div>
@@ -423,6 +424,13 @@ class Entreprise extends React.Component {
className={classes.button}
onClick={() => Router.push(`/Reponse?companyId=${company.id}`)}
>Candidature spontanée</Button>
<Link href="#discover" >
<Button
variant="contained"
className={classes.button + ' cypButtonApply'}
>Offres</Button>
</Link>
</section>
</Hidden>
{company.presentation_video && <VideoVimeo videoId={Ar.last(_.split(company.presentation_video.cdn_url, '/'))} autoplay='1' />}
@@ -504,6 +512,13 @@ class Entreprise extends React.Component {
className={classes.button}
onClick={() => Router.push(`/Reponse?companyId=${company.id}`)}
>Candidature spontanée</Button>
<Link href="#discover" >
<Button
variant="contained"
className={classes.button + ' cypButtonApply'}
>Offres</Button>
</Link>
<Typography className={classes.contentCondition}>
ou
</Typography>
+5 -3
View File
@@ -9,7 +9,7 @@ import { fetchJobRequest } from '../actions/ads'
import { fetchCompanyRequest } from '../actions/companies'
import { fetchCurrentUserRequest } from '../actions/user'
import { uploadMedia } from '../actions/media'
import Loader from './../components/templates/loader'
import LoaderVideo from './../components/templates/loaderVideo'
import Answer from '../components/organisms/Answer'
import LayoutBack from '../components/templates/LayoutBack'
import { withStyles } from '@material-ui/core/styles'
@@ -286,7 +286,7 @@ class Reponse extends React.Component {
</Head>
{/* https://codesandbox.io/s/ii0us */}
{ loading ?
<Loader /> :
<LoaderVideo /> :
<Fragment>
<section className={classes.headerContainer}>
@@ -407,7 +407,9 @@ class Reponse extends React.Component {
(
<Answer mediaId={!!this.props.media && this.props.media.id}
companyId={!!offre.company ? offre.company.id : !!company.brand_name ? company.id : null}
adId={offre.id}>
adId={offre.id}
companyName={!!offre.company.brand_name? offre.company.brand_name: ''}
companyMails={offre.company.users}>
</Answer>
)}
<Snack variant="error" message={!!!_.isEmpty(this.state.errors) && this.state.errors.message }