1ee243378a9a0023d658997e27b844b833cec610
[redakcja.git] / apps / catalogue / templates / catalogue / book_owner.html
1 {% extends "catalogue/base.html" %}
2 {% load i18n %}
3
4 {% block inner_content %}
5     <a href="{% url 'catalogue_user' %}">{% trans "My resources" %}</a> /
6     {% if doc.owner_organization %}
7         <a href="{% url 'organizations_main' doc.owner_organization.pk %}">{{ doc.owner_organization }}</a>
8     {% else %}
9         {{ doc.owner_user.first_name }} {{ doc.owner_user.last_name }}
10     {% endif %} /
11     <h1 style='margin-bottom: 1em'>{{ doc.meta.title }}</h1>
12
13
14     <form enctype="multipart/form-data" method="POST">
15     {% csrf_token %}
16         <label for="owner">{% trans "Owner" %}</label>
17             <select class="form-control" name="owner_organization">
18                 <option value=''>{{ request.user }}</option>
19                 {% for org in request.user.membership_set.all %}
20                     <option value="{{ org.organization.pk }}"
21                         {% if doc.owner_organization == org.organization %}selected="selected"{% endif %}
22                     >{{ org.organization }}</option>
23                 {% endfor %}
24             </select>
25
26         <button style="margin-top:1em;" class="btn btn-default" type="submit">{% trans "Change owner" %}</button></td></tr>
27     </form>
28
29 {% endblock %}