-
Notifications
You must be signed in to change notification settings - Fork 7
S24 privacy combined profile #1060
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
…rder to solve merging conflicts
This reverts commit a937cfd.
Generalized user privacy variable names and defined values for isPrivate to be PUBLIC or PRIVATE rather than False or True in Combined Profile View Model
Co-authored-by: Russ Tuck <[email protected]>
Co-authored-by: Russ Tuck <[email protected]>
Co-authored-by: Russ Tuck <[email protected]>
|
@jsenning I can't assign the review to you (as the author), but please review my changes from today. |
| /// user making the request.</param> | ||
| /// <returns>True if the user making the request is authorized to see | ||
| /// profile information for students, and false otherwise.</returns> | ||
| public bool CanISeeStudents(IEnumerable<AuthGroup> viewerGroups) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The naming of these methods is confusing, and it's odd that they're in AccountService since they aren't related to account data.
I think these would make more sense as extension methods on the type IEnumerable<AuthGroup> (probably in the Auth folder), since they are essentially methods for a set of auth groups. For example, this would become:
| public bool CanISeeStudents(IEnumerable<AuthGroup> viewerGroups) | |
| public static class AuthGroupExtensions { | |
| public static bool CanViewStudents(this IEnumerable<AuthGroup> viewerGroups) { | |
| if (viewerGroups.Contains(AuthGroup.SiteAdmin) || | |
| viewerGroups.Contains(AuthGroup.Police) || | |
| viewerGroups.Contains(AuthGroup.FacStaff) || | |
| viewerGroups.Contains(AuthGroup.Student)) | |
| { | |
| return true; | |
| } | |
| return false; | |
| } | |
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably be deleted, since it no longer serves any purpose.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This still enforces KeepPrivate for students. It is used in the Housing/Apartment code (which I don't believe is being used).
Gordon360/Models/ViewModels/PublicFacultyStaffProfileViewModel.cs
Outdated
Show resolved
Hide resolved
|
If it should be done then let's do it now. The code that uses these tables is only in the branches associated with the s24-privacy-combined-profile PRs on the API and UI.
Thank you!
Jonathan R. Senning
Professor of Mathematics and Computer Science
Gordon College, 255 Grapevine Road, Wenham, MA 01984-1899
Office: 978.867.4376
Sent from mobile phone, please forgive any typos.
-------- Original message --------
From: Evan Platzer ***@***.***>
Date: 7/14/25 12:15 PM (GMT-05:00)
To: gordon-cs/gordon-360-api ***@***.***>
Cc: Jonathan Senning ***@***.***>, Mention ***@***.***>
Subject: Re: [gordon-cs/gordon-360-api] S24 privacy combined profile (PR #1060)
** CAUTION: External Email: Do not click links or open attachments unless you recognize the sender and know the content is safe.**
@EjPlatzer commented on this pull request.
________________________________
In Gordon360/Models/CCT/dbo/UserPrivacy_Settings.cs<#1060 (comment)>:
+
+namespace Gordon360.Models.CCT;
+
+[PrimaryKey("gordon_id", "Field")]
+[Table("UserPrivacy_Settings", Schema = "dbo")]
+public partial class UserPrivacy_Settings
+{
+ [Key]
+ [StringLength(10)]
+ [Unicode(false)]
+ public string gordon_id { get; set; }
+
+ [Key]
+ [StringLength(50)]
+ [Unicode(false)]
+ public string Field { get; set; }
Typically, that's something y'all would do, but I don't think the current students have permissions to, so for the sake of time, I can do that. It might require further updates to the code though.
—
Reply to this email directly, view it on GitHub<#1060 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABRH2ALUDBR5XVRABDSRJTT3IPJHBAVCNFSM6AAAAAB65YAHXCVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZTAMJWHE2DGNJVGU>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
…don-cs/gordon-360-api into s24-privacy-combined-profile
…ordon-360-api into s24-privacy-combined-profile
Generalize privacy settings for items appearing in a user's profile.
This is a large PR and reflects work done during two consecutive summer practicums. It supersedes PR #1042 and #937 and is partnered with PR gordon-cs/gordon-360-ui#2355 in gordon-360-ui.
See gordon-cs/gordon-360-ui#2355 for a description. In particular, the conversation includes comments that probably should be in this conversation as they address how privacy is implemented in the API.