-
Notifications
You must be signed in to change notification settings - Fork 107
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
fix(proposal): 404 error for co-speaker #1188
base: master
Are you sure you want to change the base?
Conversation
@mattwang44 uncertain if it's a good solution: When I simply remove if/else statement in the dispatch function, 404 no longer shows up(of course) while speaker A remains unaffected(Did I miss anything?) |
記得修改 test cases |
賀! 研究中 |
b7b01ac
to
b5de854
Compare
Hide the form for co-speaker that contains buttons of decision Accepted/Declined selection.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1188 +/- ##
==========================================
+ Coverage 71.19% 73.99% +2.79%
==========================================
Files 84 81 -3
Lines 3451 3057 -394
==========================================
- Hits 2457 2262 -195
+ Misses 994 795 -199 ☔ View full report in Codecov by Sentry. |
@@ -34,7 +34,7 @@ | |||
<td>{{ speaker_info.get_status_display }}</td> | |||
<td> | |||
<form method="post" | |||
action="{% url 'additional_speaker_set_status' pk=speaker_info.pk %}"> | |||
action="{% url 'additional_speaker_set_status' pk=speaker_info.pk %}" hidden> |
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.
這個 form 永遠都會被藏起來,這是我們想要的嗎?
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.
果然答案沒有這麼簡單. 我再摸摸.
方向上是做一個switch?
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.
根據 discord 討論的 method 1,現況是後端已經有 switch(也就是 registry 存的 f'{settings.CONFERENCE_DEFAULT_SLUG}.proposals.editable'
),方向是讓前端能根據這個 switch 現在是開或關來控制下列其一(可能需要先討論要選擇哪個):
a. 這個 form 上能夠調整共同講者狀態之按鈕的 disabled 與否
b. 這個 form 的顯示與否
c. 可能有其他做法?
This reverts commit 8eb2728.
Add switch on user_dashboard determined by the parameter "proposals_editable" in templates.
Add uneditable table and messages when editable parameter switches off.
Add test for additional speaker under uneditable condition.
@mattwang44 I thought “request” can be one of parameters to switch the edit status and check if additional speaker is allowed to update/cancel the form during uneditable time. ...seems like “request” is not included in these two forms. What is the key par should I consider? |
@mattwang44 跟GPT協作找到了一個方法是用RequestFactory來測試: |
Types of changes
Thanks for sending a pull request! Please fill in the following content to let us know better about this change.
Please put an
x
in the box that appliesDescription
Resolve 404 error and strange style of table after co-speaker pressed accept/decline during reviewing stage, which "SLUG.proposals.editable" is false.
Steps to Test This Pull Request
Steps to reproduce the behavior:
Expected behavior
404 happened in Step[7] disappear.
More Information
Screenshots