[ticket/17414] Add placeholder when there are no questions yet

PHPBB-17414
This commit is contained in:
Marc Alexander 2024-10-05 21:40:08 +02:00
parent c02f8688c4
commit d85267707c
No known key found for this signature in database
GPG key ID: 50E0D2423696F995
2 changed files with 7 additions and 0 deletions

View file

@ -18,11 +18,13 @@
<tr>
<th colspan="3">{L_QUESTIONS}</th>
</tr>
{% if questions %}
<tr class="row3">
<td style="text-align: center;">{L_QUESTION_TEXT}</td>
<td style="width: 5%; text-align: center;">{L_QUESTION_LANG}</td>
<td style="vertical-align: top; width: 50px; text-align: center; white-space: nowrap;">{L_ACTION}</td>
</tr>
{% endif %}
</thead>
<tbody>
@ -33,6 +35,10 @@
<td style="text-align: center;">{{ question.QUESTION_LANG }}</td>
<td style="text-align: center;"><a href="{{ question.U_EDIT }}">{{ ICON_EDIT }}</a> <a href="{{ question.U_DELETE }}">{{ ICON_DELETE }}</a></td>
</tr>
{% else %}
<tr>
<td class="row3 centered-text" colspan="3">{{ lang('QA_NO_QUESTIONS') }}</td>
</tr>
{% endfor %}
</tbody>

View file

@ -61,4 +61,5 @@ $lang = array_merge($lang, array(
'QA_ERROR_MSG' => 'Please fill in all fields and enter at least one answer.',
'QA_LAST_QUESTION' => 'You cannot delete all questions while the plugin is active.',
'QA_NO_QUESTIONS' => 'There are no questions yet.',
));