Skip to content
Open
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% load i18n %}

<table class="proposals-table table table-striped table-hover">
<table class="proposals-table table table-responsive">
<thead>
<tr>
<th class="proposal-title">{% trans 'Title' %}</th>
Expand Down Expand Up @@ -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>
Copy link
Member

Choose a reason for hiding this comment

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

這個 form 永遠都會被藏起來,這是我們想要的嗎?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

果然答案沒有這麼簡單. 我再摸摸.
方向上是做一個switch?

Copy link
Member

@mattwang44 mattwang44 Apr 25, 2024

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. 可能有其他做法?

{% csrf_token %}
{% if speaker_info.status != 'accepted' %}
<button type="submit" name="status" value="accepted"
Expand Down