|
|
@@ -14,27 +14,47 @@
|
|
|
|
|
|
{% block body %}
|
|
|
|
|
|
- {% if utente.errors %}
|
|
|
- {{ utente.errors }}
|
|
|
- {% for field in utente %}
|
|
|
+<!-- Nav tabs -->
|
|
|
+<ul class="nav nav-tabs" id="myTab" role="tablist">
|
|
|
+ <li class="nav-item" role="presentation">
|
|
|
+ <button class="nav-link active" id="home-tab" data-bs-toggle="tab" data-bs-target="#profile" type="button" role="tab" aria-controls="Profile" aria-selected="true">Profilo</button>
|
|
|
+ </li>
|
|
|
+ <li class="nav-item" role="presentation">
|
|
|
+ <button class="nav-link" id="profile-tab" data-bs-toggle="tab" data-bs-target="#documents" type="button" role="tab" aria-controls="Documents" aria-selected="false">Documenti</button>
|
|
|
+ </li>
|
|
|
+ <li class="nav-item" role="presentation">
|
|
|
+ <button class="nav-link" id="messages-tab" data-bs-toggle="tab" data-bs-target="#messages" type="button" role="tab" aria-controls="Messages" aria-selected="false">Logging</button>
|
|
|
+ </li>
|
|
|
+</ul>
|
|
|
+<!-- end nav tabs -->
|
|
|
+
|
|
|
+<!-- Tab panes -->
|
|
|
+<div class="tab-content">
|
|
|
+ <div class="tab-pane active" id="profiles" role="tabpanel" aria-labelledby="profile-tab" tabindex="0">
|
|
|
+ <div>
|
|
|
+ {% if utente.errors %}
|
|
|
+ {{ utente.errors }}
|
|
|
+ {% for field in utente %}
|
|
|
{% for error in field.errors %}
|
|
|
- <div class="alert alert-danger">
|
|
|
- <strong>{{ error|escape }}</strong>
|
|
|
- </div>
|
|
|
+ <div class="alert alert-danger">
|
|
|
+ <strong>{{ error|escape }}</strong>
|
|
|
+ </div>
|
|
|
{% endfor %}
|
|
|
- {% endfor %}
|
|
|
- {% for error in utente.non_field_errors %}
|
|
|
+ {% endfor %}
|
|
|
+ {% for error in utente.non_field_errors %}
|
|
|
<div class="alert alert-danger">
|
|
|
<strong>{{ error|escape }}</strong>
|
|
|
</div>
|
|
|
- {% endfor %}
|
|
|
- {% else %}
|
|
|
- Nessun Errore rilevato
|
|
|
- {% endif %}
|
|
|
+ {% endfor %}
|
|
|
+ {% else %}
|
|
|
+ Nessun Errore rilevato
|
|
|
+ {% endif %}
|
|
|
+ </div>
|
|
|
|
|
|
- <form name='UserEdit' method='post'>
|
|
|
- {% csrf_token %}
|
|
|
- <div class='form-group'>
|
|
|
+ <!-- editing parametri utente -->
|
|
|
+ <form name='UserEdit' method='post'>
|
|
|
+ {% csrf_token %}
|
|
|
+ <div class='form-group'>
|
|
|
<label for="codicefiscale">Codice Fiscale</label>
|
|
|
<input type='text' class='form-control' name='codicefiscale' id='codicefiscale' value='{{ utente.codicefiscale.value }}'>
|
|
|
|
|
|
@@ -50,30 +70,33 @@
|
|
|
<label for="mail" class="form-control-label">Email</label>
|
|
|
<input type='mail' class='form-control' name='mail' id='mail' value='{{ utente.mail.value }}'
|
|
|
|
|
|
- <label for="pin" class="form-control-label">Pin</label>
|
|
|
+ <label for="pin" class='form-control-label'>Pin</label>
|
|
|
<input type='text' class='form-control' name='pin' id='pin' value='{{ utente.pin.value }}'
|
|
|
- </div>
|
|
|
+ </div>
|
|
|
|
|
|
- <div class="form-check">
|
|
|
- <input type="checkbox" class="form-check-input" name='CancellaUtente' id='CancellaUtente'>
|
|
|
- <Label class="form-check-label" for='CancellaUtente'>Cancella Questo record!</label>
|
|
|
- </div>
|
|
|
+ <div class="form-check">
|
|
|
+ <input type="checkbox" class="form-check-input" name='CancellaUtente' id='CancellaUtente'>
|
|
|
+ <Label class="form-check-label" for='CancellaUtente'>Cancella Questo record!</label>
|
|
|
+ </div>
|
|
|
|
|
|
- <div>
|
|
|
+ <div class='form-check'>
|
|
|
<input type='submit' class="btn btn-secondary" value='Aggiorna'>
|
|
|
<input type='submit' class="btn btn-primary" name="ritorna" value="Ritorna">
|
|
|
- </td>
|
|
|
- </form>
|
|
|
-{% endblock %}
|
|
|
+ </div>
|
|
|
+ </form>
|
|
|
+ <!-- fine del form di editing -->
|
|
|
+ </div>
|
|
|
|
|
|
-{% block bodybottom %}
|
|
|
- <div><br><br></div>
|
|
|
- <div class='form-outline mb-3 text-center btn-primary h3'>
|
|
|
+ <div class="tab-pane" id="profile" role="tabpanel" aria-labelledby="document-tab" tabindex="0">
|
|
|
+ <!-- documenti -->
|
|
|
+ <div><br><br></div>
|
|
|
+
|
|
|
+ <div class='form-outline mb-3 text-center btn-primary h3'>
|
|
|
Elenco Documenti Associati
|
|
|
- </div>
|
|
|
- <div>
|
|
|
+ </div>
|
|
|
+
|
|
|
<table class='table table-striped table-hover'>
|
|
|
- <thead class='thead-dark'>
|
|
|
+ <thead class='thead-dark'>
|
|
|
<tr>
|
|
|
<th scope='col'>Documento</th>
|
|
|
<th scope='col'>Storage</th>
|
|
|
@@ -82,9 +105,9 @@
|
|
|
<th scope='col'>Elimina</th>
|
|
|
|
|
|
</tr>
|
|
|
- </thead>
|
|
|
- <tbody>
|
|
|
- {% for documento in documentiUtente %}
|
|
|
+ </thead>
|
|
|
+ <tbody>
|
|
|
+ {% for documento in documentiUtente %}
|
|
|
<tr>
|
|
|
<td> {{ documento.documento }} </td>
|
|
|
<td> {{ documento.storage}} </td>
|
|
|
@@ -93,63 +116,61 @@
|
|
|
<!-- <td> <input class='btn btn-primary' type='submit' name='Elimina' value='{{ documento.id }}'></td> -->
|
|
|
<td> <button type='button' class='btn btn-primary active' onclick="window.open('{% url "documento:finalize" documento.id uid %}')">Vedi</button>
|
|
|
<button type='button' class='btn btn-primary' data-bs-toggle='modal' data-bs-target='#ConfirmDeleteModal{{ documento.id }}' value='{{ documento.id }}'>Elimina!</button></td>
|
|
|
- </tr>
|
|
|
+ <td>
|
|
|
|
|
|
<!-- Modal -->
|
|
|
- <div class="modal fade" id="ConfirmDeleteModal{{ documento.id }}" tabindex="-1" role="dialog" aria-labelledby="ConfirmDeleteLabel{{ document.id }}" aria-hidden="true">
|
|
|
- <div class="modal-dialog" role="document">
|
|
|
- <div class="modal-content">
|
|
|
- <div class="modal-header">
|
|
|
- <h5 class="modal-title" id="ConfirmDeleteLabel">Conferma Cancellazione</h5>
|
|
|
- <button type="button" class="close" data-bs-dismiss="modal" aria-label="Close">
|
|
|
- <span aria-hidden="true">×</span>
|
|
|
- </button>
|
|
|
+ <div class="modal fade" id="ConfirmDeleteModal{{ documento.id }}" tabindex="-1" role="dialog" aria-labelledby="ConfirmDeleteLabel{{ document.id }}" aria-hidden="true">
|
|
|
+ <div class="modal-dialog" role="document">
|
|
|
+ <div class="modal-content">
|
|
|
+ <div class="modal-header">
|
|
|
+ <h5 class="modal-title" id="ConfirmDeleteLabel">Conferma Cancellazione</h5>
|
|
|
+ <button type="button" class="close" data-bs-dismiss="modal" aria-label="Close">
|
|
|
+ <span aria-hidden="true">×</span>
|
|
|
+ </button>
|
|
|
+ </div>
|
|
|
+ <div class="modal-body">
|
|
|
+ Confermi la cancellazione di {{ documento.documento }}?<br>
|
|
|
+ La cancellazione del documento è definitiva,immediata e non recuperabile.
|
|
|
</div>
|
|
|
- <div class="modal-body">
|
|
|
- Confermi la cancellazione di {{ documento.documento }}?<br>
|
|
|
- La cancellazione del documento è definitiva,immediata e non recuperabile.
|
|
|
- </div>
|
|
|
- <div class="modal-footer">
|
|
|
- <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
|
|
|
- <form name='ConfirmDeleteModal' method='POST'>
|
|
|
- {% csrf_token %}
|
|
|
- <button type="submit" name="DeleteDocument" value='{{ documento.id }}' class="btn btn-primary">Conferma</button>
|
|
|
- </form>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <!-- end modal -->
|
|
|
-
|
|
|
- {% endfor %}
|
|
|
- </tbody>
|
|
|
- </table>
|
|
|
-
|
|
|
- <form name='fileManager' method="POST" enctype='multipart/form-data'>
|
|
|
- {% csrf_token %}
|
|
|
- <td><label for='descrizione'>Descrizione: </label><input type='text' name='descrizione' id='descrizione' value=''>
|
|
|
- <td><input type='file' class="btn btn-primary" name='allegati' id='allegati' value='{{ uf.allegati }}' accept='application/pdf' multiple></td>
|
|
|
- <td><input class="btn btn-primary" type='submit' value='Inserisci'><td>
|
|
|
- </form>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div><br><br></div>
|
|
|
-
|
|
|
-
|
|
|
- {% if listaok %}
|
|
|
- <table class='table table-striped table-hover'>
|
|
|
- <thead class='thead-dark'>
|
|
|
- <tr>
|
|
|
- <th scope='col'>Documento caricato con successo</th>
|
|
|
- </tr>
|
|
|
- </thead>
|
|
|
- <tbody>
|
|
|
- {% for l in listaok %}
|
|
|
- <tr>
|
|
|
- <td> {{ l }} </td>
|
|
|
+ <div class="modal-footer">
|
|
|
+ <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
|
|
|
+ <form name='ConfirmDeleteModal' method='POST'>
|
|
|
+ {% csrf_token %}
|
|
|
+ <button type="submit" name="DeleteDocument" value='{{ documento.id }}' class="btn btn-primary">Conferma</button>
|
|
|
+ </form>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <!-- end modal -->
|
|
|
+ </td>
|
|
|
</tr>
|
|
|
- {% endfor %}
|
|
|
- </tbody>
|
|
|
+ {% endfor %}
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+
|
|
|
+ <form name='fileManager' method="POST" enctype='multipart/form-data'>
|
|
|
+ {% csrf_token %}
|
|
|
+ <td><label for='descrizione'>Descrizione: </label><input type='text' name='descrizione' id='descrizione' value=''>
|
|
|
+ <td><input type='file' class="btn btn-primary" name='allegati' id='allegati' value='{{ uf.allegati }}' accept='application/pdf' multiple></td>
|
|
|
+ <td><input class="btn btn-primary" type='submit' value='Inserisci'><td>
|
|
|
+ </form>
|
|
|
+
|
|
|
+ <div><br><br></div>
|
|
|
+
|
|
|
+ {% if listaok %}
|
|
|
+ <table class='table table-striped table-hover'>
|
|
|
+ <thead class='thead-dark'>
|
|
|
+ <tr>
|
|
|
+ <th scope='col'>Documento caricato con successo</th>
|
|
|
+ </tr>
|
|
|
+ </thead>
|
|
|
+ <tbody>
|
|
|
+ {% for l in listaok %}
|
|
|
+ <tr>
|
|
|
+ <td> {{ l }} </td>
|
|
|
+ </tr>
|
|
|
+ {% endfor %}
|
|
|
+ </tbody>
|
|
|
</table>
|
|
|
{% endif %}
|
|
|
|
|
|
@@ -170,36 +191,43 @@
|
|
|
</tbody>
|
|
|
</table>
|
|
|
{% endif %}
|
|
|
+
|
|
|
+ </div>
|
|
|
|
|
|
+ <div class="tab-pane" id="profile" role="tabpanel" aria-labelledby="profile-tab" tabindex="0">
|
|
|
|
|
|
- <div><br><br></div>
|
|
|
+ <div><br><br></div>
|
|
|
|
|
|
- <div class='form-outline mb-3 text-center btn-primary h3'>
|
|
|
- Elenco Azioni Registrate
|
|
|
- </div>
|
|
|
- <div>
|
|
|
- <table class='table table-striped table-hover'>
|
|
|
- <thead class='thead-dark'>
|
|
|
- <tr>
|
|
|
- <th scope='col'>Data</th>
|
|
|
- <th scope='col'>Causale</th>
|
|
|
- <th scope='col'>Utente</th>
|
|
|
- <th scope='col'>Amministratore</th>
|
|
|
- <th scope='col'>documento</th>
|
|
|
+ <div class='form-outline mb-3 text-center btn-primary h3'>
|
|
|
+ Elenco Azioni Registrate
|
|
|
+ </div>
|
|
|
|
|
|
- </tr>
|
|
|
+ <div>
|
|
|
+ <table class='table table-striped table-hover'>
|
|
|
+ <thead class='thead-dark'>
|
|
|
+ <tr>
|
|
|
+ <th scope='col'>Data</th>
|
|
|
+ <th scope='col'>Causale</th>
|
|
|
+ <th scope='col'>Utente</th>
|
|
|
+ <th scope='col'>Amministratore</th>
|
|
|
+ <th scope='col'>documento</th>
|
|
|
+ </tr>
|
|
|
</thead>
|
|
|
<tbody>
|
|
|
- {% for attivita in listaAttivita %}
|
|
|
- <tr>
|
|
|
- <td> {{ attivita.data | date:'d/m/Y H:i' }} </td>
|
|
|
- <td> {{ attivita.causale.nome }} </td>
|
|
|
- <td> {{ attivita.utente.nome }} </td>
|
|
|
- <td> {{ attivita.amministratore.name }}</td>
|
|
|
- <td> {{ attivita.documento.documento }}</td>
|
|
|
- </tr>
|
|
|
- {% endfor %}
|
|
|
- </tbody>
|
|
|
- </table>
|
|
|
- </div>
|
|
|
+ {% for attivita in listaAttivita %}
|
|
|
+ <tr>
|
|
|
+ <td> {{ attivita.data | date:'d/m/Y H:i' }} </td>
|
|
|
+ <td> {{ attivita.causale.nome }} </td>
|
|
|
+ <td> {{ attivita.utente.nome }} </td>
|
|
|
+ <td> {{ attivita.amministratore.name }}</td>
|
|
|
+ <td> {{ attivita.documento.documento }}</td>
|
|
|
+ </tr>
|
|
|
+ {% endfor %}
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+ </div>
|
|
|
+</div>
|
|
|
+{% endblock %}
|
|
|
+
|
|
|
+{% block bodybottom %}
|
|
|
{% endblock %}
|