summaryrefslogtreecommitdiffstats
path: root/engagements/templates/engagements/organisation_list.html
blob: 4328067e4521841e2cfcc894803a034d1f799ce7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
{% extends "core/base.html" %}

{% block content %}

<div class="flex py-4">
    <div class="w-full px-4 py-8 my-5 bg-white shadow-md rounded-lg">
        <header class="bg-blue-100 p-4">
            <h2 class="text-2xl font-bold">Organisations</h2>
        </header>
        <div class="p-4 mb-4">
            <div class="overflow-x-auto">
                <table class="w-full divide-y divide-gray-200">
                    <thead class="bg-gray-50">
                        <tr>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Organisation</th>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Team</th>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Is Regulated?</th>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Responsible Persons</th>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Accountable Persons</th>
                            <th scope="col" class="px-2 py-1 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Information Holders</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-200">
                        {% for obj in object_list %}
                        <tr>
                            <td class="px-2 py-1 whitespace-nowrap text-m">{{ obj.name }}</td>
                            <td class="px-2 py-1 whitespace-nowrap text-m">{{ obj.lead_team }}</td>
                            <td class="text-center px-2 py-1 whitespace-nowrap text-m">
                                {% if obj.is_regulated_entity %}
                                    &#9989;
                                {% else %}
                                    &#10060;
                                {% endif %}
                            </td>
                            <td class="px-2 py-1 whitespace-nowrap text-m">
                                {% if obj.rp.all %}
                                <ul>
                                {% for p in obj.rp.all  %}
                                <li>{{ p.first_name }} {{p.last_name }}</li>    
                                {% endfor %}
                                </ul>
                                {% else %}
                                   <p>-</p> 
                                {% endif %}
                            </td>
                            <td class="px-2 py-1 whitespace-nowrap text-m">
                                {% if obj.ap.all %}
                                <ul>
                                {% for p in obj.ap.all  %}
                                <li>{{ p.first_name }} {{p.last_name }}</li>    
                                {% endfor %}
                                </ul>
                                {% else %}
                                   <p>-</p> 
                                {% endif %}
                            </td>
                            <td class="px-2 py-1 whitespace-nowrap text-m">
                                {% if p.obj.ih.all %}
                                <ul>
                                {% for p in obj.ih.all  %}
                                <li>{{ p.first_name }} {{p.last_name }}</li>    
                                {% endfor %}
                                </ul>
                                {% else %}
                                   <p>-</p> 
                                {% endif %}
                            </td>
                        </tr>
                        {% endfor %}
                    </tbody>
                </table>

            </div>

        </div>
    </div>
</div>

{% endblock content %}