{"id":18773317,"url":"https://github.com/developeromarfaruk/grape-agro-staff-list","last_synced_at":"2026-04-13T23:33:00.065Z","repository":{"id":190268442,"uuid":"582127585","full_name":"DeveloperOmarFaruk/grape-agro-staff-list","owner":"DeveloperOmarFaruk","description":"Grape agro staff list CRUD operation","archived":false,"fork":false,"pushed_at":"2022-12-27T08:14:31.000Z","size":342,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-29T08:28:15.572Z","etag":null,"topics":["axios","bootstrap","json-api","json-server","material-ui","react-hooks","react-router","reactjs"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DeveloperOmarFaruk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-12-25T19:43:03.000Z","updated_at":"2022-12-27T08:05:11.000Z","dependencies_parsed_at":null,"dependency_job_id":"8e2c8097-1378-4110-8fec-5d59131a8e6e","html_url":"https://github.com/DeveloperOmarFaruk/grape-agro-staff-list","commit_stats":null,"previous_names":["developeromarfaruk/grape-agro-staff-list"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperOmarFaruk%2Fgrape-agro-staff-list","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperOmarFaruk%2Fgrape-agro-staff-list/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperOmarFaruk%2Fgrape-agro-staff-list/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperOmarFaruk%2Fgrape-agro-staff-list/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DeveloperOmarFaruk","download_url":"https://codeload.github.com/DeveloperOmarFaruk/grape-agro-staff-list/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239680983,"owners_count":19679509,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["axios","bootstrap","json-api","json-server","material-ui","react-hooks","react-router","reactjs"],"created_at":"2024-11-07T19:33:38.677Z","updated_at":"2025-12-13T19:30:11.344Z","avatar_url":"https://github.com/DeveloperOmarFaruk.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Getting Started with Create React App\n\nThis project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).\n\n## Available Scripts\n\nIn the project directory, you can run:\n\n### `npm start`\n\nRuns the app in the development mode.\\\nOpen [http://localhost:3000](http://localhost:3000) to view it in your browser.\n\nThe page will reload when you make changes.\\\nYou may also see any lint errors in the console.\n\n### `npm test`\n\nLaunches the test runner in the interactive watch mode.\\\nSee the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.\n\n### `npm run build`\n\nBuilds the app for production to the `build` folder.\\\nIt correctly bundles React in production mode and optimizes the build for the best performance.\n\nThe build is minified and the filenames include the hashes.\\\nYour app is ready to be deployed!\n\nSee the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.\n\n### `npm run eject`\n\n**Note: this is a one-way operation. Once you `eject`, you can't go back!**\n\nIf you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.\n\nInstead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own.\n\nYou don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it.\n\n## Learn More\n\nYou can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).\n\nTo learn React, check out the [React documentation](https://reactjs.org/).\n\n### Code Splitting\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)\n\n### Analyzing the Bundle Size\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)\n\n### Making a Progressive Web App\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)\n\n### Advanced Configuration\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)\n\n### Deployment\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)\n\n### `npm run build` fails to minify\n\nThis section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)\n\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\u003c!-- Project Details Road Map --\u003e\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\u003c!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --\u003e\n\n\u003c!-- Json Format --\u003e\n\n{\n\"staff\": [\n{\n\"staffId\": \"01736648160\",\n\"name\": \"Md Omar Faruk Tutul\",\n\"email\": \"omarfaruk18115@gmail.com\",\n\"mobile\": \"0173664816000\",\n\"id\": 1\n},\n{\n\"staffId\": \"017366481602\",\n\"name\": \"Md Omar Faruk Tutul\",\n\"email\": \"omarfaruk18115@gmail.com\",\n\"mobile\": \"01736648160\",\n\"id\": 2\n},\n{\n\"staffId\": \"017366481605\",\n\"name\": \"Omar Faruk\",\n\"email\": \"developer.omarfaruk@gmail.com\",\n\"mobile\": \"01736648160\",\n\"id\": 3\n},\n{\n\"staffId\": \"0173664816044\",\n\"name\": \"Omar Faruk\",\n\"email\": \"developer.omarfaruk@gmail.com\",\n\"mobile\": \"01736648160\",\n\"id\": 4\n},\n{\n\"staffId\": \"01521404561566\",\n\"name\": \"Md. Omar Faruk\",\n\"email\": \"developer.omarfaruk@gmail.com\",\n\"mobile\": \"01521404561\",\n\"id\": 5\n},\n{\n\"staffId\": \"5665\",\n\"name\": \"Md. Omar Faruk\",\n\"email\": \"developer.omarfaruk@gmail.com\",\n\"mobile\": \"01736648160\",\n\"id\": 6\n},\n{\n\"staffId\": \"017366481605563\",\n\"name\": \"Omar Faruk\",\n\"email\": \"developer.omarfaruk@gmail.com\",\n\"mobile\": \"3363636536363\",\n\"id\": 7\n}\n]\n\n}\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// Staff Data load API call State and Function Area\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst [staff, SetStaff] = useState([]);\n\nuseEffect(() =\u003e {\nasync function getAllStaff() {\ntry {\nconst responesAllStaff = await axios.get(\n`http://localhost:3030/staff/`\n);\n// console.log(responesStaff.data);\nSetStaff(responesAllStaff.data);\n} catch (error) {\nconsole.log(\"Something is Wrong\");\n}\n}\ngetAllStaff();\n}, []);\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// Add Form State and Function Area\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n    const [staffAdd, setStaffAdd] = useState({\n    staffId: \"\",\n    name: \"\",\n    email: \"\",\n    mobile: \"\",\n\n});\n\nconst [status, SetStatus] = useState();\n\nfunction inputAddFormChange(e) {\nsetStaffAdd({\n...staffAdd,\n[e.target.name]: e.target.value,\n});\n}\n\nasync function onAddSubmit(e) {\ne.preventDefault();\ntry {\nawait axios.post(`http://localhost:3030/staff`, staffAdd);\n} catch (error) {\nconsole.log(\"Something is Wrong\");\n}\nsetAddShow(false);\nSetStatus(true);\n}\n\n    if (status) {\n    return \u003cHome /\u003e;\n\n}\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// User specific id select for use\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst { id } = useParams();\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// back to path for use\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst navigate = useNavigate();\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// Edit Form State and Funcion Area\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst [staffEdit, setStaffEdit] = useState({\nstaffId: \"\",\nname: \"\",\nemail: \"\",\nmobile: \"\",\n});\n\nfunction inputEditFormChange(e) {\nsetStaffEdit({\n...staffEdit,\n[e.target.name]: e.target.value,\n});\n}\n\nuseEffect(() =\u003e {\nasync function getStaff() {\ntry {\nconst responesStaff = await axios.get(\n`http://localhost:3030/staff/${id}`\n);\n// console.log(responesStaff.data);\nsetStaffEdit(responesStaff.data);\n} catch (error) {\nconsole.log(\"Something is Wrong\");\n}\n}\ngetStaff();\n}, [id]);\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// Edit Form submit function\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nasync function onEditSubmit(e) {\ne.preventDefault();\ntry {\nawait axios.put(`http://localhost:3030/staff/${id}`, staffEdit);\n} catch (error) {\nconsole.log(\"Something is Wrong\");\n}\n\n    navigate(\"/\");\n\n}\n\n    // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n// User specific id select for use\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst { id } = useParams();\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// back to path for use\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst navigate = useNavigate();\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// Staff Data load API call State and Function Area\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nconst [staff, SetStaff] = useState([]);\n\nuseEffect(() =\u003e {\nasync function getStaff() {\ntry {\nconst responesStaff = await axios.get(\n`http://localhost:3030/staff/${id}`\n);\n// console.log(responesStaff.data);\nSetStaff(responesStaff.data);\n} catch (error) {\nconsole.log(\"Something is Wrong\");\n}\n}\ngetStaff();\n}, [id]);\n\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n// ID pass\n// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\u003c!-- \u003cRoutes\u003e\n        \u003cRoute path=\"/\" element={\u003cHome /\u003e} /\u003e\n        \u003cRoute path=\"/view/:id\" element={\u003cView /\u003e} /\u003e\n        \u003cRoute path=\"/edit/:id\" element={\u003cEdit /\u003e} /\u003e\n      \u003c/Routes\u003e --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperomarfaruk%2Fgrape-agro-staff-list","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeveloperomarfaruk%2Fgrape-agro-staff-list","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperomarfaruk%2Fgrape-agro-staff-list/lists"}