- Timestamp:
- 06/17/24 21:59:14 (2 weeks ago)
- Branches:
- main
- Children:
- 08f82ec
- Parents:
- b248810
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
jobvista-frontend/src/views/applications/ApplyToJobAdModal.js
rb248810 rbefb988 1 1 import React, {useState} from "react"; 2 import "../ job_advertisements/Form.css";2 import "../shared_css/Modal.css"; 3 3 4 4 import 'react-responsive-modal/styles.css'; 5 5 import {Modal} from 'react-responsive-modal'; 6 import Select from "react-select";7 6 8 7 //Validation … … 12 11 13 12 14 import {employmentStatusOptions, industryOptions, jobTypeOptions} from "../selectOptions";15 13 import {useDispatch, useSelector} from "react-redux"; 16 import {JobAdvertisementActions} from "../../redux/actions/jobAdvertisementActions";17 14 import Roles from "../../enumerations/Roles"; 18 15 import {ApplicationActions} from "../../redux/actions/applicationActions"; 16 import {notifyJobAdApply} from "../../utils/toastUtils"; 19 17 20 18 … … 55 53 formData,(success, response) => { 56 54 if(success) { 57 console.log("Job Advertisement added")58 55 toggleModal() 56 notifyJobAdApply() 59 57 } 60 58 } … … 70 68 {role===Roles.JOBSEEKER && 71 69 <> 72 {jobAd.active && <button onClick={toggleModal} className=" card-button apply">Apply now</button> }70 {jobAd.active && <button onClick={toggleModal} className="apply-button apply">Apply now</button> } 73 71 {!jobAd.active && <button className="card-button apply disabled">Apply now</button> } 74 72 </> … … 86 84 <label className="label">Why are you interested in joining our company?</label> 87 85 <textarea type="text" placeholder="Write your answer here..." 88 {...register("answerOne")} className="applic taion-textarea"/>86 {...register("answerOne")} className="application-textarea"/> 89 87 <p style={{color: "red"}}>{errors.answerOne?.message}</p> 90 88 91 89 <label className="label">What makes you a good fit for this position?</label> 92 90 <textarea type="text" placeholder="Write your answer here..." 93 {...register("answerTwo")} className="applic taion-textarea"/>91 {...register("answerTwo")} className="application-textarea"/> 94 92 <p style={{color: "red"}}>{errors.answerTwo?.message}</p> 95 93 96 94 <label className="label">What do you hope to achieve in your first 6 months in this role?</label> 97 95 <textarea type="text" placeholder="Write your answer here..." 98 {...register("answerThree")} className="applic taion-textarea"/>96 {...register("answerThree")} className="application-textarea"/> 99 97 <p style={{color: "red"}}>{errors.answerThree?.message}</p> 100 98 … … 103 101 <label htmlFor="start">Curriculum vitae (CV)</label> 104 102 <br/> 105 <input {...register("file")} onChange={(e) => setResumeFile(e.target.files[0])} required type="file" id="fileUpload" accept=".pdf"/>103 <input {...register("file")} className="resume-link" onChange={(e) => setResumeFile(e.target.files[0])} required type="file" id="fileUpload" accept=".pdf"/> 106 104 107 105 <br/> 108 106 <label className="label">Message to the recruiter</label> 109 107 <textarea type="text" placeholder="Optional..." 110 {...register("messageToRecruiter")} className="applic taion-textarea"/>108 {...register("messageToRecruiter")} className="application-textarea"/> 111 109 112 110 <br/><br/> … … 115 113 </div> 116 114 117 <div className="aligned"> 115 <div className="modal-buttons"> 116 <div className="cancel-btn" onClick={toggleModal}> Cancel</div> 118 117 <button className="submit-btn"> Submit</button> 119 118 </div>
Note:
See TracChangeset
for help on using the changeset viewer.