engagingnewsproject / enp-platform

The core platform for the CME public facing website and peripheral solutions.
https://mediaengagement.org/
Other
4 stars 0 forks source link

Staff Members - Update Team Categories #323

Closed julia-elias closed 2 weeks ago

julia-elias commented 1 month ago

We need to change the "Team category" for each team member on the staff page so that it matches up with the new Team categories we've created (as seen in photo). image

Here is a link to a list of all the Team members and the categories that they should be assigned - https://docs.google.com/document/d/1XV6O2SrD-ZUfr4ND1luAAbUIwXw8Y_TIQTb0oh4YM9E/edit?usp=sharing.

Updating each Team Member's Category

  1. Sign into the WP Admin dashboard.

  2. Navigate to the list of Team members in the dashboard. image

  3. Search for the team member in the search bar or manually find their page. In this case, we're looking for Lee Anh Kahlor. image

  4. Hover over the team member's name, and select the "Quick edit" option on the team member's page. image

  5. Under the "Team category" option, uncheck the Team member's old category if it doesn't match up with their new Team category. For Lee Anh, she is designated as a Principal Investigator, so we will check that option. image

  6. Select the "update" button, and go view the Staff page to make sure the team member's icon and info is appearing under the correct category. image image

katalinadeaven commented 1 month ago

Once we have all of this sorted out on the live page let's get rid of the old designations on the WP dashboard end so there's no confusion (we should only need the new "Team Category" check box and not the others like "Team Semster" "Team Designation," etc.

luukee commented 1 month ago

An explanation for the devs (@julia-elias, @EthanL06, @Tominium, @DavidLungu) on how we can remove these modules:

  1. Go to a staff members WP Admin edit page and see what the name of these modules are. Or any other identifiying attributes. Like for "Team Designation" if you hover over the "Add new category link you will see team_designation in the URL. This tells us the taxonomy must be related to "team_designation" so we will search the theme code for that.

    Screenshot 2024-09-16 at 1 47 18 PM

    "taxonomy" what's that!?

    • WordPress taxonomies are systems for grouping and categorizing content, such as posts, using predefined or custom terms (e.g., categories or tags). They help organize content for easier navigation and filtering on a website.
  2. Searching the theme code:

    • Shift + Command + P - "team_designation"

    Screenshot 2024-09-16 at 2 04 23 PM

    "register_taxonomy" tells me this is where the taxonomy is set up, so lets check that out.

    _register_taxonomy is a WordPress function used to create custom taxonomies, allowing you to group content in ways beyond the default categories and tags. This function can be applied to one or more post types and allows for hierarchical (like categories) or non-hierarchical (like tags) classifications._

  3. From reading the register_taxonomy docs in the link above I see that show_ui might have to do with what we want. So I'll set the src/Managers/Structures/PostTypes/Team.php registerTeamDesignation function to false, refresh the WP Admin staff edit page and I see the "Team designation" module is gone!!

    Screenshot 2024-09-16 at 2 19 06 PM

Main thing to learn

WordPress (coding in general) is all about relationships & refrences. Also, referring to docs are essential.

Using this knowledge will make you a WordPress professional in no time :)

luukee commented 2 weeks ago

@EthanL06

One issue i found was the Member Display Link ACF not working as it should & I think the ACF related and the template code was overwritten in a git merge. So we will need to bring that back.

Let me know of any questions you have. Thanks!