2021-08-22 17:07:19 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8">
|
|
|
|
<title>Upravljanje institucije - Šolar</title>
|
2021-12-23 07:51:37 +00:00
|
|
|
<link rel="stylesheet" href="../static/css/header.css" type="text/css">
|
|
|
|
<link rel="stylesheet" href="../static/css/form.css" type="text/css">
|
|
|
|
<link rel="stylesheet" href="../static/css/simple-grid.css" type="text/css">
|
2022-02-13 14:20:20 +00:00
|
|
|
<link rel="stylesheet" href="../static/css/slovenscina-admin.css" type="text/css">
|
2021-12-23 07:51:37 +00:00
|
|
|
<link rel="stylesheet" href="../static/css/manage-institution.css" type="text/css">
|
2022-02-13 14:20:20 +00:00
|
|
|
|
|
|
|
|
2021-08-22 17:07:19 +00:00
|
|
|
</head>
|
|
|
|
<body>
|
2021-12-04 17:49:20 +00:00
|
|
|
<header>
|
2021-12-23 07:51:37 +00:00
|
|
|
<div class="logo"><a href="../"><img src="../static/image/logo-white.svg"/></a></div>
|
2022-02-13 14:20:20 +00:00
|
|
|
<div class="dropdown">
|
|
|
|
<button class="dropbtn"><img src="/static/image/menu.svg"/></button>
|
|
|
|
<div class="dropdown-content">
|
|
|
|
<a href="../oddaja">Oddaja</a>
|
|
|
|
<a href="../zgodovina">Zgodovina</a>
|
|
|
|
<a href="../pogodbe">Ekipa</a>
|
|
|
|
{% if is_institution_coordinator %}
|
|
|
|
<hr/>
|
|
|
|
<a href="../manage-institution">Upravljaj z institucijo</a>
|
|
|
|
{% endif %}
|
|
|
|
{% if is_admin %}
|
|
|
|
<hr/>
|
|
|
|
<a href="../admin">Administracijski meni</a>
|
|
|
|
{% endif %}
|
|
|
|
<hr/>
|
|
|
|
<a href="https://slovenscina.eu/" target="_blank">Več informacij</a>
|
|
|
|
<hr/>
|
|
|
|
<a href="../logout">Odjava</a>
|
|
|
|
</div>
|
2021-12-04 17:49:20 +00:00
|
|
|
</div>
|
|
|
|
</header>
|
|
|
|
<div class="container" style="margin-top:8rem;">
|
2021-08-22 17:07:19 +00:00
|
|
|
{% with messages = get_flashed_messages() %}
|
|
|
|
{% if messages %}
|
2022-02-13 14:20:20 +00:00
|
|
|
<div>
|
2021-08-22 17:07:19 +00:00
|
|
|
{{ messages[0] }}
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
{% endwith %}
|
|
|
|
|
2022-02-14 14:01:03 +00:00
|
|
|
<h1>{{institution.name}}</h1>
|
2021-08-22 17:07:19 +00:00
|
|
|
<h3>Seznam uporabnikov v vaši instituciji</h3>
|
2022-02-13 14:47:19 +00:00
|
|
|
<table class="tableFixHead">
|
2021-08-22 17:07:19 +00:00
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Ime in priimek</th>
|
|
|
|
<th>Email</th>
|
2022-02-13 14:20:20 +00:00
|
|
|
<th>Vloga</th>
|
|
|
|
<th>Akcije</th>
|
2021-08-22 17:07:19 +00:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for item in institution_users %}
|
|
|
|
<tr>
|
|
|
|
<td>{{item.name}}</td>
|
|
|
|
<td>{{item.email}}</td>
|
2022-02-13 14:47:19 +00:00
|
|
|
<td>
|
|
|
|
<div>
|
2022-02-14 14:01:03 +00:00
|
|
|
<a href="javascript:void(0);" onclick="toggleEditForm(this)" class="toggle-edit-role">Spremeni</a>
|
|
|
|
{{role_map[item.id]}}
|
2022-02-13 14:47:19 +00:00
|
|
|
</div>
|
2022-02-14 14:01:03 +00:00
|
|
|
<form action="../changeuserrole-institution" method="post" style="display:none;">
|
2022-02-13 14:47:19 +00:00
|
|
|
<input type="hidden" id="user-id" name="user-id" value="{{item.id}}"/>
|
2022-02-14 14:01:03 +00:00
|
|
|
<select class="role" name="role">
|
2022-02-13 14:47:19 +00:00
|
|
|
<option value="coordinator">Koordinator/-ka</option>
|
|
|
|
<option value="mentor">Mentor/-ica</option>
|
|
|
|
<option value="other">Druga vloga</option>
|
|
|
|
</select>
|
|
|
|
<input type="submit" value="Shrani"/>
|
|
|
|
</form>
|
|
|
|
</td>
|
2022-02-13 14:20:20 +00:00
|
|
|
<td>
|
|
|
|
<form action="../deluserfrominstitution" method="post">
|
|
|
|
<input type="hidden" id="user_id" name="user_id" value="{{item.id}}">
|
|
|
|
<input type="submit" value="Odstrani uporabnika">
|
|
|
|
</form>
|
|
|
|
</td>
|
2021-08-22 17:07:19 +00:00
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
<br>
|
2022-02-13 14:20:20 +00:00
|
|
|
|
2021-12-04 17:49:20 +00:00
|
|
|
</div>
|
2021-08-22 17:07:19 +00:00
|
|
|
</body>
|
2022-02-13 14:47:19 +00:00
|
|
|
<script>
|
|
|
|
var toggleEditForm = function(el) {
|
|
|
|
var td = el.closest("td");
|
|
|
|
el.closest("div").style.display = "none";
|
|
|
|
td.querySelector("form").style.display = "block";
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</script>
|
2022-02-14 14:01:03 +00:00
|
|
|
</html>
|