mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-02-04 08:13:38 +00:00
- Make the code work outside backups module. - Move code to main.js so that any app can use this functionality. - Make the code work for multiple such form fields in the same page. - Use only pure JS, don't use jQuery. - Add event handlers only after DOM content is loaded to avoid race conditions. Tests performed: - Checking the select-all button checks all options. - De-checking the select-all button de-checks all options. - De-checking one option when everything is checked, de-checks the select-all button. - Checking the last option when everything else is checked, checks the select-all button. - When loading a schedule page with all options checked, select-all button is checked. - When loading a schedule page with some option unchecked, select-all button is unchecked. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
32 lines
558 B
HTML
32 lines
558 B
HTML
{% extends "base.html" %}
|
|
{% comment %}
|
|
# SPDX-License-Identifier: AGPL-3.0-or-later
|
|
{% endcomment %}
|
|
|
|
{% load bootstrap %}
|
|
{% load i18n %}
|
|
{% load static %}
|
|
|
|
{% block content %}
|
|
<h2>{{ title }}</h2>
|
|
|
|
{% if name %}
|
|
<p>
|
|
{% trans 'Restore data from' %} {{ name }}
|
|
</p>
|
|
{% endif %}
|
|
|
|
<p>
|
|
<form class="form" method="post">
|
|
{% csrf_token %}
|
|
|
|
{{ form|bootstrap }}
|
|
|
|
<input id="restore_btn" type="submit"
|
|
class="btn btn-primary"
|
|
value="{% trans 'Restore' %}" />
|
|
</form>
|
|
</p>
|
|
|
|
{% endblock %}
|