PATCH /profiles/current lets a participant set their participantType
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 68/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- typescript
- Lĩnh vực
- authorization
Hướng nghiên cứu
Tìm kiểu yêu cầu được dùng bởi PATCH /profiles/current và định nghĩa của UpdateProfileRequest. Trước tiên, lần theo route đến phần xác thực yêu cầu rồi so sánh với route quản trị PATCH /profiles/{profileId}. Gán cho route người tham gia một kiểu yêu cầu loại trừ participantType; hoàn tất khi các thao tác cập nhật của người tham gia không thể thay đổi trường này, còn các thao tác cập nhật của quản trị viên vẫn có thể.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
PATCH /profiles/current writes the request body straight into the participant's profile, and UpdateProfileRequest includes participantType. So a participant can make themselves STANDARD, GUARDIAN, DEPENDENT_AGE or DEPENDENT_OTHER. The profile edit page doesn't send this field, so it takes a hand-made request.
participantType decides whose survey answers set a dependent's consent: a guardian's answers are copied to the family's dependents, combined across co-guardians. The admin route, PATCH /profiles/{profileId}, guards this. It refuses to leave a dependent with no guardian or to add a dependent to a family with no guardian, and it recalculates the dependents' answers afterwards. The participant route does none of that. A guardian can step out of their family's consent, or a participant can mark themselves a dependent in a family with no guardian, and the dependents' answers aren't recalculated either way.
Fix: give PATCH /profiles/current its own request type without participantType, and leave type changes to the admin route.
Related: #580, #585.
- Ngôn ngữ chính
- TypeScript
- Star
- 4
- Fork
- 0
- Merge trung bình
- 14 giờ 50 phút
- Pull request đã merge (30 ngày)
- 5
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của Garvan-Data-Science-Platform/ctrl
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 82/100
-
admin-client backend bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
-
backend bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
backend bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
-
backend bug enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Garvan-Data-Science-Platform/ctrl#956 · 1 bình luận ·
Tất cả issue của Garvan-Data-Science-Platform/ctrl
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Chocobozzz/PeerTube#7832 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Pay to use?Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 66/100
darkreader/darkreader#16108 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Add: Dak Nong TV SDĐang mởcheck:passed streams:add
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
Maintainer thường phản hồi trong vòng 1 ngày
-
bug engine
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
frostney/GocciaScript#1746 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
agilepathway/label-checker#739 · 4 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày