From af50246bc4509a6176ac3f12ae7af8aed2faeabb Mon Sep 17 00:00:00 2001 From: ADITYA SAROHA Date: Sun, 9 Feb 2025 00:26:55 +0530 Subject: [PATCH 1/2] Added the Academics Component in the Main Form. --- package-lock.json | 78 ++++++++++------ package.json | 1 + .../Attended Workshops/attendedWorkshop.js | 57 ++++++++++++ .../booksPublishedInternational.js | 77 ++++++++++++++++ .../booksPublishedNational.js | 77 ++++++++++++++++ .../Main Form/Certification/certification.js | 55 ++++++++++++ .../Faculty Appraisal/facultyAppraisal.js | 31 +++++++ .../pgDiscretionGuided.js | 53 +++++++++++ .../Main Form/UG Projects/UGProjects.js | 53 +++++++++++ .../WrkshopOrganized/workshopOrganized.js | 90 +++++++++++++++++++ src/CPS-Frontend/Main Form/form.js | 28 ++++++ 11 files changed, 574 insertions(+), 26 deletions(-) create mode 100644 src/CPS-Frontend/Main Form/Attended Workshops/attendedWorkshop.js create mode 100644 src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js create mode 100644 src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js create mode 100644 src/CPS-Frontend/Main Form/Certification/certification.js create mode 100644 src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js create mode 100644 src/CPS-Frontend/Main Form/PG Discretion Guided/pgDiscretionGuided.js create mode 100644 src/CPS-Frontend/Main Form/UG Projects/UGProjects.js create mode 100644 src/CPS-Frontend/Main Form/WrkshopOrganized/workshopOrganized.js diff --git a/package-lock.json b/package-lock.json index ac7bbdc..308681b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,6 +11,7 @@ "@emotion/react": "^11.14.0", "@emotion/styled": "^11.14.0", "@material/web": "^2.2.0", + "@mui/icons-material": "^6.4.3", "@mui/material": "^6.4.1", "@mui/x-date-pickers": "^7.24.1", "cra-template": "1.2.0", @@ -2939,24 +2940,49 @@ } }, "node_modules/@mui/core-downloads-tracker": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-6.4.1.tgz", - "integrity": "sha512-SfDLWMV5b5oXgDf3NTa2hCTPC1d2defhDH2WgFKmAiejC4mSfXYbyi+AFCLzpizauXhgBm8OaZy9BHKnrSpahQ==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-6.4.3.tgz", + "integrity": "sha512-hlyOzo2ObarllAOeT1ZSAusADE5NZNencUeIvXrdQ1Na+FL1lcznhbxfV5He1KqGiuR8Az3xtCUcYKwMVGFdzg==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/mui-org" + } + }, + "node_modules/@mui/icons-material": { + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/icons-material/-/icons-material-6.4.3.tgz", + "integrity": "sha512-3IY9LpjkwIJVgL/SkZQKKCUcumdHdQEsJaIavvsQze2QEztBt0HJ17naToN0DBBdhKdtwX5xXrfD6ZFUeWWk8g==", + "dependencies": { + "@babel/runtime": "^7.26.0" + }, + "engines": { + "node": ">=14.0.0" + }, "funding": { "type": "opencollective", "url": "https://opencollective.com/mui-org" + }, + "peerDependencies": { + "@mui/material": "^6.4.3", + "@types/react": "^17.0.0 || ^18.0.0 || ^19.0.0", + "react": "^17.0.0 || ^18.0.0 || ^19.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } } }, "node_modules/@mui/material": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/@mui/material/-/material-6.4.1.tgz", - "integrity": "sha512-MFBfia6UiKxyoLeGkAh8M15bkeDmfnsUTMRJd/vTQue6YQ8AQ6lw9HqDthyYghzDEWIvZO/lQQzLrZE8XwNJLA==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/material/-/material-6.4.3.tgz", + "integrity": "sha512-ubtQjplbWneIEU8Y+4b2VA0CDBlyH5I3AmVFGmsLyDe/bf0ubxav5t11c8Afem6rkSFWPlZA2DilxmGka1xiKQ==", "dependencies": { "@babel/runtime": "^7.26.0", - "@mui/core-downloads-tracker": "^6.4.1", - "@mui/system": "^6.4.1", + "@mui/core-downloads-tracker": "^6.4.3", + "@mui/system": "^6.4.3", "@mui/types": "^7.2.21", - "@mui/utils": "^6.4.1", + "@mui/utils": "^6.4.3", "@popperjs/core": "^2.11.8", "@types/react-transition-group": "^4.4.12", "clsx": "^2.1.1", @@ -2975,7 +3001,7 @@ "peerDependencies": { "@emotion/react": "^11.5.0", "@emotion/styled": "^11.3.0", - "@mui/material-pigment-css": "^6.4.1", + "@mui/material-pigment-css": "^6.4.3", "@types/react": "^17.0.0 || ^18.0.0 || ^19.0.0", "react": "^17.0.0 || ^18.0.0 || ^19.0.0", "react-dom": "^17.0.0 || ^18.0.0 || ^19.0.0" @@ -3001,12 +3027,12 @@ "integrity": "sha512-H91OHcwjZsbq3ClIDHMzBShc1rotbfACdWENsmEf0IFvZ3FgGPtdHMcsv45bQ1hAbgdfiA8SnxTKfDS+x/8m2g==" }, "node_modules/@mui/private-theming": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/@mui/private-theming/-/private-theming-6.4.1.tgz", - "integrity": "sha512-DcT7mwK89owwgcEuiE7w458te4CIjHbYWW6Kn6PiR6eLtxBsoBYphA968uqsQAOBQDpbYxvkuFLwhgk4bxoN/Q==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/private-theming/-/private-theming-6.4.3.tgz", + "integrity": "sha512-7x9HaNwDCeoERc4BoEWLieuzKzXu5ZrhRnEM6AUcRXUScQLvF1NFkTlP59+IJfTbEMgcGg1wWHApyoqcksrBpQ==", "dependencies": { "@babel/runtime": "^7.26.0", - "@mui/utils": "^6.4.1", + "@mui/utils": "^6.4.3", "prop-types": "^15.8.1" }, "engines": { @@ -3027,9 +3053,9 @@ } }, "node_modules/@mui/styled-engine": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-6.4.0.tgz", - "integrity": "sha512-ek/ZrDujrger12P6o4luQIfRd2IziH7jQod2WMbLqGE03Iy0zUwYmckRTVhRQTLPNccpD8KXGcALJF+uaUQlbg==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-6.4.3.tgz", + "integrity": "sha512-OC402VfK+ra2+f12Gef8maY7Y9n7B6CZcoQ9u7mIkh/7PKwW/xH81xwX+yW+Ak1zBT3HYcVjh2X82k5cKMFGoQ==", "dependencies": { "@babel/runtime": "^7.26.0", "@emotion/cache": "^11.13.5", @@ -3060,15 +3086,15 @@ } }, "node_modules/@mui/system": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/@mui/system/-/system-6.4.1.tgz", - "integrity": "sha512-rgQzgcsHCTtzF9MZ+sL0tOhf2ZBLazpjrujClcb4Siju5lTrK0xX4PsiropActzCemNfM+mOu+0jezAVnfRK8g==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/system/-/system-6.4.3.tgz", + "integrity": "sha512-Q0iDwnH3+xoxQ0pqVbt8hFdzhq1g2XzzR4Y5pVcICTNtoCLJmpJS3vI4y/OIM1FHFmpfmiEC2IRIq7YcZ8nsmg==", "dependencies": { "@babel/runtime": "^7.26.0", - "@mui/private-theming": "^6.4.1", - "@mui/styled-engine": "^6.4.0", + "@mui/private-theming": "^6.4.3", + "@mui/styled-engine": "^6.4.3", "@mui/types": "^7.2.21", - "@mui/utils": "^6.4.1", + "@mui/utils": "^6.4.3", "clsx": "^2.1.1", "csstype": "^3.1.3", "prop-types": "^15.8.1" @@ -3112,9 +3138,9 @@ } }, "node_modules/@mui/utils": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/@mui/utils/-/utils-6.4.1.tgz", - "integrity": "sha512-iQUDUeYh87SvR4lVojaRaYnQix8BbRV51MxaV6MBmqthecQoxwSbS5e2wnbDJUeFxY2ppV505CiqPLtd0OWkqw==", + "version": "6.4.3", + "resolved": "https://registry.npmjs.org/@mui/utils/-/utils-6.4.3.tgz", + "integrity": "sha512-jxHRHh3BqVXE9ABxDm+Tc3wlBooYz/4XPa0+4AI+iF38rV1/+btJmSUgG4shDtSWVs/I97aDn5jBCt6SF2Uq2A==", "dependencies": { "@babel/runtime": "^7.26.0", "@mui/types": "^7.2.21", diff --git a/package.json b/package.json index f4851d0..a7115f2 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "@emotion/react": "^11.14.0", "@emotion/styled": "^11.14.0", "@material/web": "^2.2.0", + "@mui/icons-material": "^6.4.3", "@mui/material": "^6.4.1", "@mui/x-date-pickers": "^7.24.1", "cra-template": "1.2.0", diff --git a/src/CPS-Frontend/Main Form/Attended Workshops/attendedWorkshop.js b/src/CPS-Frontend/Main Form/Attended Workshops/attendedWorkshop.js new file mode 100644 index 0000000..4a2f6f4 --- /dev/null +++ b/src/CPS-Frontend/Main Form/Attended Workshops/attendedWorkshop.js @@ -0,0 +1,57 @@ +import React from "react"; +import { useState } from "react"; +import { RadioGroup, Radio, Box, Tooltip, FormGroup, TextField, Card, CardContent, Typography, CardHeader, FormControlLabel } from "@mui/material"; + + +const ConferenceOrganizer = () => { + + const [conferenceOrgChecked, setconferenceOrgChecked] = useState(false); + + const [numberOfConferenceOrg, setnumberOfConferenceOrg] = useState(); + console.log(numberOfConferenceOrg); + + const handleConferenceOrgChecked = (e) => { + setconferenceOrgChecked(e.target.value); + } + + return ( + <> + + + + + Have you ever Attended Workshop / FDP / Short term + courses of minimum of 05 working days + duration in offline mode.? + handleConferenceOrgChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(conferenceOrgChecked !== "No" && conferenceOrgChecked) && + <> + + + Number of Attended Workshops / FDP / STC + + -Maximum Allowed Value is 3 from last Appointment
+ -Please Ensure Valid Entries Only.
+
+ + } arrow placement="right" enterDelay={200} leaveDelay={200}> { let value = parseInt(e.target.value, 10); if (value > 3) { value = 3 } if (value < 0) { value = 0 } if (isNaN(value)) { value = e.target.value } e.target.value = value; setnumberOfConferenceOrg(value) }} /> +
+
+ + + } + +
+ + ); +} + +export default ConferenceOrganizer; diff --git a/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js b/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js new file mode 100644 index 0000000..bc163c8 --- /dev/null +++ b/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js @@ -0,0 +1,77 @@ +import React from "react"; +import { useState, useEffect } from "react"; +import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; + +const BooksPublishedInInternational = () => { + + const [industryProjectsChecked, setindustryProjectsChecked] = useState(false); + + const [NumberofIndustryProjects, setNumberofIndustryProjects] = useState(); + console.log(setNumberofIndustryProjects); + + const [bookISBNnumber, setbookISBNnumber] = useState([]); + console.log(bookISBNnumber); + + const [IndustryProjectsNumber, setIndustryProjectsNumber] = useState([]); + + useEffect(() => { + if (NumberofIndustryProjects) { + const count = parseInt(NumberofIndustryProjects, 10) || 0; + setIndustryProjectsNumber((prevList) => { + const newList = [...prevList]; + if (newList.length < count) { + newList.push(...Array(count - newList.length).fill({ industryAttachementsOption: "" })); + } else { + newList.length = count; + } + return newList; + }); + } + }, [NumberofIndustryProjects]); + + const handleaIndustryProjectsChecked = (e) => { + setindustryProjectsChecked(e.target.value); + } + + return ( + <> + + + + + Do you have any Text / Reference book published on relevant + subjects from reputed international + publishers with ISBN? + handleaIndustryProjectsChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(industryProjectsChecked !== "No" && industryProjectsChecked) && + <> + + { let value = parseInt(e.target.value, 10); if (value <= 0) { value = 0; } else if (value) { } else { value = isNaN(value); } e.target.value = value; setNumberofIndustryProjects(e.target.value) }} /> + + + {(industryProjectsChecked !== "No") && IndustryProjectsNumber.map((_, index) => ( + + Information About Text / Reference Book {index + 1} + + { let value = parseInt(e.target.value, 10); if (value <= 0) { value = 0; } else if (value) { } else { value = isNaN(value); } e.target.value = value; setbookISBNnumber(e.target.value) }} /> + + + ))} + + + } + + + + + ); +} + +export default BooksPublishedInInternational; \ No newline at end of file diff --git a/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js b/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js new file mode 100644 index 0000000..1e01a6c --- /dev/null +++ b/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js @@ -0,0 +1,77 @@ +import React from "react"; +import { useState, useEffect } from "react"; +import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; + +const BooksPublishedInNational = () => { + + const [industryProjectsChecked, setindustryProjectsChecked] = useState(false); + + const [NumberofIndustryProjects, setNumberofIndustryProjects] = useState(); + console.log(setNumberofIndustryProjects); + + const [bookISBNnumber, setbookISBNnumber] = useState([]); + console.log(bookISBNnumber); + + const [IndustryProjectsNumber, setIndustryProjectsNumber] = useState([]); + + useEffect(() => { + if (NumberofIndustryProjects) { + const count = parseInt(NumberofIndustryProjects, 10) || 0; + setIndustryProjectsNumber((prevList) => { + const newList = [...prevList]; + if (newList.length < count) { + newList.push(...Array(count - newList.length).fill({ industryAttachementsOption: "" })); + } else { + newList.length = count; + } + return newList; + }); + } + }, [NumberofIndustryProjects]); + + const handleaIndustryProjectsChecked = (e) => { + setindustryProjectsChecked(e.target.value); + } + + return ( + <> + + + + + Do you have any Text / Reference Books published on + relevant subjects from reputed national + publishers with ISBN? + handleaIndustryProjectsChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(industryProjectsChecked !== "No" && industryProjectsChecked) && + <> + + { let value = parseInt(e.target.value, 10); if (value <= 0) { value = 0; } else if (value) { } else { value = isNaN(value); } e.target.value = value; setNumberofIndustryProjects(e.target.value) }} /> + + + {(industryProjectsChecked !== "No") && IndustryProjectsNumber.map((_, index) => ( + + Information About Text / Reference Book {index + 1} + + { let value = parseInt(e.target.value, 10); if (value <= 0) { value = 0; } else if (value) { } else { value = isNaN(value); } e.target.value = value; setbookISBNnumber(e.target.value) }} /> + + + ))} + + + } + + + + + ); +} + +export default BooksPublishedInNational; \ No newline at end of file diff --git a/src/CPS-Frontend/Main Form/Certification/certification.js b/src/CPS-Frontend/Main Form/Certification/certification.js new file mode 100644 index 0000000..c172793 --- /dev/null +++ b/src/CPS-Frontend/Main Form/Certification/certification.js @@ -0,0 +1,55 @@ +import React from "react"; +import { useState } from "react"; +import { RadioGroup, Radio, Box, Tooltip, FormGroup, TextField, Card, CardContent, Typography, CardHeader, FormControlLabel } from "@mui/material"; + + +const Certification = ({ maxValue }) => { + + const [conferenceOrgChecked, setconferenceOrgChecked] = useState(false); + + const [numberOfConferenceOrg, setnumberOfConferenceOrg] = useState(); + console.log(numberOfConferenceOrg); + + const handleConferenceOrgChecked = (e) => { + setconferenceOrgChecked(e.target.value); + } + + return ( + <> + + + + + Do have Certification in NPTEL / Coursera / + Microsoft / IBM / Cisco offered Courses? + handleConferenceOrgChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(conferenceOrgChecked !== "No" && conferenceOrgChecked) && + <> + + + Number of Certification in NPTEL / Coursera / Microsoft / IBM / Cisco offered Courses + + -Maximum Allowed Value is {maxValue}
+ -Please Ensure Valid Entries Only.
+
+ + } arrow placement="right" enterDelay={200} leaveDelay={200}> { let value = parseInt(e.target.value, 10); if (value > maxValue) { value = maxValue } if (value < 0) { value = 0 } if (isNaN(value)) { value = e.target.value } e.target.value = value; setnumberOfConferenceOrg(value) }} /> +
+
+ + + } + +
+ + ); +} + +export default Certification; diff --git a/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js b/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js new file mode 100644 index 0000000..0864fe2 --- /dev/null +++ b/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js @@ -0,0 +1,31 @@ +import React from "react"; +import { useState, useEffect } from "react"; +import AddIcon from "@mui/icons-material/Add"; +import { Button, Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; + +const FacultyAppraisal = () => { + + + return ( + <> + + + + + + + + + + + + + + + ); +} + +export default FacultyAppraisal; \ No newline at end of file diff --git a/src/CPS-Frontend/Main Form/PG Discretion Guided/pgDiscretionGuided.js b/src/CPS-Frontend/Main Form/PG Discretion Guided/pgDiscretionGuided.js new file mode 100644 index 0000000..1da0076 --- /dev/null +++ b/src/CPS-Frontend/Main Form/PG Discretion Guided/pgDiscretionGuided.js @@ -0,0 +1,53 @@ +import React from "react"; +import { useState } from "react"; +import { RadioGroup, Radio, Box, Tooltip, FormGroup, TextField, Card, CardContent, Typography, CardHeader, FormControlLabel } from "@mui/material"; + + +const PGDiscretionGuided = ({ maxValue }) => { + + const [conferenceOrgChecked, setconferenceOrgChecked] = useState(false); + + const [numberOfConferenceOrg, setnumberOfConferenceOrg] = useState(); + console.log(numberOfConferenceOrg); + + const handleConferenceOrgChecked = (e) => { + setconferenceOrgChecked(e.target.value); + } + + return ( + <> + + + + + Do have PG Dissertation guided? + handleConferenceOrgChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(conferenceOrgChecked !== "No" && conferenceOrgChecked) && + <> + + + Number of PG Dissertation guided + + -Maximum Allowed Value is {maxValue}
+ -Please Ensure Valid Entries Only.
+
+ + } arrow placement="right" enterDelay={200} leaveDelay={200}> { let value = parseInt(e.target.value, 10); if (value > maxValue) { value = maxValue } if (value < 0) { value = 0 } if (isNaN(value)) { value = e.target.value } e.target.value = value; setnumberOfConferenceOrg(value) }} /> +
+
+ + + } + +
+ + ); +} + +export default PGDiscretionGuided; diff --git a/src/CPS-Frontend/Main Form/UG Projects/UGProjects.js b/src/CPS-Frontend/Main Form/UG Projects/UGProjects.js new file mode 100644 index 0000000..5a61d3b --- /dev/null +++ b/src/CPS-Frontend/Main Form/UG Projects/UGProjects.js @@ -0,0 +1,53 @@ +import React from "react"; +import { useState } from "react"; +import { RadioGroup, Radio, Box, Tooltip, FormGroup, TextField, Card, CardContent, Typography, CardHeader, FormControlLabel } from "@mui/material"; + + +const UGProjects = ({ maxValue }) => { + + const [conferenceOrgChecked, setconferenceOrgChecked] = useState(false); + + const [numberOfConferenceOrg, setnumberOfConferenceOrg] = useState(); + console.log(numberOfConferenceOrg); + + const handleConferenceOrgChecked = (e) => { + setconferenceOrgChecked(e.target.value); + } + + return ( + <> + + + + + Do have PG Dissertation guided? + handleConferenceOrgChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(conferenceOrgChecked !== "No" && conferenceOrgChecked) && + <> + + + Number of UG Projects + + -Maximum Allowed Value is {maxValue}
+ -Please Ensure Valid Entries Only.
+
+ + } arrow placement="right" enterDelay={200} leaveDelay={200}> { let value = parseInt(e.target.value, 10); if (value > maxValue) { value = maxValue } if (value < 0) { value = 0 } if (isNaN(value)) { value = e.target.value } e.target.value = value; setnumberOfConferenceOrg(value) }} /> +
+
+ + + } + +
+ + ); +} + +export default UGProjects; \ No newline at end of file diff --git a/src/CPS-Frontend/Main Form/WrkshopOrganized/workshopOrganized.js b/src/CPS-Frontend/Main Form/WrkshopOrganized/workshopOrganized.js new file mode 100644 index 0000000..1bfbb93 --- /dev/null +++ b/src/CPS-Frontend/Main Form/WrkshopOrganized/workshopOrganized.js @@ -0,0 +1,90 @@ +import React from "react"; +import { useState, useEffect } from "react"; +import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; + +const WorkhopOrganized = () => { + + const [industryProjectsChecked, setindustryProjectsChecked] = useState(false); + + const [NumberofIndustryProjects, setNumberofIndustryProjects] = useState(); + console.log(setNumberofIndustryProjects); + + const IndustryProjectsOption = ["Sucessfully Completed", "On Going", "Not Completed"]; + + const [IndustryProjectsNumber, setIndustryProjectsNumber] = useState([]); + + useEffect(() => { + if (NumberofIndustryProjects) { + const count = parseInt(NumberofIndustryProjects, 10) || 0; + setIndustryProjectsNumber((prevList) => { + const newList = [...prevList]; + if (newList.length < count) { + newList.push(...Array(count - newList.length).fill({ industryAttachementsOption: "" })); + } else { + newList.length = count; + } + return newList; + }); + } + }, [NumberofIndustryProjects]); + + const handleaIndustryProjectsChecked = (e) => { + setindustryProjectsChecked(e.target.value); + } + + const handleIndustryAttachementsSelect = (index, event) => { + const newIndustryProjectsNumber = [...IndustryProjectsNumber]; + newIndustryProjectsNumber[index] = { ...newIndustryProjectsNumber[index], industryAttachementsOption: event.target.value } + setIndustryProjectsNumber(newIndustryProjectsNumber); + //console.log(IndustryProjectsNumber[index]); + } + + return ( + <> + + + + + Have you ever organized as coordinator / convener or + participated as a resource person in any Workshop / FDP / Short term courses of + minimum of 05 working days duration ? + handleaIndustryProjectsChecked(e)}> + } label="Yes" /> + } label="No" /> + + + + {(industryProjectsChecked !== "No" && industryProjectsChecked) && + <> + + { let value = parseInt(e.target.value, 10); if (value <= 0) { value = 0; } else if (value) { } else { value = isNaN(value); } e.target.value = value; setNumberofIndustryProjects(e.target.value) }} /> + + + {(industryProjectsChecked !== "No") && IndustryProjectsNumber.map((_, index) => ( + + Information About Workshop / FDP / STC Project {index + 1} + + Select Options* + + + + ))} + + + } + + + + + ); +} + +export default WorkhopOrganized; \ No newline at end of file diff --git a/src/CPS-Frontend/Main Form/form.js b/src/CPS-Frontend/Main Form/form.js index 1fe1df4..2dc7f27 100644 --- a/src/CPS-Frontend/Main Form/form.js +++ b/src/CPS-Frontend/Main Form/form.js @@ -12,6 +12,14 @@ import Administration3 from "./Administration - 3/administration3"; import Administration4 from "./Administration - 4/administration4"; import IndustryAttachement from "./Industry Attachement/industryAttachement"; import IndustryProjectCompletion from "./Industry Projects/industryProjects"; +import WorkhopOrganized from "./WrkshopOrganized/workshopOrganized"; +import AttendedWorkshops from "./Attended Workshops/attendedWorkshop"; +import Certification from "./Certification/certification"; +import PGDiscretionGuided from "./PG Discretion Guided/pgDiscretionGuided"; +import UGProjects from "./UG Projects/UGProjects"; +import BooksPublishedInInternational from "./BookPublishedInternational/booksPublishedInternational"; +import BooksPublishedInNational from "./BooksPublishedInNational/booksPublishedNational"; +import FacultyAppraisal from "./Faculty Appraisal/facultyAppraisal"; const Form = () => { const [checked, setChecked] = useState(false); @@ -244,6 +252,26 @@ const Form = () => { + {/* This is the Academics Section */} + + + + + + + + + + + + + + + + + + + ); From 6a0e2d4a2b0b8a8973ac375106debfc35e4148af Mon Sep 17 00:00:00 2001 From: ADITYA SAROHA Date: Sun, 9 Feb 2025 00:48:45 +0530 Subject: [PATCH 2/2] Resolved the errors of Netlify bot --- .../BookPublishedInternational/booksPublishedInternational.js | 2 +- .../BooksPublishedInNational/booksPublishedNational.js | 2 +- .../Main Form/Faculty Appraisal/facultyAppraisal.js | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js b/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js index bc163c8..9cdac7f 100644 --- a/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js +++ b/src/CPS-Frontend/Main Form/BookPublishedInternational/booksPublishedInternational.js @@ -1,6 +1,6 @@ import React from "react"; import { useState, useEffect } from "react"; -import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; +import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, TextField } from "@mui/material"; const BooksPublishedInInternational = () => { diff --git a/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js b/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js index 1e01a6c..50f3f14 100644 --- a/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js +++ b/src/CPS-Frontend/Main Form/BooksPublishedInNational/booksPublishedNational.js @@ -1,6 +1,6 @@ import React from "react"; import { useState, useEffect } from "react"; -import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; +import { Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, TextField } from "@mui/material"; const BooksPublishedInNational = () => { diff --git a/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js b/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js index 0864fe2..ddf0b97 100644 --- a/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js +++ b/src/CPS-Frontend/Main Form/Faculty Appraisal/facultyAppraisal.js @@ -1,7 +1,6 @@ import React from "react"; -import { useState, useEffect } from "react"; import AddIcon from "@mui/icons-material/Add"; -import { Button, Radio, RadioGroup, FormGroup, Card, CardHeader, FormControlLabel, Typography, FormControl, Select, MenuItem, InputLabel, TextField } from "@mui/material"; +import { Button, Card, CardHeader, FormControl } from "@mui/material"; const FacultyAppraisal = () => {