Skip to content

Add a CCE Minor Note feature attached to the Notes section in the User profile#1737

Open
munsakad wants to merge 3 commits into
developmentfrom
dee_and_bright_CCE_Minor_Note_feature
Open

Add a CCE Minor Note feature attached to the Notes section in the User profile#1737
munsakad wants to merge 3 commits into
developmentfrom
dee_and_bright_CCE_Minor_Note_feature

Conversation

@munsakad

Copy link
Copy Markdown
Contributor

Issue Description

Fixes issue #1405

  • The user profile Notes section had no way to flag a note as related to the CCE Minor, even though the profile already tracks CCE Minor interest. This adds a "CCE Minor" note tag alongside the existing Bonner tag.

Changes

  • Added a "Related to CCE Minor" toggle to the Add Note modal, shown only when the user has a CCE Minor interest (volunteer.minorInterest).
    -Display a "CCE Minor" prefix in the note's Visible To column, mirroring the existing Bonner prefix convention.
    -Pass the flag through the Edit button via a data-cceminor attribute so the modal can pre-fill it.
    -All changes are confined to app/templates/main/userProfile.html.

Testing

Open a profile for a user with CCE Minor interest and click Add Note, confirm that the "Related to CCE Minor" toggle appears.
For a user without CCE Minor interest, confirm the toggle is hidden.
Verify a note flagged as CCE Minor shows the "CCE Minor" prefix in the Visible To column.
Confirm that the Bonner toggle and existing note behavior are unchanged.

@DanielRukwasha

Copy link
Copy Markdown
Contributor

Overall Impression

The feature makes sense and the approach of mirroring Bonner tag behavior is a smart, consistent design decision.
However,

The template references row.isCCEMinorNote and submits a cceMinor form field, but there are no backend changes in this
My question will be

  • Does the Note model already have an isCCEMinorNote field? If not, this will silently fail (Jinja will render it as
    False/empty with no error).
  • Is there a route handler that reads the cceMinor POST parameter and saves it?
    e

DanielRukwasha

This comment was marked as resolved.

@github-actions

Copy link
Copy Markdown

View Code Coverage

@MImran2002 MImran2002 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are the changes or the bugs that I encounter:
Fix 1: I think this issue alone should not be solved with a HTML. This is broader because this could potentially include javascript and python. (Hint: look at how bonner notes work)

Fix 2: Because the code only holds html I am not seeing any cce minor flags from my side:
(These three notes are created by toggling cceminor)

Image

Fix 3: When I toggle the CCEminor and save the note, just like the bonner if i were to create a bonner note and go back and look i will see the model has bonner note toggle
bonner example:

Image

cceminor:

Image

if its cceminor the toggle should be toggled to show it is working.

Fix 4: In an instance where both the bonner and cce minor are toggle the bonner notes accordion seems to overwrite the cceminor notes and the note only appear in bonner this scenario should be considered as in should the note that have both toggles need to appear on both or one of them.

@MImran2002

Copy link
Copy Markdown
Contributor

@munsakad and @brightfietsop-ux after the department issue you guys worked on, while waiting for that issue to be reviewed and merged. Worked on this as we don't want this to be dragged into the weeks ahead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants