Skip to content

Commit d0ef7f5

Browse files
committed
Merge branch 'development' of https://github.com/hackforla/VRMS into mui1684
2 parents f46546c + c5bc4ee commit d0ef7f5

28 files changed

+1277
-631
lines changed

.github/workflows/New-issue-create-card.yml

Lines changed: 0 additions & 13 deletions
This file was deleted.

.github/workflows/all-PRs.yaml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,24 @@ jobs:
99
test-backend-unit:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v4
1313
- name: Make envfile
14-
uses: SpicyPizza/create-envfile@v1
14+
uses: SpicyPizza/create-envfile@v2
1515
with:
1616
envkey_BACKEND_PORT: ${{ secrets.BACKEND_PORT }}
1717
envkey_REACT_APP_PROXY: ${{ secrets.REACT_APP_PROXY }}
1818
file_name: backend/.env
1919
- name: Build the backend container
20-
run: docker-compose build backend
20+
run: docker compose build backend
2121
- name: Run backend unit test suite
22-
run: docker-compose run --rm backend yarn run test --testPathIgnorePatterns=routers
22+
run: docker compose run --rm backend yarn run test --testPathIgnorePatterns=routers
2323

2424
test-backend-integration:
2525
runs-on: ubuntu-latest
2626
steps:
27-
- uses: actions/checkout@v2
27+
- uses: actions/checkout@v4
2828
- name: Make envfile
29-
uses: SpicyPizza/create-envfile@v1
29+
uses: SpicyPizza/create-envfile@v2
3030
with:
3131
envkey_CUSTOM_REQUEST_HEADER: ${{ secrets.CUSTOM_REQUEST_HEADER }}
3232
envkey_SLACK_OAUTH_TOKEN: ${{ secrets.SLACK_OAUTH_TOKEN }}
@@ -47,24 +47,24 @@ jobs:
4747
envkey_MAILHOG_PASSWORD: ${{ secrets.MAILHOG_PASSWORD }}
4848
file_name: backend/.env
4949
- name: Build the backend container
50-
run: docker-compose build backend
50+
run: docker compose build backend
5151
- name: Run backend integration test suite
52-
run: docker-compose run --rm backend yarn run test backend/routers/
52+
run: docker compose run --rm backend yarn run test backend/routers/
5353

5454
test-client-unit:
5555
runs-on: ubuntu-latest
5656
steps:
57-
- uses: actions/checkout@v2
57+
- uses: actions/checkout@v4
5858
- name: Build the client container
59-
run: docker-compose build client
59+
run: docker compose build client
6060
- name: Run client unit test suite
61-
run: docker-compose run --rm client yarn run test
61+
run: docker compose run --rm client yarn run test
6262

6363
# test-mvp-unit:
6464
# runs-on: ubuntu-latest
6565
# steps:
66-
# - uses: actions/checkout@v2
66+
# - uses: actions/checkout@v4
6767
# - name: Build the client mvp container
68-
# run: docker-compose build client-mvp-04
68+
# run: docker compose build client-mvp-04
6969
# - name: Run frontend unit test suite
70-
# run: docker-compose run --rm client-mvp-04 yarn run test
70+
# run: docker compose run --rm client-mvp-04 yarn run test

.github/workflows/all-merges.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
if: github.event.pull_request.merged == true
1212
steps:
13-
- uses: actions/checkout@v2
13+
- uses: actions/checkout@v4
1414
- name: Set up QEMU
1515
uses: docker/setup-qemu-action@v1
1616
- name: Set up Docker Buildx

.github/workflows/aws-backend-deploy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Debug Action
2626
uses: hmarr/debug-action@v1.0.0
2727
- name: Checkout
28-
uses: actions/checkout@v2
28+
uses: actions/checkout@v4
2929
with:
3030
ref: ${{ github.event.inputs.ref }}
3131
- name: Set AWS Env & Image Tag per workflow
@@ -45,7 +45,7 @@ jobs:
4545
needs: [setup_env]
4646
steps:
4747
- name: Checkout
48-
uses: actions/checkout@v2
48+
uses: actions/checkout@v4
4949
with:
5050
ref: ${{ github.event.inputs.ref }}
5151
- name: Configure AWS credentials

.github/workflows/pr-instructions.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
Add-Pull-Request-Instructions:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v4
1313

1414
# Create the message to post
1515
- name: Create Instruction
@@ -28,7 +28,7 @@ jobs:
2828
echo ${{ steps.instruction.outputs.result }} > addingPrInstructions/artifact/artifact.txt
2929
3030
- name: Upload Artifacts
31-
uses: actions/upload-artifact@v2
31+
uses: actions/upload-artifact@v3
3232
with:
3333
name: adding-pr-instructions-artifact
3434
path: addingPrInstructions/artifact/

.github/workflows/wr-pr-instructions.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
const artifactJSON = JSON.parse(artifact);
4545
return artifactJSON
4646
47-
- uses: actions/checkout@v2
47+
- uses: actions/checkout@v4
4848
# Create the message to post
4949
- name: Post Comment
5050
uses: actions/github-script@v4

CODE_OF_CONDUCT.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
VRMS is governed by the [Hack for LA Code of Conduct](https://www.hackforla.org/code-of-conduct/) which applies to any interaction on our VRMS slack channel (inside the HackforLA Slack workspace), direct slack messages, github org or repository, or any other communication medium.

CONTRIBUTING.md

Lines changed: 69 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
<p>This document outlines the process for joining our team and contributing to the VRMS Github repository. If you notice errors or have important information to add, please feel free to propose changes to this document with a pull request</p>
55

6-
76
<h2>Table of Contents</h2>
87

98
- [**Part 1 : How to join the team**](#part-1--how-to-join-the-team)
@@ -24,15 +23,16 @@
2423
- [**4.1 Push changes to your forked repository**](#41-push-changes-to-your-forked-repository)
2524
- [**4.2 Create a pull request on the VRMS repository**](#42-create-a-pull-request-on-the-vrms-repository)
2625

27-
2826
## **Part 1 : How to join the team**
2927

3028
### **1.1 VRMS contributor expectations**
29+
3130
- Attend at least 1 team meeting per week
3231
- Devote a minimum of 6 hours per week to working on VRMS assignments
3332
- Communicate with the team leadership if you plan to step away from the project
3433

3534
### **1.2 Reach out to us on Slack**
35+
3636
If you would like to contribute to our project, please reach out to the team leads on Slack or at one of our weekly meetings. You can find the current project team, their slack links, and our team meeting times on the [VRMS Project Details Page](https://www.hackforla.org/projects/vrms).
3737

3838
### **1.3 Become a member of the repository Team**
@@ -50,15 +50,16 @@ These steps are manditory in order to contribute to all HackforLA projects.
5050
## **Part 2: How to set up the development environment**
5151

5252
### **2.1 Fork the repository**
53-
*A fork is a copy of the repository that will be placed on your GitHub account url.*
5453

55-
* In https://github.com/hackforla/VRMS, look for the fork icon in the top right. Click it and create a fork of the repository.
54+
_A fork is a copy of the repository that will be placed on your GitHub account url._
55+
56+
- In https://github.com/hackforla/VRMS, look for the fork icon in the top right. Click it and create a fork of the repository.
5657

57-
* It should create a copy here: https://github.com/YOUR_GITHUB_USERNAME/vrms, where `YOUR_GITHUB_USERNAME` is replaced with your github username.
58+
- It should create a copy here: https://github.com/YOUR_GITHUB_USERNAME/vrms, where `YOUR_GITHUB_USERNAME` is replaced with your github username.
5859

5960
> NOTE: This copy is on a remote server on the GitHub website and not on your computer yet.
6061
61-
* Click the icon again, it will give you the URL associated with your forked repository and not create a new fork.
62+
- Click the icon again, it will give you the URL associated with your forked repository and not create a new fork.
6263

6364
### **2.2 Clone the remote repository to your local computer**
6465

@@ -67,39 +68,42 @@ The following process will make a copy of the fork that you just created on your
6768
1. Create a new folder on your local computer that will contain `hackforla` projects.
6869

6970
2. In your shell (terminal), navigate to this folder then run the following commands:
70-
```bash
71-
git clone https://github.com/YOUR_GITHUB_USERNAME/vrms.git
72-
```
7371

74-
You should now have a new folder in your `hackforla` folder called `vrms`.
72+
```bash
73+
git clone https://github.com/YOUR_GITHUB_USERNAME/vrms.git
74+
```
75+
76+
You should now have a new folder in your `hackforla` folder called `vrms`.
7577

7678
3. Verify which URL your `origin` remote is pointing to:
77-
```bash
78-
git remote show origin
79-
```
80-
Your terminal should return:
81-
```bash
82-
remote origin
83-
Fetch URL: https://github.com/YOUR_GITHUB_USERNAME/vrms.git
84-
Push URL: https://github.com/YOUR_GITHUB_USERNAME/vrms.git
85-
...
86-
```
87-
88-
If you accidentally cloned the `hackforla/vrms.git` then you can change your local copy to upload to your fork with the following:
89-
90-
```bash
91-
git remote set-url origin https://github.com/YOUR_GITHUB_USERNAME/vrms.git
92-
```
79+
80+
```bash
81+
git remote show origin
82+
```
83+
84+
Your terminal should return:
85+
86+
```bash
87+
remote origin
88+
Fetch URL: https://github.com/YOUR_GITHUB_USERNAME/vrms.git
89+
Push URL: https://github.com/YOUR_GITHUB_USERNAME/vrms.git
90+
...
91+
```
92+
93+
If you accidentally cloned the `hackforla/vrms.git` then you can change your local copy to upload to your fork with the following:
94+
95+
```bash
96+
git remote set-url origin https://github.com/YOUR_GITHUB_USERNAME/vrms.git
97+
```
9398

9499
4. Add another remote called `vrms` that points to the `hackforla` version of the repository. This will allow you to incorporate changes later:
95-
```bash
96-
git remote add vrms https://github.com/hackforla/vrms.git
97-
```
100+
```bash
101+
git remote add vrms https://github.com/hackforla/vrms.git
102+
```
98103

99104
Note: Understanding how git remotes work will make collaborating much easier. You can learn more about remotes [here](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/configuring-a-remote-for-a-fork) and [here](https://git-scm.com/book/en/v2/Git-Basics-Working-with-Remotes).
100105

101-
102-
### **2.3 Get up and running**
106+
### **2.3 Get up and running**
103107

104108
1. Have [Node](https://nodejs.org/en/download/) and NPM installed locally:
105109

@@ -128,7 +132,7 @@ Note: Understanding how git remotes work will make collaborating much easier. Yo
128132

129133
Note 2: `touch` is a Unix/Linux or Mac command; It is not available in Windows. In Windows, use a text editor (e.g. Notepad) to create an empty file and save it in each of the locations as `.env` . (If you use Windows Explorer to create the file it will create a file called `.env.txt`, which will not work.)
130134

131-
- Then paste the content from the [document](https://docs.google.com/document/d/1PdcZhyo2a2lr0JNcgyzpWi98tGkZeH1Zxz-Jnf6JQDU/edit?usp=sharing). It is accessible for the project team members only.
135+
- Then paste the content from the [document](https://docs.google.com/document/d/1PdcZhyo2a2lr0JNcgyzpWi98tGkZeH1Zxz-Jnf6JQDU/edit?usp=sharing). It is accessible for the project team members only.
132136

133137
- _Please note that the `ports` for the frontend and backend are set in this location_
134138

@@ -140,16 +144,15 @@ Note: Understanding how git remotes work will make collaborating much easier. Yo
140144

141145
- Navigate to the root of the application `vrms/` and run `yarn start`
142146

143-
*Troubleshooting :* If you encounter the following error after running `yarn start`:
144-
145-
```
146-
Error: error:0308010C:digital envelope routines::unsupported
147-
```
148-
Try changing your node version to `16.14.2` by running `nvm use 16.14.2`. If you do not have `nvm` installed, see [install instructions](https://github.com/nvm-sh/nvm#installing-and-updating)
147+
_Troubleshooting :_ If you encounter the following error after running `yarn start`:
149148

149+
```
150+
Error: error:0308010C:digital envelope routines::unsupported
151+
```
150152

151-
You should now have a live app. Happy hacking.
153+
Try changing your node version to `16.14.2` by running `nvm use 16.14.2`. If you do not have `nvm` installed, see [install instructions](https://github.com/nvm-sh/nvm#installing-and-updating)
152154

155+
You should now have a live app. Happy hacking.
153156

154157
### **2.4 Running Tests**
155158

@@ -166,66 +169,68 @@ To view and edit the development database manually, you can download [MongoDB Co
166169

167170
If you want to install a local copy to experiment with and learn more about MongoDB, you can use [this tutorial](https://zellwk.com/blog/local-mongodb/)
168171

169-
170-
171172
## **Part 3: How to work on issues**
172173

173-
174174
### **3.1 Claim an Issue**
175175

176-
Developers may assign themselves to issues from the [Prioritized Backlog column](https://github.com/hackforla/VRMS/projects/12#column-19074778) of the project board.
176+
Developers may assign themselves to issues from the [Prioritized Backlog column](https://github.com/orgs/hackforla/projects/72/views/1?filterQuery=backlog) of the project board.
177177

178178
The Prioritized Backlog column is filtered so the first (top) issue has the highest priority and should be worked on next if possible.
179179

180180
Developers may choose from issues with the following `role` labels:
181+
181182
- `role: Front End`
182183
- `role: Back End`
183184
- `role: Database`
184185

185186
Claiming an issue is a two step process:
187+
186188
1. Assign yourself to the issue using the gear icon in the upper right corner of the issue where it says "Assignees"
187189
2. Move the issue from the `Prioritized Backlog` to the `In Progress` column of the project board
188190

189-
190191
### **3.2 Create a new branch for each issue you work on**
191-
You will create a new branch for each issue you work on. Doing all your work on feature branches leaves your repository's main branch unmodified and greatly simplifies keeping your fork in sync with the main project.
192192

193+
You will create a new branch for each issue you work on. Doing all your work on feature branches leaves your repository's main branch unmodified and greatly simplifies keeping your fork in sync with the main project.
193194

194-
1. Before creating a new branch, always make sure you are currently on the `development` branch by using the command
195-
```bash
196-
git branch
197-
```
195+
1. Before creating a new branch, always make sure you are currently on the `development` branch by using the command
196+
```bash
197+
git branch
198+
```
198199
2. Before creating a new branch, always pull down the latest changes from the `development` branch by using the command
199-
```bash
200-
git pull vrms development
201-
```
200+
```bash
201+
git pull vrms development
202+
```
202203
3. Finally, create a new branch where you will work on your issue by using the command:
203-
```bash
204-
git checkout -b your-branch-name
205-
```
204+
```bash
205+
git checkout -b your-branch-name
206+
```
206207

207208
### **3.3 Work on the Issue**
208-
Every issue will contain action items you must complete before you are ready to submit a pull request. Be sure to use the checkboxes as you complete each action item so we can track your progress!
209209

210+
Every issue will contain action items you must complete before you are ready to submit a pull request. Be sure to use the checkboxes as you complete each action item so we can track your progress!
210211

211212
After you have completed the action items, add and commit the changes to your new branch using the commands
213+
212214
```
213215
git add .
214216
git commit -m "your commit message"
215-
```
216-
217+
```
217218

218219
## **Part 4: How to create pull requests**
220+
219221
### **4.1 Push changes to your forked repository**
222+
220223
1. Before pushing code, always pull down the latest changes from the `development` branch by using the command
221-
```
222-
git pull vrms development
223-
```
224+
```
225+
git pull vrms development
226+
```
224227
2. Once you are satisfied with your changes, push them to the feature branch you made within your remote repository.
225-
```
226-
git push --set-upstream origin your-branch-name
227-
```
228+
```
229+
git push --set-upstream origin your-branch-name
230+
```
231+
228232
### **4.2 Create a pull request on the VRMS repository**
233+
229234
1. Go to your fork of the VRMS repository on GitHub and click on the `Compare & pull request` button. <details><summary>See screenshot</summary> <img src="https://user-images.githubusercontent.com/73561520/220488394-09bc759e-98d9-4a09-86c6-66378cf50923.png"/></details>
230235
2. Be sure to title your pull request by summarizing the changes you made
231236
3. Be sure to add your issue number where the template says `Fixes #replace_this_text_with_the_issue_number`

backend/models/user.model.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,11 @@ const userSchema = mongoose.Schema({
99
lastName: { type: String },
1010
},
1111
email: { type: String, unique: true },
12-
accessLevel: { type: String, default: "user" },
12+
accessLevel: {
13+
type: String,
14+
enum: ["user", "admin", "superadmin"], // restricts values to "user", "admin" and "superadmin"
15+
default: "user"
16+
},
1317
createdDate: { type: Date, default: Date.now },
1418
currentRole: { type: String }, // will remove but need to update check-in form
1519
desiredRole: { type: String }, // will remove but need to update check-in form

backend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"cors": "^2.8.5",
4545
"dotenv": "^8.2.0",
4646
"dotenv-expand": "^5.1.0",
47-
"express": "^4.17.1",
47+
"express": "^4.20.0",
4848
"express-validator": "^6.6.1",
4949
"googleapis": "^59.0.0",
5050
"helmet": "^3.22.0",

0 commit comments

Comments
 (0)