Projet

Général

Profil

0001-manager-use-list-and-icons-for-exception-sources-386.patch

Frédéric Péters, 23 décembre 2019 13:33

Télécharger (3,15 ko)

Voir les différences:

Subject: [PATCH] manager: use list and icons for exception sources (#38689)

 chrono/manager/static/css/style.scss          |  7 ++++
 .../chrono/manager_import_exceptions.html     | 32 +++++--------------
 2 files changed, 15 insertions(+), 24 deletions(-)
chrono/manager/static/css/style.scss
274 274
		width: 10em;
275 275
	}
276 276
}
277

  
278
ul.objects-list.single-links li a.link-action-icon.refresh {
279
	margin-right: 3em;
280
	&::before {
281
		content: "\f021"; /* refresh */
282
	}
283
}
chrono/manager/templates/chrono/manager_import_exceptions.html
14 14

  
15 15
<form method="post" enctype="multipart/form-data">
16 16
  {% if exception_sources %}
17
  <table class="main">
18
    <thead>
19
      <tr>
20
        <th>{% trans "Exceptions" %}</th>
21
        <th></th>
22
        <th></th>
23
      </tr>
24
    </thead>
25
    <tbody>
17
  <ul class="objects-list single-links">
26 18
      {% for object in exception_sources %}
27
      <tr>
28
        <td>
29
          <span title="{{ object }}">
30
            {% if object.ics_filename %}{{ object|truncatechars:50 }}{% else %}<a href="{{ object }}">{{ object|truncatechars:50 }}</a>{% endif %}
31
          </span>
32
        </td>
33
        <td>
19
        <li>
20
          <a title="{{ object }}" {% if not object.ics_filename %}href="{{ object }}"{% endif %}>{% if object.ics_filename %}{{ object|truncatechars:50 }}{% else %}{{ object|truncatechars:50 }}{% endif %}</a>
34 21
          {% if object.ics_filename %}
35
            <a rel="popup" href="{% url 'chrono-manager-time-period-exception-source-replace' object.pk %}">{% trans "replace" %}</a>
22
            <a rel="popup" class="link-action-icon refresh" href="{% url 'chrono-manager-time-period-exception-source-replace' object.pk %}">{% trans "replace" %}</a>
36 23
          {% else %}
37
            <a href="{% url 'chrono-manager-time-period-exception-source-refresh' object.pk %}">{% trans "refresh" %}</a>
24
            <a class="link-action-icon refresh" href="{% url 'chrono-manager-time-period-exception-source-refresh' object.pk %}">{% trans "refresh" %}</a>
38 25
          {% endif %}
39
        </td>
40
        <td><a rel="popup" href="{% url 'chrono-manager-time-period-exception-source-delete' object.pk %}">{% trans "remove" %}</a></td>
41
      </tr>
26
          <a rel="popup" class="delete" href="{% url 'chrono-manager-time-period-exception-source-delete' object.pk %}">{% trans "remove" %}</a>
27
        </li>
42 28
      {% endfor %}
43
    </tbody>
44
   </table>
45
   <br />
29
  </ul>
46 30
  {% endif %}
47 31

  
48 32
  <p class="notice">{% trans "To add new exceptions, you can upload a file or specify an address to a remote calendar." %}</p>
49
-