This command line program is a Python based, object oriented program that would allow for a small company to keep track of their employee's information and access specific info as and when needed. The program pushes to a Google Sheet which can be manipulated from inside the program. Data can be added, deleted, and modified. Along with this, salaries can be set using predefined boundaries or set manually.
In this theoretical company, employees added to the system are randomly generated a 4 digit employee number. This allows them to easily find their information on the system.
-
First time visitor goals:
- To be able to intuitively navigate the program and complete tasks easily and quickly.
-
Returning visitor goals
- To learn how the program operates, navigate and control data faster and easier over time.
-
Frequent user goals
- To see updates to the program covering checks on email inputs, auto age complete using birthdates rather than explicit age inputs.
-
Site owner goals
- To create a simple to use, easy to navigate program that would allow a theoretical company to process employees into a list external from the program and store data necessary for regular company business needs.
-
User input at every step to walk the user through how the program operates without them having to write any complicated lines of text/code.
-
Pre-set salary brackets for 3 levels of seniority, and the option to input a different amount manually.
-
Two levels of employee location, basic and specific. Using the ALL command, a user can find an employee's number and use that to locate their specific information to delete or modify.
- Email verification that will only add the inputted data into the system if it contains an '@' symbol and a '.com'.
- Python
- Git
- GitHub
- Google Sheets API
- Google Drive API
-
The Python code passes through the PEP8 linter with no major issues.
-
During development, code was written to give the correct output when the correct input was given. Once that was working, invalid inputs were fed into the program to see how it reacted. Most bugs in the code were resolved this way. Furthermore, print statements and breakpoints were used when an error was harder to resolve. 'Try, except' blocks were used for ValueErrors and displayed to the user in short, sharp explanations to convey the issue quickly.
-
The program handles invalid inputs for most instances when the user is prompted. However when updating information on a current employee, the age can be set to any input, not just an integer.
-
It is possible for more than one employee to be generated the same random number. A fix was attempted during development but ultimately left out as more important sections of the program were still far from completed.
- The project was deployed using Heroku.
- Two buildpacks were added from the Settings tab. The ordering is as follows:
heroku/python
heroku/nodejs
-
A Config Var called
PORT
was created and set to8000
-
A second Config Var was created called
CREDS
and set to the contents of the JSON file. -
The project was connected to the GitHub repository and deployed.
- You can view the live site here.
-
Code
- Code not covered in the lessons leading up to this project were researched and found on Stack Overflow and W3Schools.
-
Content
- All Python code was written by the developer.
- HTML and CSS is template code written by Code Institute.
-
Tutor support at Code Institute for all their support throughout.
-
Friends and family for viewing the site and giving feedback.