link_box.html 737 Bytes
Newer Older
1
{% load go_extras %}
Jean Michel Rouly's avatar
Jean Michel Rouly committed
2
{% load qr_tags %}
3

4
5
6
7
8
9
10
11
<div class="link-box">
  <p>
    <strong>Long:</strong> <a href="{{url.target}}">{{url.target}}</a>
    <br />

    <strong>Short:</strong> <a href="/{{url.short}}">{{url.short}}</a>
    <br />

12
    {% if url.owner = request.user and request.user|is_registered %}
13
14
15
    <strong>Clicks:</strong> {{url.clicks}}
    <br />

16
    <strong>Expires:</strong> {{url.expires|default_if_none:"Never"}}
17
18
    <br />

19
    <strong>QR Code:</strong> <br/> {%qr_from_text url.get_absolute_url 90%}
20
21
    <br />

22
23
24
25
26
27
28
29
30
    <strong>
      <a href="{%url 'delete' url.short%}"
      onclick="return confirm('Are you sure you want to delete this link?');">
        Delete
      </a>
    </strong>
    {% endif %}
  </p>
</div>