Open jng34 opened 3 weeks ago
Want to review this pull request? Take a look at this documentation for a step by step guide!
From your project repository, check out a new branch and test the changes.
git checkout -b jng34-filteredPermissionsDataComp development
git pull https://github.com/jng34/VRMS.git filteredPermissionsDataComp
@trillium, can you confirm that the accessLevel in the dummy data object should be "admin" or "projectLead"?
const user = {
_id: 1,
name: {
firstName: "John",
lastName: "Doe"
},
accessLevel: "projectLead", // or "admin"
email: "johndoe@hackforla.org",
projects: ["Home Unite Us, VRMS"]
}
From the user.model.js
, the value "projectLead" is not in the enum.
accessLevel: {
type: String,
enum: ["user", "admin", "superadmin"], // restricts values to "user", "admin" and "superadmin"
default: "user"
},
It looks like we have this roleOnProject
property under the ProjectTeamMemberSchema.
const projectTeamMemberSchema = mongoose.Schema({
userId: { type: String }, // id of the user
projectId: { type: String }, // id of the project
teamMemberStatus: { type: String }, // Active or Inactive
vrmsProjectAdmin: { type: Boolean }, // does this team member have admin rights to the project in VRMS?
roleOnProject: { type: String }, // Developer, Project Manager, UX, Data Science
...})
cc: @jng34, @JackHaeg
Per @trillium recommend leaving values discussed above as-is, and making necessary adjustments in: https://github.com/hackforla/VRMS/issues/1801
@trillium, can you confirm this is okay, or should this PR include the changes in #1798? It should link to "/users". But, for the purpose of testing without the changes in the other PR, it uses "/users/permission-search" instead.
cc: @JackHaeg, @jng34
Fixes #1752
What changes did you make and why did you make them ?
/users/permission-search/admin
and/users/permission-search/projects
corresponding to each search tabAdmins
will be filtered alphabetically by first name andProject Leads
will be filtered alphabetically by Project name and by then first nameScreenshots of Proposed Changes Of The Website
Visuals before changes are applied
Visuals after changes are applied